GTK+2 panel 

GTK+2 panel Git Source Tree

Root/configure.ac

1AC_PREREQ(2.58)
2
3AC_INIT([GTK2 panel],[0.1.0],[gtk2panel-devel@lists.sourceforge.net],[gtk2panel])
4
5m4_ifdef([LT_INIT],
6 [LT_INIT([disable-static])],
7 [AC_DISABLE_STATIC
8 AC_PROG_LIBTOOL])
9
10AC_CONFIG_SRCDIR([configure.ac])
11AC_CONFIG_HEADERS([config.h.in])
12AC_CONFIG_AUX_DIR([build])
13AC_CONFIG_MACRO_DIR([build])
14
15AM_INIT_AUTOMAKE
16
17AC_DEFINE([PACKAGE_DESCRIPTION],
18 ["A bleeding edge panel heavily based on the GTK+2 stack"],
19 [Package description to be used as summary.])
20AC_DEFINE([PACKAGE_DATADIR],
21 ["@pkgdatadir@"],
22 [Directory where the package data will be installed.])
23
24dnl Enable silent rules, if possible
25m4_ifdef([AM_SILENT_RULES],
26 [AM_SILENT_RULES([yes])],
27 [AC_SUBST([AM_V_GEN],[])])
28
29
30##################################################
31# Checks for programs
32##################################################
33
34AC_PROG_CC
35PKG_PROG_PKG_CONFIG
36GTK_DOC_CHECK
37
38
39##################################################
40# Check for header files
41##################################################
42
43AC_CHECK_HEADERS([string.h])
44
45
46##################################################
47# Check for typedefs, structures and compiler characteristics
48##################################################
49
50AC_LANG(C)
51AC_C_CONST
52
53
54##################################################
55# Check for required packages
56##################################################
57
58PKG_CHECK_MODULES([GOBJECT],[glib-2.0 >= 2.6.0 gobject-2.0 >= 2.6.0])
59PKG_CHECK_MODULES([GTK],[gtk+-2.0 >= 2.16.0])
60
61
62dnl Glade catalog dir. Valid values include:
63dnl - check: try to figure out the correct path at configure time
64dnl - yes: figure out the correct path at configure time or fail
65dnl - no: glade support disabled
66dnl - ...: explicit path to glade catalogs (check for gladeui disabled)
67AC_ARG_WITH(glade_catalogdir,
68 [AC_HELP_STRING([--with-glade-catalogdir@<:@=DIR@:>@],
69 [where to install the glade catalogs @<:@default=check@:>@])],
70 [],[with_glade_catalogdir=check])
71
72# Both "check" and "yes" require gladeui detection but "yes" fails on gladeui not found.
73# gtk2panel is GTK+2 based, so only gladeui-1.0 is checked.
74AS_IF([test "x${with_glade_catalogdir}" = "xcheck" -o "x${with_glade_catalogdir}" = "xyes"],
75 [catalogdir=$($PKG_CONFIG --define-variable=prefix='${prefix}' \
76 --define-variable=exec_prefix='${exec_prefix}' --define-variable=libdir='${libdir}' \
77 --define-variable=bindir='${bindir}' --define-variable=datarootdir='${datarootdir}' \
78 --define-variable=datadir='${datadir}' --define-variable=includedir='${includedir}' \
79 --variable=catalogdir gladeui-1.0)
80 AS_IF([test "x${catalogdir}" != "x"], [with_glade_catalogdir="${catalogdir}"])])
81
82# Handle "yes" failure
83AS_IF([test "x${with_glade_catalogdir}" = "xyes"],
84 [AC_MSG_ERROR([Glade support explicitely required but gladeui-1.0 not found])])
85
86# Handle "check" graceful degradation
87AS_IF([test "x${with_glade_catalogdir}" = "xcheck"],
88 [with_glade_catalogdir=no])
89
90AM_CONDITIONAL([HAVE_GLADE],[test "x${with_glade_catalogdir}" != "xno"])
91AM_COND_IF([HAVE_GLADE],
92 [enable_glade=yes
93 report_glade_catalogdir="
94 Glade catalog dir: ${with_glade_catalogdir}"],
95 [enable_glade=no
96 report_glade_catalogdir=""])
97AC_SUBST([GLADE_CATALOGDIR],${with_glade_catalogdir})
98
99
100
101##################################################
102# Check for optional libwnck support (pager and taskbar widgets)
103##################################################
104
105AC_ARG_ENABLE([libwnck],
106 [AS_HELP_STRING([--enable-libwnck],
107 [Enable libwnck based widgets @<:@default=check@:>@])],
108 [],[enable_libwnck=check])
109AS_IF([test "x$enable_libwnck" != "xno"],
110 [PKG_CHECK_MODULES([LIBWNCK],[libwnck-1.0],
111 [enable_libwnck=yes],
112 [AS_IF([test "x$enable_libwnck" = "xyes"],
113 [AC_MSG_ERROR([$LIBWNCK_PKG_ERRORS but libwnck widgets requested])],
114 [enable_libwnck=no])])])
115AM_CONDITIONAL([HAVE_LIBWNCK],[test "x$enable_libwnck" = "xyes"])
116
117
118##################################################
119# Final step
120##################################################
121
122AC_CONFIG_FILES([Makefile
123 libgpsystem/Makefile
124 libgpwidgets/Makefile
125 gtk2panel/Makefile
126 examples/Makefile
127 docs/Makefile
128 docs/gtk2panel/bookinfo.xml
129 docs/gtk2panel/Makefile])
130AC_OUTPUT
131
132AC_MSG_NOTICE([
133
134The following features will be enabled:
135
136 libwnck-based widgets: $enable_libwnck
137 Install glade catalogs: $enable_glade$report_glade_catalogdir
138])

Archive Download this file

Branches

Tags