Commit Graph

2641 Commits

Author SHA1 Message Date
Nico Weber
1c34a1517e
Merge pull request #1496 from mathstuf/minor-fixes
Minor fixes
2018-11-15 14:36:09 -05:00
Jan Niklas Hasse
f95f51bc6e
Merge pull request #1196 from danw/ReadFile_opt
Optimize ReadFile allocations
2018-11-14 17:50:40 +01:00
Jan Niklas Hasse
a63fb13322 Improve error message when Python wasn't found for the browse tool
See #1306.
2018-11-14 16:57:12 +01:00
Jan Niklas Hasse
2108bb3103 Explain why there's no browse tool, fix #1478 2018-11-14 16:39:14 +01:00
Ben Boeckel
70017a9def HACKING: use Python for the project 2018-11-14 09:55:00 -05:00
Ben Boeckel
4fd00f2681 HACKING: fix some whitespace nits 2018-11-14 09:54:43 -05:00
Jan Niklas Hasse
65f5d9633b Fix rendering of code block, fix #955 2018-11-14 15:09:19 +01:00
Martell Malone
378486ba6e Make -j 0 run unlimited parallel builds, fix #1309 2018-11-14 13:46:53 +01:00
GoaLitiuM
1b8ab152ea Enable ANSI escape sequences on Windows 10 terminals 2018-11-14 11:00:45 +02:00
Jan Niklas Hasse
a65f0d42dc
Merge pull request #1264 from gahr/DirName-compile-time
DirName's separators and their length are known at compile time
2018-11-13 17:14:06 +01:00
Jan Niklas Hasse
bf7517505a Add --verbose as an alternative spelling for -v, fix #1310 2018-11-13 16:56:22 +01:00
Jan Niklas Hasse
d3ea98a8c3 Add unit test for #1491 2018-11-13 15:17:43 +01:00
Jan Niklas Hasse
16e3a45b87
Merge pull request #1491 from mathstuf/elision-off-by-n
util: don't add ellipses width when deciding if they're necessary
2018-11-13 15:17:00 +01:00
Jan Niklas Hasse
bf7107bb86 Allow disabling of escape code stripping, fix #1475
Don't strip colors when CLICOLOR_FORCE is set to a non-zero value. This
environment variable is also used by CMake's Make back-end.
2018-11-13 15:15:43 +01:00
Ben Boeckel
1463fdc0f7 subprocess-win32: add hint on ERROR_INVALID_PARAMETER
This is generally associated with the command line being too long. Give
a hint to this case in the error message.
2018-11-09 10:51:17 -05:00
Ben Boeckel
e2aa04fdef Win32Fatal: support a "hint" for the error
The callsite might have extra context which is helpful for interpreting
the error message.
2018-11-09 10:51:17 -05:00
Ben Boeckel
6a9411e784 manual: mention the "invalid parameter" case
This happens often enough and the error message is quite unhelpful.
Mention this error explicitly in the documentation.
2018-11-09 10:51:17 -05:00
Ben Boeckel
d81cb42a37 util: don't add ellipses width when deciding if they're necessary
If the string fits, just use it. If we need the ellipses, *then* we need
to compute the width based on that.
2018-11-09 10:47:27 -05:00
Jan Niklas Hasse
99c5c2287b
Merge pull request #1307 from moroten/fix-too-long-path-test-bug
Verify GetFullPathName return value
2018-11-08 15:24:49 +01:00
Fredrik Medley
ef46561561 Verify GetFullPathName return value
GetFullPathName previously failed silently on long path names resulting
in uninitialized path result.

