summaryrefslogtreecommitdiff
path: root/configure.ac.in
blob: 20b51062be3e0ddf99e9a8da4d744849c47856c5 (plain)
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
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
dnl vi:set et ai sw=2 sts=2 ts=2: */
dnl
dnl Copyright (c) 2007-2011 Jannis Pohlmann <jannis@xfce.org>
dnl Copyright (c) 2012-2020 The Xfce development team
dnl
dnl This library is free software; you can redistribute it and/or
dnl modify it under the terms of the GNU Library General Public
dnl License as published by the Free Software Foundation; either
dnl version 2 of the License, or (at your option) any later version.
dnl
dnl This library is distributed in the hope that it will be useful,
dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
dnl GNU Library General Public License for more details.
dnl
dnl You should have received a copy of the GNU Library General
dnl Public License along with this library; if not, write to the
dnl Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
dnl Boston, MA 02110-1301, USA.

dnl ***************************
dnl *** Version information ***
dnl ***************************
m4_define([garcon_verinfo], [0:0:0])
m4_define([garcon_version_api_major], [1])
m4_define([garcon_version_major], [4])
m4_define([garcon_version_minor], [16])
m4_define([garcon_version_micro], [1])
m4_define([garcon_version_build], [@REVISION@])
m4_define([garcon_version_tag], [git])
m4_define([garcon_version], [garcon_version_major().garcon_version_minor().garcon_version_micro()ifelse(garcon_version_tag(), [git], [garcon_version_tag()-garcon_version_build()], [garcon_version_tag()])])

dnl ********************************************
dnl *** Full debug support for GIT snapshots ***
dnl ********************************************
m4_define([garcon_debug_default], [ifelse(garcon_version_tag(), [git], [yes], [minimum])])

dnl ****************************
dnl *** For intltool support ***
dnl ****************************
m4_define([intltool_minimum_version], [0.51])

dnl ***************************
dnl *** Initialize autoconf ***
dnl ***************************
AC_COPYRIGHT([Copyright (c) 2007-2011 Jannis Pohlmann <jannis@xfce.org>
Copyright (c) 2012-2020 The Xfce development team
              ])
AC_INIT([garcon], [garcon_version], [https://gitlab.xfce.org/xfce/garcon])
AC_PREREQ([2.69])
AC_CONFIG_MACRO_DIRS([m4])
AC_REVISION([@REVISION@])
AC_CANONICAL_TARGET()

dnl ***************************
dnl *** Initialize automake ***
dnl ***************************
AM_INIT_AUTOMAKE([1.15 dist-bzip2 tar-ustar no-dist-gzip foreign])
AC_CONFIG_HEADERS([config.h])
AM_MAINTAINER_MODE()
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])

dnl **************************
dnl *** Libtool versioning ***
dnl **************************
GARCON_VERINFO=garcon_verinfo()
AC_SUBST([GARCON_VERINFO])

dnl ****************************
dnl *** Subst garcon version ***
dnl ****************************
GARCON_VERSION_MAJOR=garcon_version_major()
GARCON_VERSION_MINOR=garcon_version_minor()
GARCON_VERSION_MICRO=garcon_version_micro()
GARCON_VERSION_API_MAJOR=garcon_version_api_major()
GARCON_VERSION_API=$GARCON_VERSION_API_MAJOR
AC_SUBST([GARCON_VERSION_MAJOR])
AC_SUBST([GARCON_VERSION_MINOR])
AC_SUBST([GARCON_VERSION_MICRO])
AC_SUBST([GARCON_VERSION_API_MAJOR])
AC_SUBST([GARCON_VERSION_API])

dnl ********************************
dnl *** Check for basic programs ***
dnl ********************************
AM_PROG_AS()
AC_PROG_CC()
AC_PROG_INSTALL()
IT_PROG_INTLTOOL([intltool_minimum_version])
AM_PROG_CC_C_O()

dnl **************************
dnl *** Initialize libtool ***
dnl **************************
LT_PREREQ([2.2.6])
LT_INIT([disable-static])

dnl ***************************************
dnl *** Check for standard header files ***
dnl ***************************************
AC_CHECK_HEADERS([fcntl.h errno.h sys/mman.h sys/stat.h sys/wait.h memory.h \
                  stdlib.h stdio.h string.h sys/types.h sys/time.h unistd.h \
                  time.h stdarg.h sys/types.h sys/uio.h sched.h ctype.h])

dnl ************************************
dnl *** Check for standard functions ***
dnl ************************************
AC_FUNC_MMAP()
dnl AC_CHECK_FUNCS([])

dnl ******************************
dnl *** Check for i18n support ***
dnl ******************************
XDT_I18N([@LINGUAS@])

dnl ***********************************
dnl *** Check for required packages ***
dnl ***********************************
XDT_CHECK_PACKAGE([GLIB], [glib-2.0], [2.50.0])
XDT_CHECK_PACKAGE([GIO], [gio-2.0], [2.50.0])
XDT_CHECK_PACKAGE([LIBXFCE4UTIL], [libxfce4util-1.0], [4.15.6])
XDT_CHECK_PACKAGE([GOBJECT], [gobject-2.0], [2.50.0])
XDT_CHECK_PACKAGE([GTHREAD], [gthread-2.0], [2.50.0])
XDT_CHECK_PACKAGE([GTK3], [gtk+-3.0], [3.20.0])
XDT_CHECK_PACKAGE([LIBXFCE4UI2], [libxfce4ui-2], [4.15.7])

dnl *************************
dnl *** Check for gtk-doc ***
dnl *************************
GTK_DOC_CHECK([1.20])

dnl ***************************************
dnl *** Check for GObject Introspection ***
dnl ***************************************
GOBJECT_INTROSPECTION_CHECK([1.50.0])

dnl ***********************************
dnl *** Check for debugging support ***
dnl ***********************************
XDT_FEATURE_DEBUG([garcon_debug_default])

dnl **************************************
dnl *** Check for linker optimizations ***
dnl **************************************
XDT_FEATURE_LINKER_OPTS()

AC_CONFIG_FILES([
Makefile
data/Makefile
data/xfce/Makefile
docs/Makefile
docs/reference/Makefile
garcon/Makefile
garcon/garcon-1.pc
garcon/garcon-config.h
garcon-gtk/Makefile
garcon-gtk/garcon-gtk3-1.pc
icons/Makefile
icons/32x32/Makefile
po/Makefile.in
tests/Makefile
])
AC_OUTPUT

dnl ***************************
dnl *** Print configuration ***
dnl ***************************
echo
echo "Build Configuration:"
echo
echo "* Debug Support:  $enable_debug"
echo "* GObject Introspection support: $enable_introspection"
echo