From 66a33095ccd93461e7e84c934ffe58405dae6e40 Mon Sep 17 00:00:00 2001 From: Thomas Spura Date: Sep 26 2012 14:34:23 +0000 Subject: patch: assume a prefix of /usr instead of / in a usrmoved system --- diff --git a/mypaint-1.0.0-usrmove.patch b/mypaint-1.0.0-usrmove.patch new file mode 100644 index 0000000..fd9b8d7 --- /dev/null +++ b/mypaint-1.0.0-usrmove.patch @@ -0,0 +1,13 @@ +diff -ur mypaint-1.0.0.orig/mypaint.py mypaint-1.0.0/mypaint.py +--- mypaint-1.0.0.orig/mypaint.py 2011-11-22 21:27:03.000000000 +0100 ++++ mypaint-1.0.0/mypaint.py 2012-09-26 16:21:40.125539307 +0200 +@@ -68,6 +68,9 @@ + + if os.path.basename(dir_install) == 'bin': + prefix=os.path.dirname(dir_install) ++ if prefix == "/": ++ # we have most likely a usrmoved system and disallow a prefix of / ++ prefix = u"/usr" + assert isinstance(prefix, unicode) + libpath=join(prefix, lib_shared) + libpath_compiled = join(prefix, lib_compiled) diff --git a/mypaint.spec b/mypaint.spec index dbb5ac9..914ec0a 100644 --- a/mypaint.spec +++ b/mypaint.spec @@ -2,7 +2,7 @@ Name: mypaint Version: 1.0.0 -Release: 3%{?dist} +Release: 4%{?dist} Summary: A fast and easy graphics application for digital painters Group: Applications/Multimedia @@ -15,6 +15,9 @@ Source1: http://mypaintatelier.googlecode.com/files/ramon2.zip # taken from http://mypaintatelier.googlecode.com/files/Concept%20Design.zip # but koji doesn't like sources with a whitespace, so we rename it Source2: Concept_Design.zip +# don't allow a prefix of "/" and assum a prefix of "/usr" instead +# occurs with a usrmoved system +Patch0: mypaint-1.0.0-usrmove.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel, gtk2-devel, pygtk2-devel @@ -40,6 +43,7 @@ The %{name}-data package contains common data files for %{name}. %prep %setup -q +%patch0 -p1 # Ramon2 brushes unzip %{SOURCE1} -x order.conf -d brushes @@ -126,6 +130,9 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : %changelog +* Wed Sep 26 2012 Thomas Spura - 1.0.0-4 +- patch: assume a prefix of /usr instead of / in a usrmoved system + * Fri Jul 20 2012 Fedora Release Engineering - 1.0.0-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild