SHA256
3
0
forked from pool/meson

Accepting request 643014 from GNOME:Next

- Update to version 0.48.1:
  * See https://github.com/mesonbuild/meson/milestone/31?closed=1
- Drop meson-Fix-handling-generated-desktop-files.patch: Fixed
  upstream. 
- Update to version 0.48.1:
  * See https://github.com/mesonbuild/meson/milestone/31?closed=1
- Drop meson-Fix-handling-generated-desktop-files.patch: Fixed
  upstream.

OBS-URL: https://build.opensuse.org/request/show/643014
OBS-URL: https://build.opensuse.org/package/show/devel:tools:building/meson?expand=0&rev=113
This commit is contained in:
Alexei Sorokin 2018-10-18 18:54:10 +00:00 committed by Git OBS Bridge
parent 5493e1453a
commit 1b51552e07
9 changed files with 37 additions and 143 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:982937ba5b380abe13f3a0c4dff944dd19d08b72870e3b039f5037c91f82835f
size 1307245

View File

@ -1,16 +0,0 @@
-----BEGIN PGP SIGNATURE-----
iQIzBAABCgAdFiEElRgfTu0U/fTkG1GNO/RpO/7rlCgFAlumorcACgkQO/RpO/7r
lChMPA//Y8IrvqHSNZNhMi1VO3ey2eUd4vkmqaqtk7s/YSZ8MobNQf6SK+svwMFd
d8YmSlHAuf19u22W1EBy9tNOy+AbkB6iNfKxDPPA3ksGPD2twXjSsoymQeuVEiRG
PS0sDH67QgGoWqQ/++KorOlbaGs1MNU7oM55NgJFNitNDKtNw2u2SckybGdSUOlT
LEPm3OQxB89MUgkyfticScfRJqI5XHjDGrjBrbNqt++5wMzDyKpNzz3yryUKDzk3
QyXWlNEtHwKn6J6pEtAuIQTXJwMzml230C3YCaxyFDNDorxSHMinSV9RoMzyN76S
kIC2gFtkYdhdRWqBgF5dv/t6ExZdQ05dA4C6wzL4bWNJiQOmELXzxhGkBcs6Cl5j
vJZ3cDsE4gIkjSQdHOvRr6/9vN+BGaZDD4pP1kZ2VaVF82dftMWEV6gpxiPuyJMz
2tVz+zZQONQcj7JR8+Vi8jm2s3dCyUfAlOImfSLkIQvOEIAKSowh5xGdMp6GFpnA
J3LIzsQqxozazHqxDePSpkebODo9HfTHnfb5Ou8Dh/hOGu2PddBx/iIeTtzFrdji
P1mFhb5pq/b8L+3N96DehyXgJjCk4h8Ojjur+BDD8CSJCoM5gS4lWD0t4fiOVceX
YQp14oIFGtrnq3utaq6jPNbF2nW7Hl40sXniVZ+V2hCdZjKwoeE=
=ErKv
-----END PGP SIGNATURE-----

3
meson-0.48.1.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:425d12edbb81498314926afa93a3eb2fca4ca6929cbe0f8abeb6ab45d1d9fa8f
size 1310184

16
meson-0.48.1.tar.gz.asc Normal file
View File

@ -0,0 +1,16 @@
-----BEGIN PGP SIGNATURE-----
iQIzBAABCgAdFiEElRgfTu0U/fTkG1GNO/RpO/7rlCgFAlvHYC8ACgkQO/RpO/7r
lChNQg/+PEvQNB7bEugB3XxVoYyFNzLBeByZ7wRFTAGbJflIZj6ar9OaoPTQOHZX
WdQ5oZr2pYx5ZNAoDWJ2B2maUBo3HIR35xoAV83vC6VJEkFr+A6DrtXVFMcgiPhv
v1wWEFvAr2gyVde9dFi311ex1N/k5pfQDZsyAsBFiIOMuLbVgYXCOKZ1e5LhBQU7
n4q/mfpLwhMJ8LxXp1j9sdaGu1hEarF7qQisyb8Le9bPQdtKCA+j1H48OUefuSlj
UT92BOuV1v8dI8gknoe5ISpXR2CIDUjDUbcKz2orZo3C6w/hgZYD/TmA3hB/Sr1/
0wDFpsRpXJsE/G0zSZNvAN9bdsEGPbeTF+4SaNAMI4kR8jxuCT0Koe/Q/oE40i9o
eIIh8cwQ85G6n4Wb2ABdzrXqog4kyQniq1qd87XcFNPHHqV58CoRJ3ZNpa9/XHld
DyGugVWeoj2+DMQKnGkT9llM+p40aZS2hUT/TDjjhQ+DZpX2a60ApLeDhYVqt15t
/6Dyxps3K/s5TCacyji4u0zxvZPtkh44zsFHScf4LZa/t/riJIjBbupcMzFIfF85
ZAe/XD4JmwzdnOAbVcjfeFkYk7XBg5NxZqPTO3JBfyRt1XQ8a+I/NigTXCU89SzL
aINOxnYHqcsSvHbBrMrJcF/jrGBcptbvOCNVa8atLOk8vx5sjrk=
=ZJhg
-----END PGP SIGNATURE-----

