2012-07-21 03:36:58 +00:00
|
|
|
dnl configure.ac
|
|
|
|
dnl m4 preprocessor script for autotools
|
|
|
|
dnl
|
2013-12-27 11:44:59 +00:00
|
|
|
dnl Copyright (c) 2011, 2012, 2013, 2014 pkgconf authors (see AUTHORS).
|
2012-07-21 03:36:58 +00:00
|
|
|
dnl
|
|
|
|
dnl Permission to use, copy, modify, and/or distribute this software for any
|
|
|
|
dnl purpose with or without fee is hereby granted, provided that the above
|
|
|
|
dnl copyright notice and this permission notice appear in all copies.
|
|
|
|
dnl
|
|
|
|
dnl This software is provided 'as is' and without any warranty, express or
|
|
|
|
dnl implied. In no event shall the authors be liable for any damages arising
|
|
|
|
dnl from the use of this software.
|
|
|
|
|
2022-06-26 18:58:08 +00:00
|
|
|
AC_PREREQ([2.71])
|
2023-11-22 18:46:19 +00:00
|
|
|
AC_INIT([pkgconf],[2.1.0],[https://github.com/pkgconf/pkgconf/issues/new])
|
2018-02-12 06:46:47 +00:00
|
|
|
AC_CONFIG_SRCDIR([cli/main.c])
|
2020-05-24 20:29:19 +00:00
|
|
|
AC_CONFIG_MACRO_DIR([m4])
|
2017-09-26 17:27:52 +00:00
|
|
|
AX_CHECK_COMPILE_FLAG([-Wall], [CFLAGS="$CFLAGS -Wall"])
|
|
|
|
AX_CHECK_COMPILE_FLAG([-Wextra], [CFLAGS="$CFLAGS -Wextra"])
|
|
|
|
AX_CHECK_COMPILE_FLAG([-Wformat=2], [CFLAGS="$CFLAGS -Wformat=2"])
|
|
|
|
AX_CHECK_COMPILE_FLAG([-std=gnu99], [CFLAGS="$CFLAGS -std=gnu99"], [
|
|
|
|
AX_CHECK_COMPILE_FLAG([-std=c99], [CFLAGS="$CFLAGS -std=c99"])
|
|
|
|
])
|
2015-09-06 14:35:08 +00:00
|
|
|
AC_CONFIG_HEADERS([libpkgconf/config.h])
|
2023-04-24 13:49:33 +00:00
|
|
|
AC_CHECK_DECLS([strlcpy, strlcat, strndup], [], [], [[#include <string.h>]])
|
|
|
|
AC_CHECK_DECLS([reallocarray])
|
2016-12-30 16:26:45 +00:00
|
|
|
AC_CHECK_HEADERS([sys/stat.h])
|
2017-01-25 23:07:10 +00:00
|
|
|
AM_INIT_AUTOMAKE([foreign dist-xz subdir-objects])
|
2016-05-20 02:12:24 +00:00
|
|
|
AM_SILENT_RULES([yes])
|
2015-09-06 14:35:08 +00:00
|
|
|
LT_INIT
|
2011-07-25 02:03:17 +00:00
|
|
|
|
2015-05-22 02:47:50 +00:00
|
|
|
AC_SYS_LARGEFILE
|
2012-07-24 06:48:23 +00:00
|
|
|
|
2022-06-26 18:58:08 +00:00
|
|
|
AC_ARG_WITH([personality-dir],[AS_HELP_STRING([--with-personality-dir],[specify
|
2018-05-10 00:27:53 +00:00
|
|
|
the place where cross-compile personality files will be found])],
|
|
|
|
PERSONALITY_PATH="$withval",
|
2018-05-10 18:36:49 +00:00
|
|
|
PERSONALITY_PATH="${datadir}/pkgconfig/personality.d:${sysconfdir}/pkgconfig/personality.d")
|
2018-05-10 00:27:53 +00:00
|
|
|
|
|
|
|
AC_SUBST([PERSONALITY_PATH])
|
|
|
|
|
2022-06-26 18:58:08 +00:00
|
|
|
AC_ARG_WITH([pkg-config-dir],[AS_HELP_STRING([--with-pkg-config-dir],[specify
|
2017-06-24 17:45:44 +00:00
|
|
|
the place where pc files will be found])],PKG_DEFAULT_PATH="$withval",
|
|
|
|
PKG_DEFAULT_PATH="${libdir}/pkgconfig:${datadir}/pkgconfig")
|
2012-07-24 06:48:23 +00:00
|
|
|
|
2017-06-24 17:45:44 +00:00
|
|
|
AC_SUBST([PKG_DEFAULT_PATH])
|
2012-07-24 06:48:23 +00:00
|
|
|
|
2022-06-26 18:58:08 +00:00
|
|
|
AC_ARG_WITH([system-libdir],[AS_HELP_STRING([--with-system-libdir],[specify the
|
2012-07-24 20:24:52 +00:00
|
|
|
system library directory (default LIBDIR)])],
|
|
|
|
SYSTEM_LIBDIR="$withval", SYSTEM_LIBDIR="${libdir}")
|
|
|
|
|
|
|
|
AC_SUBST([SYSTEM_LIBDIR])
|
|
|
|
|
2022-06-26 18:58:08 +00:00
|
|
|
AC_ARG_WITH([system-includedir],[AS_HELP_STRING([--with-system-includedir],[specify the
|
2012-07-24 20:24:52 +00:00
|
|
|
system include directory (default INCLUDEDIR)])],
|
|
|
|
SYSTEM_INCLUDEDIR="$withval", SYSTEM_INCLUDEDIR="${includedir}")
|
|
|
|
|
|
|
|
AC_SUBST([SYSTEM_INCLUDEDIR])
|
2012-07-24 06:48:23 +00:00
|
|
|
|
2011-07-25 02:03:17 +00:00
|
|
|
AC_PROG_CPP
|
|
|
|
AC_PROG_CC
|
|
|
|
AC_PROG_INSTALL
|
|
|
|
AC_PROG_LN_S
|
|
|
|
|
2016-12-14 07:30:41 +00:00
|
|
|
AC_CONFIG_FILES([Makefile Kyuafile libpkgconf.pc tests/Kyuafile tests/test_env.sh])
|
2011-07-25 02:03:17 +00:00
|
|
|
AC_OUTPUT
|