Commit 6b78a90d authored by Simon McVittie's avatar Simon McVittie

Only build GLib-based tests on amd64

This makes it a lot easier to satisfy the build-dependencies on OSs
where GLib is not fully multiarch, like Debian 8 'jessie' and
SteamOS 2 'brewmaster'.
Signed-off-by: Simon McVittie's avatarSimon McVittie <smcv@collabora.com>
parent 97f7e8dd
......@@ -68,7 +68,16 @@ PKG_CHECK_MODULES([LIBELF], [libelf >= 0.152], [have_libelf=yes], [
LIBELF_LIBS=-lelf
])
PKG_CHECK_MODULES([GLIB], [glib-2.0], [have_glib=yes], [have_glib=no])
AC_ARG_WITH([glib],
[AS_HELP_STRING([--with-glib=yes/no],
[use GLib for better test coverage [default=yes]])],
[],
[with_glib=auto])
AS_IF([test "$with_glib" != no],
[PKG_CHECK_MODULES([GLIB], [glib-2.0], [have_glib=yes], [have_glib=no])],
[have_glib=no])
AS_IF([test "$with_glib" = yes && test "$have_glib" = no],
[AC_MSG_ERROR([GLib required but not found])])
AM_CONDITIONAL([HAVE_GLIB], [test "x$have_glib" = xyes])
AC_ARG_ENABLE([host-prefix],
......
......@@ -13,7 +13,8 @@ Build-Depends:
gtk-doc-tools,
libelf-dev,
libipc-run-perl,
libglib2.0-dev,
libglib2.0-0 <!nocheck>,
libglib2.0-dev [amd64],
libjpeg62-turbo <!nocheck> | libjpeg62 (>= 6b1) <!nocheck>,
perl:any,
xsltproc,
......
......@@ -11,6 +11,12 @@ confflags = \
--libexecdir=\$${exec_prefix}/lib/libcapsule \
$(NULL)
ifeq ($(DEB_HOST_ARCH),amd64)
confflags += --with-glib
else
confflags += --without-glib
endif
override_dh_auto_configure:
dh_auto_configure -- $(confflags)
......
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