You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While compiling fish for Windows (32-bit version on 64-bit OS), I had a problem that fish refused to be compiled. This is caused by following code in configure.
## If we are compiling against glibc, set some flags to work around# some rather stupid attempts to hide prototypes for *wprintf# functions, as well as prototypes of various gnu extensions.#
{ $as_echo"$as_me:${as_lineno-$LINENO}: checking if we are compiling against glibc">&5$as_echo_n"checking if we are compiling against glibc... ">&6; }
iftest"$cross_compiling" = yes;then:
{ { $as_echo"$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':">&5$as_echo"$as_me: error: in \`$ac_pwd':">&2;}
as_fn_error $?"cannot run test program while cross compilingSee \`config.log' for more details""$LINENO" 5; }
else
cat confdefs.h - <<_ACEOF >conftest.$ac_ext/* end confdefs.h. */ #include <stdlib.h> #ifdef __GLIBC__ #define STATUS 0 #else #define STATUS 1 #endifintmain (){ return STATUS; ; return 0;}_ACEOFif ac_fn_cxx_try_run "$LINENO";then:
glibc=yes
else
glibc=no
fi
rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
conftest.$ac_objext conftest.beam conftest.$ac_extfi
Reacted by Brandon Clifford, Manu and Lukas Martini
@brandon099, Given this issue has been open nearly three years it's going to take someone like yourself who is motivated to make this work for it to be implemented. Pull-requests gladly accepted 😄
Activity
zanchey commentedon Oct 29, 2013
See http://www.gnu.org/savannah-checkouts/gnu/autoconf/manual/autoconf-2.69/html_node/Runtime.html - the configure script uses
AC_RUN_IFELSEin a few places. We would either need to come up with sensible defaults for those clauses for when cross-compiling, or alternatively rewrite them to compile/link only tests.brandon099 commentedon Jul 6, 2016
Trying to CC for an embedded linux project and would love to have fish available. +1
krader1961 commentedon Jul 6, 2016
@brandon099, Given this issue has been open nearly three years it's going to take someone like yourself who is motivated to make this work for it to be implemented. Pull-requests gladly accepted 😄
zanchey commentedon Jul 6, 2016
I had a bit of a look, and there's a simple change and a complex one.
The simple change is to provide a crosscompilation default for the configure check for
have_realpath_null.The more complex change is to turn the configure-time check for
/proc/self/statinto a runtime check.I managed to successfully crosscompile by just forcing the
/proc/self/statcheck to always fail, but that's obviously not an appropriate solution.Switch to runtime check for /proc/self/stat
Switch to runtime check for /proc/self/stat
zanchey commentedon Apr 29, 2019
have_realpath_nullgot dropped in 7fd3079, so I think it's just the/proc/self/statthat needs to be turned into a runtime check. I'll make a PR.floam commentedon Apr 29, 2019
There are a few platforms where we should nonetheless be able to skip
stating that path.Switch to runtime check for /proc/self/stat
zanchey commentedon Apr 30, 2019
I think this should be possible now, but I'll wait to hear in #5848 before closing.