Repository navigation
Conversation
Updated sed expression to escape hash character for compatibility across versions of GNU make.
| # The following line determines for the Makefile what languages should be addressed. | ||
| # Edit the file po4a.cfg in this source tree to adjust. | ||
| LANGUAGES := $(strip $(shell sed -e's/#.*//' < $(DOC_DIR)/po4a.cfg | grep '^\[po4a_langs\]' | cut -d" " -f2-)) | ||
| # The escape of the hash in the sed expression prevents an interpretation as a comment by some versions of GNU make. |
There was a problem hiding this comment.
I personally ran into this on macOS 27.0.1 with Apple's version of GNU make 3.81:
$ make --version
GNU Make 3.81
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
This program built for i386-apple-darwin11.3.0
I presume this was shipping with Xcode. Weird that this is still the x86 variant. Anyway.
The version shipping with brew did not have that problem.
$ /opt/homebrew/bin/gmake --version
GNU Make 4.4.1
Built for aarch64-apple-darwin27.0.0
Copyright (C) 1988-2023 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <https://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
There was a problem hiding this comment.
On a meta-level, I am trying to find a way to contribute from where my current routine is residing, and this is on a mac. I do not expect the mac to start controlling any serious hardware in real-time, but I do expect it to be capable to communicate with LinuxCNC controllers. So, I now just want to see how far the current code base carries me. And if there are any low-hanging fruits the improve the compatibility of LinuxCNC then I hope to address these before the release branches.
Updated sed expression to escape hash character for compatibility across versions of GNU make.
It is not necessarily the LANGUAGES assignment per se but the combination with then following echo in the line below.
It is not observed for all versions of Make as it seems. The stable branch does not have this sed expression.