~lubuntu-software-center-team/lubuntu-software-center/vala-port

« back to all changes in this revision

Viewing changes to configure.ac

  • Committer: Stephen Smally
  • Date: 2012-07-04 20:42:18 UTC
  • Revision ID: eco.stefi@fastwebnet.it-20120704204218-we49v7ac9ammtsrz
Added build system

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
AC_PREREQ([2.57])
 
2
AC_INIT(light-software-center,[0.0.9], [],light-software-center)
 
3
AM_INIT_AUTOMAKE([1.11 -Wall -Werror foreign])
 
4
 
 
5
# Support silent build rules. Disable by either passing --disable-silent-rules
 
6
# to configure or passing V=1 to make
 
7
AM_SILENT_RULES([yes])
 
8
AC_PROG_INTLTOOL(, [no-xml])
 
9
AM_MAINTAINER_MODE
 
10
 
 
11
AM_CONFIG_HEADER(config.h)
 
12
AC_CONFIG_MACRO_DIR([m4])
 
13
 
 
14
AC_PROG_CC
 
15
AC_PROG_INSTALL
 
16
AM_PROG_CC_C_O
 
17
AC_PROG_CC_STDC
 
18
 
 
19
#Initialize libtool
 
20
LT_PREREQ([2.2])
 
21
LT_INIT
 
22
 
 
23
AC_ARG_ENABLE(more_warnings,
 
24
       [AS_HELP_STRING([--enable-more-warnings],
 
25
               [Add more warnings @<:@default=no@:>@])],
 
26
       [enable_more_warnings="${enableval}"],
 
27
       [enable_more_warnings=no]
 
28
)
 
29
 
 
30
if test x"$enable_more_warnings" = x"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"
 
32
fi
 
33
AC_SUBST(ADDITIONAL_FLAGS)
 
34
 
 
35
PKG_CHECK_MODULES(GTK, [gtk+-3.0 >= 3.0.0])
 
36
AC_SUBST(GTK_CFLAGS)
 
37
AC_SUBST(GTK_LIBS)
 
38
 
 
39
PKG_CHECK_MODULES(X11, [x11])
 
40
AC_SUBST(X11_CFLAGS)
 
41
AC_SUBST(X11_LIBS)
 
42
 
 
43
PKG_CHECK_MODULES(GLIB, [glib-2.0 >= 2.6.0])
 
44
AC_SUBST(GLIB_CFLAGS)
 
45
AC_SUBST(GLIB_LIBS)
 
46
 
 
47
PKG_CHECK_MODULES(GIO, [gio-unix-2.0])
 
48
AC_SUBST(GIO_CFLAGS)
 
49
AC_SUBST(GIO_LIBS)
 
50
 
 
51
PKG_CHECK_MODULES(PKGLIB, [packagekit-glib2])
 
52
AC_SUBST(PKGLIB_CFLAGS)
 
53
AC_SUBST(PKGLIB_LIBS)
 
54
 
 
55
PKG_CHECK_MODULES(SQLH, [sqlheavy-0.1])
 
56
AC_SUBST(SQLH_CFLAGS)
 
57
AC_SUBST(SQLH_LIBS)
 
58
 
 
59
PKG_CHECK_MODULES(GEE, [gee-1.0])
 
60
AC_SUBST(GEE_CFLAGS)
 
61
AC_SUBST(GEE_LIBS)
 
62
 
 
63
AM_PROG_VALAC([0.14.0])
 
64
if test "x$VALAC" = "x"; then
 
65
        AC_MSG_ERROR([You need Vala compiler])
 
66
fi
 
67
 
 
68
# Generate po/LINGUAS on the fly rather than relying on translators
 
69
# to maintain it manually. This also overcome the problem that Transifex
 
70
# cannot add a language to po/LINGUAS if a new po file is submitted.
 
71
rm -f $srcdir/po/LINGUAS
 
72
for po_file in `ls $srcdir/po/*.po | sort`;
 
73
do
 
74
    lang=`echo "$po_file" | sed "s|.*/po/\(.*\)\.po|\1|g"`
 
75
    echo $lang >> $srcdir/po/LINGUAS
 
76
done
 
77
 
 
78
GETTEXT_PACKAGE=light-software-center
 
79
AC_SUBST(GETTEXT_PACKAGE)
 
80
AM_GLIB_GNU_GETTEXT
 
81
AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE", [Gettext package.])
 
82
 
 
83
 
 
84
AC_OUTPUT([
 
85
  Makefile
 
86
  src/Makefile
 
87
  db-build/Makefile
 
88
  po/Makefile.in
 
89
])
 
90
 
 
91
echo
 
92
echo Light-software-center...................... : Version $VERSION
 
93
echo
 
94
echo Prefix....................................... : $prefix