Use bundled rust deps on RHEL
This commit is contained in:
parent
1ab4079edc
commit
f81621bf41
16
loupe.spec
16
loupe.spec
@ -1,5 +1,11 @@
|
|||||||
%bcond_without check
|
%bcond_without check
|
||||||
|
|
||||||
|
%if 0%{?rhel}
|
||||||
|
%global bundled_rust_deps 1
|
||||||
|
%else
|
||||||
|
%global bundled_rust_deps 0
|
||||||
|
%endif
|
||||||
|
|
||||||
%global tarball_version %%(echo %{version} | tr '~' '.')
|
%global tarball_version %%(echo %{version} | tr '~' '.')
|
||||||
|
|
||||||
Name: loupe
|
Name: loupe
|
||||||
@ -28,6 +34,12 @@ Source0: https://download.gnome.org/sources/loupe/45/loupe-%{tarball_vers
|
|||||||
BuildRequires: cargo-rpm-macros
|
BuildRequires: cargo-rpm-macros
|
||||||
BuildRequires: itstool
|
BuildRequires: itstool
|
||||||
BuildRequires: meson
|
BuildRequires: meson
|
||||||
|
%if 0%{?bundled_rust_deps}
|
||||||
|
BuildRequires: pkgconfig(gtk4)
|
||||||
|
BuildRequires: pkgconfig(gweather4)
|
||||||
|
BuildRequires: pkgconfig(lcms2)
|
||||||
|
BuildRequires: pkgconfig(libadwaita-1)
|
||||||
|
%endif
|
||||||
BuildRequires: /usr/bin/appstream-util
|
BuildRequires: /usr/bin/appstream-util
|
||||||
BuildRequires: /usr/bin/desktop-file-validate
|
BuildRequires: /usr/bin/desktop-file-validate
|
||||||
|
|
||||||
@ -55,13 +67,17 @@ Features:
|
|||||||
%prep
|
%prep
|
||||||
%autosetup -p1 -n loupe-%{tarball_version}
|
%autosetup -p1 -n loupe-%{tarball_version}
|
||||||
|
|
||||||
|
%if ! 0%{?bundled_rust_deps}
|
||||||
rm -rf vendor
|
rm -rf vendor
|
||||||
sed -i -e '/Cargo.lock/d' meson.build
|
sed -i -e '/Cargo.lock/d' meson.build
|
||||||
%cargo_prep
|
%cargo_prep
|
||||||
|
%endif
|
||||||
|
|
||||||
|
|
||||||
|
%if ! 0%{?bundled_rust_deps}
|
||||||
%generate_buildrequires
|
%generate_buildrequires
|
||||||
%cargo_generate_buildrequires
|
%cargo_generate_buildrequires
|
||||||
|
%endif
|
||||||
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
|
Loading…
Reference in New Issue
Block a user