1 # Process this file with autoconf to produce a configure script
3 AM_INIT_AUTOMAKE([opkg], [0.99.163])
4 AM_CONFIG_HEADER(config.h)
9 for top_builddir in . .. ../.. $ac_auxdir $ac_auxdir/..; do
10 test -f $top_builddir/configure && break
22 # Checks for libraries (hah! opkg is pretty much self-contained)
23 PKG_CHECK_MODULES(CURL, libcurl)
25 # Checks for header files
29 AC_CHECK_HEADERS([errno.h fcntl.h memory.h regex.h stddef.h stdlib.h string.h strings.h unistd.h utime.h])
31 # Checks for typedefs, structures, and compiler characteristics.
38 AC_CHECK_MEMBERS([struct stat.st_rdev])
40 # Don't do annoying tests that don't work when cross-compiling, just trust them.
41 # The AC_FUNC_MEMCMP test doesn't work during a cross-compile, disable.
43 # The AC_FUNC_STAT test doesn't work during a cross-compile, disable.
46 # Checks for library functions
52 AC_CHECK_FUNCS([memmove memset mkdir regcomp strchr strcspn strdup strerror strndup strrchr strstr strtol strtoul sysinfo utime])
55 AC_ARG_WITH(opkglibdir,
56 [ --with-opkglibdir=DIR specifies directory to put status and info files.
57 "/opkg" is always added so if you want your files
58 to be in /usr/lib/opkg you should indicate
59 --with-opkglibdir=/usr/lib ],
61 yes) AC_MSG_ERROR(bad value ${withval} given for opkg libs directories ) ;;
63 *) opkglibdir=$with_opkglibdir ;;
66 # Default local prefix if it is empty
67 if test x$opkglibdir = x; then
73 AC_OUTPUT(Makefile etc/Makefile familiar/Makefile familiar/control familiar/control-unstripped familiar/libopkg-control familiar/libopkg-dev-control libbb/Makefile libopkg.pc opkg.h)