[postr] Readded nautilus patch

Tim Lauridsen timlau at fedoraproject.org
Sun Oct 24 08:50:01 UTC 2010


commit c2b650479ebfd64c6f93511a0678a4d114963904
Author: Tim Lauridsen <timlau at fedoraproject.org>
Date:   Sun Oct 24 10:49:28 2010 +0200

    Readded nautilus patch

 nautilus-ext-dir.patch |   45 +++++++++++++++++++++++++++++++++++++++++++++
 postr.spec             |    8 +++++++-
 2 files changed, 52 insertions(+), 1 deletions(-)
---
diff --git a/nautilus-ext-dir.patch b/nautilus-ext-dir.patch
new file mode 100644
index 0000000..4a4eea6
--- /dev/null
+++ b/nautilus-ext-dir.patch
@@ -0,0 +1,45 @@
+--- postr-0.12.3/setup.py	2008-12-19 15:51:01.000000000 +0100
++++ postr-0.12.3.new/setup.py	2009-08-25 15:44:58.123732748 +0200
+@@ -1,9 +1,30 @@
+ #!/usr/bin/env python
+ 
++import os
+ from distutils.core import setup
++from distutils.command.install_data import install_data
+ from glob import glob
+ from src.version import __version__
+ 
++
++class InstallData(install_data):
++    def run(self):
++        self.data_files.extend(self._nautilus_plugin())
++        install_data.run(self)
++    
++    def _nautilus_plugin(self):
++        files = []
++        cmd = os.popen('pkg-config --variable=pythondir nautilus-python', 'r')
++        res = cmd.readline().strip()
++        ret = cmd.close()
++            
++        if ret is None:
++           dest = res[5:]
++           files.append((dest, ['nautilus/postrExtension.py']))
++        
++        return files
++
++
+ setup(name='Postr',
+       version=__version__,
+       description='Flickr Uploader',
+@@ -21,10 +42,7 @@
+                   ('share/icons/hicolor/24x24/apps', glob('data/24x24/*.png')),
+                   ('share/icons/hicolor/32x32/apps', glob('data/32x32/*.png')),
+                   ('share/icons/hicolor/scalable/apps', glob('data/scalable/*.svg')),
+-                  # TODO: inspect nautilus-python.pc to get path
+-                  ('lib/nautilus/extensions-1.0/python', ['nautilus/postrExtension.py']),
+-                  ('lib/nautilus/extensions-2.0/python', ['nautilus/postrExtension.py']),
+-                  ],
++                  ], cmdclass={'install_data': InstallData}
+       
+       )
+ 
diff --git a/postr.spec b/postr.spec
index 4310ce8..e3b6273 100644
--- a/postr.spec
+++ b/postr.spec
@@ -3,13 +3,15 @@
 
 Name:           postr
 Version:        0.12.4
-Release:        1%{?dist}
+Release:        2%{?dist}
 Summary:        Flickr uploader
 
 Group:          Applications/Multimedia
 License:        GPLv2+
 URL:            http://projects.gnome.org/postr/
 Source0:        http://ftp.gnome.org/pub/GNOME/sources/postr/0.12/%{name}-%{version}.tar.gz
+Patch0:			nautilus-ext-dir.patch
+
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 BuildRequires:  python-devel
@@ -30,6 +32,7 @@ Tool for uploading photos to the photo-sharing website Flickr.
 
 %prep
 %setup -q
+%patch0 -p1
 
 
 %build
@@ -71,6 +74,9 @@ touch --no-create %{_datadir}/icons/hicolor || :
 
 
 %changelog
+* Sun Oct 24 2010 Tim Lauridsen <timlau at fedoraproject.org> 0.12.4-2
+- readded nautilus patch
+
 * Sun Oct 24 2010 Tim Lauridsen <timlau at fedoraproject.org> 0.12.4-1
 - upstream 0.12.4
 - removed patches


More information about the scm-commits mailing list