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
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
|
AC_INIT(control-center)
AM_CONFIG_HEADER(config.h)
AM_INIT_AUTOMAKE(control-center, 2.1.5)
AM_MAINTAINER_MODE
AC_PROG_INTLTOOL
GNOME_COMPILE_WARNINGS
AC_ISC_POSIX
AC_PROG_CC
AC_STDC_HEADERS
AM_PROG_LIBTOOL
changequote(,)dnl
if test "x$GCC" = "xyes"; then
case " $CFLAGS " in
*[\ \ ]-Wall[\ \ ]*) ;;
*) CFLAGS="$CFLAGS -Wall" ;;
esac
fi
changequote([,])dnl
# Internationalization support
ALL_LINGUAS="ar az be bg ca cs da de el en_GB es et fi fr ga gl hr hu it ja ko lt lv ms nl nn no pl pt pt_BR ro ru sk sl sv ta tr uk vi wa zh_CN zh_TW"
GETTEXT_PACKAGE=control-center-2.0
AC_SUBST(GETTEXT_PACKAGE)
AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", [Gettext package])
AM_GLIB_GNU_GETTEXT
AC_CHECK_FUNCS(usleep)
AC_CHECK_FUNCS(putenv,[AC_DEFINE(HAVE_PUTENV,,[putenv])])
AC_CHECK_FUNCS(setenv,[AC_DEFINE(HAVE_SETENV,,[setenv])])
AC_PATH_XTRA
x_libs="$X_PRE_LIBS $X_LIBS -lX11 $X_EXTRA_LIBS"
dnl keyboard-properties-capplet
savecppflags=$CPPFLAGS
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
AC_CHECK_HEADERS(X11/extensions/xf86misc.h, XF86MISC_LIBS="-lXxf86misc")
AC_SUBST(XF86MISC_LIBS)
AC_CHECK_HEADERS(X11/extensions/XKB.h)
CPPFLAGS=$savecppflags
dnl ==============================================
dnl Check that we meet the dependencies
dnl ==============================================
COMMON_MODULES="gtk+-2.0 >= 2.1.0 gconf-2.0 libgnomeui-2.0 libglade-2.0 >= 1.99.12 libbonobo-2.0 libbonoboui-2.0 libglade-2.0 gconf-2.0 gnome-desktop-2.0"
PKG_CHECK_MODULES(CAPPLET, $COMMON_MODULES)
PKG_CHECK_MODULES(GNOMECC, $COMMON_MODULES libxml-2.0 gnome-desktop-2.0 gnome-vfs-2.0)
PKG_CHECK_MODULES(GNOME_SETTINGS_DAEMON, gtk+-2.0 gconf-2.0 libgnomeui-2.0 esound gnome-desktop-2.0)
PKG_CHECK_MODULES(OLD_CAPPLET, libgnomeui-2.0 libglade-2.0)
PKG_CHECK_MODULES(GNOME, libgnomeui-2.0)
PKG_CHECK_MODULES(VFS_CAPPLET, $COMMON_MODULES gnome-vfs-module-2.0 gnome-vfs-2.0)
PKG_CHECK_MODULES(SOUND_CAPPLET, esound)
PKG_CHECK_MODULES(METACITY, libmetacity-private)
dnl
dnl Check for Xft version 2; we build in extra functionality to the font capplet
dnl when we have it.
dnl
xft_modules=
if $PKG_CONFIG --exists xft ; then
xft_modules="xft"
AC_DEFINE(HAVE_XFT2,,[Build Xft functionality to the font capplet])
fi
PKG_CHECK_MODULES(FONT_CAPPLET, $COMMON_MODULES $xft_modules)
CAPPLET_LIBS="$CAPPLET_LIBS $x_libs"
GNOMECC_LIBS="$GNOMECC_LIBS $x_libs"
GNOME_SETTINGS_DAEMON_LIBS="$GNOME_SETTINGS_DAEMON_LIBS $x_libs"
AC_PATH_PROG(GCONFTOOL, gconftool-2)
dnl
dnl Check for gtk+ with multihead support
dnl
AC_MSG_CHECKING([for gtk+ multihead support])
if $PKG_CONFIG --atleast-version 2.1.0 gtk+-2.0; then
AC_DEFINE(HAVE_GTK_MULTIHEAD,,[gtk+ with multihead support found])
AC_MSG_RESULT(yes)
else
AC_MSG_RESULT(no)
fi
dnl ==============================================
dnl End: Check that we meet the dependencies
dnl ==============================================
dnl ==============================================
dnl IDL settings
dnl ==============================================
# orbit-idl
ORBIT_IDL="`$PKG_CONFIG --variable=orbit_idl ORBit-2.0`"
AC_SUBST(ORBIT_IDL)
# idl directories
LIBBONOBO_IDL_DIR="`$PKG_CONFIG --variable=idldir libbonobo-2.0`"
AC_SUBST(LIBBONOBO_IDL_DIR)
BONOBO_ACTIVATION_IDL_DIR="`$PKG_CONFIG --variable=idldir bonobo-activation-2.0`"
AC_SUBST(BONOBO_ACTIVATION_IDL_DIR)
# esd
ESDSERVERDIR=`$PKG_CONFIG --variable=esd_serverdir esound`
if test x"$ESDSERVERDIR" = x; then
ESD_SERVER="esd"
else
ESD_SERVER="$ESDSERVERDIR/esd"
fi
AC_SUBST(ESD_SERVER)
AC_PATH_PROG(GDK_PIXBUF_CSOURCE, gdk-pixbuf-csource, no)
if test x"$GDK_PIXBUF_CSOURCE" = xno; then
AC_MSG_ERROR([gdk-pixbuf-csource executable not found in your path - should be installed with GTK])
fi
AC_SUBST(GDK_PIXBUF_CSOURCE)
dnl ==============================================
dnl Special GConf section
dnl ==============================================
AC_PATH_PROG(GCONFTOOL, gconftool-2, no)
if test x"$GCONFTOOL" = xno; then
AC_MSG_ERROR([gconftool-2 executable not found in your path - should be installed with GConf])
fi
AM_GCONF_SOURCE_2
dnl ==============================================
dnl Define the main variables
dnl ==============================================
COMMON_CFLAGS="-I\$(top_srcdir)/capplets/common"
COMMON_LIBS="\$(top_builddir)/capplets/common/libcommon.la"
EXTRA_CFLAGS="-I\$(top_srcdir)/ -DG_LOG_DOMAIN=\"\\\"\$(cappletname)-properties\\\"\" -DGNOMELOCALEDIR=\"\\\"${prefix}/${DATADIRNAME}/locale\\\"\""
GNOMECC_CAPPLETS_CFLAGS="${CAPPLET_CFLAGS} ${EXTRA_CFLAGS} ${COMMON_CFLAGS}"
GNOMECC_CAPPLETS_LIBS="${CAPPLET_LIBS} ${COMMON_LIBS}"
GNOMECC_CAPPLETS_CLEANFILES="\$(desktop) \$(desktop).in"
GNOMECC_CAPPLETS_EXTRA_DIST="ChangeLog \$(desktop).in.in \$(cappletname)-capplet.png \$(cappletname)-properties.glade \$(pixmaps_DATA)"
AC_SUBST(GNOMECC_CAPPLETS_EXTRA_DIST)
AC_SUBST(GNOMECC_CAPPLETS_CLEANFILES)
AC_SUBST(GNOMECC_CAPPLETS_CFLAGS)
AC_SUBST(GNOMECC_CAPPLETS_LIBS)
AC_SUBST(GNOME_SETTINGS_DAEMON_CFLAGS)
AC_SUBST(GNOME_SETTINGS_DAEMON_LIBS)
AC_SUBST(VFS_CAPPLET_CFLAGS)
AC_SUBST(VFS_CAPPLET_LIBS)
AC_SUBST(SOUND_CAPPLET_CFLAGS)
AC_SUBST(SOUND_CAPPLET_LIBS)
AC_SUBST(FONT_CAPPLET_CFLAGS)
AC_SUBST(FONT_CAPPLET_LIBS)
AC_SUBST(GNOMECC_CFLAGS)
AC_SUBST(GNOMECC_LIBS)
AC_SUBST(METACITY_CFLAGS)
AC_SUBST(METACITY_LIBS)
dnl ==============================================
dnl End: Define the main variables
dnl ==============================================
GCONF_CONFIG_SOURCE=
AC_ARG_ENABLE(gconf-source, [ --enable-gconf-source=sourceaddress Where to install schema files.],GCONF_CONFIG_SOURCE=$enable_gconf_source,)
if test "x$GCONF_CONFIG_SOURCE" = "x"; then
GCONF_CONFIG_SOURCE="xml::\${DESTDIR}\${sysconfdir}/gconf/gconf.xml.defaults"
fi
AC_SUBST(GCONF_CONFIG_SOURCE)
AC_SUBST(INSTALL_GCONF_CONFIG_SOURCE)
ORBIT_IDL="`$PKG_CONFIG --variable=orbit_idl ORBit-2.0`"
AC_SUBST(ORBIT_IDL)
LIBBONOBO_IDL_DIR="`$PKG_CONFIG --variable=idldir libbonobo-2.0`"
AC_SUBST(LIBBONOBO_IDL_DIR)
BONOBO_ACTIVATION_IDL_DIR="`$PKG_CONFIG --variable=idldir bonobo-activation-2.0`"
AC_SUBST(BONOBO_ACTIVATION_IDL_DIR)
dnl ==============================================
dnl Define the directories
dnl ==============================================
if test "x${prefix}" = "xNONE"; then
real_prefix=${ac_default_prefix}
else
real_prefix=${prefix}
fi
AC_DEFINE_UNQUOTED(GNOMECC_DATA_DIR, "${real_prefix}/share/${GETTEXT_PACKAGE}",[Path to gnomecc data files])
GNOMECC_ICONS_DIR='$(datadir)/'${GETTEXT_PACKAGE}'/icons'
AC_SUBST(GNOMECC_ICONS_DIR)
GNOMECC_DESKTOP_DIR='$(datadir)/'${GETTEXT_PACKAGE}'/capplets'
AC_SUBST(GNOMECC_DESKTOP_DIR)
GNOMECC_GLADE_DIR='$(datadir)/'${GETTEXT_PACKAGE}'/interfaces'
AC_SUBST(GNOMECC_GLADE_DIR)
GNOMECC_PIXMAPS_DIR='$(datadir)/'${GETTEXT_PACKAGE}'/pixmaps'
AC_SUBST(GNOMECC_PIXMAPS_DIR)
dnl ==============================================
dnl End: Define the directories
dnl ==============================================
dnl =======================================
dnl Variables for config_archiverConf.sh.in
dnl =======================================
CONFIG_ARCHIVER_LIBDIR='-L${libdir}'
CONFIG_ARCHIVER_LIBS="$CONFIG_ARCHIVER_LIBS -lconfig_archiver"
CONFIG_ARCHIVER_INCLUDEDIR="$CONFIG_ARCHIVER_CFLAGS -I${includedir}"
AC_SUBST(CONFIG_ARCHIVER_LIBDIR)
AC_SUBST(CONFIG_ARCHIVER_LIBS)
AC_SUBST(CONFIG_ARCHIVER_INCLUDEDIR)
dnl =======================================
dnl End: Variables for config_archiverConf.sh.in
dnl =======================================
AC_OUTPUT([
Makefile
po/Makefile.in
idl/Makefile
gnome-settings-daemon/Makefile
control-center/Makefile
libbackground/Makefile
libwindow-settings/Makefile
libwindow-settings/gnome-window-settings-2.0.pc
capplets/Makefile
capplets/common/Makefile
capplets/background/Makefile
capplets/default-applications/Makefile
capplets/desktop-links/Makefile
capplets/file-types/Makefile
capplets/file-types/libuuid/Makefile
capplets/font/Makefile
capplets/keybindings/Makefile
capplets/keyboard/Makefile
capplets/mouse/Makefile
capplets/sound/Makefile
capplets/theme-switcher/Makefile
capplets/ui-properties/Makefile
capplets/accessibility/Makefile
capplets/accessibility/keyboard/Makefile
capplets/network/Makefile
capplets/windows/Makefile
schemas/Makefile
libsounds/Makefile
control-center.spec
])
dnl due to a bug in intltool we need to expand something from the root last control-center.spec
|