printers: Check for CUPS header files
Don't build Printers panel if there are not CUPS header files.
This commit is contained in:
parent
7d7e249627
commit
a03eb1664c
2 changed files with 13 additions and 5 deletions
13
configure.ac
13
configure.ac
|
@ -107,10 +107,15 @@ PKG_CHECK_MODULES(PULSEAUDIO,
|
||||||
libpulse-mainloop-glib >= $PA_REQUIRED_VERSION)
|
libpulse-mainloop-glib >= $PA_REQUIRED_VERSION)
|
||||||
AC_SUBST(PULSEAUDIO_CFLAGS)
|
AC_SUBST(PULSEAUDIO_CFLAGS)
|
||||||
AC_SUBST(PULSEAUDIO_LIBS)
|
AC_SUBST(PULSEAUDIO_LIBS)
|
||||||
# check for cups
|
|
||||||
AC_CHECK_HEADERS(cups/cups.h cups/http.h cups/ipp.h)
|
AC_CHECK_HEADERS([cups/cups.h cups/http.h cups/ipp.h], have_cups=yes, have_cups=no)
|
||||||
CUPS_LIBS=-lcups
|
if test x$have_cups = xyes ; then
|
||||||
AC_SUBST(CUPS_LIBS)
|
CUPS_LIBS=-lcups
|
||||||
|
AC_SUBST(CUPS_LIBS)
|
||||||
|
else
|
||||||
|
AC_MSG_WARN(*** Printers panel will not be built (CUPS header files not found) ***)
|
||||||
|
fi
|
||||||
|
AM_CONDITIONAL(BUILD_PRINTERS, [test x$have_cups = xyes])
|
||||||
|
|
||||||
gtk_lib_dir=`$PKG_CONFIG --variable libdir gtk+-3.0`
|
gtk_lib_dir=`$PKG_CONFIG --variable libdir gtk+-3.0`
|
||||||
gtk_binary_version=`$PKG_CONFIG --variable gtk_binary_version gtk+-3.0`
|
gtk_binary_version=`$PKG_CONFIG --variable gtk_binary_version gtk+-3.0`
|
||||||
|
|
|
@ -5,7 +5,6 @@ SUBDIRS= \
|
||||||
display \
|
display \
|
||||||
media \
|
media \
|
||||||
mouse \
|
mouse \
|
||||||
printers \
|
|
||||||
region \
|
region \
|
||||||
network \
|
network \
|
||||||
info \
|
info \
|
||||||
|
@ -15,4 +14,8 @@ SUBDIRS= \
|
||||||
user-accounts \
|
user-accounts \
|
||||||
datetime
|
datetime
|
||||||
|
|
||||||
|
if BUILD_PRINTERS
|
||||||
|
SUBDIRS += printers
|
||||||
|
endif
|
||||||
|
|
||||||
-include $(top_srcdir)/git.mk
|
-include $(top_srcdir)/git.mk
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue