u6a/configure.ac

51 lines
1.3 KiB
Plaintext
Raw Normal View History

2020-01-30 10:11:10 +00:00
AC_PREREQ([2.69])
2020-02-02 17:09:21 +00:00
AC_INIT([u6a], [0.01], [bug-report@cismon.net])
2020-01-30 10:11:10 +00:00
AM_INIT_AUTOMAKE([foreign])
AC_CONFIG_SRCDIR([src/u6a.c])
AC_CONFIG_HEADERS([config.h])
AC_CONFIG_FILES([Makefile src/Makefile man/Makefile])
2020-02-02 17:09:21 +00:00
dnl Check for operating system
AC_CANONICAL_HOST
case "${host_os}" in
linux*)
2020-02-08 16:51:31 +00:00
AC_SUBST([MANPATH_CONF], [/etc/manpath.config])
2020-02-02 17:09:21 +00:00
AC_SUBST([REBUILD_MANDB], [mandb])
AC_SUBST([BASE64_ENCODE], [-w0])
AC_SUBST([BASE64_DECODE], [-d])
2020-02-02 17:09:21 +00:00
;;
darwin*)
2020-02-08 16:51:31 +00:00
AC_SUBST([MANPATH_CONF], [/private/etc/man.conf])
2020-02-02 17:09:21 +00:00
AC_SUBST([REBUILD_MANDB], [/usr/libexec/makewhatis])
AC_SUBST([BASE64_ENCODE], [-b0])
AC_SUBST([BASE64_DECODE], [-D])
2020-02-02 17:09:21 +00:00
;;
*)
AC_MSG_ERROR(["Unsupported OS: ${host_os}"])
;;
esac
2020-01-30 10:11:10 +00:00
dnl Checks for programs.
2020-06-05 08:54:30 +00:00
AC_PROG_CC_STDC
2020-01-30 10:11:10 +00:00
dnl Checks for header files.
AC_CHECK_HEADERS([arpa/inet.h inttypes.h stddef.h stdint.h stdlib.h string.h unistd.h],
[],
2020-02-02 17:09:21 +00:00
[AC_MSG_ERROR(["required header(s) not found"])])
2020-01-30 10:11:10 +00:00
dnl Checks for typedefs, structures, and compiler characteristics.
AC_CHECK_HEADER_STDBOOL
AC_C_INLINE
AC_C_RESTRICT
AC_TYPE_UINT16_T
AC_TYPE_UINT32_T
AC_TYPE_UINT8_T
AC_TYPE_SIZE_T
dnl Checks for library functions.
AC_FUNC_MALLOC
AC_FUNC_REALLOC
AC_CHECK_FUNCS([getopt_long strtoul])
AC_OUTPUT