Fix flatpak build
When building prusa-slicer as flatpak, Perl test suite is unable to build because of many build-related errors (Perl tests have many dependencies which have to be built with /app prefix, which is not always simple). As we are unable to pass any flags to rpmbuild to switch off the Perl tests, we need to switch them off for flatpak build directly in the spec file. The second change is related to %{perl_vendorlib} and %{perl_vendorarch} macros, which are not set during flatpak build (a build %without perltests). When the %{flatpak} macro is not set, there should be no change in functionality.
This commit is contained in:
parent
2cebe75897
commit
d552b687e5
@ -1,9 +1,14 @@
|
|||||||
# Currently all of the test suite requires the old Perl infrastructure to run.
|
# Currently all of the test suite requires the old Perl infrastructure to run.
|
||||||
|
# When building flatpak, tests have to be disabled by default due to some missing dependencies.
|
||||||
|
%if 0%{?flatpak}
|
||||||
|
%bcond_with perltests
|
||||||
|
%else
|
||||||
%bcond_without perltests
|
%bcond_without perltests
|
||||||
|
%endif
|
||||||
|
|
||||||
Name: prusa-slicer
|
Name: prusa-slicer
|
||||||
Version: 2.2.0
|
Version: 2.2.0
|
||||||
Release: 5%{?dist}
|
Release: 6%{?dist}
|
||||||
Summary: 3D printing slicer optimized for Prusa printers
|
Summary: 3D printing slicer optimized for Prusa printers
|
||||||
|
|
||||||
# The main PrusaSlicer code and resources are AGPLv3, with small parts as
|
# The main PrusaSlicer code and resources are AGPLv3, with small parts as
|
||||||
@ -352,8 +357,11 @@ desktop-file-install --dir=%buildroot%_datadir/applications %SOURCE1
|
|||||||
# we want the test suite to run. It could be placed into a subpackage, but
|
# we want the test suite to run. It could be placed into a subpackage, but
|
||||||
# nothing needs it currently and it would conflict with the other slic3r
|
# nothing needs it currently and it would conflict with the other slic3r
|
||||||
# package.
|
# package.
|
||||||
rm -rf %buildroot/%perl_vendorarch
|
#
|
||||||
rm -rf %buildroot/%perl_vendorlib
|
# The %%perl_vendorarch and %%perl_vendorlib can be undefined,
|
||||||
|
# which would cause deleting of the whole buildroot.
|
||||||
|
%{?perl_vendorarch:rm -rf %buildroot/%perl_vendorarch}
|
||||||
|
%{?perl_vendorlib:rm -rf %buildroot/%perl_vendorlib}
|
||||||
|
|
||||||
# Upstream installs the translation source files when they probably shouldn't
|
# Upstream installs the translation source files when they probably shouldn't
|
||||||
ls -lR %buildroot%_datadir/PrusaSlicer/localization
|
ls -lR %buildroot%_datadir/PrusaSlicer/localization
|
||||||
@ -404,6 +412,11 @@ find %buildroot%_datadir/PrusaSlicer/localization -type d | sed '
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Wed Aug 26 2020 Jan Beran <jaberan@redhat.com> - 2.2.0-6
|
||||||
|
- Add fixes for the flatpak build:
|
||||||
|
disable perltests by default when building flatpak
|
||||||
|
don't remove Perl modules when building without perltests
|
||||||
|
|
||||||
* Mon Aug 24 2020 Miro Hrončok <mhroncok@redhat.com> - 2.2.0-5
|
* Mon Aug 24 2020 Miro Hrončok <mhroncok@redhat.com> - 2.2.0-5
|
||||||
- Rebuilt for openvdb 7.1
|
- Rebuilt for openvdb 7.1
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user