From f8574d3d9efae2ea0697babd60bfdc3983f36744 Mon Sep 17 00:00:00 2001 From: David Tardon Date: Jun 09 2014 07:07:20 +0000 Subject: allow to limit the space needed for build --- diff --git a/libreoffice.spec b/libreoffice.spec index 41db8f5..c92d3c5 100644 --- a/libreoffice.spec +++ b/libreoffice.spec @@ -30,6 +30,13 @@ # effect %bcond_without langpacks +# remove workdir at the end of %%build, to allow build on space-constrained machines +%ifarch s390 s390x +%bcond_without smallbuild +%else +%bcond_with smallbuild +%endif + # generated by %%langpack definitions %global langpack_langs %{nil} @@ -1266,8 +1273,17 @@ export GNOME_MIME_THEME=hicolor # TODO use empty variables? Should make the renaming hacks in %%install # unnecessary. . ./bin/get_config_variables PRODUCTVERSIONSHORT PRODUCTVERSION WORKDIR -cd $WORKDIR/CustomTarget/sysui/share/libreoffice +pushd $WORKDIR/CustomTarget/sysui/share/libreoffice ./create_tree.sh +popd +mkdir $WORKDIR/os-integration +cp -pr $WORKDIR/CustomTarget/sysui/share/output/usr/share/* $WORKDIR/os-integration + +%if %{with smallbuild} +# remove the biggest offenders +# NOTE: not removing complete LinkTarget, as some libs are needed for smoketest +rm -rf $WORKDIR/CxxObject $WORKDIR/GenCxxObject $WORKDIR/HelpTarget $WORKDIR/LinkTarget/CppunitTest +%endif echo build end time is `date`, diskspace: `df -h . | tail -n 1` @@ -1474,7 +1490,7 @@ for app in base calc draw impress math startcenter writer xsltfilter; do done popd -pushd $WORKDIR/CustomTarget/sysui/share/output/usr/share +pushd $WORKDIR/os-integration #get rid of the gnome icons and other unneeded files rm -rf icons/gnome applications application-registry