]> git.draconx.ca Git - slotifier.git/blob - configure.ac
Don't use gnulib gettext module.
[slotifier.git] / configure.ac
1 dnl Copyright © 2018-2019 Nick Bowler
2 dnl
3 dnl License WTFPL2: Do What The Fuck You Want To Public License, version 2.
4 dnl This is free software: you are free to do what the fuck you want to.
5 dnl There is NO WARRANTY, to the extent permitted by law.
6
7 AC_INIT([slotifier], [0], [nbowler@draconx.ca])
8 AC_CONFIG_HEADER([config.h])
9
10 AM_INIT_AUTOMAKE([-Wall -Wno-portability foreign subdir-objects])
11 AM_SILENT_RULES([yes])
12
13 AC_PROG_CC
14 AM_PROG_CC_C_O
15 gl_EARLY
16
17 LT_INIT
18 gl_INIT
19
20 AC_CACHE_SAVE
21
22 m4_include([lib/gnulib.mk])
23
24 dnl We provide our own makefile rules for gettext.  Disable tracing of
25 dnl AM_GNU_GETTEXT to prevent autoreconf from running autopoint, and to
26 dnl prevent automake from growing gratuitous error conditions.
27 m4_traceoff([AM_GNU_GETTEXT])
28 AM_GNU_GETTEXT([external])
29 DX_LINGUAS
30
31 DX_LIB_CNEARTREE
32 DX_LIB_LIBGERBV
33
34 AS_IF([test x"$dx_cv_libgerbv_lib_found" = x"yes"],
35 [AC_CACHE_CHECK([if libgerbv supports G85 slots], [dx_cv_gerbv_supports_g85],
36 [save_CFLAGS=$CFLAGS
37 CFLAGS="$CFLAGS $LIBGERBV_CFLAGS"
38 AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
39 [#include <gerbv.h>
40 #include <stddef.h>
41 ], [static int g85_supported@<:@
42   offsetof(gerbv_drill_stats_t, G85) >= 0 ? 1 : -1
43 @:>@;])], [dx_cv_gerbv_supports_g85=yes], [dx_cv_gerbv_supports_g85=no])
44 CFLAGS=$save_CFLAGS])])
45
46 AS_IF([test x"$dx_cv_gerbv_supports_g85" != x"yes"],
47 [AC_MSG_FAILURE([Your installation of libgerbv appears not to
48 support slots.  An updated version of libgerbv is likely required.
49 The latest version may be found at <http://gerbv.geda-project.org/>.
50 m4_newline([DX_LIB_USERFLAG_BLURB([libgerbv])])
51 m4_newline([DX_LIB_PKGCONFIG_BLURB([libgerbv])])
52 ])])
53
54 AC_CONFIG_TESTDIR([.])
55 DX_PROG_AUTOTEST
56 AM_CONDITIONAL([HAVE_AUTOTEST], [test x"$dx_cv_autotest_works" = x"yes"])
57
58 AC_CONFIG_FILES([Makefile])
59 AC_OUTPUT