rmyorston / pdpmake

Public domain POSIX make
https://frippery.org/make
Other
103 stars 10 forks source link

Unable to process the makefile generated by BSDBuild #47

Closed ghost closed 1 month ago

ghost commented 1 month ago

I'm testing this project: https://github.com/JulNadeauCA/libagar

./configure && make depend all

The error message:

$ make depend all
==> core
make: (makefile:20): command not allowed here
make: (./mk/build.subd▒:215): failed to build 'depend-subdir' exit 1

I'm using MSYS2 UCRT64.

rmyorston commented 1 month ago

Works for me on Fedora Linux. What is there around line 20 of the makefile for core?

ghost commented 1 month ago

After I updated to the latest code of you, the error message is more clear:

$ make
==> core
make: (makefile:20): command not allowed here
make: (if [ "${CLEANFILES}" != "" ]; then \
        echo "rm -f ${CLEANFILES}"; \
        rm -f ${CLEANFILES}; \
fi:45): failed to build 'all-subdir' exit 1
ghost commented 1 month ago

Works for me on Fedora Linux. What is there around line 20 of the makefile for core?

There is nothing interesting. BSDBuild is a collection of makefiles. The line number reported doesn't mean much because everything will be preprocessed. I tried to do a grep of if [ "${CLEANFILES}" != "" ]; and all instances of it are in the makefiles in the mk directory.

rmyorston commented 1 month ago

the error message is more clear

Um, not really. Those error messages are supposed to give the name of the Makefile. How on earth does the second one think an if statement is the name of a Makefile?

rmyorston commented 1 month ago

Commit 0e593f0575fb0feff25d1f85698bc3bb09a61d79 seems to fix this issue as well.