While creating a Homebrew formula for YAEP, I noticed that building the software in parallel fails sometimes.
Steps to Reproduce
mkdir build
cd build
# I use Ninja (https://ninja-build.org) below, since it seems to
# fail consistently (unlike e.g. `make` using the switch `-j9`,
# which only fails sometimes).
cmake -GNinja ..
ninja
Expected Result
The build system creates the library without any problems.
Actual Result
Ninja prints the following error message:
[12/211] Building C object src/CMakeFiles/yaep_test.dir/yaep.c.o
FAILED: src/CMakeFiles/yaep_test.dir/yaep.c.o
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc -Isrc -DYAEP_TEST -DYAEP_DEBUG -std=gnu90 -MD -MT src/CMakeFiles/yaep_test.dir/yaep.c.o -MF src/CMakeFiles/yaep_test.dir/yaep.c.o.d -o src/CMakeFiles/yaep_test.dir/yaep.c.o -c ../src/yaep.c
../src/yaep.c:3497:10: fatal error: 'sgramm.c' file not found
#include "sgramm.c"
^~~~~~~~~~
1 error generated.
[16/211] Building CXX object src/CMakeFiles/yaep++_test.dir/yaep.cpp.o
FAILED: src/CMakeFiles/yaep++_test.dir/yaep.cpp.o
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++ -Isrc -DYAEP_TEST -DYAEP_DEBUG -std=gnu++11 -MD -MT src/CMakeFiles/yaep++_test.dir/yaep.cpp.o -MF src/CMakeFiles/yaep++_test.dir/yaep.cpp.o.d -o src/CMakeFiles/yaep++_test.dir/yaep.cpp.o -c ../src/yaep.cpp
In file included from ../src/yaep.cpp:61:
In file included from ../src/yaep.c:3497:
build/src/sgramm.c:398:2: error: unterminated conditional directive
#if (! defined yyoverflow \
^
../src/yaep.cpp:99:10: error: use of undeclared identifier 'yaep_parse_grammar'
return yaep_parse_grammar (this->grammar, strict_p, description);
^
2 errors generated.
[18/211] [BISON][bison_ansic] Building parser with bison 3.2.2
ansic.y: warning: 1 shift/reduce conflict [-Wconflicts-sr]
ninja: build stopped: subcommand failed.
Issue Description
While creating a Homebrew formula for YAEP, I noticed that building the software in parallel fails sometimes.
Steps to Reproduce
Expected Result
The build system creates the library without any problems.
Actual Result
Ninja prints the following error message:
.
Additional Information
10.14.1
3.13.1