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 | a0d571e13457fcad7d43b480e354df08d49a1c89 (patch) | |
tree | 0ef20620545e8d56e82047e727d9b6bd64198ded /configure | |
parent | df9904609a72052b1014f48e4de8fa1baa74fc94 (diff) | |
download | txr-a0d571e13457fcad7d43b480e354df08d49a1c89.tar.gz txr-a0d571e13457fcad7d43b480e354df08d49a1c89.tar.bz2 txr-a0d571e13457fcad7d43b480e354df08d49a1c89.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.
Diffstat (limited to 'configure')
-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) |