Commit from LXDE Translation Project with Pootle by user forfolias.: 24 of 24 message...
[lxde/lxinput.git] / configure.in
CommitLineData
14f5ccb1
HJYP
1dnl Process this file with autoconf to produce a configure script.
2
3AC_INIT(configure.in)
a031a272 4AM_INIT_AUTOMAKE(lxinput, 0.3.0)
14f5ccb1 5AM_CONFIG_HEADER(config.h)
22e5efb3
JL
6# Support silent build rules. Disable by either passing --disable-silent-rules
7# to configure or passing V=1 to make
8AM_SILENT_RULES([yes])
9
14f5ccb1
HJYP
10AM_MAINTAINER_MODE
11
12AC_ISC_POSIX
13AC_PROG_CC
14AM_PROG_CC_STDC
15AC_HEADER_STDC
16
17AM_GLIB_GNU_GETTEXT
18IT_PROG_INTLTOOL([0.40.0])
19
20pkg_modules="gtk+-2.0 >= 2.12.0 gthread-2.0"
21PKG_CHECK_MODULES(GTK, [$pkg_modules])
22AC_SUBST(GTK_CFLAGS)
23AC_SUBST(GTK_LIBS)
24
ff18e6bb
HJYP
25PKG_CHECK_MODULES(XLIB, "x11")
26AC_SUBST(XLIB_CFLAGS)
27AC_SUBST(XLIB_LIBS)
28
3a0fc902
JL
29# Pass --enable-maintainer-mode to enable more CFLAGS
30if test "$USE_MAINTAINER_MODE" = "yes"; then
31 ADDITIONAL_FLAGS="-Wall -Werror=all -Werror=format -Werror=implicit-function-declaration -Werror=implicit-int -Werror=missing-braces -Werror=parentheses -Werror=return-type -Werror=strict-aliasing -Werror=switch -Wuninitialized -Werror=unused-label -Werror=unused-value -Wextra -Wno-missing-field-initializers -Wno-unused-parameter -Werror=missing-declarations -Wredundant-decls -Wmissing-noreturn -Wpointer-arith -Wcast-align -Wwrite-strings -Werror=inline -Werror=format-nonliteral -Wformat-nonliteral -Werror=format-security -Wformat-security -Winit-self -Werror=missing-include-dirs -Werror=undef -Werror=aggregate-return -Wmissing-format-attribute -Werror=nested-externs -fno-strict-aliasing -fmessage-length=0 -Wp,-D_FORTIFY_SOURCE=2 -DG_DISABLE_DEPRECATED -DG_DISABLE_SINGLE_INCLUDES -DGDK_DISABLE_DEPRECATED -DGDK_PIXBUF_DISABLE_DEPRECATED -DGDK_PIXBUF_DISABLE_SINGLE_INCLUDES -DGTK_DISABLE_DEPRECATED -DGTK_DISABLE_SINGLE_INCLUDES"
32fi
33AC_SUBST(ADDITIONAL_FLAGS)
34
1e9362df
JH
35AC_ARG_ENABLE(man,
36 [AC_HELP_STRING([--enable-man],
37 [regenerate roff man pages from Docbook @<:@default=no@:>@])],
38 [enable_man="${enableval}"],
39 [enable_man=no]
40)
41
46c1dfce
HJYP
42# Generate po/LINGUAS on the fly rather than relying on translators
43# to maintain it manually. This also overcome the problem that Transifex
44# cannot add a language to po/LINGUAS if a new po file is submitted.
45rm -f $srcdir/po/LINGUAS
46for po_file in `ls $srcdir/po/*.po | sort`;
47do
48 lang=`echo "$po_file" | sed "s|.*/po/\(.*\)\.po|\1|g"`
49 echo $lang >> $srcdir/po/LINGUAS
50done
51
14f5ccb1
HJYP
52GETTEXT_PACKAGE=lxinput
53AC_SUBST(GETTEXT_PACKAGE)
46c1dfce 54AM_GLIB_GNU_GETTEXT
14f5ccb1
HJYP
55AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE", [Gettext package.])
56
1e9362df 57if test x"$enable_man" = x"yes"; then
ff18e6bb
HJYP
58 AC_PATH_PROG([XSLTPROC], [xsltproc])
59 if test -z "$XSLTPROC"; then
60 enable_man=no
61 fi
62
63 dnl check for DocBook DTD and stylesheets in the local catalog.
64 JH_CHECK_XML_CATALOG([-//OASIS//DTD DocBook XML V4.1.2//EN],
65 [DocBook XML DTD V4.1.2], [], enable_man=no)
66 JH_CHECK_XML_CATALOG([http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl],
67 [DocBook XSL Stylesheets >= 1.70.1], [], enable_man=no)
1e9362df
JH
68fi
69
70AM_CONDITIONAL(ENABLE_REGENERATE_MAN, test "x$enable_man" != "xno")
71
14f5ccb1
HJYP
72AC_OUTPUT([
73Makefile
74src/Makefile
75po/Makefile.in
a93acddb 76man/Makefile
14f5ccb1 77])