Open duthils opened 1 year ago
Is this safe with different build dirs?
No, you're right, the following example scenario does not work:
mkdir build
cd build
../configure --with-examples --with-drill
make -j1
I'll look for a better fix.
I updated the branch with a different fix that works with different build directories than .
.
Why:
.o
file alone will compile with-c file.c
.lo
file alone will create the corresponding .o files with-c ./file.c
make -j1
will only execute the.lo
rules; the.o
rules will be skipped since the.o
files are already created from the.lo
rules with option-c ./file.c
make -j2
will execute the.lo
rules and the.o
rules in parallel, creating the.o
file with option-c file.c
assert()
captures the path of the source file (taken from the-c
option) in the compiled binary in order to display the source of the assertion errorExample:
examples/ldns-dane
withmake -j1
, the binary contains the string./examples/ldns-dane.c
examples/ldns-dane
withmake -j2
, the binary contains the stringexamples/ldns-dane.c