Use meson build system
The last tarball has been generated with meson, so it doesn't have a pre-generated configure script. As this is the last release with autotools support, it's better to just move to meson instead of messing around with autogen.
This commit is contained in:
parent
b00b876777
commit
66bc024dd4
37
0001-build-Fix-installation-with-DESTDIR-set.patch
Normal file
37
0001-build-Fix-installation-with-DESTDIR-set.patch
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
From 4a7c705a8c181eda6bb4e03a5674aab393331a04 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Bastien Nocera <hadess@hadess.net>
|
||||||
|
Date: Fri, 29 Nov 2019 17:50:48 +0100
|
||||||
|
Subject: [PATCH] build: Fix installation with DESTDIR set
|
||||||
|
|
||||||
|
os.path.join() doesn't simply concatenate paths as:
|
||||||
|
If a component is an absolute path, all previous components are
|
||||||
|
thrown away and joining continues from the absolute path component.
|
||||||
|
|
||||||
|
Strip the leading '/' from the configured prefix if needed to prevent
|
||||||
|
that.
|
||||||
|
|
||||||
|
Closes: https://gitlab.gnome.org/GNOME/gjs/issues/291
|
||||||
|
---
|
||||||
|
build/symlink-gjs.py | 6 +++++-
|
||||||
|
1 file changed, 5 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/build/symlink-gjs.py b/build/symlink-gjs.py
|
||||||
|
index 365a3211..2c6f0a57 100644
|
||||||
|
--- a/build/symlink-gjs.py
|
||||||
|
+++ b/build/symlink-gjs.py
|
||||||
|
@@ -12,7 +12,11 @@ destdir = os.environ.get('DESTDIR')
|
||||||
|
install_prefix = os.environ.get('MESON_INSTALL_PREFIX')
|
||||||
|
bindir = sys.argv[1]
|
||||||
|
if destdir is not None:
|
||||||
|
- installed_bin_dir = os.path.join(destdir, install_prefix, bindir)
|
||||||
|
+ # os.path.join() doesn't concat paths if one of them is absolute
|
||||||
|
+ if install_prefix[0] == '/' and os.name is not 'nt':
|
||||||
|
+ installed_bin_dir = os.path.join(destdir, install_prefix[1:], bindir)
|
||||||
|
+ else:
|
||||||
|
+ installed_bin_dir = os.path.join(destdir, install_prefix, bindir)
|
||||||
|
else:
|
||||||
|
installed_bin_dir = os.path.join(install_prefix, bindir)
|
||||||
|
|
||||||
|
--
|
||||||
|
2.23.0
|
||||||
|
|
12
gjs.spec
12
gjs.spec
@ -16,11 +16,14 @@ License: MIT and (MPLv1.1 or GPLv2+ or LGPLv2+)
|
|||||||
URL: https://wiki.gnome.org/Projects/Gjs
|
URL: https://wiki.gnome.org/Projects/Gjs
|
||||||
Source0: https://download.gnome.org/sources/%{name}/1.58/%{name}-%{version}.tar.xz
|
Source0: https://download.gnome.org/sources/%{name}/1.58/%{name}-%{version}.tar.xz
|
||||||
|
|
||||||
|
Patch0: 0001-build-Fix-installation-with-DESTDIR-set.patch
|
||||||
|
|
||||||
BuildRequires: cairo-gobject-devel
|
BuildRequires: cairo-gobject-devel
|
||||||
BuildRequires: chrpath
|
BuildRequires: chrpath
|
||||||
BuildRequires: dbus-daemon
|
BuildRequires: dbus-daemon
|
||||||
BuildRequires: dbus-glib-devel
|
BuildRequires: dbus-glib-devel
|
||||||
BuildRequires: gcc-c++
|
BuildRequires: gcc-c++
|
||||||
|
BuildRequires: meson
|
||||||
BuildRequires: gettext
|
BuildRequires: gettext
|
||||||
BuildRequires: glib2-devel >= %{glib2_version}
|
BuildRequires: glib2-devel >= %{glib2_version}
|
||||||
BuildRequires: gobject-introspection-devel >= %{gobject_introspection_version}
|
BuildRequires: gobject-introspection-devel >= %{gobject_introspection_version}
|
||||||
@ -62,12 +65,11 @@ the functionality of the installed gjs package.
|
|||||||
%autosetup -p1
|
%autosetup -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%configure --disable-static --enable-installed-tests
|
%meson
|
||||||
|
%meson_build
|
||||||
make %{?_smp_mflags} V=1
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%make_install
|
%meson_install
|
||||||
|
|
||||||
# Remove lib64 rpaths
|
# Remove lib64 rpaths
|
||||||
chrpath --delete %{buildroot}%{_bindir}/gjs-console
|
chrpath --delete %{buildroot}%{_bindir}/gjs-console
|
||||||
@ -76,7 +78,7 @@ chrpath --delete %{buildroot}%{_libexecdir}/gjs/installed-tests/minijasmine
|
|||||||
find %{buildroot} -name '*.la' -exec rm -f {} ';'
|
find %{buildroot} -name '*.la' -exec rm -f {} ';'
|
||||||
|
|
||||||
%check
|
%check
|
||||||
#make check
|
#meson_test
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%license COPYING
|
%license COPYING
|
||||||
|
Loading…
Reference in New Issue
Block a user