View File

@ -1,116 +0,0 @@
From 2ff69b20df0864182fdf2b146d29dc67d0cb9a5b Mon Sep 17 00:00:00 2001
From: Jussi Pakkanen <jpakkane@gmail.com>
Date: Mon, 1 Oct 2018 20:31:48 +0300
Subject: [PATCH] Fix handling generated .desktop files. Closes #4304.
---
mesonbuild/modules/i18n.py | 22 ++++++++++---------
.../6 gettext/generated/desktopgenerator.py | 9 ++++++++
.../6 gettext/generated/meson.build | 14 ++++++++++++
.../generated/something.desktop.in.in | 15 +++++++++++++
test cases/frameworks/6 gettext/meson.build | 1 +
5 files changed, 51 insertions(+), 10 deletions(-)
create mode 100644 test cases/frameworks/6 gettext/generated/desktopgenerator.py
create mode 100644 test cases/frameworks/6 gettext/generated/meson.build
create mode 100644 test cases/frameworks/6 gettext/generated/something.desktop.in.in
diff --git a/mesonbuild/modules/i18n.py b/mesonbuild/modules/i18n.py
index 0fc052b778..8b5e18162f 100644
--- a/mesonbuild/modules/i18n.py
+++ b/mesonbuild/modules/i18n.py
@@ -82,17 +82,19 @@ def merge_file(self, state, args, kwargs):
kwargs['command'] = command
inputfile = kwargs['input']
- if isinstance(inputfile, str):
- inputfile = mesonlib.File.from_source_file(state.environment.source_dir,
+ if hasattr(inputfile, 'held_object'):
+ ct = build.CustomTarget(kwargs['output'] + '_merge', state.subdir, state.subproject, kwargs)
+ else:
+ if isinstance(inputfile, str):
+ inputfile = mesonlib.File.from_source_file(state.environment.source_dir,
state.subdir, inputfile)
- output = kwargs['output']
- ifile_abs = inputfile.absolute_path(state.environment.source_dir,
- state.environment.build_dir)
- values = mesonlib.get_filenames_templates_dict([ifile_abs], None)
- outputs = mesonlib.substitute_values([output], values)
- output = outputs[0]
-
- ct = build.CustomTarget(output + '_' + state.subdir + '_merge', state.subdir, state.subproject, kwargs)
+ output = kwargs['output']
+ ifile_abs = inputfile.absolute_path(state.environment.source_dir,
+ state.environment.build_dir)
+ values = mesonlib.get_filenames_templates_dict([ifile_abs], None)
+ outputs = mesonlib.substitute_values([output], values)
+ output = outputs[0]
+ ct = build.CustomTarget(output + '_' + state.subdir + '_merge', state.subdir, state.subproject, kwargs)
return ModuleReturnValue(ct, [ct])
@FeatureNewKwargs('i18n.gettext', '0.37.0', ['preset'])
diff --git a/test cases/frameworks/6 gettext/generated/desktopgenerator.py b/test cases/frameworks/6 gettext/generated/desktopgenerator.py
new file mode 100644
index 0000000000..150ed0435f
--- /dev/null
+++ b/test cases/frameworks/6 gettext/generated/desktopgenerator.py
@@ -0,0 +1,9 @@
+#!/usr/bin/env python3
+
+import sys, shutil
+
+ifile = sys.argv[1]
+ofile = sys.argv[2]
+
+os.unlink(ofile)
+shutil.copy(ifile, ofile)
diff --git a/test cases/frameworks/6 gettext/generated/meson.build b/test cases/frameworks/6 gettext/generated/meson.build
new file mode 100644
index 0000000000..02e61ba352
--- /dev/null
+++ b/test cases/frameworks/6 gettext/generated/meson.build
@@ -0,0 +1,14 @@
+dgen = find_program('desktopgenerator.py')
+
+desktop_in_file = custom_target('something.desktop.in',
+ input : ['something.desktop.in.in'],
+ output : 'something.desktop.in',
+ command : [dgen, '@INPUT@', '@OUTPUT@'],
+)
+
+i18n.merge_file(
+ input : desktop_in_file,
+ output : 'something.desktop',
+ type : 'desktop',
+ po_dir : '../po',
+)
diff --git a/test cases/frameworks/6 gettext/generated/something.desktop.in.in b/test cases/frameworks/6 gettext/generated/something.desktop.in.in
new file mode 100644
index 0000000000..e2094fdc22
--- /dev/null
+++ b/test cases/frameworks/6 gettext/generated/something.desktop.in.in
@@ -0,0 +1,15 @@
+[Desktop Entry]
+Name=Something doer
+Comment=Do something
+# Translators: Search terms to find this application. Do NOT translate or localize the semicolons! The list MUST also end with a semicolon!
+Keywords=zip;tar;extract;unpack;
+TryExec=file-roller
+Exec=file-roller %U
+StartupNotify=true
+Terminal=false
+Type=Application
+# Translators: Do NOT translate or transliterate this text (this is an icon file name)!
+Icon=something
+Categories=GTK;GNOME;Utility
+X-GNOME-DocPath=file-roller/file-roller.xml
+X-GNOME-UsesNotifications=true
diff --git a/test cases/frameworks/6 gettext/meson.build b/test cases/frameworks/6 gettext/meson.build
index 9b84856060..09ef9829eb 100644
--- a/test cases/frameworks/6 gettext/meson.build
+++ b/test cases/frameworks/6 gettext/meson.build
@@ -15,3 +15,4 @@ subdir('po')
subdir('src')
subdir('data')
subdir('data2')
+subdir('generated')

View File

@ -1,3 +1,11 @@
-------------------------------------------------------------------
Thu Oct 18 12:52:39 UTC 2018 - bjorn.lie@gmail.com
- Update to version 0.48.1:
* See https://github.com/mesonbuild/meson/milestone/31?closed=1
- Drop meson-Fix-handling-generated-desktop-files.patch: Fixed
upstream.
-------------------------------------------------------------------
Fri Oct 5 22:21:26 UTC 2018 - bjorn.lie@gmail.com

View File

@ -24,7 +24,7 @@
%endif
%define _name mesonbuild
Name: meson%{name_ext}
Version: 0.48.0
Version: 0.48.1
Release: 0
Summary: Python-based build system
License: Apache-2.0
@ -43,8 +43,6 @@ Patch2: meson-suse-fix-llvm-3.8.patch
Patch3: 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.
Patch4: meson-fix-gcc48.patch
# PATCH-FIX-UPSTREAM meson-Fix-handling-generated-desktop-files.patch -- Fix handling generated .desktop files
Patch5: meson-Fix-handling-generated-desktop-files.patch
BuildRequires: python3-base
BuildRequires: python3-setuptools
@ -140,7 +138,6 @@ This package provides support for meson.build files in Vim.
%patch3 -p1
%patch4 -p1
%endif
%patch5 -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

View File

@ -1,3 +1,11 @@
-------------------------------------------------------------------
Thu Oct 18 12:52:39 UTC 2018 - bjorn.lie@gmail.com
- Update to version 0.48.1:
* See https://github.com/mesonbuild/meson/milestone/31?closed=1
- Drop meson-Fix-handling-generated-desktop-files.patch: Fixed
upstream.
-------------------------------------------------------------------
Fri Oct 5 22:21:26 UTC 2018 - bjorn.lie@gmail.com

View File

@ -24,7 +24,7 @@
%endif
%define _name mesonbuild
Name: meson%{name_ext}
Version: 0.48.0
Version: 0.48.1
Release: 0
Summary: Python-based build system
License: Apache-2.0
@ -43,8 +43,6 @@ Patch2: meson-suse-fix-llvm-3.8.patch
Patch3: 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.
Patch4: meson-fix-gcc48.patch
# PATCH-FIX-UPSTREAM meson-Fix-handling-generated-desktop-files.patch -- Fix handling generated .desktop files
Patch5: meson-Fix-handling-generated-desktop-files.patch
BuildRequires: python3-base
BuildRequires: python3-setuptools
@ -140,7 +138,6 @@ This package provides support for meson.build files in Vim.
%patch3 -p1
%patch4 -p1
%endif
%patch5 -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