Skip to content

Commit

Permalink
Fix more problems with chpl-env-gen.h
Browse files Browse the repository at this point in the history
Follow-up to commit Avoid problems with + in chpl-env-gen.h
Replace . with _ and don't make defines for CHPL_*_CC / CHPL_*_CXX

---
Signed-off-by: Michael Ferguson <mppf@users.noreply.github.com>
  • Loading branch information
mppf committed Jun 17, 2021
1 parent e268214 commit 8b73d85
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions runtime/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,11 @@ $(CHPL_ENV_HEADER): $(CHPL_MAKE_HOME)/util/printchplenv $(CHPL_MAKE_HOME)/util/c
@echo "#ifndef _CHPL_ENV_GEN_H_" >> $(CHPL_ENV_HEADER)
@echo "#define _CHPL_ENV_GEN_H_" >> $(CHPL_ENV_HEADER)
@$(CHPL_MAKE_HOME)/util/printchplenv --runtime --no-tidy --anonymize --simple | \
grep -v _COMMAND_ | \
sed s/[-+\/]/_/g | \
grep -v CHPL_HOST_CC | \
grep -v CHPL_HOST_CXX | \
grep -v CHPL_TARGET_CC | \
grep -v CHPL_TARGET_CXX | \
sed s/[-+.\/]/_/g | \
sed s/\=/' '/ | \
awk '{ print "#define " $$1 "_" toupper($$2) }' >> $(CHPL_ENV_HEADER)
@echo "#endif /* _CHPL_ENV_GEN_H_ */" >> $(CHPL_ENV_HEADER)
Expand Down

0 comments on commit 8b73d85

Please sign in to comment.