diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2022-01-05 08:16:43 -0800 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2022-01-05 08:16:43 -0800 |
commit | 1dc97f25d98178ced9f470550aa202431f87a150 (patch) | |
tree | d433f0b6d7f6e85adab9b7e1199c7de718168a2a /Makefile | |
parent | a042deb42ab0a48cda353b26db2cde8459644e7d (diff) | |
download | txr-1dc97f25d98178ced9f470550aa202431f87a150.tar.gz txr-1dc97f25d98178ced9f470550aa202431f87a150.tar.bz2 txr-1dc97f25d98178ced9f470550aa202431f87a150.zip |
build: support CPPFLAGS.
* Makefile (TXR_CFLAGS): Pull in $(CPPFLAGS) also. It seems
some distros like Gentoo are relying on programs to
interpolate CPPFLAGS, and use this variable for passing
preprocessor-level options like -Dfoo=bar. This is an
incredibly bad, unnecessary idea, but let's play along.
Now because we are merging this into TXR_CFLAGS, it means
that these preprocessor-only flags are used for linking,
when nothing is being preprocessed, which makes no sense.
However, GNU Make's built-in recipe for linking C code seems
to do the same thing.
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -33,8 +33,8 @@ endif VERBOSE := TXR_CFLAGS := -iquote . $(if $(top_srcdir), -iquote $(top_srcdir)) \ - $(LANG_FLAGS) $(DIAG_FLAGS) \ - $(DBG_FLAGS) $(PLATFORM_CFLAGS) $(EXTRA_FLAGS) $(CFLAGS) + $(LANG_FLAGS) $(DIAG_FLAGS) $(DBG_FLAGS) $(PLATFORM_CFLAGS) \ + $(EXTRA_FLAGS) $(CFLAGS) $(CPPFLAGS) TXR_CFLAGS := $(filter-out $(REMOVE_FLAGS),$(TXR_CFLAGS)) TXR_LDFLAGS := $(CONF_LDFLAGS) $(PLATFORM_LDFLAGS) $(EXTRA_LDFLAGS) $(LDFLAGS) TXR_LDLIBS := -lm $(CONF_LDLIBS) $(PLAFORM_LDLIBS) $(EXTRA_LDLIBS) $(LDLIBS) |