%if 0%{?fedora} <= 19 %define rubyabi 1.9.1 %endif %define repoid 76353 %define majorver 0.6.9 %undefine minorver %undefine ifpre %define fedorarel 9 %define rel %{?ifpre:0.}%{fedorarel}%{?minorver:.%minorver} Name: alexandria Version: %{majorver} Release: %{rel}%{?dist}.1 Summary: Book collection manager Group: Applications/Productivity License: GPLv2+ URL: http://alexandria.rubyforge.org/ Source0: http://rubyforge.org/frs/download.php/%{repoid}/%{name}-%{version}%{?minorver:-%{minorver}}.tar.gz # Patches discussing with the upstream # Trial fix for hang up when importing list containing invalid isdn # ref: alexandria-Bugs-25348 # Check if this issue is fixed in rev 1154 #Patch2: alexandria-0.6.4.1-hang-importing-invalid-isdn.patch # Trial fix for crash when importing a book with isdn # With alexandria-0.6.6, the fix for this issue is still incomplete # ref: alexandria-BUgs-28263 Patch3: alexandria-0.6.6-dont_use_thread_when_adding_file_by_isdn.patch # Fix crash when searching book # ref: alexandria-Bugs-29479 Patch by Tomoh K. # Applied in 0.6.9 # Patch4: alexandria-0.6.8-set_status_label.patch # Upstream patches # Patches not submitted to the upstream # Support when rubygem(gst) (gstreamer) is not installed # Note that rubygem-gstreamer is not yet in Fedora #Patch10: alexandria-0.6.8-nogst-support.patch # Always require rubygems Patch11: alexandria-0.6.8-always-require-rubygems.patch # Use RbConfig Patch12: alexandria-0.6.8-rbconfig.patch # Use rdoc # Well, seems not needed on 0.6.9 # Patch13: alexandria-0.6.8-rdoc.patch # Force encoding type to make rake happy Patch14: alexandria-0.6.8-ascii-fix.patch # Fix kcode issues with 1.9 # Well, with the original fix, some strange failure on startup # happens on ja_JP.utf8... Patch15: alexandria-0.6.8-kcodefix.patch # eval fix Patch16: alexandria-0.6.8-evalfix.patch # With working zoom and ruby19, z3950 provider aborts # with syntax error about next Patch17: alexandria-0.6.8-z3950-next.patch # Two fixes: # a. loading yaml file generated by ruby 18x will show garbage characters # b. moving book entry to another library which also contains the # same book will cause crash.. Patch18: alexandria-0.6.8-utf8-convert.patch # More UTF-8 fix on ruby 1.9, when exporting library to HTML # (bug 819188) Patch19: alexandria-0.6.8-export-to-HTML-with-ruby19.patch # More UTF-8 fix on ruby 1.9, when exporting library to csv # or bibtex Patch20: alexandria-0.6.8-export-to-CSV-bintex-with-ruby19.patch # Remove garbage character with icon view on multibyte locate Patch21: alexandria-0.6.8-iconview-multibyte.patch # Split Patch18 into two patches, one for lib/alexandria/models/library.rb # (this file) and other. Also handle broken yaml file correctly and let # user redownload it # (bug 861740) Patch22: alexandria-0.6.8-yaml-unescape.patch # Add a feature to remove broken yaml files at startup when requested # (bug 869556) Patch23: alexandria-0.6.9-delete-broken-yaml.patch # Kill iconv Patch24: alexandria-0.6.9-iconv.patch # Handle the case thread was not created with adding new book Patch25: alexandria-0.6.9-newbook-nothread.patch # Make z3950 provider work # ZOOM::Connection.count must be string Patch26: alexandria-0.6.9-z3950-zoom-count.patch # Read negative value as integer in case position has such value # (bug 1014295) Patch27: alexandria-0.6.9-negative-value.patch # Specify goocanvas version (bug 1024931) Patch28: alexandria-0.6.9-goocanvas-version.patch # Make glade2 translatable text actually translated (i10ned) Patch29: alexandria-0.6.9-glade-gettext.patch BuildArch: noarch %if 0%{?fedora} >= 19 Requires: ruby(release) BuildRequires: ruby(release) %else Requires: ruby(abi) = %{rubyabi} Requires: ruby BuildRequires: ruby(abi) = %{rubyabi} BuildRequires: ruby %endif # For ruby macros BuildRequires: ruby-devel BuildRequires: rubygem(rake) BuildRequires: desktop-file-utils # For gconf related macros BuildRequires: GConf2 BuildRequires: gettext BuildRequires: intltool # Amazon AWS v3 -> v4 switch # AWS v4 is supported by alexandria itself # But hpricot is still needed #Requires: ruby(amazon) Requires: rubygem(gettext) Requires: rubygem(hpricot) Requires: rubygem(htmlentities) Requires: ruby(imagesize) # Dependency removed on 0.6.4b1 #Requires: ruby(mechanize) # Kill ruby(revolution) dependency #Requires: ruby(revolution) # ruby(zoom) -> rubygem(zoom) switch #Requires: ruby(zoom) Requires: rubygem(zoom) >= 0.3.0 Requires: rubygem(marc) # Killed on 0.6.8 #Requires: ruby(gconf2) # Explicitly Requires: GConf2 Requires: rubygem(gdk_pixbuf2) Requires: rubygem(glib2) # Killed on 0.6.8 #Requires: ruby(gnome2) #Requires: ruby(libglade2) # Added from 0.6.8 # Requires: rubygem(goocanvas) # The above needs more explicit %if 0%{?fedora} >= 20 Requires: rubygem-goocanvas1 %else Requires: rubygem-goocanvas %endif Requires: rubygem(gstreamer) # Uses syck (bug 922217) %if 0%{?fedora} >= 19 Requires: rubygem(syck) %endif Requires(pre): GConf2 Requires(post): GConf2 Requires(preun): GConf2 %description Alexandria is a GNOME application to help you manage your book collection. %prep %setup -q -n %{name}-%{majorver}%{?minorver:-%{?minorver}} # Check if patch2 issue is fixed in rev 1154 #%%patch2 -p0 -b .up25348 %patch3 -p1 -b .up28263.isdn #%%patch4 -p0 -b .up29479.search #%%patch10 -p1 -b .nogst %patch11 -p1 -b .gem %patch12 -p1 -b .rbconfig #%%patch13 -p1 -b .rdoc %patch14 -p1 -b .ascii %patch15 -p1 -b .kcodefix %patch16 -p1 -b .evalfix %patch17 -p1 -b .z3950_next %patch18 -p1 -b .ruby19_utf8 %patch19 -p1 -b .export_html %patch20 -p1 -b .export_csv %patch21 -p1 -b .icon_kanji %patch22 -p1 -b .broken_yaml %patch23 -p1 -b .delete_yaml %patch24 -p1 -b .iconv %patch25 -p1 -b .nothread %patch26 -p1 -b .z3950_count %patch27 -p1 -b .negative %patch28 -p1 -b .goocanvasver %patch29 -p1 -b .gettext # Embed Fedora EVR %{__sed} -i.evr \ -e "s|\(DISPLAY_VERSION = \).*$|\1'%{version}-%{release}'|" \ Rakefile # Make msgfmt verbose %{__sed} -i.msgfmt \ -e '/system/s|msgfmt |msgfmt --statistics |' \ util/rake/gettextgenerate.rb %build rake build --trace %install rake install_package_staging \ DESTDIR=$RPM_BUILD_ROOT \ RUBYLIBDIR=%{ruby_vendorlibdir} desktop-file-install \ %if 0%{?fedora} < 19 --vendor fedora \ %endif --dir $RPM_BUILD_ROOT%{_datadir}/applications/ \ --delete-original \ $RPM_BUILD_ROOT%{_datadir}/applications/%{name}.desktop # Move gconf files to where Fedora uses %{__mkdir_p} $RPM_BUILD_ROOT%{_sysconfdir} %{__mv} \ $RPM_BUILD_ROOT%{_datadir}/gconf/ \ $RPM_BUILD_ROOT%{_sysconfdir}/ # %%{_datadir}/menu seems to be used for debian # Removing for Fedora %{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/menu/ # Cleanups %{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/pixmaps/ %{__rm} -f $RPM_BUILD_ROOT%{_bindir}/%{name}.* %find_lang %{name} %pre %gconf_schema_prepare %{name} exit 0 %post touch --no-create %{_datadir}/icons/hicolor/ %gconf_schema_upgrade %{name} exit 0 %preun %gconf_schema_remove %{name} exit 0 %postun [ "$1" -eq 0 ] || exit 0 touch --no-create %{_datadir}/icons/hicolor/ %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor exit 0 %posttrans %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor exit 0 %files -f %{name}.lang %defattr(-,root,root,-) %doc COPYING %doc ChangeLog* %doc INSTALL %doc README* %doc TODO %doc doc/[A-Z]* %doc doc/cuecat_support.rdoc %{_mandir}/man1/%{name}.1* %{_bindir}/%{name} %{ruby_vendorlibdir}/%{name}.rb %{ruby_vendorlibdir}/%{name}/ %{_sysconfdir}/gconf/schemas/%{name}.schemas %{_datadir}/%{name}/ %{_datadir}/gnome/help/%{name}/ %{_datadir}/omf/%{name}/ %{_datadir}/sounds/%{name}/ %{_datadir}/applications/*%{name}.desktop %{_datadir}/icons/hicolor/*/apps/%{name}.* %changelog * Sat Jun 07 2014 Fedora Release Engineering - 0.6.9-9.1 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild * Wed Feb 12 2014 Mamoru TASAKA - 0.6.9-9 - Make glade2 translatable text actually translated (i10ned) * Fri Nov 1 2013 Mamoru TASAKA - 0.6.9-8 - Change dependency on goocanvas on F-20+ (bug 1025095) - Specify goocanvas version (bug 1024931) * Mon Oct 7 2013 Mamoru TASAKA - 0.6.9-7 - Read negative value as integer in case position has such value (bug 1014295) * Wed Aug 21 2013 Mamoru TASAKA - 0.6.9-6 - Change ZOOM::Connection.count to string to make z3950 provider work again * Sat Aug 03 2013 Fedora Release Engineering - 0.6.9-5.1 - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild * Sun Mar 17 2013 Mamoru TASAKA - 0.6.9-5 - F-19: rebuild for ruby 2.0.0 - F-19: require rubygem(syck) (bug 922217) * Sat Feb 16 2013 Mamoru TASAKA - 0.6.9-4 - Kill iconv and use encode instead - Handle the case thread was not created with adding new book * Sat Feb 9 2013 Mamoru TASAKA - 0.6.9-3 - F-19: kill vendorization of desktop file (fpc#247) * Sat Oct 27 2012 Mamoru Tasaka - 0.6.9-2 - Add a feature to remove broken yaml files at startup when requested (bug 869556) * Sun Oct 14 2012 Mamoru Tasaka - 0.6.9-1 - 0.6.9 * Sat Oct 13 2012 Mamoru Tasaka - 0.6.8-9 - Rescue the case where parsing yaml file failed and let user re-download book information (bug 861740) * Wed Jul 18 2012 Fedora Release Engineering - 0.6.8-8.1 - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild * Wed May 30 2012 Mamoru Tasaka - 0.8.6-8 - More UTF-8 fix on ruby 1.9, when exporting library to CSV and bibtex - Remove garbage character with icon view on multibyte locate * Sun May 6 2012 Mamoru Tasaka - 0.8.6-7 - More UTF-8 fix on ruby 1.9, when exporting library to HTML (bug 819188) * Fri Apr 13 2012 Mamoru Tasaka - 0.6.8-6 - Convert escaped characters in yaml file generated by ruby 18x to aviod garbage characters - Fix crash when moving book entry to another library when the same entry is found * Wed Apr 11 2012 Mamoru Tasaka - 0.6.8-5 - Fix crash on z3950 provider with working zoom * Sun Apr 8 2012 Mamoru Tasaka - 0.6.8-4 - Fix crash on ja_JP.utf8 (and perhaps on other multibyte locales) * Fri Mar 23 2012 Tom Callaway - 0.6.8-3 - get working again * Thu Jan 12 2012 Fedora Release Engineering - 0.6.8-2.1 - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild * Sun Jan 8 2012 Mamoru Tasaka - 0.6.8-2 - Require rubygem(gstreamer) & remove no longer needed patch * Sun Dec 25 2011 Mamoru Tasaka - 0.6.8-1 - Update to 0.6.8 - Dependency for old ruby-gnome2 stuff is removed - Make always require rubygems - Patch to support usage without rubygem(gst) * Sun Nov 27 2011 Mamoru Tasaka - 0.6.7-1 - Update to 0.6.7 * Mon Feb 07 2011 Fedora Release Engineering - 0.6.6-2.svn1154_trunk.1 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild * Sun Aug 16 2010 Mamoru Tasaka - 0.6.6-2.svn1154 - Update from trunk to try the following fixes - Hang with importing bad ISDN number (alexandria-Bugs-25348) - UTF-8 issue on WorldCat provider (alexandria-Bugs-28437) - Other fixes on providers * Tue Jun 22 2010 Mamoru Tasaka - 0.6.6-1 - Update to 0.6.6 - Still apply Patch3 (it seems isdn segv fix isn't complete) * Fri Jun 18 2010 Mamoru Tasaka - 0.6.6-0.7.beta2 - Execute add_single_book_by_isbn in non-thread, which will fix the crash when imporing books with ISDN (upstream bug 28263) * Sat Jun 5 2010 Mamoru Tasaka - 0.6.6-0.6.beta2 - Apply patch for upstream bug 28250, icon view rearrangement issue * Sat May 8 2010 Mamoru Tasaka - 0.6.6-0.5.beta2 - Try 0.6.6 beta2 * Sat May 8 2010 Mamoru Tasaka - 0.6.6-0.4.svn1138_trunk - Try rev 1138, supporting Duban provider - Scriptlets update * Wed Dec 23 2009 Mamoru Tasaka - 0.6.6-0.3.beta1 - Try 0.6.6 beta1 * Fri Dec 18 2009 Mamoru Tasaka - 0.6.6-0.2.alpha - Use "rake install_package_staging" as explained by the upstream (in alexandria-Bugs-27578) - Kill the creation of 64/128 icons as scalable svg is already installed * Thu Dec 17 2009 Mamoru Tasaka - 0.6.6-0.1.alpha - Try 0.6.6 alpha * Tue Sep 8 2009 Mamoru Tasaka - Wrong patch of sanity check patch applied on F-10/11, fixing... * Wed Sep 2 2009 Mamoru Tasaka - 0.6.5-7 - Fix for parsing WorldCat provider search result (alexandria-Bugs-27028) * Sat Aug 28 2009 Mamoru Tasaka - 0.6.5-6 - Fix crash on startup in tr_TR.UTF-8 (bug 520170, alexandria-Bugs-27015) * Thu Aug 27 2009 Mamoru Tasaka - 0.6.5-5 - Add sanity check for invalid search result, now using upstream patch - Fix DeaStore provider where search result contains no Author (alexandria-Bugs-27000) * Fri Aug 21 2009 Mamoru Tasaka - 0.6.5-3 - Clarify GLib.convert usage in utils.rb (does not change the functionality of alexandria, alexandria-Bugs-26968) * Thu Aug 20 2009 Mamoru Tasaka - 0.6.5-2 - Kill the previous 2 patches (for now) * Thu Aug 20 2009 Mamoru Tasaka - 0.6.5-1 - Update to 0.6.5 - Remove 2 upstreamed patches (1 patch still unremoved) - Add 2 patches, will report upstream * Sat Jul 25 2009 Mamoru Tasaka - F-12: Mass rebuild * Mon Apr 13 2009 Mamoru Tasaka - 0.6.4.1-6 - Trial fix to fix hang when importing list containing invalid isdn (alexandria-Bugs-25348) * Wed Apr 8 2009 Mamoru Tasaka - 0.6.4.1-5 - Embed Fedora EVR * Tue Apr 7 2009 Mamoru Tasaka - 0.6.4.1-4 - Fix for strange behavior with right click on left pane (alexandria-Bugs-25021) * Thu Mar 26 2009 Mamoru Tasaka - 0.6.4.1-2 - Fix arguments of bindtextdomain() for ruby(gettext) 2.0.0 (alexandria-Bugs-24882) * Mon Mar 16 2009 Mamoru Tasaka - 0.6.4.1-1 - 0.6.4.1 (fixing alexandria-Bugs-24568) * Sun Mar 15 2009 Mamoru Tasaka - 0.6.4-1 - 0.6.4 - Patch from upstream to fix issue when book entry is once sorted (alexandria-Bugs-24568) * Fri Mar 6 2009 Mamoru Tasaka - 0.6.4-0.2.b1 - Add ruby(htmlentities) dependency * Tue Mar 3 2009 Mamoru Tasaka - 0.6.4-0.1.b1 - Update to 0.6.4 beta 1 - Drop all patches, merged into upstream * Fri Feb 27 2009 Mamoru Tasaka - 0.6.3-11 - library UTF-8 patch update * Thu Feb 26 2009 Mamoru Tasaka - 0.6.3-10 - Use upstreamed patch for UTF-8 strings issue * Thu Feb 26 2009 Mamoru Tasaka - 0.6.3-9 - Attempt to handle UTF-8 strings in library names correctly (alexandria-Bugs-20168) * Tue Feb 24 2009 Mamoru Tasaka - F-11: Mass rebuild * Tue Feb 24 2009 Mamoru Tasaka - 0.6.3-8 - Global-ize "nested" macro - GTK icon cache update scripts update * Wed Feb 4 2009 Mamoru Tasaka - 0.6.3-7 - Add hpricot dependency again (for Amazon provider) * Sun Jan 11 2009 Mamoru Tasaka - 0.6.3-6 - Rebuild to restore ARCHIVESIZE * Wed Jul 16 2008 Mamoru Tasaka - 0.6.3-5 - Remove workaround for bug 436697 (tooltips crash). This was a bug on ruby-gnome2 which is fixed in 0.17.0 rc1 (ref: alexandria-Bugs-19042) * Thu Apr 3 2008 Mamoru Tasaka - 0.6.3-4 - Drop ruby(amazon) dependency (Amazon no longer provides AWSv3, AWSv4 is supported by alexandria itself) * Sun Mar 23 2008 Mamoru Tasaka - 0.6.3-2 - Disable tooltips on_motion func for now to workaround for bug 436697 * Sat Feb 23 2008 Mamoru Tasaka - 0.6.3-1 - 0.6.3 - One patch removed (applied by upstream) * Mon Dec 31 2007 Mamoru Tasaka - 0.6.2-2 - Trial workaround patch for bug 427070 * Thu Dec 20 2007 Mamoru Tasaka - 0.6.2-1 - 0.6.2 - Two patches for 0.6.2b2 are removed. * Sun Dec 16 2007 Mamoru Tasaka - 0.6.2-0.6.b2 - Pass exception when user don't use evolution for mailer. - Fix crash when yelp is not installed. - Add INSTALL to %%doc as this file contains some useful information. * Wed Dec 12 2007 Mamoru Tasaka - 0.6.2-0.3.b2 - Also require ruby(revolution) * Tue Nov 13 2007 Mamoru Tasaka - 0.6.2-0.2.b2 - Add more requires of ruby modules to support more function * Sun Nov 4 2007 Mamoru Tasaka - 0.6.2-0.1.b2 - And try 0.6.2 beta 2 * Fri Nov 2 2007 Mamoru Tasaka - 0.6.2-0.1.b1 - Try 0.6.2 beta 1 * Fri May 11 2007 Mamoru Tasaka - 0.6.1-3 - This time completely disable scrollkeeper-update - Create 128x128 icon also * Tue May 1 2007 Mamoru Tasaka - 0.6.1-2 - Fix scriptlets typo * Sun Apr 22 2007 Mamoru Tasaka - 0.6.1-1 - Initial packaging