diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2021-01-04 19:53:23 -0800 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2021-01-04 19:53:23 -0800 |
commit | 8a2a1aa2b580a7765a392989b6b1f3f01dd116f9 (patch) | |
tree | 0ef20620545e8d56e82047e727d9b6bd64198ded | |
parent | cb2198c275c497698b489f7bbeb98aff550ef007 (diff) | |
download | txr-8a2a1aa2b580a7765a392989b6b1f3f01dd116f9.tar.gz txr-8a2a1aa2b580a7765a392989b6b1f3f01dd116f9.tar.bz2 txr-8a2a1aa2b580a7765a392989b6b1f3f01dd116f9.zip |
configure: tweak test for inline.
It seems that the Brew people are running into a problem. The
configure test is detecting that "inline" can be used for
declaring inline functions, but then some functions are not
inlined, requiring an external definition.
On GNU/Linuxes, we detect "static inline", so this doesn't
reproduce.
This is likely triggered by the recent change to compile as
C99 (unless configuring in maintainer mode).
* configure: Let's revise the set of possible definitions of
INLINE that we try. Firstly, we only try "inline" if we are
compiling as C++. If that fails, all the other forms of inline
we try include "static". Let's not mess with anything involving
"extern". Like a bare "inline", it might work in the test
program but cause some sort of failure.
-rwxr-xr-x | configure | 5 |
1 files changed, 2 insertions, 3 deletions
@@ -1528,9 +1528,8 @@ printf "Checking how to declare inline functions ... " if [ -z "$inline" ] ; then for inline in \ - "inline" "static inline" "extern inline" \ - "__inline__" "static __inline__" "extern __inline__" \ - "static" + "${cplusplus:+inline}" "static inline" \ + "static __inline__" "static" do cat > conftest1.c <<! $inline int func(void) |