configure.ac not correct with test about libm ? (patch included)
Quoted 7 lines · Dieter Bloms
Hi,
I want to compile xen-unstable (last commit 25622:3c426da4788e) on alpinelinux.
During the run of configure there is an error message like:
Quoted 7 lines
"checking for isnan in -lm... no"
I discussed this with the maintainer of the alpinelinux distribution and he told me, that the macro in configure.ac is wrong.
I found out, that isnan is a macro not a function, so we have to use
AC_CHECK_DECLSinstead ofAC_CHECK_LIB.
Is isnan always macro, or just in this particular libc implementation?
Or does AC_CHECK_DECLS work right whether it is a macro or a function?
Quoted 17 lines
So made this little patch to get it work:
--snip--
diff -r3c426da4788etools/configure.actools/configure.ac Mon Jul 23 13:43:16 2012 +0200 renamed from tools/configure.ac Sun Jul 22 16:37:25 2012 +0100 +1
-2@@ -133,7 +133,7 @@ AC_SUBST(zlib) AC_CHECK_LIB([aio], [io_setup], [system_aio="y"], [system_aio="n"]) AC_SUBST(system_aio) -AC_CHECK_LIB([m], [isnan], [], [AC_MSG_ERROR([Could not find libm])]) +AC_CHECK_DECLS([isnan], [], [AC_MSG_ERROR([Could not find libm])], [[#include <math.h>]]) AC_CHECK_LIB([crypto], [MD5], [], [AC_MSG_ERROR([Could not find libcrypto])]) AC_CHECK_LIB([ext2fs], [ext2fs_open2], [libext2fs="y"], [libext2fs="n"]) AC_SUBST(libext2fs) --snip--
Quoted 1 line
maybe someone of the developers is willing to add this little patch.
Please submit patches to xen-devel according to the procedure in
http://wiki.xen.org/wiki/SubmittingXenPatches , I've CC'd it this time for you
In particular it will need a Signed off by line.
Ian.
Quoted 37 lines · Ian Campbell
Quoted 7 lines · Dieter Bloms
Hi,
I want to compile xen-unstable (last commit 25622:3c426da4788e) on alpinelinux.
During the run of configure there is an error message like:
Quoted 7 lines
"checking for isnan in -lm... no"
I discussed this with the maintainer of the alpinelinux distribution and he told me, that the macro in configure.ac is wrong.
I found out, that isnan is a macro not a function, so we have to use
AC_CHECK_DECLSinstead ofAC_CHECK_LIB.Is isnan always macro, or just in this particular libc implementation?
Or does
AC_CHECK_DECLSwork right whether it is a macro or a function?Quoted 17 lines
So made this little patch to get it work:
--snip--
diff -r3c426da4788etools/configure.actools/configure.ac Mon Jul 23 13:43:16 2012 +0200 renamed from tools/configure.ac Sun Jul 22 16:37:25 2012 +0100 +1
-2@@ -133,7 +133,7 @@ AC_SUBST(zlib) AC_CHECK_LIB([aio], [io_setup], [system_aio="y"], [system_aio="n"]) AC_SUBST(system_aio) -AC_CHECK_LIB([m], [isnan], [], [AC_MSG_ERROR([Could not find libm])]) +AC_CHECK_DECLS([isnan], [], [AC_MSG_ERROR([Could not find libm])], [[#include <math.h>]]) AC_CHECK_LIB([crypto], [MD5], [], [AC_MSG_ERROR([Could not find libcrypto])]) AC_CHECK_LIB([ext2fs], [ext2fs_open2], [libext2fs="y"], [libext2fs="n"]) AC_SUBST(libext2fs) --snip--
Quoted 7 lines
Quoted 1 line
maybe someone of the developers is willing to add this little patch.
Please submit patches to xen-devel according to the procedure in
http://wiki.xen.org/wiki/SubmittingXenPatches , I've CC'd it this time for youIn particular it will need a Signed off by line.
Actually don't worry about this -- it turns out we didn't need libm anyway and Dario has posted a patch to remove the check altogether.