Hello community, here is the log from the commit of package meson for openSUSE:Factory checked in at 2018-05-06 14:56:52 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/meson (Old) and /work/SRC/openSUSE:Factory/.meson.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Package is "meson" Sun May 6 14:56:52 2018 rev:32 rq:602533 version:0.46.0 Changes: -------- --- /work/SRC/openSUSE:Factory/meson/meson-testsuite.changes 2018-03-24 16:10:26.926163476 +0100 +++ /work/SRC/openSUSE:Factory/.meson.new/meson-testsuite.changes 2018-05-06 14:56:53.911088429 +0200 @@ -1,0 +2,15 @@ +Mon Apr 30 07:03:53 UTC 2018 - dimstar@opensuse.org + +- Add meson-keep-spaces-in-pc-files.patch: Keep spaces in generated + pkgconfig files (gh#mesonbuild/meson#3479). +- Rebase meson-restore-python3.4.patch. + +------------------------------------------------------------------- +Wed Apr 25 18:53:17 UTC 2018 - sor.alexei@meowr.ru + +- Update to version 0.46.0: + * See http://mesonbuild.com/Release-notes-for-0-46-0.html +- Rebase meson-test-installed-bin.patch, + meson-restore-python3.4.patch, meson-fix-gcc48.patch. + +------------------------------------------------------------------- meson.changes: same change Old: ---- meson-0.45.0.tar.gz meson-0.45.0.tar.gz.asc New: ---- meson-0.46.0.tar.gz meson-0.46.0.tar.gz.asc meson-keep-spaces-in-pc-files.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ meson-testsuite.spec ++++++ --- /var/tmp/diff_new_pack.wBjGNU/_old 2018-05-06 14:56:54.603063039 +0200 +++ /var/tmp/diff_new_pack.wBjGNU/_new 2018-05-06 14:56:54.607062892 +0200 @@ -24,25 +24,27 @@ %endif %define _name mesonbuild Name: meson%{name_ext} -Version: 0.45.0 +Version: 0.46.0 Release: 0 Summary: Python-based build system License: Apache-2.0 Group: Development/Tools/Building -Url: http://mesonbuild.com/ +URL: http://mesonbuild.com/ Source: https://github.com/%{_name}/meson/releases/download/%{version}/meson-%{version}.tar.gz Source1: https://github.com/%{_name}/meson/releases/download/%{version}/meson-%{version}.tar.gz.asc Source2: meson.keyring # PATCH-FIX-OPENSUSE meson-suse-ify-macros.patch dimstar@opensuse.org -- Make the macros non-RedHat specific: so far there are no separate {C,CXX,F}FLAGS. Patch0: meson-suse-ify-macros.patch +# PATCH-FIX-OPENSUSE meson-test-installed-bin.patch dimstar@opensuse.org -- We want the test suite to run against /usr/bin/meson coming from our meson package. +Patch1: meson-test-installed-bin.patch +# PATCH-FIX-UPSTREAM meson-keep-spaces-in-pc-files.patch gh#mesonbuild/meson#3479 dimstar@opensuse.org -- Keep spaces in generated .pc files +Patch2: meson-keep-spaces-in-pc-files.patch # PATCH-FIX-OPENSUSE meson-suse-fix-llvm-3.8.patch -- Fix LLVM 3.8 tests. -Patch1: meson-suse-fix-llvm-3.8.patch +Patch3: meson-suse-fix-llvm-3.8.patch # PATCH-FIX-OPENSUSE meson-restore-python3.4.patch -- Restore Python 3.4 support (reverts commit 0538009). -Patch2: meson-restore-python3.4.patch +Patch4: meson-restore-python3.4.patch # PATCH-FIX-OPENSUSE meson-fix-gcc48.patch sor.alexei@meowr.ru -- Fix GCC 4.8 handling for openSUSE Leap 42.x. -Patch3: meson-fix-gcc48.patch -# PATCH-FIX-OPENSUSE meson-test-installed-bin.patch dimstar@opensuse.org -- We want the test suite to run against /usr/bin/meson coming from our meson package. -Patch100: meson-test-installed-bin.patch +Patch5: meson-fix-gcc48.patch BuildRequires: python3 BuildArch: noarch %if %{testsuite} @@ -128,12 +130,13 @@ %prep %setup -q -n meson-%{version} %patch0 -p1 -%if 0%{?suse_version} < 1500 %patch1 -p1 %patch2 -p1 +%if 0%{?suse_version} < 1500 %patch3 -p1 +%patch4 -p1 +%patch5 -p1 %endif -%patch100 -p1 # Remove static boost tests from test cases/frameworks/1 boost (can't use patch due to spaces in dirname) sed -i "/static/d" test\ cases/frameworks/1\ boost/meson.build ++++++ meson.spec ++++++ --- /var/tmp/diff_new_pack.wBjGNU/_old 2018-05-06 14:56:54.639061718 +0200 +++ /var/tmp/diff_new_pack.wBjGNU/_new 2018-05-06 14:56:54.639061718 +0200 @@ -24,25 +24,27 @@ %endif %define _name mesonbuild Name: meson%{name_ext} -Version: 0.45.0 +Version: 0.46.0 Release: 0 Summary: Python-based build system License: Apache-2.0 Group: Development/Tools/Building -Url: http://mesonbuild.com/ +URL: http://mesonbuild.com/ Source: https://github.com/%{_name}/meson/releases/download/%{version}/meson-%{version}.tar.gz Source1: https://github.com/%{_name}/meson/releases/download/%{version}/meson-%{version}.tar.gz.asc Source2: meson.keyring # PATCH-FIX-OPENSUSE meson-suse-ify-macros.patch dimstar@opensuse.org -- Make the macros non-RedHat specific: so far there are no separate {C,CXX,F}FLAGS. Patch0: meson-suse-ify-macros.patch +# PATCH-FIX-OPENSUSE meson-test-installed-bin.patch dimstar@opensuse.org -- We want the test suite to run against /usr/bin/meson coming from our meson package. +Patch1: meson-test-installed-bin.patch +# PATCH-FIX-UPSTREAM meson-keep-spaces-in-pc-files.patch gh#mesonbuild/meson#3479 dimstar@opensuse.org -- Keep spaces in generated .pc files +Patch2: meson-keep-spaces-in-pc-files.patch # PATCH-FIX-OPENSUSE meson-suse-fix-llvm-3.8.patch -- Fix LLVM 3.8 tests. -Patch1: meson-suse-fix-llvm-3.8.patch +Patch3: meson-suse-fix-llvm-3.8.patch # PATCH-FIX-OPENSUSE meson-restore-python3.4.patch -- Restore Python 3.4 support (reverts commit 0538009). -Patch2: meson-restore-python3.4.patch +Patch4: meson-restore-python3.4.patch # PATCH-FIX-OPENSUSE meson-fix-gcc48.patch sor.alexei@meowr.ru -- Fix GCC 4.8 handling for openSUSE Leap 42.x. -Patch3: meson-fix-gcc48.patch -# PATCH-FIX-OPENSUSE meson-test-installed-bin.patch dimstar@opensuse.org -- We want the test suite to run against /usr/bin/meson coming from our meson package. -Patch100: meson-test-installed-bin.patch +Patch5: meson-fix-gcc48.patch BuildRequires: python3 BuildArch: noarch %if %{testsuite} @@ -128,12 +130,13 @@ %prep %setup -q -n meson-%{version} %patch0 -p1 -%if 0%{?suse_version} < 1500 %patch1 -p1 %patch2 -p1 +%if 0%{?suse_version} < 1500 %patch3 -p1 +%patch4 -p1 +%patch5 -p1 %endif -%patch100 -p1 # Remove static boost tests from test cases/frameworks/1 boost (can't use patch due to spaces in dirname) sed -i "/static/d" test\ cases/frameworks/1\ boost/meson.build ++++++ meson-0.45.0.tar.gz -> meson-0.46.0.tar.gz ++++++ ++++ 12171 lines of diff (skipped) ++++++ meson-fix-gcc48.patch ++++++ --- /var/tmp/diff_new_pack.wBjGNU/_old 2018-05-06 14:56:55.575027375 +0200 +++ /var/tmp/diff_new_pack.wBjGNU/_new 2018-05-06 14:56:55.575027375 +0200 @@ -1,6 +1,6 @@ --- a/mesonbuild/compilers/cpp.py +++ b/mesonbuild/compilers/cpp.py -@@ -102,9 +102,11 @@ class GnuCPPCompiler(GnuCompiler, CPPCom +@@ -104,9 +104,11 @@ class GnuCPPCompiler(GnuCompiler, CPPCom '3': default_warn_args + ['-Wextra', '-Wpedantic']} def get_options(self): @@ -16,27 +16,16 @@ 'STL debug mode', --- a/mesonbuild/minit.py +++ b/mesonbuild/minit.py -@@ -123,8 +123,7 @@ int main(int argc, char **argv) {{ - - hello_c_meson_template = '''project('{project_name}', 'c', - version : '{version}', -- default_options : ['warning_level=3', -- 'cpp_std=c++14']) -+ default_options : ['warning_level=3']) - - exe = executable('{exe_name}', '{source_name}', - install : true) -@@ -148,7 +147,8 @@ int main(int argc, char **argv) {{ - +@@ -149,7 +149,7 @@ int main(int argc, char **argv) {{ hello_cpp_meson_template = '''project('{project_name}', 'cpp', version : '{version}', -- default_options : ['warning_level=3']) -+ default_options : ['warning_level=3', + default_options : ['warning_level=3', +- 'cpp_std=c++14']) + 'cpp_std=c++1y']) exe = executable('{exe_name}', '{source_name}', install : true) -@@ -219,7 +219,7 @@ int main(int argc, char **argv) {{ +@@ -220,7 +220,7 @@ int main(int argc, char **argv) {{ lib_cpp_meson_template = '''project('{project_name}', 'cpp', version : '{version}', @@ -45,6 +34,15 @@ # These arguments are only used to build the shared library # not the executables that use the library. +@@ -416,7 +416,7 @@ def create_meson_build(options): + default_options = ['warning_level=3'] + if options.language == 'cpp': + # This shows how to set this very common option. +- default_options += ['cpp_std=c++14'] ++ default_options += ['cpp_std=c++1y'] + # If we get a meson.build autoformatter one day, this code could + # be simplified quite a bit. + formatted_default_options = ', '.join("'{}'".format(x) for x in default_options) --- "a/test cases/unit/16 prebuilt shared/patron.c" +++ "b/test cases/unit/16 prebuilt shared/patron.c" @@ -5,4 +5,5 @@ int main(int argc, char **argv) { ++++++ meson-keep-spaces-in-pc-files.patch ++++++
From cbc2f2d1df769123caa2e4562dbe1809cca1304d Mon Sep 17 00:00:00 2001 From: Jussi Pakkanen
Date: Sun, 29 Apr 2018 21:43:24 +0300 Subject: [PATCH] Keep separator spaces in pkg-config declarations. Closes #3479.
---
mesonbuild/modules/pkgconfig.py | 6 ++++--
run_unittests.py | 11 +++++++++++
test cases/unit/31 pkgconfig format/meson.build | 12 ++++++++++++
test cases/unit/31 pkgconfig format/somelib.c | 5 +++++
4 files changed, 32 insertions(+), 2 deletions(-)
create mode 100644 test cases/unit/31 pkgconfig format/meson.build
create mode 100644 test cases/unit/31 pkgconfig format/somelib.c
diff --git a/mesonbuild/modules/pkgconfig.py b/mesonbuild/modules/pkgconfig.py
index a3ba973f3..419a14c77 100644
--- a/mesonbuild/modules/pkgconfig.py
+++ b/mesonbuild/modules/pkgconfig.py
@@ -139,8 +139,10 @@ def add_version_reqs(self, name, version_reqs):
if version_reqs:
if name not in self.version_reqs:
self.version_reqs[name] = set()
- # We could have '>=1.0' or '>= 1.0', remove spaces to normalize
- new_vreqs = [s.replace(' ', '') for s in mesonlib.stringlistify(version_reqs)]
+ # Note that pkg-config is picky about whitespace.
+ # 'foo > 1.2' is ok but 'foo>1.2' is not.
+ # foo, bar' is ok, but 'foo,bar' is not.
+ new_vreqs = [s for s in mesonlib.stringlistify(version_reqs)]
self.version_reqs[name].update(new_vreqs)
def split_version_req(self, s):
diff --git a/run_unittests.py b/run_unittests.py
index f06c9a0ea..ce5fe14dd 100755
--- a/run_unittests.py
+++ b/run_unittests.py
@@ -3056,6 +3056,17 @@ def test_pkgconfig_internal_libraries(self):
self.init(os.path.join(testdirbase, 'app'))
self.build()
+ @unittest.skipIf(shutil.which('pkg-config') is None, 'Pkg-config not found.')
+ def test_pkgconfig_formatting(self):
+ testdir = os.path.join(self.unit_test_dir, '31 pkgconfig format')
+ self.init(testdir)
+ myenv = os.environ.copy()
+ myenv['PKG_CONFIG_PATH'] = self.privatedir
+ ro = subprocess.run(['pkg-config', '--libs', 'libsomething'], stdout=subprocess.PIPE,
+ env=myenv)
+ self.assertEqual(ro.returncode, 0)
+ self.assertIn(b'-lgobject-2.0', ro.stdout)
+ self.assertIn(b'-lgio-2.0', ro.stdout)
class LinuxArmCrossCompileTests(BasePlatformTests):
'''
diff --git a/test cases/unit/31 pkgconfig format/meson.build b/test cases/unit/31 pkgconfig format/meson.build
new file mode 100644
index 000000000..bb702401f
--- /dev/null
+++ b/test cases/unit/31 pkgconfig format/meson.build
@@ -0,0 +1,12 @@
+project('pkgformat', 'c',
+ version : '1.0')
+
+pkgg = import('pkgconfig')
+
+l = shared_library('something', 'somelib.c')
+
+pkgg.generate(libraries: l,
+ version: '1.0',
+ name: 'libsomething',
+ description: 'A library that does something',
+ requires: 'gobject-2.0 >= 2.54, gio-2.0 >= 2.54')
diff --git a/test cases/unit/31 pkgconfig format/somelib.c b/test cases/unit/31 pkgconfig format/somelib.c
new file mode 100644
index 000000000..6d876c8f2
--- /dev/null
+++ b/test cases/unit/31 pkgconfig format/somelib.c
@@ -0,0 +1,5 @@
+#include