File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -155,7 +155,7 @@ else ifneq ($(HAVE_RULES),)
155155 $(error invalid HAVE_RULES value '$(HAVE_RULES)')
156156endif
157157
158- HAVE_EXECINFO_H =$(shell ( echo " #include <execinfo.h>") | $(CXX ) -c -xc - 2> /dev/null && echo "1" || echo "0")
158+ HAVE_EXECINFO_H =$(shell echo -e "\x23 #include <execinfo.h>" | $(CXX ) -c -xc - 2> /dev/null && echo "1" || echo "0")
159159override CPPFLAGS += -DHAVE_EXECINFO_H=$(HAVE_EXECINFO_H )
160160
161161override CXXFLAGS += $(CXXOPTS )
Original file line number Diff line number Diff line change @@ -771,8 +771,9 @@ int main(int argc, char **argv)
771771 << " $(error invalid HAVE_RULES value '$(HAVE_RULES)')\n "
772772 << " endif\n\n " ;
773773
774- // the # needs to be escaped on older make versions
775- fout << " HAVE_EXECINFO_H=$(shell echo \" #include <execinfo.h>\" | $(CXX) -c -xc - 2> /dev/null && echo \" 1\" || echo \" 0\" )\n "
774+ // older make versions require the # to be escaped.
775+ // the # needs to be specified as hex because newer make version use it verbatim and thus break this command.
776+ fout << " HAVE_EXECINFO_H=$(shell echo -e \"\\ x23#include <execinfo.h>\" | $(CXX) -c -xc - 2> /dev/null && echo \" 1\" || echo \" 0\" )\n "
776777 << " override CPPFLAGS += -DHAVE_EXECINFO_H=$(HAVE_EXECINFO_H)\n\n " ;
777778
778779 fout << " override CXXFLAGS += $(CXXOPTS)\n " ;
You can’t perform that action at this time.
0 commit comments