buildroot/package/libglib2/0002-allow-explicit-disabling-of-tests.patch
Adam Duskett 01d3360eb6 package/libglib2: bump to 2.62.3
Changes include:
 - Rename 0002-add-option-to-build-tests.patch to
   0002-allow-explicit-disabling-of-tests.patch to work with 2.62.3.

   Upstream now has an option called "installed_tests," which can be used to
   prevent the unit tests from being built. However, the check only works for
   cross-compiling and not host builds, which would mean that the tests still
   build when compiling the host variant.

   This conditional causes an error on older systems such as Debian8 or Centos7
   because the command `objcopy --add-symbol` is used when building the test
   "test_resources2," which is not available with the older version of objcopy
   provided by those distributions.

   Removing the conditionals and checking for just the installed_tests_enabled
   option allows for a much simpler patch.

 - Change -Dtests=false to -Dinstalled_tests=false in libglib2.mk as per the
   above comment.

           br-arm-full [1/6]: OK
br-arm-cortex-a9-glibc [2/6]: OK
 br-arm-cortex-m4-full [3/6]: SKIPPED
        br-x86-64-musl [4/6]: OK
    br-arm-full-static [5/6]: OK
          sourcery-arm [6/6]: OK

Signed-off-by: Adam Duskett <Aduskett@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-11-30 23:07:33 +01:00

38 lines
1.4 KiB
Diff
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

From cdccbc6ec36243463613cb32d7058c26c3c51e16 Mon Sep 17 00:00:00 2001
From: Adam Duskett <Aduskett@gmail.com>
Date: Wed, 18 Sep 2019 09:50:00 -0700
Subject: [PATCH] allow explicit disabling of tests
Upstream won't build tests when cross-compiling. However; this means still
building the tests during a host build. Building the tests causes build
failures on older distributions such as CentOS 6 and Debian 7 because the
command `objcopy --add-symbol` is used when building the test
"test_resources2," which is not available with the older version of objcopy
provided by the distributions.
Instead, remove the conditional checks which set build_tests and only check if
installed_tests_enabled is passed.
Signed-off-by: Adam Duskett <Aduskett@gmail.com>
Refresh for 2.62.2
---
meson.build | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/meson.build b/meson.build
index 99806d0..3206603 100644
--- a/meson.build
+++ b/meson.build
@@ -77,7 +77,7 @@ installed_tests_template = files('template.test.in')
installed_tests_template_tap = files('template-tap.test.in')
# Dont build the tests unless we can run them (either natively, in an exe wrapper, or by installing them for later use)
-build_tests = not meson.is_cross_build() or (meson.is_cross_build() and meson.has_exe_wrapper()) or installed_tests_enabled
+build_tests = installed_tests_enabled
add_project_arguments('-D_GNU_SOURCE', language: 'c')
--
2.23.0