2 dnl Process this file with autoconf to generate configure.
4 dnl The AX_* macros are defined in files in the top-level m4
7 #####################################################################
8 # Set up configuration system
9 #####################################################################
11 AC_INIT([gEDA/gaf], [1.10.0], [https://bugs.launchpad.net/geda], [geda-gaf])
14 AC_CONFIG_SRCDIR([libgeda/src/libgeda.c])
15 AC_CONFIG_AUX_DIR([build-tools])
16 AC_CONFIG_MACRO_DIR([m4])
17 AC_CONFIG_HEADER([config.h])
19 AM_INIT_AUTOMAKE([parallel-tests color-tests tar-ustar])
22 AC_GNU_SOURCE # FIXME for some reason this is needed?
24 #####################################################################
25 # Do version number magic
26 #####################################################################
28 AX_GIT_VERSION([20191008])
30 # This is used for keeping the ChangeLog files up-to-date
31 AC_SUBST([CHANGELOG_BASE], [1.0-20070526])
33 #####################################################################
34 # Windows/MinGW/Cygwin support
35 #####################################################################
39 #####################################################################
40 # Check for compiling & linking tools
41 #####################################################################
45 m4_ifdef([AM_PROG_AR], [AM_PROG_AR]) dnl Workaround for Automake 1.11
48 if test "X$ac_cv_prog_cc_stdc" = "Xno"; then
49 AC_MSG_ERROR([C compiler cannot compile ISO Standard C])
58 AX_PROG_CC_WARNING([maybe_uninitialized], [maybe-uninitialized])
59 AX_PROG_CC_WARNING([misleading_indentation], [misleading-indentation])
61 AX_GCC_FLAGS([-Wall $Werror_maybe_uninitialized_IF_SUPPORTED])
67 AC_PATH_PROGS([M4], [gm4 m4], [m4])
69 #####################################################################
70 # Internationalisation
71 #####################################################################
74 AM_GNU_GETTEXT([external])
75 AM_GNU_GETTEXT_VERSION([0.18])
78 #####################################################################
79 # Check for libraries that use pkg-config
80 #####################################################################
84 AX_CHECK_GUILE([2.0.10])
86 PKG_CHECK_MODULES(GLIB, [glib-2.0 >= 2.41.1], ,
87 AC_MSG_ERROR([GLib 2.20.0 or later is required.]))
89 PKG_CHECK_MODULES(GIO, [gio-2.0 >= 2.20.0], ,
90 AC_MSG_ERROR([GIO 2.20.0 or later is required.]))
92 PKG_CHECK_MODULES(GTK, [gtk+-2.0 >= 2.18.0], ,
93 AC_MSG_ERROR([GTK+ 2.18.0 or later is required.]))
95 PKG_CHECK_MODULES(GDK, [gdk-2.0 >= 2.18.0], ,
96 AC_MSG_ERROR([GDK 2.18.0 or later is required.]))
98 PKG_CHECK_MODULES(GDK_PIXBUF, [gdk-pixbuf-2.0 >= 2.18.0], ,
99 AC_MSG_ERROR([GDK_PIXBUF 2.18.0 or later is required.]))
103 PKG_CHECK_MODULES(PANGOCAIRO, [pangocairo >= 0.26], ,
104 AC_MSG_ERROR([PANGOCAIRO 0.26 or later is required.]))
106 PKG_CHECK_MODULES(PANGO, [pango >= 1.23.0], ,
107 AC_MSG_ERROR([PANGO 1.23.0 or later is required.]))
109 #####################################################################
110 # Header files & particular functions
111 #####################################################################
115 # FIXME these checks are obsolete, because every plausible platform
116 # provides what they check for.
119 # FIXME these checks may be pointless for one of three reasons: every
120 # even vaguely sane libc implementation provides them; we don't use
121 # any of their functions in favour of GLib alternatives; or we don't
122 # provide an alternative, so the build will fail anyway.
123 AC_CHECK_HEADERS([stdlib.h string.h unistd.h])
125 # FIXME since we don't have a sensible alternative, if these headers
126 # are missing we should fail. Also need to remove HAVE_ERRNO_H tests
127 # in the C source code, since if we *don't* have it the build will
129 AC_CHECK_HEADERS([errno.h fcntl.h])
131 # FIXME On a system without locale.h, the user may have just disabled NLS
132 # to be able to build. But are there known systems with working NLS but
133 # without a locale.h? We do need to include locale.h on some systems
134 # to be able to build gschem/src/gschem.c
135 AC_CHECK_HEADERS([locale.h])
137 # Check for lrint in math library.
138 AC_CHECK_LIB([m], [lrint],
139 AC_DEFINE([HAVE_LRINT], 1,
140 [If your math library has lrint in it, define this]))
142 AC_CHECK_LIB([m], [atan2])
144 AC_CHECK_FUNCS([chown getlogin])
146 # Check if the getopt header is present
147 AC_CHECK_HEADERS([getopt.h])
148 # Check for getopt_long
149 # On FreeBSD the 'gnugetopt' library is needed.
150 AC_SEARCH_LIBS([getopt_long], [gnugetopt],
151 AC_DEFINE([HAVE_GETOPT_LONG], 1,
152 [Define to 1 if you have the `getopt_long' function.]))
154 # Check for misc features of awk
157 #####################################################################
159 #####################################################################
163 # Viewing documentation
169 # KDE 3 desktop files
171 # XDG database updates
178 #####################################################################
179 # Tool-specific setup
180 #####################################################################
182 # Where should data files be installed/searched for?
184 # Where should PCB footprints be searched for?
186 # Set up libgeda with the correct ld version number
188 # Set up libgedacairo with the correct ld version number
189 AX_LIBGEDACAIRO([1:2:0])
191 #####################################################################
192 # Recurse into Xorn configuration
193 #####################################################################
198 AC_CONFIG_SUBDIRS([xorn])
200 #####################################################################
202 #####################################################################
204 AC_CONFIG_FILES([Makefile
208 libgeda/po/domain.mak
209 libgeda/po/Makefile.in
210 libgeda/data/Makefile
211 libgeda/docs/Makefile
212 libgeda/docs/images/Makefile
213 libgeda/include/Makefile
215 libgeda/scheme/Makefile
218 libgedacairo/Makefile
219 libgedacairo/libgedacairo.pc
225 gschem/po/Makefile.in
227 gschem/include/Makefile
228 gschem/scripts/Makefile
230 gschem/examples/Makefile
233 gschem/bitmap/Makefile
234 gschem/tests/Makefile
235 gschem/scheme/Makefile
238 gattrib/po/Makefile.in
239 gattrib/design/Makefile
240 gattrib/docs/Makefile
241 gattrib/include/Makefile
243 gattrib/lib/system-gattribrc
245 gattrib/data/Makefile
247 gsymcheck/docs/Makefile
248 gsymcheck/include/Makefile
249 gsymcheck/lib/Makefile
250 gsymcheck/lib/system-gsymcheckrc
251 gsymcheck/po/Makefile.in
252 gsymcheck/src/Makefile
253 gsymcheck/tests/Makefile
256 gnetlist-legacy/Makefile
257 gnetlist-legacy/po/Makefile.in
258 gnetlist-legacy/src/Makefile
259 gnetlist-legacy/include/Makefile
260 gnetlist-legacy/scheme/Makefile
261 gnetlist-legacy/examples/Makefile
262 gnetlist-legacy/tests/Makefile
263 gnetlist-legacy/docs/Makefile
264 gnetlist-legacy/docs/vams/Makefile
265 gnetlist-legacy/examples/vams/Makefile
266 gnetlist-legacy/examples/vams/vhdl/Makefile
267 gnetlist-legacy/examples/vams/vhdl/basic-vhdl/Makefile
268 gnetlist-legacy/examples/vams/vhdl/new-vhdl/Makefile
269 gnetlist-legacy/examples/switcap/Makefile
270 gnetlist-legacy/lib/Makefile
271 gnetlist-legacy/utils/Makefile
272 gnetlist-legacy/scripts/Makefile
273 gnetlist-legacy/scripts/annotate.sh
274 gnetlist-legacy/scripts/bom_xref.sh
275 gnetlist-legacy/scripts/bompp.sh
276 gnetlist-legacy/lib/system-gnetlistrc
280 utils/examples/Makefile
281 utils/examples/gmk_sym/Makefile
282 utils/examples/gsch2pcb/Makefile
283 utils/examples/tragesym/Makefile
284 utils/gschlas/Makefile
286 utils/include/Makefile
288 utils/lib/system-gschlasrc
289 utils/scripts/Makefile
291 utils/tests/gxyrs/Makefile
292 utils/tests/refdes_renum/Makefile
295 symbols/documentation/Makefile
298 docs/scheme-api/Makefile
299 docs/toplevel/Makefile
300 docs/toplevel/gedadocs.html
304 examples/RF_Amp/Makefile
305 examples/RF_Amp/model/Makefile
306 examples/RF_Amp/sym/Makefile
307 examples/TwoStageAmp/Makefile
308 examples/gTAG/Makefile
309 examples/lightning_detector/Makefile
312 contrib/smash_megafile/Makefile
313 contrib/olib/Makefile
314 contrib/gmk_sym/Makefile
315 contrib/sarlacc_schem/Makefile
316 contrib/scripts/Makefile
317 contrib/scripts/sw2asc