Build failure on macOS 10.15
Russ Allbery
eagle at eyrie.org
Mon Nov 30 18:36:04 UTC 2020
Julien ÉLIE <julien at trigofacile.com> writes:
> Oh, thanks!
> I'm wondering whether RRA_PROG_LD_FLAG should not take 2 arguments into
> account ($1 for CFLAGS, and $2 for LDFLAGS).
> Use case would be to improve the current chek for PIE to:
> RRA_PROG_LD_FLAG([-fPIE], [-pie],
> [CFLAGS="${CFLAGS} -fPIE"
> LDFLAGS="${LDFLAGS} -pie"], [])
> instead of only using RRA_PROG_CC_FLAG, checking that the compiler
> supports -fPIE, and assuming (without testing it) that the linker will
> accept -pie.
Don't you want something like this?
RRA_PROG_CC_FLAG([-fPIE],
[CFLAGS="$CFLAGS -fPIE"
RRA_PROG_LD_FLAG([-pie], [LDFLAGS="$LDFLAGS -pie"])])
I could support checking both at the same time, but I think the above is
equivalent for all systems I'm aware of and makes it fairly clear what's
going on.
--
Russ Allbery (eagle at eyrie.org) <https://www.eyrie.org/~eagle/>
Please send questions to the list rather than mailing me directly.
<https://www.eyrie.org/~eagle/faqs/questions.html> explains why.
More information about the inn-workers
mailing list