From patchwork Sat Mar 9 18:21:28 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Petazzoni X-Patchwork-Id: 226372 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from whitealder.osuosl.org (whitealder.osuosl.org [140.211.166.138]) by ozlabs.org (Postfix) with ESMTP id 4E6792C0338 for ; Sun, 10 Mar 2013 05:23:37 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id C35588C8CE; Sat, 9 Mar 2013 18:23:35 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id dwn0zlKkWtJY; Sat, 9 Mar 2013 18:23:33 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id 5FA7C8BEBB; Sat, 9 Mar 2013 18:23:32 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from fraxinus.osuosl.org (fraxinus.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id 5A6E78F74B for ; Sat, 9 Mar 2013 18:23:38 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 46009103B7D for ; Sat, 9 Mar 2013 18:23:16 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 2tXxCG3QOOXp for ; Sat, 9 Mar 2013 18:23:03 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail.free-electrons.com (mail.free-electrons.com [94.23.35.102]) by fraxinus.osuosl.org (Postfix) with ESMTP id 26BAD10B9B8 for ; Sat, 9 Mar 2013 18:21:24 +0000 (UTC) Received: by mail.free-electrons.com (Postfix, from userid 106) id B82BFB5D; Sat, 9 Mar 2013 19:21:40 +0100 (CET) Received: from localhost (humanoidz.org [82.247.183.72]) by mail.free-electrons.com (Postfix) with ESMTPSA id 835FB7FF for ; Sat, 9 Mar 2013 19:21:39 +0100 (CET) From: Thomas Petazzoni To: buildroot@uclibc.org Date: Sat, 9 Mar 2013 19:21:28 +0100 Message-Id: <1362853290-15592-4-git-send-email-thomas.petazzoni@free-electrons.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1362853290-15592-1-git-send-email-thomas.petazzoni@free-electrons.com> References: <1362853290-15592-1-git-send-email-thomas.petazzoni@free-electrons.com> Subject: [Buildroot] [PATCH 3/5] libglib2: don't build tests X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: buildroot-bounces@busybox.net Add a patch that provides an additional --disable-tests option to the configure script. Disabling the build of tests has two benefits: * Prevents the build of a lot of code that doesn't build on noMMU platforms. * Reduces the build time. Signed-off-by: Thomas Petazzoni --- package/libglib2/libglib2-no-tests.patch | 117 ++++++++++++++++++++++++++++++ package/libglib2/libglib2.mk | 7 +- 2 files changed, 123 insertions(+), 1 deletion(-) create mode 100644 package/libglib2/libglib2-no-tests.patch diff --git a/package/libglib2/libglib2-no-tests.patch b/package/libglib2/libglib2-no-tests.patch new file mode 100644 index 0000000..81b5af2 --- /dev/null +++ b/package/libglib2/libglib2-no-tests.patch @@ -0,0 +1,117 @@ +Add a --disable-tests option to the configure script + +Disabling the build of tests has two benefits: + * Prevents the build of a lot of code that doesn't build on noMMU + platforms. + * Reduces the build time. + +Signed-off-by: Thomas Petazzoni + +Index: libglib2-2.30.3/Makefile.am +=================================================================== +--- libglib2-2.30.3.orig/Makefile.am 2012-03-11 22:43:28.000000000 +0100 ++++ libglib2-2.30.3/Makefile.am 2013-03-09 17:32:01.000000000 +0100 +@@ -6,7 +6,11 @@ + + ACLOCAL_AMFLAGS = -I m4macros ${ACLOCAL_FLAGS} + +-SUBDIRS = . m4macros glib gmodule gthread gobject gio tests po docs ++if BUILD_TESTS ++TEST_SUBDIR = tests ++endif ++ ++SUBDIRS = . m4macros glib gmodule gthread gobject gio $(TEST_SUBDIR) po docs + DIST_SUBDIRS = $(SUBDIRS) build + + bin_SCRIPTS = glib-gettextize +Index: libglib2-2.30.3/gio/Makefile.am +=================================================================== +--- libglib2-2.30.3.orig/gio/Makefile.am 2012-03-11 22:44:19.000000000 +0100 ++++ libglib2-2.30.3/gio/Makefile.am 2013-03-09 17:32:38.000000000 +0100 +@@ -282,7 +282,11 @@ + + endif + +-SUBDIRS += tests ++if BUILD_TESTS ++TEST_SUBDIR = tests ++endif ++ ++SUBDIRS += $(TEST_SUBDIR) + + libgio_2_0_la_SOURCES = \ + gappinfo.c \ +Index: libglib2-2.30.3/configure.ac +=================================================================== +--- libglib2-2.30.3.orig/configure.ac 2013-03-09 17:30:55.000000000 +0100 ++++ libglib2-2.30.3/configure.ac 2013-03-09 17:37:27.000000000 +0100 +@@ -234,11 +234,18 @@ + [AC_HELP_STRING([--disable-rebuilds], + [disable all source autogeneration rules])],, + [enable_rebuilds=yes]) ++AC_ARG_ENABLE(tests, ++ [AC_HELP_STRING([--disable-tests], ++ [disable all tests])], ++ enable_tests=${enableval}, ++ enable_tests=yes) + + if test "x$enable_threads" != "xyes"; then + enable_threads=no + fi + ++AM_CONDITIONAL(BUILD_TESTS, [test x$enable_tests = xyes]) ++ + AC_MSG_CHECKING([whether to enable garbage collector friendliness]) + if test "x$enable_gc_friendly" = "xyes"; then + AC_DEFINE(ENABLE_GC_FRIENDLY_DEFAULT, 1, [Whether to enable GC friendliness by default]) +Index: libglib2-2.30.3/glib/Makefile.am +=================================================================== +--- libglib2-2.30.3.orig/glib/Makefile.am 2012-03-11 22:43:28.000000000 +0100 ++++ libglib2-2.30.3/glib/Makefile.am 2013-03-09 18:02:59.000000000 +0100 +@@ -42,7 +42,11 @@ + gregex_h = + endif + +-SUBDIRS = libcharset $(PRINTF_SUBDIR) $(MAYBE_PCRE) update-pcre . tests ++if BUILD_TESTS ++TEST_SUBDIR = tests ++endif ++ ++SUBDIRS = libcharset $(PRINTF_SUBDIR) $(MAYBE_PCRE) update-pcre . $(TEST_SUBDIR) + + DIST_SUBDIRS = libcharset gnulib pcre update-pcre tests + +Index: libglib2-2.30.3/gobject/Makefile.am +=================================================================== +--- libglib2-2.30.3.orig/gobject/Makefile.am 2012-03-11 22:43:29.000000000 +0100 ++++ libglib2-2.30.3/gobject/Makefile.am 2013-03-09 18:03:40.000000000 +0100 +@@ -4,7 +4,11 @@ + ## Process this file with automake to produce Makefile.in + include $(top_srcdir)/Makefile.decl + +-SUBDIRS = . tests ++if BUILD_TESTS ++TEST_SUBDIR = tests ++endif ++ ++SUBDIRS = . $(TEST_SUBDIR) + + BUILT_SOURCES= + CLEANFILES= +Index: libglib2-2.30.3/gthread/Makefile.am +=================================================================== +--- libglib2-2.30.3.orig/gthread/Makefile.am 2012-03-11 22:43:29.000000000 +0100 ++++ libglib2-2.30.3/gthread/Makefile.am 2013-03-09 18:04:16.000000000 +0100 +@@ -1,7 +1,11 @@ + ## Process this file with automake to produce Makefile.in + include $(top_srcdir)/Makefile.decl + +-SUBDIRS = . tests ++if BUILD_TESTS ++TEST_SUBDIR = tests ++endif ++ ++SUBDIRS = . $(TEST_SUBDIR) + DIST_SUBDIRS = tests + + AM_CPPFLAGS = \ diff --git a/package/libglib2/libglib2.mk b/package/libglib2/libglib2.mk index 278e635..b108b89 100644 --- a/package/libglib2/libglib2.mk +++ b/package/libglib2/libglib2.mk @@ -9,6 +9,8 @@ LIBGLIB2_VERSION = $(LIBGLIB2_VERSION_MAJOR).$(LIBGLIB2_VERSION_MINOR) LIBGLIB2_SOURCE = glib-$(LIBGLIB2_VERSION).tar.xz LIBGLIB2_SITE = http://ftp.gnome.org/pub/gnome/sources/glib/$(LIBGLIB2_VERSION_MAJOR) +LIBGLIB2_AUTORECONF = YES +HOST_LIBGLIB2_AUTORECONF = YES LIBGLIB2_INSTALL_STAGING = YES LIBGLIB2_INSTALL_STAGING_OPT = DESTDIR=$(STAGING_DIR) LDFLAGS=-L$(STAGING_DIR)/usr/lib install @@ -61,7 +63,10 @@ HOST_LIBGLIB2_CONF_OPT = \ --enable-debug=no \ --disable-dtrace \ --disable-systemtap \ - --disable-gcov + --disable-gcov \ + --disable-tests + +LIBGLIB2_CONF_OPT += --disable-tests LIBGLIB2_DEPENDENCIES = host-pkgconf host-libglib2 libffi zlib $(if $(BR2_NEEDS_GETTEXT),gettext)