[libreoffice/f16] fix multilib .py[c|o] files

Caolán McNamara caolanm at fedoraproject.org
Mon Feb 13 10:59:59 UTC 2012


commit bbe1df310100e8218dafaf1c301cd22b290f4bff
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Mon Feb 13 10:59:57 2012 +0000

    fix multilib .py[c|o] files

 0001-preserve-timestamps-for-.py-files.patch |   28 ++++++++++++++++++++++++++
 libreoffice.spec                             |    6 ++++-
 2 files changed, 33 insertions(+), 1 deletions(-)
---
diff --git a/0001-preserve-timestamps-for-.py-files.patch b/0001-preserve-timestamps-for-.py-files.patch
new file mode 100644
index 0000000..88aefa5
--- /dev/null
+++ b/0001-preserve-timestamps-for-.py-files.patch
@@ -0,0 +1,28 @@
+From 18af7e03d81d295a47457486d3036681bd17eb81 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= <caolanm at redhat.com>
+Date: Mon, 13 Feb 2012 10:45:59 +0000
+Subject: [PATCH] preserve timestamps for .py files
+
+.pyc and .pyo binary caches contain the timestamp of the .py file, so for
+fedora multilib if the .py files get different times on different arch then the
+.py[o|c] files end up being different for the same content
+---
+ solenv/bin/install-gdb-printers |    2 +-
+ 1 files changed, 1 insertions(+), 1 deletions(-)
+
+diff --git a/solenv/bin/install-gdb-printers b/solenv/bin/install-gdb-printers
+index 99686cf..df327a0 100755
+--- a/solenv/bin/install-gdb-printers
++++ b/solenv/bin/install-gdb-printers
+@@ -165,7 +165,7 @@ fi
+ 
+ if [[ ${DESTDIR}${pythondir} != ${GDBDIR} ]]; then
+     mkdir -p "${DESTDIR}${pythondir}" || die "cannot create dir '${DESTDIR}${pythondir}'"
+-    cp -r "${GDBDIR}/libreoffice" "${DESTDIR}${pythondir}"
++    cp -pr "${GDBDIR}/libreoffice" "${DESTDIR}${pythondir}"
+ fi
+ 
+ make_autoload cppu ure-link/lib libuno_cppu."$DYLIB".3
+-- 
+1.7.7.6
+
diff --git a/libreoffice.spec b/libreoffice.spec
index ada8bb7..9b0320d 100644
--- a/libreoffice.spec
+++ b/libreoffice.spec
@@ -206,6 +206,7 @@ Patch87: 0001-fdo-40378-compile-defined-names-that-had-unresolveds.patch
 Patch88: 0002-fix-fdo-40590-stop-abusing-regular-string-token-for-.patch
 Patch89: 0003-fix-fdo-40590-stop-abusing-regular-string-token-for-.patch
 Patch90: libreoffice-ensure-non-broken-xml-tree.patch
+Patch91: 0001-preserve-timestamps-for-.py-files.patch
 
 %{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")}
 %define instdir %{_libdir}
@@ -1095,6 +1096,7 @@ mv -f redhat.soc extras/source/palettes/standard.soc
 %patch88 -p1 -b .1fix-fdo-40590-stop-abusing-regular-string-token-for-.patch
 %patch89 -p1 -b .2fix-fdo-40590-stop-abusing-regular-string-token-for-.patch
 %patch90 -p1 -b .ensure-non-broken-xml-tree.patch
+%patch91 -p1 -b .preserve-timestamps-for-.py-files.patch
 
 # these are horribly incomplete--empty translations and copied english
 # strings with spattering of translated strings
@@ -2405,8 +2407,10 @@ update-desktop-database %{_datadir}/applications &> /dev/null || :
 %endif
 
 %changelog
-* Mon Feb 13 2012 Caolán McNamara <caolanm at redhat.com> - 3.4.5.2-6
+* Mon Feb 13 2012 Caolán McNamara <caolanm at redhat.com> - 3.4.5.2-6.UNBUILT
 - ensure non broken xml help.tree files
+- ensure gdb .py files have the same timstamps so that multilib
+  .pyc's and .pyo's have the same content (timestamp in binary cache)
 
 * Thu Feb 09 2012 Caolán McNamara <caolanm at redhat.com> - 3.4.5.2-5
 - Resolves: fdo#38595 border width lost in ODF import


More information about the scm-commits mailing list