nss-pam-ldapd icon indicating copy to clipboard operation
nss-pam-ldapd copied to clipboard

build: Fix clang compiliation by decontaminating build environment

Open salahcoronya opened this issue 7 months ago • 0 comments

The statements in configure.ac "pollute" the environmental variables. This causes problem when --enable-warnings is set and clang is the compiler. It only works by accident on gcc because gcc aborts on illegal flags anyway, but clang does not which causes -Werror to get added to the check. One of the warning conflicts with that, causing it to be uncompiliable under clang.

This patch removes the environmental polluation by storing the flags in automake variables. The flags are then added by automake. Also, there already a function in autoconf-archive to determine valid flags, so use that instead of the hand-rolled one.

salahcoronya avatar Jul 07 '24 05:07 salahcoronya