Disable perl in flatpak builds
This commit is contained in:
parent
ef9c4f9c59
commit
ed58afe7c9
@ -2,6 +2,12 @@
|
|||||||
|
|
||||||
%bcond_without libheif
|
%bcond_without libheif
|
||||||
|
|
||||||
|
%if 0%{?flatpak}
|
||||||
|
%bcond_with perl
|
||||||
|
%else
|
||||||
|
%bcond_without perl
|
||||||
|
%endif
|
||||||
|
|
||||||
# Disable automatic .la file removal
|
# Disable automatic .la file removal
|
||||||
%global __brp_remove_la_files %nil
|
%global __brp_remove_la_files %nil
|
||||||
|
|
||||||
@ -39,8 +45,10 @@ BuildRequires: pkgconfig(libpng)
|
|||||||
BuildRequires: pkgconfig(libtiff-4)
|
BuildRequires: pkgconfig(libtiff-4)
|
||||||
BuildRequires: giflib-devel
|
BuildRequires: giflib-devel
|
||||||
BuildRequires: pkgconfig(zlib)
|
BuildRequires: pkgconfig(zlib)
|
||||||
|
%if %{with perl}
|
||||||
BuildRequires: perl-devel >= 5.8.1
|
BuildRequires: perl-devel >= 5.8.1
|
||||||
BuildRequires: perl-generators
|
BuildRequires: perl-generators
|
||||||
|
%endif
|
||||||
%if 0%{?rhel} && 0%{?rhel} < 8
|
%if 0%{?rhel} && 0%{?rhel} < 8
|
||||||
BuildRequires: ghostscript-devel
|
BuildRequires: ghostscript-devel
|
||||||
%else
|
%else
|
||||||
@ -175,6 +183,7 @@ Note this documentation can also be found on the ImageMagick website:
|
|||||||
http://www.imagemagick.org/
|
http://www.imagemagick.org/
|
||||||
|
|
||||||
|
|
||||||
|
%if %{with perl}
|
||||||
%package perl
|
%package perl
|
||||||
Summary: ImageMagick perl bindings
|
Summary: ImageMagick perl bindings
|
||||||
Requires: %{name}-libs%{?_isa} = %{epoch}:%{version}-%{release}
|
Requires: %{name}-libs%{?_isa} = %{epoch}:%{version}-%{release}
|
||||||
@ -186,6 +195,7 @@ Perl bindings to ImageMagick.
|
|||||||
|
|
||||||
Install ImageMagick-perl if you want to use any perl scripts that use
|
Install ImageMagick-perl if you want to use any perl scripts that use
|
||||||
ImageMagick.
|
ImageMagick.
|
||||||
|
%endif
|
||||||
|
|
||||||
|
|
||||||
%package c++
|
%package c++
|
||||||
@ -238,7 +248,10 @@ export CFLAGS="%{optflags} -DIMPNG_SETJMP_IS_THREAD_SAFE"
|
|||||||
--enable-shared \
|
--enable-shared \
|
||||||
--disable-static \
|
--disable-static \
|
||||||
--with-modules \
|
--with-modules \
|
||||||
|
%if %{with perl}
|
||||||
--with-perl \
|
--with-perl \
|
||||||
|
--with-perl-options="INSTALLDIRS=vendor %{?perl_prefix} CC='%__cc -L$PWD/magick/.libs' LDDLFLAGS='-shared -L$PWD/magick/.libs'" \
|
||||||
|
%endif
|
||||||
--with-x \
|
--with-x \
|
||||||
--with-threads \
|
--with-threads \
|
||||||
--with-magick_plus_plus \
|
--with-magick_plus_plus \
|
||||||
@ -250,7 +263,6 @@ export CFLAGS="%{optflags} -DIMPNG_SETJMP_IS_THREAD_SAFE"
|
|||||||
--with-openexr \
|
--with-openexr \
|
||||||
--with-rsvg \
|
--with-rsvg \
|
||||||
--with-xml \
|
--with-xml \
|
||||||
--with-perl-options="INSTALLDIRS=vendor %{?perl_prefix} CC='%__cc -L$PWD/magick/.libs' LDDLFLAGS='-shared -L$PWD/magick/.libs'" \
|
|
||||||
--with-urw-base35-font-dir="%{urw_base35_fontpath}" \
|
--with-urw-base35-font-dir="%{urw_base35_fontpath}" \
|
||||||
--without-dps \
|
--without-dps \
|
||||||
--without-gcc-arch \
|
--without-gcc-arch \
|
||||||
@ -286,6 +298,7 @@ cp -a www/source %{buildroot}%{_datadir}/doc/%{name}-%{VER}
|
|||||||
# Delete *ONLY* _libdir/*.la files! .la files used internally to handle plugins - BUG#185237!!!
|
# Delete *ONLY* _libdir/*.la files! .la files used internally to handle plugins - BUG#185237!!!
|
||||||
rm %{buildroot}%{_libdir}/*.la
|
rm %{buildroot}%{_libdir}/*.la
|
||||||
|
|
||||||
|
%if %{with perl}
|
||||||
# perlmagick: fix perl path of demo files
|
# perlmagick: fix perl path of demo files
|
||||||
%{__perl} -MExtUtils::MakeMaker -e 'MY->fixin(@ARGV)' PerlMagick/demo/*.pl
|
%{__perl} -MExtUtils::MakeMaker -e 'MY->fixin(@ARGV)' PerlMagick/demo/*.pl
|
||||||
|
|
||||||
@ -306,6 +319,7 @@ if [ -z perl-pkg-files ] ; then
|
|||||||
echo "ERROR: EMPTY FILE LIST"
|
echo "ERROR: EMPTY FILE LIST"
|
||||||
exit -1
|
exit -1
|
||||||
fi
|
fi
|
||||||
|
%endif
|
||||||
|
|
||||||
# fix multilib issues: Rename provided file with platform-bits in name.
|
# fix multilib issues: Rename provided file with platform-bits in name.
|
||||||
# Create platform independant file inplace of provided and conditionally include required.
|
# Create platform independant file inplace of provided and conditionally include required.
|
||||||
@ -408,9 +422,11 @@ rm PerlMagick/demo/Generic.ttf
|
|||||||
%{_libdir}/pkgconfig/Magick++-7.Q16HDRI.pc
|
%{_libdir}/pkgconfig/Magick++-7.Q16HDRI.pc
|
||||||
%{_mandir}/man1/Magick++-config.*
|
%{_mandir}/man1/Magick++-config.*
|
||||||
|
|
||||||
|
%if %{with perl}
|
||||||
%files perl -f perl-pkg-files
|
%files perl -f perl-pkg-files
|
||||||
%{_mandir}/man3/*
|
%{_mandir}/man3/*
|
||||||
%doc PerlMagick/demo/ PerlMagick/Changelog PerlMagick/README.txt
|
%doc PerlMagick/demo/ PerlMagick/Changelog PerlMagick/README.txt
|
||||||
|
%endif
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* Tue Aug 22 2023 Sérgio Basto <sergio@serjux.com> - 1:7.1.1.15-1
|
* Tue Aug 22 2023 Sérgio Basto <sergio@serjux.com> - 1:7.1.1.15-1
|
||||||
|
Loading…
Reference in New Issue
Block a user