From 4f8da65765038aaae574aed54e305746ef4cfded875f344165351997417410ac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Mon, 9 Feb 2015 10:26:48 +0000 Subject: [PATCH 1/3] - Move removal of obsolete dirs from %pretrans to %pre bnc#916181 OBS-URL: https://build.opensuse.org/package/show/LibreOffice:Factory/libreoffice?expand=0&rev=222 --- libreoffice.changes | 5 +++++ libreoffice.spec | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/libreoffice.changes b/libreoffice.changes index fed3dee..513ecc8 100644 --- a/libreoffice.changes +++ b/libreoffice.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Mon Feb 9 10:26:08 UTC 2015 - tchvatal@suse.com + +- Move removal of obsolete dirs from %pretrans to %pre bnc#916181 + ------------------------------------------------------------------- Thu Jan 29 14:35:49 UTC 2015 - tchvatal@suse.com diff --git a/libreoffice.spec b/libreoffice.spec index 6ecf09f..aa87cdc 100644 --- a/libreoffice.spec +++ b/libreoffice.spec @@ -1139,7 +1139,7 @@ rm -rf %{buildroot}%{_libdir}/%{name}/readmes/ # We have ton of duped files so run over it %fdupes %{buildroot}/usr -%pretrans +%pre # do not crate cache for bundled extensions because it is not secure # rather remove it (fdo#53006, fdo#51252, bnc#769448) # Remove after 12.2 is out of support/migration scope. From 65e58ab072fece7710da10b58f82439287f24b330bd6919f267d94bda7ed0db2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Mon, 9 Feb 2015 18:06:11 +0000 Subject: [PATCH 2/3] - %pre is not enough the script needs to be rewritten in lua OBS-URL: https://build.opensuse.org/package/show/LibreOffice:Factory/libreoffice?expand=0&rev=223 --- libreoffice.changes | 5 +++++ libreoffice.spec | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/libreoffice.changes b/libreoffice.changes index 513ecc8..1aa1cba 100644 --- a/libreoffice.changes +++ b/libreoffice.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Mon Feb 9 18:00:17 UTC 2015 - tchvatal@suse.com + +- %pre is not enough the script needs to be rewritten in lua + ------------------------------------------------------------------- Mon Feb 9 10:26:08 UTC 2015 - tchvatal@suse.com diff --git a/libreoffice.spec b/libreoffice.spec index aa87cdc..6ecf09f 100644 --- a/libreoffice.spec +++ b/libreoffice.spec @@ -1139,7 +1139,7 @@ rm -rf %{buildroot}%{_libdir}/%{name}/readmes/ # We have ton of duped files so run over it %fdupes %{buildroot}/usr -%pre +%pretrans # do not crate cache for bundled extensions because it is not secure # rather remove it (fdo#53006, fdo#51252, bnc#769448) # Remove after 12.2 is out of support/migration scope. From 3b39b30243427909cfe487ca4aad2609a0b7650b980e82b935764f943889dee9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Tue, 10 Feb 2015 12:50:41 +0000 Subject: [PATCH 3/3] - Reduce bit the compilation preparations as we prepped most of the things by _constraints and it is no longer needed OBS-URL: https://build.opensuse.org/package/show/LibreOffice:Factory/libreoffice?expand=0&rev=224 --- libreoffice.changes | 6 ++++++ libreoffice.spec | 40 +++++++++++----------------------------- 2 files changed, 17 insertions(+), 29 deletions(-) diff --git a/libreoffice.changes b/libreoffice.changes index 1aa1cba..3ed951c 100644 --- a/libreoffice.changes +++ b/libreoffice.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Tue Feb 10 12:49:37 UTC 2015 - tchvatal@suse.com + +- Reduce bit the compilation preparations as we prepped most of the + things by _constraints and it is no longer needed + ------------------------------------------------------------------- Mon Feb 9 18:00:17 UTC 2015 - tchvatal@suse.com diff --git a/libreoffice.spec b/libreoffice.spec index 6ecf09f..24d8ac8 100644 --- a/libreoffice.spec +++ b/libreoffice.spec @@ -859,10 +859,10 @@ echo "HTML_TIMESTAMP = NO" >> odk/docs/idl/Doxyfile # Parallel build settings ... lo_jobs="%{?jobs:%{jobs}}" %ifarch %{arm} -%if ! 0%{?qemu_user_space_build:1} -# native hardware is not that powerful -lo_jobs="1" -%endif + %if ! 0%{?qemu_user_space_build:1} + # native hardware is not that powerful + lo_jobs="1" + %endif %endif # do not eat all memory echo "Available memory:" @@ -870,40 +870,22 @@ free echo "System limits:" ulimit -a lo_jobs_reduced= -if test -e "%{_libexecdir}/icecc/bin/gcc" -a -e "%{_libexecdir}/icecc/bin/g++" ; then - PARALLEL_BUILD="$PARALLEL_BUILD --enable-icecream" -else - if test -n "$lo_jobs" -a "$lo_jobs" -gt 1 ; then - if test `uname -i` = "x86_64" ; then - mem_per_process=1000 - else - mem_per_process=800 - fi - %if 0%{?qemu_user_space_build:1} - mem_per_process=1200 - %endif - max_mem=`LANG=C free -t -m | sed -n "s|^Mem: *\([0-9]*\).*$|\1|p"` - max_jobs="$(($max_mem / $mem_per_process))" - test "$lo_jobs" -gt "$max_jobs" && lo_jobs="$max_jobs" && lo_jobs_reduced="yes" && echo "Warning: Reducing number of jobs to $max_jobs because of memory limits" - test "$lo_jobs" -le 0 && lo_jobs=1 && echo "Warning: Do not use the parallel build at all becuse of memory limits" - fi +if test -n "$lo_jobs" -a "$lo_jobs" -gt 1 ; then + mem_per_process=1200 + max_mem=`LANG=C free -t -m | sed -n "s|^Mem: *\([0-9]*\).*$|\1|p"` + max_jobs="$(($max_mem / $mem_per_process))" + test "$lo_jobs" -gt "$max_jobs" && lo_jobs="$max_jobs" && lo_jobs_reduced="yes" && echo "Warning: Reducing number of jobs to $max_jobs because of memory limits" + test "$lo_jobs" -le 0 && lo_jobs=1 && echo "Warning: Do not use the parallel build at all becuse of memory limits" fi # finally set jobs PARALLEL_BUILD= if test -n "$lo_jobs" ; then PARALLEL_BUILD="--with-parallelism=$lo_jobs" fi -# using icecream # make sure that JAVA_HOME is set correctly source %{_sysconfdir}/profile.d/alljava.sh # use RPM_OPT_FLAGS, ... -# FIXME: use -g1 instead of -g; the .o files need about 12GB disk space with full debugging symbols; there is not enough disk space and not enough memory for linking libmerged on the build hosts -# 12.3 has broken cppconnector with wrong incude paths -%if 0%{?suse_version} == 01230 -ARCH_FLAGS="`echo %{optflags} | sed -e 's/\-fexceptions//g' -e 's/^-g /-g1 /g' -e 's/ -g / -g1 /g' -e 's/ -g$/ -g1/g'` -fno-strict-aliasing -I%{_includedir}/mysql-connector/ " -%else -ARCH_FLAGS="`echo %{optflags} | sed -e 's/\-fexceptions//g' -e 's/^-g /-g1 /g' -e 's/ -g / -g1 /g' -e 's/ -g$/ -g1/g'` -fno-strict-aliasing" -%endif +ARCH_FLAGS="%{optflags}" CFLAGS="$ARCH_FLAGS" CXXFLAGS="$ARCH_FLAGS" export ARCH_FLAGS CFLAGS CXXFLAGS