rpms/gnofract4d/F-7 gnofract4d-make-desktop-file-valid.patch, NONE, 1.1 gnofract4d-test-suite.patch, NONE, 1.1 .cvsignore, 1.5, 1.6 gnofract4d.spec, 1.13, 1.14 sources, 1.5, 1.6

Stewart Adam (firewing) fedora-extras-commits at redhat.com
Wed Nov 21 04:39:37 UTC 2007


Author: firewing

Update of /cvs/extras/rpms/gnofract4d/F-7
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv9036/F-7

Modified Files:
	.cvsignore gnofract4d.spec sources 
Added Files:
	gnofract4d-make-desktop-file-valid.patch 
	gnofract4d-test-suite.patch 
Log Message:
Initial import of gnofract4d after claiming it


gnofract4d-make-desktop-file-valid.patch:

--- NEW FILE gnofract4d-make-desktop-file-valid.patch ---
--- gnofract4d.desktop.old	2007-10-26 00:39:02.000000000 -0400
+++ gnofract4d.desktop 19:16:52.000000000 -0500
@@ -1,6 +1,4 @@
 [Desktop Entry]
-Version=3.6
-Encoding=UTF-8
 Name=Gnofract 4D Fractal Generator
 Comment=Generate fractal images such as the Mandelbrot set
 Exec=gnofract4d %F
@@ -8,6 +6,5 @@
 Terminal=false
 Type=Application
 Categories=GNOME;Graphics;Math;
-MimeType=text/x-gnofract4d-fractal-parameters
-
-
+MimeType=text/x-gnofract4d-fractal-parameters;
+Version=1.0

gnofract4d-test-suite.patch:

--- NEW FILE gnofract4d-test-suite.patch ---
--- test.py.orig	2007-11-17 11:30:35.000000000 -0500
+++ test.py	2007-11-17 11:34:48.000000000 -0500
@@ -35,12 +35,17 @@
         self.failUnless(m,"doc doesn't specify version")
         self.assertEqual(options.version,m.group(1), "Version mismatch")
 
-    def testDesktopFileVersionMatches(self):
+    # Version= key is not supposed to be used by the program, but rather to
+    # designate to which version of the desktop-entry standard
+    # a file complies to. See:
+    # http://standards.freedesktop.org/desktop-entry-spec/desktop-entry-spec-latest.html
+    #
+    """def testDesktopFileVersionMatches(self):
         dtop = open("gnofract4d.desktop").read()
         dtop_re  = re.compile("Version=(\S+)")
         m = dtop_re.search(dtop)
         self.failUnless(m,"Desktop file doesn't specify version")
-        self.assertEqual(options.version,m.group(1), "Version mismatch")
+        self.assertEqual(options.version,m.group(1), "Version mismatch")"""
 
     def testWebsiteVersionMatches(self):
         if not os.path.exists("website"):
--- fract4dgui/test.py.orig	2007-11-17 11:29:15.000000000 -0500
+++ fract4dgui/test.py	2007-11-17 11:36:12.000000000 -0500
@@ -24,7 +24,9 @@
 import test_fract4dguic
 import test_utils
 import test_renderqueue
-import test_director
+# Fedora doesn't ship Transcode, may as well just skip the test since we know
+# it will fail
+#import test_director
 
 def suite():
     tests = (
@@ -41,8 +43,7 @@
         test_painter.suite(),
         test_fract4dguic.suite(),
         test_utils.suite(),
-        test_main_window.suite(),
-        test_director.suite())
+        test_main_window.suite())
     return unittest.TestSuite(tests)
 
 def main():


Index: .cvsignore
===================================================================
RCS file: /cvs/extras/rpms/gnofract4d/F-7/.cvsignore,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- .cvsignore	20 May 2006 20:49:08 -0000	1.5
+++ .cvsignore	21 Nov 2007 04:39:03 -0000	1.6
@@ -1 +1 @@
-gnofract4d-2.14.tar.gz
+gnofract4d-3.6.tar.gz


