https://bugs.openldap.org/show_bug.cgi?id=9528
Issue ID: 9528 Summary: liblmdb throws away environment CFLAGS Product: LMDB Version: 0.9.29 Hardware: All OS: All Status: UNCONFIRMED Severity: normal Priority: --- Component: liblmdb Assignee: bugs@openldap.org Reporter: quanah@openldap.org Target Milestone: ---
When building LMDB, specified hardening flags are thrown away due to the Makefile overriding CFLAGS:
Makefile:CFLAGS = $(THREADS) $(OPT) $(W) $(XCFLAGS)
https://bugs.openldap.org/show_bug.cgi?id=9528
--- Comment #1 from Howard Chu hyc@openldap.org --- (In reply to Quanah Gibson-Mount from comment #0)
When building LMDB, specified hardening flags are thrown away due to the Makefile overriding CFLAGS:
Makefile:CFLAGS = $(THREADS) $(OPT) $(W) $(XCFLAGS)
Put them in XCFLAGS.
https://bugs.openldap.org/show_bug.cgi?id=9528
--- Comment #2 from Quanah Gibson-Mount quanah@openldap.org --- (In reply to Howard Chu from comment #1)
(In reply to Quanah Gibson-Mount from comment #0)
When building LMDB, specified hardening flags are thrown away due to the Makefile overriding CFLAGS:
Makefile:CFLAGS = $(THREADS) $(OPT) $(W) $(XCFLAGS)
Put them in XCFLAGS.
Seems like things should be the opposite direction, Makefile does XCFLAGS= $(THREADS) $(OPT) $(W) $(CFLAGS) then tweaked accordingly throughout (or similar).
https://bugs.openldap.org/show_bug.cgi?id=9528
--- Comment #3 from Howard Chu hyc@openldap.org --- (In reply to Quanah Gibson-Mount from comment #2)
(In reply to Howard Chu from comment #1)
(In reply to Quanah Gibson-Mount from comment #0)
When building LMDB, specified hardening flags are thrown away due to the Makefile overriding CFLAGS:
Makefile:CFLAGS = $(THREADS) $(OPT) $(W) $(XCFLAGS)
Put them in XCFLAGS.
Seems like things should be the opposite direction, Makefile does XCFLAGS= $(THREADS) $(OPT) $(W) $(CFLAGS) then tweaked accordingly throughout (or similar).
No. CFLAGS contains everything else. Everything else is individually overridable. Manually overriding CFLAGS itself is wrong.