Signed-off-by: Fredrik Medley <fredrik.medley@autoliv.com>
2018-11-08 14:56:52 +01:00
Jan Niklas Hasse
44ed3743af Make output_test.py independent of the environment 2018-11-07 18:20:07 +01:00
Jan Niklas Hasse
0858f2ee48
Merge pull request #1488 from maciej-pawlowski-opera/issue-1227-2
Fix parsing some special chars in depfiles (take 2)
2018-11-07 12:07:35 +01:00
ikifof
0db30f237c Fix older VS compatibility issues and PDB files generation issue. (#1435)
Fixes #1411.
2018-11-07 11:32:29 +01:00
Maciej Pawlowski
3edc4d4110 Fix parsing some special chars in depfiles
This allows paths with "[", "]" and "%" to appear in depfiles.
Previously, only "[" would be handled properly.
Fixes #1227.
2018-11-07 11:22:37 +01:00
Maciej Pawlowski
edb848dd6c Regenerate depfile_parser.cc and lexer.cc with newer re2c 2018-11-07 11:07:29 +01:00
Jan Niklas Hasse
cf51ff558f
Merge pull request #1473 from zdave/query-term-stdout
Query terminal width from STDOUT_FILENO
2018-11-06 00:51:28 +01:00
Jan Niklas Hasse
19c294671c Exclude broken DiskInterfaceTests from MSVC, see #1423 2018-11-05 21:46:34 +01:00
Jan Niklas Hasse
a3f284ac35
Merge pull request #1326 from 0-wiz-0/master
Two fixes for NetBSD
2018-11-05 20:47:30 +01:00
Jan Niklas Hasse
9342a7e5ff
Merge pull request #1457 from V-for-Vasili/AIX-support
Port to AIX platform
2018-11-05 20:07:05 +01:00
Jan Niklas Hasse
3841023a44 Add test for #1418 (edge output should match status) 2018-11-05 18:52:51 +01:00
Jan Niklas Hasse
4baea2b826 Revert "Fix confusing smart console output from concurrent builds"
This reverts commit 52c1d0c8f8.

Fixes #1418.
2018-11-05 18:51:08 +01:00
Jan Niklas Hasse
775c8e89ef Add script to test Ninja's output
First test checks for #1214.
2018-11-05 18:42:31 +01:00
Jan Niklas Hasse
10e66a153d Do not always strip colored output in verbose mode, fix #1214 2018-11-05 16:49:39 +01:00
Jan Niklas Hasse
0eb7199902 Ignore Visual Studio Code project files 2018-11-02 11:01:34 +01:00
Jan Niklas Hasse
d849e8fc85 AppVeyor: Also build with MinGW 2018-11-02 10:46:42 +01:00
Jan Niklas Hasse
f6971c9139
Merge pull request #1472 from Hi-Angel/master
Fix wrong description of script installation
2018-11-02 09:20:28 +01:00
Jan Niklas Hasse
3400ae9f21
Merge pull request #1299 from pcc/fflush
Flush stdout after printing "Cleaning..." message
2018-10-30 11:16:41 +01:00
Andrew Maclean
cadcfc19ba Add more instructions for building ninja in Windows (#1169)
This should clarify that the instructions are for Visual Studio.
It also opens the possibility for others to write similar sections for using gcc/clang in Windows.
2018-10-30 11:12:13 +01:00
Jan Niklas Hasse
f95652d587
Merge pull request #1481 from rickysarraf/fix-testcase-whoami
Fix testcase failure in docker environment
2018-10-29 20:18:50 +01:00
Jan Niklas Hasse
3eb9cd2f88
Merge pull request #1485 from nomis/freebsd-11
Fix compilation on FreeBSD 11.2 (use st_mtim.tv_nsec)
2018-10-29 20:13:17 +01:00
Jan Niklas Hasse
590a0e9768
Merge pull request #1350 from korli/posix_spawn_errno
posix_spawn_* calls don't set errno, use the return value.
2018-10-29 18:31:18 +01:00
Jan Niklas Hasse
812250db0b
Merge pull request #1430 from whereswaldon/patch-1
Fix simple typo in HACKING.md
2018-10-29 17:31:46 +01:00
Simon Arlott
febd3b3761
Fix compilation on FreeBSD 11.2 (use st_mtim.tv_nsec)
./src/disk_interface.cc: In member function 'virtual TimeStamp RealDiskInterface::Stat(const string&, std::__cxx11::string*) const':
./src/disk_interface.cc:216:51: error: 'struct stat' has no member named 'st_mtimensec'; did you mean 'st_mtim'?
   return (int64_t)st.st_mtime * 1000000000LL + st.st_mtimensec;
                                                   ^~~~~~~~~~~~
                                                   st_mtim
2018-10-25 20:50:27 +01:00
Peter Wu
6e30a04bbe browse.py: fix delay with multiple connections
When Firefox opens two TCP connections and sends a request over the
second connection, it is not processed until the first one is closed.
Use a threaded server to solve this issue. Tested with Python 2.7.15 and
3.6.5. (Also tested with 2.6, but that failed due to lack of argparse.)

Link: https://bugs.python.org/issue31639
2018-10-25 13:10:30 +02:00
Nico Weber
fccab7408a
Merge pull request #1417 from stefanb2/topic-silence-gcc-fallthrough-warnings
Silence GCC -Wimplicit-fallthrough warnings
2018-10-24 08:34:43 -07:00
Nico Weber
d2045dedc3
Merge pull request #1467 from cdluminate/master
Misc typo fixes by https://github.com/codespell-project/codespell/
2018-10-24 07:39:42 -07:00
Shoaib Meenai
b8834a2b3d
Change gyp to gn
Chrome has switched from gyp to gn, and Fuschia also uses it now.

Note that the "Chromium Ninja documentation" link is dead, but I'm not sure what to replace it with. The closest I've found is https://chromium.googlesource.com/experimental/chromium/src/+/refs/wip/bajones/webvr/docs/ninja_build.md, but I'm not sure that's the original intended target.
2018-10-19 13:11:49 -07:00
Ritesh Raj Sarraf
74f0355d8a
Replace whoami with a more generic command
In our docker environment, the normal user does not have a name.
This results in the `whoami` command to fail which expects a name to print

Replace `whoami` with `id -u`, which print print the numeric id

I have no name!@7427761b8f4c:/tmp/d$ whoami
whoami: cannot find name for user ID 1000
I have no name!@7427761b8f4c:/tmp/d$ id
uid=1000 gid=0(root) groups=0(root)

Signed-off-by: Ritesh Raj Sarraf <ritesh.sarraf@collabora.com>
2018-10-12 20:56:43 +05:30
David Emett
f56a832844 Query terminal width from STDOUT_FILENO
Rather than 0 (stdin). So it will work even if ninja's stdin isn't connected to
the terminal for whatever reason.
2018-09-29 19:23:13 +01:00
Konstantin Kharlamov
957d1990b6
Fix wrong description of script installation
The described way of installation makes zsh fail with `_arguments:comparguments:325: can only be called from completion function`. Per [zsh documentation](https://github.com/zsh-users/zsh-completions/blob/master/zsh-completions-howto.org#telling-zsh-which-function-to-use-for-completing-a-command) the correct way is to use `$fpath`.
2018-09-28 15:22:46 +03:00