meson/0003-rpm-use-VPATH-macro.patch
Igor Gnatenko d6502d0e67 Backport more RPM macro fixes (FPC ticket #655)
Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
2016-12-15 21:34:40 +01:00

70 lines
2.5 KiB
Diff

From be232228b77e9d91810efb62765f8bdf69584caa Mon Sep 17 00:00:00 2001
From: Igor Gnatenko <i.gnatenko.brain@gmail.com>
Date: Tue, 13 Dec 2016 19:20:03 +0100
Subject: [PATCH 3/3] rpm: use VPATH macro
This is more or less standardized way to have one variable which
will work for all buildsystems defined in redhat-rpm-config.
Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
(cherry picked from commit b80f8b2dc2d1ca838c814ae1b8842860a39de175)
---
data/macros.meson | 32 +++++++++++++++-----------------
1 file changed, 15 insertions(+), 17 deletions(-)
diff --git a/data/macros.meson b/data/macros.meson
index e8b15cdd..14d39da4 100644
--- a/data/macros.meson
+++ b/data/macros.meson
@@ -1,6 +1,4 @@
%__meson %{_bindir}/meson
-%__sourcedir .
-%__builddir %{_target_platform}
%meson \
export CFLAGS="${CFLAGS:-%__global_cflags}" \
@@ -8,25 +6,25 @@
export FFLAGS="${FFLAGS:-%__global_fflags}" \
export FCFLAGS="${FCFLAGS:-%__global_fcflags}" \
export LDFLAGS="${LDFLAGS:-%__global_ldflags}" \
- %{__meson} \\\
- --buildtype=plain \\\
- --prefix=%{_prefix} \\\
- --libdir=%{_libdir} \\\
- --libexecdir=%{_libexecdir} \\\
- --bindir=%{_bindir} \\\
- --includedir=%{_includedir} \\\
- --datadir=%{_datadir} \\\
- --mandir=%{_mandir} \\\
- --localedir=%{_datadir}/locale \\\
- --sysconfdir=%{_sysconfdir} \\\
- %{__sourcedir} %{__builddir} \\\
+ %{__meson} \\\
+ --buildtype=plain \\\
+ --prefix=%{_prefix} \\\
+ --libdir=%{_libdir} \\\
+ --libexecdir=%{_libexecdir} \\\
+ --bindir=%{_bindir} \\\
+ --includedir=%{_includedir} \\\
+ --datadir=%{_datadir} \\\
+ --mandir=%{_mandir} \\\
+ --localedir=%{_datadir}/locale \\\
+ --sysconfdir=%{_sysconfdir} \\\
+ %{_vpath_srcdir} %{_vpath_builddir} \\\
%{nil}
%meson_build \
- %ninja_build -C %{__builddir}
+ %ninja_build -C %{_vpath_builddir}
%meson_install \
- %ninja_install -C %{__builddir}
+ %ninja_install -C %{_vpath_builddir}
%meson_test \
- %ninja_test -C %{__builddir}
+ %ninja_test -C %{_vpath_builddir}
--
2.11.0