Commit c0efa978 authored by Emmanuel Milou's avatar Emmanuel Milou

Look for libsexy only if gtk version < 2.16 - Ticket #1116

parent 8446ad89
......@@ -28,17 +28,29 @@ AC_PROG_INSTALL
AC_STDC_HEADERS
AC_PROG_LIBTOOL
dnl Check for log4c
AC_CHECK_HEADERS(log4c.h, have_log4c=true, have_log4c=false)
if ! $have_log4c; then
AC_MSG_ERROR(Please install the log4c library)
fi
PKG_CHECK_MODULES(DEPS, \
dbus-glib-1 >= 0.35 \
libnotify >= 0.4 \
gtk+-2.0 >= 2.2 \
glib-2.0 >= 2.2 \
libsexy >= 0.1 \
dnl Check for GTK+ version
dnl If gtk+-2.0 >= 2.16, we don't need libsexy package anymore
PKG_CHECK_MODULES(GTK216, gtk+-2.0 >= 2.16, need_libsexy=false, need_libsexy=true)
if $need_libsexy; then
PKG_CHECK_MODULES(LIBSEXY, libsexy >= 0.1, have_libsexy=true, have_libsexy=false)
if ! $have_libsexy; then
AC_MSG_ERROR(libsexy package has not been found. Please install it.)
fi
fi
AC_SUBST(LIBSEXY_CFLAGS)
AC_SUBST(LIBSEXY_LIBS)
PKG_CHECK_MODULES(DEPS, \
dbus-glib-1 >= 0.35 \
libnotify >= 0.4 \
gtk+-2.0 >= 2.2 \
glib-2.0 >= 2.2 \
libebook-1.2 >= 2.22
)
......
......@@ -2,14 +2,15 @@
src = $(top_srcdir)
# Preprocessor flags
AM_CPPFLAGS = $(DEPS_CFLAGS) \
-I$(src)/src \
-I$(src)/src/config \
-I$(src)/src/dbus \
-I$(src)/src/contacts \
-I$(src)/src/addressbook \
-DDATA_DIR=\""$(prefix)/share/sflphone"\" \
-DICONS_DIR=\""$(prefix)/share/sflphone"\" \
AM_CPPFLAGS = $(DEPS_CFLAGS) \
$(LIBSEXY_CFLAGS) \
-I$(src)/src \
-I$(src)/src/config \
-I$(src)/src/dbus \
-I$(src)/src/contacts \
-I$(src)/src/addressbook \
-DDATA_DIR=\""$(prefix)/share/sflphone"\" \
-DICONS_DIR=\""$(prefix)/share/sflphone"\" \
-DCODECS_DIR=\""$(prefix)/lib/sflphone/codecs"\"
-DPREFIX=\"$(prefix)\" \
$(ZEROCONFFLAGS) \
......
......@@ -5,7 +5,6 @@ bin_PROGRAMS = sflphone-gtk
SUBDIRS = config contacts dbus
NOFIFY_LIBS = -lnotify
SEXY_LIBS = -lsexy
LOG4C = -llog4c
SFLPHONEGTK_LIBS=./contacts/libcontacts.la ./config/libconfig.la ./dbus/libdbus.la
......@@ -35,7 +34,7 @@ noinst_HEADERS = actions.h sflnotify.h mainwindow.h dialpad.h codeclist.h \
EXTRA_DIST = marshaller.list
sflphone_gtk_LDADD = $(DEPS_LIBS) $(NOTIFY_LIBS) $(SEXY_LIBS) $(SFLPHONEGTK_LIBS) $(LOG4C)
sflphone_gtk_LDADD = $(DEPS_LIBS) $(NOTIFY_LIBS) $(SFLPHONEGTK_LIBS) $(LIBSEXY_LIBS) $(LOG4C)
# add symbolic link
install-exec-local:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment