Commit Graph

2780 Commits

Author SHA1 Message Date
Jan Niklas Hasse
a999fdb0d8
Merge pull request #1892 from jhasse/windows-readonly
Delete read-only files on Windows, too
2021-02-10 08:51:56 +01:00
Peter Eszlari
6118f74838 cmake: add_compile_options / PROJECT_SOURCE_DIR 2021-02-09 13:57:23 +01:00
Colin Cross
ad3d29fb53 Put builder output through status interface
Send all output after manifest parsing is finished to the Status
interface, so that when status frontends are added they can handle
build messages.
2021-02-05 12:08:17 -08:00
Nixon Enraght-Moony
942a523a73
Clarify purpose for implicit dependencies 2021-01-29 18:34:58 +00:00
Jan Niklas Hasse
9216c31f29
Merge pull request #1905 from korli/haiku
Add Haiku support.
2021-01-28 23:42:13 +01:00
Augustin Cavalier
fba4f7b1e5 Add Haiku support. 2021-01-28 12:32:47 +01:00
Jan Niklas Hasse
68f09b03c0
Merge pull request #1904 from remexre/master
Adds dyndep support to ninja_syntax.py.
2021-01-13 17:07:49 +01:00
Nathan Ringo
c161199646 Adds dyndep support to ninja_syntax.py. 2021-01-12 10:36:45 -08:00
Jan Niklas Hasse
fb824d27b3
Merge pull request #1674 from cameron314/bugfix/core-count
Fixed processor count detection on Windows
2021-01-01 23:01:23 +01:00
Cameron
4b07ca35eb Added preprocessor if to clarify processor count workaround code is only needed on 32-bit builds (following code review) 2020-12-31 14:45:59 -05:00
Colin Cross
589f5b2497 Turn BuildStatus into an interface
Make BuildStatus an abstract interface, and move the current
implementation to StatusPrinter, to make way for a serialized
Status output.
2020-12-18 12:38:29 -08:00
Colin Cross
045890cee3 Simplify running edges status
Store the number of running edges instead of trying to compute it
from the started and finshed edge counts, which may be different
for starting and ending status messages.  Allows removing the status
parameter to PrintStatus and the EdgeStatus enum.
2020-12-18 12:38:29 -08:00
Colin Cross
dede9ac780 Move edge time from Status to Builder
The times that end up in the build log currently originate in the
status printer, and are propagated back out to the Builder.  Move
the edge times into the Builder instead, and move the overall start
time into NinjaMain so it doesn't get reset during manifest
rebuilds.
2020-12-18 12:38:25 -08:00
Jan Niklas Hasse
68f971460b
Merge pull request #1893 from AdamKorcz/fuzz1
Added fuzzer with build script and seed
2020-12-11 12:08:22 +01:00
Jan Niklas Hasse
91f4a498b2
Merge pull request #1894 from gjasny/modern-add-test-signature
cmake: Use modern add_test signature
2020-12-11 12:06:59 +01:00
Gregor Jasny
721db105e6 cmake: Use modern add_test signature
Using this modern signature makes CMake/CTest use the effective
binary path and works also with multi-config generators which put
binaries in extra `Release` folders.
2020-12-11 08:36:26 +01:00
AdamKorcz
365a149069 Created oss-fuzz folder and moved build.sh and sample ninja file into it 2020-12-10 18:00:26 +00:00
AdamKorcz
9c801316ba Added fuzzer with build script and seed 2020-12-08 20:18:29 +00:00
Jan Niklas Hasse
2d7f7e55c0 Delete read-only files on Windows, too
Fixes main complaint of #1886.
2020-12-07 19:46:10 +01:00
Jan Niklas Hasse
58f77f972b Ignore new clangd cache directory, too 2020-12-06 15:49:29 +01:00
Jan Niklas Hasse
507db2c022
Merge pull request #1791 from neheb/exp
[clang-tidy] add explicit to single argument constructors
2020-12-06 12:15:55 +01:00
Jan Niklas Hasse
e664814b6a
Merge pull request #1790 from neheb/bool
[clang-tidy] simplify boolean expression
2020-12-06 12:15:06 +01:00
Rosen Penev
0351d68f0a
[clang-tidy] add explicit to single argument constructors
Found with google-explicit-constructor

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2020-12-05 22:15:54 -08:00
Rosen Penev
7c36b8871a
[clang-tidy] simplify boolean expression
Found with readability-simplify-boolean-expr

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2020-12-05 15:47:18 -08:00
Jan Niklas Hasse
deb542192b
Merge pull request #1873 from jhasse/remove-travis
Replace Travis CI with GitHub Actions
2020-12-05 23:41:18 +01:00
Jan Niklas Hasse
7705fedfaf
Merge pull request #1876 from orgads/msvc-warnings
Suppress MSVC warnings
2020-12-05 23:41:02 +01:00
Jan Niklas Hasse
160531764c Ignore clangd files 2020-12-04 13:05:25 +01:00
Jan Niklas Hasse
629f926294
Merge pull request #1866 from jhasse/unique-edge-ids
Add unique IDs to edges
2020-12-03 18:37:09 +01:00
Jan Niklas Hasse
7193fb7c1e
Merge pull request #1792 from neheb/dec
[clang-tidy] fix inconsistent declarations
2020-12-03 10:55:34 +01:00
Rosen Penev
76ecd30541
[clang-tidy] fix inconsistent declarations
Found with readability-inconsistent-declaration-parameter-name

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2020-12-02 15:30:15 -08:00
Jan Niklas Hasse
7cff4770b5
Merge pull request #1887 from mjguzik/freebsd_cpuset
Add FreeBSD support to GetProcessorCount
2020-12-01 10:01:37 +01:00
Mateusz Guzik
9d4ea5a8e8 Add FreeBSD support to GetProcessorCount 2020-11-30 23:01:41 +00:00
Jan Niklas Hasse
ed056bdd8c mark this 1.10.2.git 2020-11-28 12:21:05 +01:00
Jan Niklas Hasse
242b7dd900 GitHub Actions: Build Universal Binary for macOS 2020-11-23 17:32:13 +01:00
Jan Niklas Hasse
a30ccaef73
Merge pull request #1879 from kadler/aix-cleanup
Fix building on AIX
2020-11-14 16:03:41 +01:00
Jan Niklas Hasse
a0b56413e4
Merge pull request #1880 from kadler/fix-hash-benchmark
Fix buffer overread in hash_collision_benchmark.cc
2020-11-14 00:31:45 +01:00
Jan Niklas Hasse
a03dd05def
Merge pull request #1878 from hdf89shfdfs/multi_generator_bug
Fix mulit-configuration bug
2020-11-14 00:03:47 +01:00
Kevin Adler
a8ad533289
Fix buffer overread in hash_collision_benchmark.cc
The randomly generated command strings are not null-terminated and
implicitly converted to StringPiece objects, which will use strlen to
determine how long the passed `char*` is. Without the null terminator,
this results in undefined behavior and regularly causes crashes on AIX.
2020-11-13 17:02:55 -06:00
Kevin Adler
92fc37555f
Fix test crashes on AIX
Both hash_collision_bench and manifest_parser_perftest crash on AIX with

