File: configure.ac

package info (click to toggle)
grsync 1.3.1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,484 kB
  • sloc: sh: 2,500; ansic: 1,344; makefile: 64
file content (91 lines) | stat: -rw-r--r-- 2,422 bytes parent folder | download
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
dnl Process this file with autoconf to produce a configure script.

AC_INIT([grsync],[1.3.1])
AC_CONFIG_SRCDIR([configure.ac])
AM_INIT_AUTOMAKE
AC_CONFIG_HEADERS([config.h])
AM_MAINTAINER_MODE

CFLAGS="-Wall -rdynamic $CFLAGS"
LIBS="-lm $LIBS"

AC_USE_SYSTEM_EXTENSIONS
AC_SEARCH_LIBS([strerror],[cposix])
AC_PROG_CC
m4_warn([obsolete],
[The preprocessor macro `STDC_HEADERS' is obsolete.
  Except in unusual embedded environments, you can safely include all
  ISO C90 headers unconditionally.])dnl

AC_ARG_ENABLE([gtk3],
    [AS_HELP_STRING([--enable-gtk3],[compile grsync against gtk+ 3.0 (default: yes)])],
    [enable_gtk3="${enableval}"],
    [enable_gtk3="yes"]
)

XMLFILE="grsync.glade"
AC_DEFINE_UNQUOTED(XMLFILE, ["$XMLFILE"], [UI Description XML File])

if test x"$enable_gtk3" = x"yes"; then
		GTK_API_VERSION="3.0"
else
		GTK_API_VERSION="2.0"
fi
pkg_modules="gtk+-$GTK_API_VERSION >= 2.16.0"
OTHER_DESKTOP_ENTRIES="Icon=grsync"
MIMEINFO_XMLNS="xmlns='http://www.freedesktop.org/standards/shared-mime-info'"
MIME_OSSOCAT=""

PKG_CHECK_MODULES(PACKAGE, [$pkg_modules])
AC_SUBST(PACKAGE_CFLAGS)
AC_SUBST(PACKAGE_LIBS)
AC_SUBST(OTHER_DESKTOP_ENTRIES)
AC_SUBST(MIMEINFO_XMLNS)
AC_SUBST(MIME_OSSOCAT)
AC_SUBST(XMLFILE)

AC_ARG_ENABLE(unity,
	AS_HELP_STRING([--enable-unity],[Build support for integration in Unity launcher [[default=no]]]),
	[enable_unity=$enableval],
	[enable_unity="no"])
if test x"$enable_unity" = "xyes"; then
	if test "x$with_localinstall" = "xyes"; then
		DBUSSERVICEDIR="${datadir}/dbus-1/services/"
	else
		DBUSSERVICEDIR=`$PKG_CONFIG --variable=session_bus_services_dir dbus-1`
	fi
	AC_SUBST(DBUSSERVICEDIR)

	PKG_CHECK_MODULES(UNITY,
		dee-1.0
		dbusmenu-glib-0.4
		unity)
	AC_SUBST(UNITY_CFLAGS)
	AC_SUBST(UNITY_LIBS)
	AC_DEFINE(HAVE_UNITY, 1, [Unity launcher support])
	CFLAGS="$UNITY_CFLAGS $CFLAGS"
	LIBS="$UNITY_LIBS $LIBS"
fi
AM_CONDITIONAL(HAVE_UNITY, test x"$enable_unity" = xyes)

AC_PROG_INTLTOOL()

GETTEXT_PACKAGE=grsync
AC_SUBST(GETTEXT_PACKAGE)
AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE", [Gettext package.])

dnl Add the languages which your application supports here.
ALL_LINGUAS="nl_NL it_IT zh_CN fr_FR sv_SE nb_NO tr_TR ru_RU de_DE es_ES cs_CZ gl_ES ca_ES pt_BR id_ID hr_HR zh_TW hu_HU el_GR pt_PT ja_JP"
AM_GLIB_GNU_GETTEXT

AC_CONFIG_FILES([
Makefile
src/Makefile
po/Makefile.in
grsync.spec
grsync.desktop
grsync.xml
it.opbyte.grsync.service
])
AC_OUTPUT