1 ###############################################################################
3 # Pakfire - The IPFire package management system #
4 # Copyright (C) 2017 Pakfire development team #
6 # This program is free software: you can redistribute it and/or modify #
7 # it under the terms of the GNU General Public License as published by #
8 # the Free Software Foundation, either version 3 of the License, or #
9 # (at your option) any later version. #
11 # This program is distributed in the hope that it will be useful, #
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of #
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
14 # GNU General Public License for more details. #
16 # You should have received a copy of the GNU General Public License #
17 # along with this program. If not, see <http://www.gnu.org/licenses/>. #
19 ###############################################################################
23 AC_INIT([pakfire-build-service],
26 [pakfire-build-service],
27 [https://git.ipfire.org/?p=pbs.git;a=summary])
29 AC_CONFIG_MACRO_DIR([m4])
30 AC_CONFIG_AUX_DIR([build-aux])
32 AC_PREFIX_DEFAULT([/usr])
43 AM_SILENT_RULES([yes])
45 IT_PROG_INTLTOOL([0.40.0])
47 XGETTEXT="${XGETTEXT} --keyword=_:1,2 --keyword=N_:1,2 --no-location"
49 GETTEXT_PACKAGE=pakfire-build-service
50 AC_SUBST(GETTEXT_PACKAGE)
59 # pygmentize (from pygments)
60 AC_CHECK_PROG(PYGMENTIZE, [pygmentize], [pygmentize])
61 if test -z "${PYGMENTIZE}"; then
62 AC_MSG_ERROR([pygmentize is required])
66 AC_CHECK_PROG(SASSC, [sassc], [sassc])
67 if test -z "${SASSC}"; then
68 AC_MSG_ERROR([sassc is required])
72 AC_CHECK_PROG(UGLIFYJS, [uglifyjs], [uglifyjs])
73 if test -z "${UGLIFYJS}"; then
74 AC_MSG_ERROR([uglifyjs is required])
81 # This makes sure pkg.m4 is available.
82 m4_pattern_forbid([^_?PKG_[A-Z_]+$],[*** pkg.m4 missing, please install pkg-config])
84 # ------------------------------------------------------------------------------
86 AX_PYTHON_MODULE([boto3], [fatal])
87 AX_PYTHON_MODULE([kerberos], [fatal])
88 AX_PYTHON_MODULE([location], [fatal])
89 AX_PYTHON_MODULE([markdown], [fatal])
90 AX_PYTHON_MODULE([psycopg], [fatal])
91 AX_PYTHON_MODULE([pygments], [fatal])
92 AX_PYTHON_MODULE([systemd.journal], [fatal])
94 # ------------------------------------------------------------------------------
96 AC_ARG_WITH([systemd],
97 AS_HELP_STRING([--with-systemd], [Enable systemd support.])
100 AS_IF([test "x$with_systemd" != "xno"],
101 [PKG_CHECK_MODULES(systemd, [libsystemd],
102 [have_systemd=yes], [have_systemd=no])],
106 AS_IF([test "x$have_systemd" = "xyes"],
107 [AC_MSG_CHECKING([for systemd system unit directory])
108 AC_ARG_WITH([systemdsystemunitdir],
109 AS_HELP_STRING([--with-systemdsystemunitdir=DIR], [Directory for systemd service files]),
110 [], [with_systemdsystemunitdir=$($PKG_CONFIG --variable=systemdsystemunitdir systemd)]
113 AC_SUBST([systemdsystemunitdir], [$with_systemdsystemunitdir])
115 if test -n "$systemdsystemunitdir" -a "x$systemdsystemunitdir" != xno; then
116 AC_MSG_RESULT([$systemdsystemunitdir])
118 AC_MSG_ERROR([not found (try --with-systemdsystemunitdir)])
121 [AS_IF([test "x$with_systemd" = "xyes"],
122 [AC_MSG_ERROR([Systemd support is enabled but no systemd has been found.])
126 AM_CONDITIONAL(HAVE_SYSTEMD, [test "x$have_systemd" = "xyes"])
128 # ------------------------------------------------------------------------------
130 datadir="${datadir}/pakfire-build-service"
131 localedir="${datadir}/translations"
136 src/buildservice/__version__.py
141 ${PACKAGE_NAME} ${VERSION}
144 sysconfdir: ${sysconfdir}
146 Systemd support ${have_systemd}