X-Git-Url: http://git.wpitchoune.net/gitweb/?p=psensor.git;a=blobdiff_plain;f=configure.ac;h=ca37fe1e62bc247d100e78c8cb8fafc9a10700c0;hp=dfcd5e7112c721840ce508766c8749c06a76d03a;hb=51450a36b7143fe230197dfa89b5fd072af7421c;hpb=ee42830c30b5ff743014ff2639d1ffcac3a3ecde diff --git a/configure.ac b/configure.ac index dfcd5e7..ca37fe1 100644 --- a/configure.ac +++ b/configure.ac @@ -40,9 +40,11 @@ PTHREAD_LIBS=-pthread AC_SUBST(PTHREAD_LIBS) # Checks sensors, required by psensor and psensor-server -AC_CHECK_LIB(sensors, sensors_init) +AC_CHECK_LIB(sensors, sensors_init, + [SENSORS_LIBS=-lsensors + AC_DEFINE([HAVE_LIBSENSORS],[1],[Use libsensors])]) AC_CHECK_HEADERS([sensors/sensors.h sensors/error.h]) -SENSORS_LIBS=-lsensors +AM_CONDITIONAL(SENSORS, test -n "$SENSORS_LIBS") AC_SUBST(SENSORS_LIBS) ############### psensor @@ -66,9 +68,10 @@ PKG_CHECK_MODULES(GTK, AM_CONDITIONAL(GTK, test -n "$GTK_LIBS") # ensure that only allowed headers are included GTK_CFLAGS+=" -DGTK_DISABLE_SINGLE_INCLUDES " -# ensure that no gtk deprecated symbols are used +# ensure that no gtk/dk deprecated symbols are used GTK_CFLAGS+=" -DGDK_DISABLE_DEPRECATED " -GTK_CFLAGS+=" -DGTK_DISABLE_DEPRECATED " +# do not enable flag because GtkStatusIcon is deprecated +#GTK_CFLAGS+=" -DGTK_DISABLE_DEPRECATED " # ensure use of accessors GTK_CFLAGS+=" -DGSEAL_ENABLE " AC_SUBST(GTK_CFLAGS) @@ -104,26 +107,9 @@ AC_SUBST(LIBNOTIFY_LIBS) # Checks AppIndicator APPINDICATOR_LIBS= - PKG_CHECK_MODULES(APPINDICATOR, appindicator3-0.1, [AC_DEFINE([HAVE_APPINDICATOR],[1],[Use AppIndicator3-0.1])], [AC_MSG_WARN(AppIndicator 3-0.1 not present")]) - -if test "$APPINDICATOR_LIBS" == ""; then - PKG_CHECK_MODULES(APPINDICATOR, - appindicator-0.1 <= 0.2.9 , - [AC_DEFINE([HAVE_APPINDICATOR],[1],[Use AppIndicator 0.2.9]) - AC_DEFINE([HAVE_APPINDICATOR_029],[1],[Use AppIndicator 0.2.9]) - ], - [AC_MSG_WARN(AppIndicator 0.2.9 not present")]) -fi - -if test "$APPINDICATOR_LIBS" == ""; then - PKG_CHECK_MODULES(APPINDICATOR, - appindicator-0.1 > 0.2.9, - [AC_DEFINE([HAVE_APPINDICATOR],[1],[Use AppIndicator > 0.2.9])], - [AC_MSG_WARN("AppIndicator > 0.2.9 not present")]) -fi AM_CONDITIONAL(APPINDICATOR, test -n "$APPINDICATOR_LIBS") AC_SUBST(APPINDICATOR_CFLAGS) AC_SUBST(APPINDICATOR_LIBS) @@ -270,6 +256,7 @@ AC_CONFIG_FILES([ ]) AC_CHECK_PROGS([HELP2MAN], [help2man]) +AM_CONDITIONAL(HELP2MAN, test -n "$HELP2MAN") AC_CHECK_PROG([ASCIIDOC], [asciidoc], yes) AM_CONDITIONAL(ASCIIDOC, test -n "$ASCIIDOC")