-
Notifications
You must be signed in to change notification settings - Fork 7
/
configure.ac
98 lines (81 loc) · 2.54 KB
/
configure.ac
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
# Copyright 2016 Artem Savkov <[email protected]>
# Copyright 2017-2019 Alex Schroeder <[email protected]>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
AC_INIT(
[bitlbee-mastodon],
[1.4.5],
[https://github.com/kensanata/bitlbee-mastodon/issues],
[bitlbee-mastodon],
[https://alexschroeder.ch/cgit/bitlbee-mastodon/about/],
)
AC_CONFIG_AUX_DIR([build-aux])
AC_CONFIG_MACRO_DIR([m4])
AM_INIT_AUTOMAKE([no-define])
AC_PROG_CC
AM_PROG_CC_C_O
AC_DISABLE_STATIC
AC_PROG_LIBTOOL
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
m4_ifdef([AC_PROG_CC_C99], [AC_PROG_CC_C99])
# Define PKG_CHECK_VAR() for pkg-config < 0.28
m4_define_default(
[PKG_CHECK_VAR],
[AC_ARG_VAR([$1], [value of $3 for $2, overriding pkg-config])
AS_IF([test -z "$$1"], [$1=`$PKG_CONFIG --variable="$3" "$2"`])
AS_IF([test -n "$$1"], [$4], [$5])]
)
# Checks for libraries.
PKG_CHECK_MODULES([BITLBEE], [bitlbee >= 3.5])
PKG_CHECK_MODULES([GLIB], [glib-2.0 >= 2.32])
AC_CONFIG_HEADERS([config.h])
# Checks for typedefs, structures, and compiler characteristics.
AC_TYPE_SIZE_T
# Checks for library functions.
AC_CHECK_FUNCS([memset])
# bitlbee-specific stuff
AC_ARG_WITH([plugindir],
[AS_HELP_STRING([--with-plugindir], [BitlBee plugin directory])],
[plugindir="$with_plugindir"]
)
AS_IF(
[test -z "$plugindir"],
[PKG_CHECK_VAR(
[BITLBEE_PLUGINDIR],
[bitlbee],
[plugindir],
[plugindir="$BITLBEE_PLUGINDIR"],
[plugindir="$libdir/bitlbee"]
)]
)
AC_SUBST([plugindir])
AC_ARG_WITH([bdatadir],
[AS_HELP_STRING([--with-bdatadir], [BitlBee data directory])],
[bdatadir="$with_bdatadir"]
)
AS_IF(
[test -z "$bdatadir"],
[PKG_CHECK_VAR(
[BITLBEE_DATADIR],
[bitlbee],
[datadir],
[datadir="$BITLBEE_DATADIR"],
[datadir="$datarootdir/bitlbee"]
)],
[datadir="$bdatadir"]
)
AC_SUBST([datadir])
AC_SUBST([ac_cv_path_SED])
AC_CONFIG_FILES([Makefile src/Makefile doc/Makefile])
AC_OUTPUT