This is the mail archive of the automake@gnu.org mailing list for the automake project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

AC_CANONICAL_SYSTEM woes


Hi, 

I am quite new with automake, please bear with me ...

o I have a simple configure.in, the first thing I want to do is check
system type, so I called AC_CANONICAL_SYSTEM like the following ...
AC_INIT(something)
AM_INIT_AUTOMAKE(common, 1.1)
AM_CONFIG_HEADER(config.h)

dnl Checks for system type
AC_CANONICAL_SYSTEM

but it always returns "configure.in:9: AC_ARG_PROGRAM was called before
AC_CANONICAL_SYSTEM", have no clue what does it mean?

o A related question is: if I want to deal with some source code with
"#ifdef LINUX...#include..." or "ifdef FREEBSD ...#include ...", and I
want to do run time checking of OS type, then compile it with different
setting, what is the best way? is AC_CANONICAL_SYSTEM the only way?

system info: autoconf 2.13, automake 1.4, Linux 5.1/FreeBSD, source
package is a "deep" one (all source code is in subdir).

Thanks for help

/Feiyi


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]