terminate called after throwing an instance of 'std::bad_alloc'
  what():  std::bad_alloc
IOT/Abort trap (core dumped)

32-bit AIX applications by default allocates only a single 256M segment
for stack and heap for 32-bit applications, which is insufficient for
these tests. When building these tests on AIX in 32-bit mode, increase
the max number of segments so they will run without crashing.
2020-11-13 15:40:51 -06:00
Kevin Adler
b52970e86b
Add libperfstat to AIX CMake build 2020-11-13 15:40:51 -06:00
Kevin Adler
1cb029b33c
Use internal getopt for IBM i and AIX 2020-11-13 15:40:51 -06:00
hdf89shfdfs
8cf4a393fa Fix mulit-configuration bug. This affected users who use
multi-configuration generators for building ninja.
2020-11-13 07:07:02 -05:00
Orgad Shaneh
d709a37d14 Suppress MSVC warnings
* D9025: overriding '/GR' with '/GR-'
* C4100: 'argc': unreferenced formal parameter
* C4244: '=': conversion from 'int' to 'char', possible loss of data (on tolower)
* C4267: 'initializing': conversion from 'size_t' to 'unsigned int', possible loss of data
* C4702: unreachable code (after Fatal)
* C4706: assignment within conditional expression
* C4996: 'strcpy': This function or variable may be unsafe
2020-11-11 13:52:54 +02:00
Jan Niklas Hasse
3094b5c289
Merge pull request #1787 from neheb/str
[clang-tidy] remove pointless string init
2020-11-10 11:34:44 +00:00
Rosen Penev
9fa3491284
[clang-tidy] remove pointless string init
Found with readability-redundant-string-init

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2020-11-07 12:27:26 -08:00
Jan Niklas Hasse
c09122cc3d Replace Travis CI with GitHub Actions 2020-11-06 19:21:31 +00:00
Jan Niklas Hasse
17bcd4c8d6
Merge pull request #1867 from jhasse/github-actions-docker
GitHub Actions: Run more tests on Ubuntu 20.04 (Docker)
2020-11-06 16:09:25 +01:00
Jan Niklas Hasse
7653ebd059
Merge pull request #1870 from nmulcahey/cmake
cmake: Use ${CMAKE_COMMAND} instead of `cmake`
2020-11-05 09:34:25 +01:00
Nathan Mulcahey
f92b5b61f3 cmake: Use ${CMAKE_COMMAND} instead of cmake
Not all users have `cmake` on their PATH and this causes a build
failure.
2020-11-03 08:41:20 -08:00
Jan Niklas Hasse
e87c49751e
Merge pull request #1868 from kadler/fix-aix-signal-checking
Handle process signalling correctly on AIX
2020-11-02 17:02:59 +01:00