Index: gnofract4d.spec
===================================================================
RCS file: /cvs/extras/rpms/gnofract4d/F-7/gnofract4d.spec,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- gnofract4d.spec	11 Dec 2006 16:36:31 -0000	1.13
+++ gnofract4d.spec	21 Nov 2007 04:39:03 -0000	1.14
@@ -1,80 +1,118 @@
+%{!?python_sitearch: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
+
 Name:           gnofract4d
-Version:        2.14
+Version:        3.6
 Release:        4%{?dist}
 Summary:        Gnofract 4D is a Gnome-based program to draw fractals
 Group:          Amusements/Graphics
-License:        GPL
+License:        LGPLv2+
 URL:            http://gnofract4d.sourceforge.net/
-Source0:        http//dl.sf.net/gnofract4d/gnofract4d-%{version}.tar.gz
-
+Source0:        http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz
+Patch0:         gnofract4d-make-desktop-file-valid.patch
+Patch1:         gnofract4d-test-suite.patch
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
-BuildRequires: scrollkeeper, python, gcc-c++, pkgconfig
-BuildRequires: gtk2-devel, python-devel
-BuildRequires: desktop-file-utils, GConf2-devel
-
-Requires(post): scrollkeeper
+Requires:      pygtk2 >= 2.6
+# Don't need to list these, they are needed by gtk2-devel
+# pkgconfig libpng-devel
+BuildRequires: xorg-x11-xinit xorg-x11-server-Xvfb
+BuildRequires: gcc-c++
+BuildRequires: pygtk2-devel >= 2.6
+BuildRequires: gtk2-devel
+BuildRequires: GConf2-devel
+BuildRequires: python-devel >= 2.4
+BuildRequires: libjpeg-devel
+BuildRequires: desktop-file-utils
 
 %description
-Gnofract 4D is a Gnome-based program to draw fractals. What sets it apart from
-other fractal programs (and makes it "4D") is the way that it treats the
-Mandelbrot and Julia sets as different views of the same four-dimensional
-fractal object. This allows you to generate images which are a cross between
-the two sets and explore their inter-relationships.
+Gnofract 4D is a free, open source program which allows anyone to create
+beautiful images called fractals. The images are automatically created by
+the computer based on mathematical principles. These include the Mandelbrot
+and Julia sets and many more. You don't need to do any math: you can explore
+a universe of images just using a mouse.
 
 %prep
-cat<<EOT
-
-Build disabled. Package is without maintainer.
-
-EOT
-exit 1
-
 
 %setup -q
-
-# make it x86-64 happy
-sed -i 's|/usr/lib/|%{_libdir}/|g' setup.cfg
-sed -i 's|/usr/lib|%{_libdir}/|g' %{name}
+# Don't use Version= key improperly
+%patch0 -b .patch0
+# Don't test Version= key impropery
+# Don't test for transcode, we _know_ it's not there.
+%patch1 -b .patch1
 
 %build
-python setup.py build
+CFLAGS="$RPM_OPT_FLAGS" %{__python} setup.py build
 
 %install
-%{__rm} -rf %{buildroot}
-python setup.py install --root="%{buildroot}"
+%{__rm} -rf $RPM_BUILD_ROOT
+%{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
+
+%{__install} -d -m0755 $RPM_BUILD_ROOT%{_datadir}/applications/
+desktop-file-install --vendor fedora --delete-original \
+        --dir $RPM_BUILD_ROOT%{_datadir}/applications \
+        $RPM_BUILD_ROOT%{_datadir}/applications/%{name}.desktop
+
+# remove the shebangs
+find $RPM_BUILD_ROOT%{python_sitearch} -perm 644 -type f -name '*.py' | while read line;do
+  sed -i 's|#!/usr/bin/env python||' "$line"
+  sed -i 's|#!/usr/bin/python||' "$line"
+done
 
-%{__install} -d -m0755 %{buildroot}%{_datadir}/applications/
-desktop-file-install --vendor fedora                            \
-	--delete-original                                       \
-        --dir ${RPM_BUILD_ROOT}%{_datadir}/applications         \
-        --add-category X-Fedora                                 \
-        %{buildroot}%{_datadir}/gnofract4d/gnofract4d.desktop
+# Why is this map 755?
+chmod 644 $RPM_BUILD_ROOT%{_datadir}/%{name}/maps/royal.map
 
 %post
-scrollkeeper-update -q || :
+update-desktop-database &> /dev/null || :
+update-mime-database %{_datadir}/mime &> /dev/null || :
 
 %postun
-scrollkeeper-update -q || :
+update-desktop-database &> /dev/null || :
+update-mime-database %{_datadir}/mime &> /dev/null || :
+
+%check
+xinit %{__python} test.py -- /usr/bin/Xvfb :9 -ac
 
 %clean
-%{__rm} -rf %{buildroot}
+%{__rm} -rf $RPM_BUILD_ROOT
 
 %files
-%defattr(-, root, root, 0755)
+%defattr(-,root,root,0755)
 %doc COPYING README
-%doc %{_datadir}/gnome/help/gnofract4d/
-%{_bindir}/gnofract4d
-%dir %{_datadir}/maps/
-%{_datadir}/maps/gnofract4d/
-%{_datadir}/mime/packages/gnofract4d-mime.xml
+%doc %{_datadir}/gnome/help/%{name}/
+%{_bindir}/%{name}
+%{_datadir}/%{name}/
+%{_datadir}/mime/packages/%{name}-mime.xml
 %{_datadir}/applications/*.desktop
-%{_datadir}/pixmaps/gnofract4d/
-%{_datadir}/pixmaps/gnofract4d-logo.png
-%{_libdir}/gnofract4d-%{version}/
-%{_datadir}/formulas/gnofract4d/
+%{_datadir}/pixmaps/%{name}*
+%{python_sitearch}/fract4d/
+%{python_sitearch}/fract4dgui/
+%{python_sitearch}/fractutils/
 
 %changelog
+* Sun Nov 18 2007 Stewart Adam <s.adam at diffingo.com> - 3.6-4
+- Fix .desktop file location
+- Fix Source0 URL
+- Own /usr/share/gnofract4d
+
+* Sun Nov 18 2007 Stewart Adam <s.adam at diffingo.com> - 3.6-3
+- BR xorg-x11-xinit, pygtk2-devel >= 2.6
+
+* Sat Nov 17 2007 Stewart Adam <s.adam at diffingo.com> - 3.6-2
+- License is actually LGPLv2+ because of lex.py, yacc.py, FCTGen.py
+- Add patch for test suite files since two tests are invalid
+- Update MIME and desktop databases
+- Use virtual X for GUI test suite
+- Remove redundant BR
+- Remove redundant entries from %%files
+- Fix rpmlint's errors about executable files/shebangs
+
+* Wed Nov 14 2007 Stewart Adam <s.adam at diffingo.com> - 3.6-1
+- Update to 3.6
+- Make Source0 a URL again
+- License is no longer GPL
+- Update spec for Fedora (re)review
+- Add patch to generate a valid .desktop file
+
 * Mon Aug 27 2006 Michael J. Knox <michael[AT]knox.net.nz> - 2.14-4
 - Rebuild for FC6
 


Index: sources
===================================================================
RCS file: /cvs/extras/rpms/gnofract4d/F-7/sources,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- sources	20 May 2006 20:49:08 -0000	1.5
+++ sources	21 Nov 2007 04:39:03 -0000	1.6
@@ -1 +1 @@
-34170bb139eb30dfd7d1c1bc647d2578  gnofract4d-2.14.tar.gz
+c43be6cf6d24affd95f051c3b989b0ce  gnofract4d-3.6.tar.gz




More information about the fedora-extras-commits mailing list