Browse Source

NEW: fbreader, liblinebreak

git-svn-id: http://trac.vinelinux.org/repos/projects/specs@1568 ec354946-7b23-47d6-9f5a-488ba84defc7
munepi 13 years ago
parent
commit
c5762827a0

+ 27 - 0
f/fbreader/README.Fedora

@@ -0,0 +1,27 @@
+README for Fedora
+-----------------
+
+The previously-monolithic FBReader package has now been split into
+separate subpackages:
+
+- fbreader: The ebook reader
+- zlibrary: Cross-platform GUI library 
+- zlibrary-ui-gtk: GTK+ interface for zlibrary
+- zlibrary-ui-qt:  Qt interface for zlibrary
+
+Two convenience packages are provided:
+- fbreader-gtk: installs fbreader and zlibrary-ui-gtk
+- fbreader-qt:  installs fbreader and zlibrary-ui-qt
+
+'yum install fbreader' does not guarantee which interface gets picked;
+install fbreader-gtk or -qt instead.
+
+If both -gtk and -qt interfaces are installed, by default
+the Gtk+ interface is used. To change the interface you want to use,
+do as root:
+
+# alternatives --config zlibrary-ui
+
+to reset the choice to the default, use
+
+# alternatives --auto zlibrary-ui

+ 21 - 0
f/fbreader/fbreader-0.12.9-desktop-file.patch

@@ -0,0 +1,21 @@
+--- fbreader-0.12.9/fbreader/desktop/desktop.desktop-file	2010-03-25 00:38:01.000000000 +0100
++++ fbreader-0.12.9/fbreader/desktop/desktop	2010-03-28 14:14:32.624078717 +0200
+@@ -1,9 +1,5 @@
+ [Desktop Entry]
+-Name=E-book reader
+-Name[ar]=قارئ الكتب الإلكترونية
+-Name[es]=Lector de Libros
+-Name[ru]=Чтение электронных книг
+-Name[zh_CN]=电子书阅读
++Name=FBReader
+ GenericName=E-book reader
+ GenericName[ar]=قارئ الكتب الإلكترونية
+ GenericName[es]=Lector de Libros
+@@ -19,5 +15,5 @@
+ StartupNotify=true
+ Terminal=false
+ Type=Application
+-Icon=FBReader.png
+-Categories=Office;Viewer;Literature;
++Icon=FBReader
++Categories=Office;Viewer;

+ 11 - 0
f/fbreader/fbreader-defaults.patch

@@ -0,0 +1,11 @@
+--- fbreader/data/default/external.desktop.xml.orig	2008-01-18 19:54:55.000000000 -0500
++++ fbreader/data/default/external.desktop.xml	2008-01-20 12:46:25.000000000 -0500
+@@ -3,7 +3,7 @@
+ 	<section name="Web Browser">
+ 		<program name="%browser" protocol="execute">
+ 			<action name="openLink" command="%command"/>
+-			<option name="command" defaultValue="mozilla %1 &amp;"/>
++			<option name="command" defaultValue="htmlview %1 &amp;"/>
+ 		</program>
+ 	</section>
+ </ExternalPrograms>

+ 12 - 0
f/fbreader/fbreader-optflags.patch

@@ -0,0 +1,12 @@
+--- makefiles/config.mk.orig	2007-09-07 15:05:39.000000000 -0400
++++ makefiles/config.mk	2007-09-21 11:51:53.000000000 -0400
+@@ -18,8 +18,7 @@
+ endif
+ 
+ ifeq "$(TARGET_STATUS)" "release"
+-	CFLAGS += -O3
+-	LDFLAGS += -s
++	CFLAGS += $(RPM_OPT_FLAGS)
+ endif
+ ifeq "$(TARGET_STATUS)" "debug"
+ 	CFLAGS += -O0 -g

+ 330 - 0
f/fbreader/fbreader-vl.spec

@@ -0,0 +1,330 @@
+## set Qt4 for make
+%define my_make    %__make QTPATH=${QTDIR} QTINCLUDE="-I ${QTDIR}/../include" MOC=%{_libdir}/qt4/bin/moc LDFLAGS="-L $QTDIR"
+
+
+Name:           fbreader
+Version:        0.12.10
+Release:        1%{?_dist_release}
+Summary:        E-book reader
+
+Group:          Applications/Publishing
+License:        GPLv2+
+URL:            http://www.fbreader.org/
+Source0:        http://www.fbreader.org/fbreader-sources-%{version}.tgz
+Source1:        README.Fedora
+Patch0:         fbreader-0.12.9-desktop-file.patch
+Patch1:         fbreader-optflags.patch
+# Use to expose the compiler flags used during build
+# Patch2:         fbreader-debug.patch
+Patch3:         fbreader-defaults.patch
+BuildRoot:      %{_tmppath}/%{name}-%{version}-root
+
+BuildRequires:  expat-devel bzip2-devel liblinebreak-devel
+BuildRequires:  gtk2-devel fribidi-devel
+BuildRequires:  curl-devel >= 7.17
+BuildRequires:  libjpeg-devel desktop-file-utils
+BuildRequires:  qt4-devel sqlite3-devel
+
+# needed because sometimes the API change without soname bump
+Requires:       zlibrary = %{version}-%{release}
+
+
+%description
+FBReader is an e-book reader, with the following main features:
+
+* Supports several formats: fb2, HTML, CHM, plucker, Palmdoc, zTxt
+  (Weasel), TCR (psion), RTF, OEB, OpenReader, mobipocket, plain text.
+* Direct reading from tar, zip, gzip and bzip2 archives. (Multiple
+  books in one archive are supported.)
+* Automatic library building.
+* Automatic encoding detection is supported.
+* Automatically generated contents table.
+* Embedded images support.
+* Footnotes/hyperlinks support.
+* Position indicator.
+* Keeps the last open book and the last read positions for all opened
+  books between runs.
+* List of last opened books.
+* Automatic hyphenations. Liang's algorithm is used. The same
+  algorithm is used in TeX, and TeX hyphenation patterns are used in
+  FBReader. Patterns for Czech, English, Esperanto, French, German and
+  Russian are included in the current version.
+* Text search.
+* Full-screen mode.
+* Screen rotation by 90, 180 and 270 degrees.
+#'
+
+%package        gtk
+Summary:        E-book reader (GTK+ interface)
+Group:          Applications/Publishing
+Requires:       %{name} = %{version}-%{release}
+Requires:       zlibrary-ui-gtk = %{version}-%{release}
+
+%description    gtk
+A virtual package that bundles both the FBreader e-book reader and its
+GTK+ user interface.
+
+
+%package        qt
+Summary:        E-book reader (Qt interface)
+Group:          Applications/Publishing
+Requires:       %{name} = %{version}-%{release}
+Requires:       zlibrary-ui-qt = %{version}-%{release}
+
+%description    qt
+A virtual package that bundles both the FBreader e-book reader and its
+Qt4 user interface.
+
+
+%package -n     zlibrary
+Summary:        Cross-platform GUI library
+Group:          System Environment/Libraries
+Requires:       zlibrary-ui = %{version}-%{release}
+
+%description -n zlibrary
+ZLibrary is a cross-platform library to build applications running on
+desktop Linux, Windows, and different Linux-based PDAs.
+
+
+%package -n     zlibrary-devel
+Summary:        Development files for zlibrary
+Group:          Development/Libraries
+Requires:       zlibrary = %{version}-%{release}
+
+%description -n zlibrary-devel
+This package contains the libraries amd header files that are needed
+for writing applications with Zlibrary.
+
+
+%package -n     zlibrary-ui-gtk
+Summary:        GTK+ interface module for ZLibrary
+Group:          System Environment/Libraries
+Provides:       zlibrary-ui = %{version}-%{release}
+
+Requires(posttrans): /sbin/update-alternatives
+Requires(postun):    /sbin/update-alternatives
+
+%description -n zlibrary-ui-gtk
+ZLibrary is a cross-platform library to build applications running on
+desktop Linux, Windows, and different Linux-based PDAs.
+
+This package provides a GTK+-based UI for ZLibrary.
+
+
+%package -n     zlibrary-ui-qt
+Summary:        Qt4 interface module for ZLibrary
+Group:          System Environment/Libraries
+Provides:       zlibrary-ui = %{version}-%{release}
+Provides:       zlibrary-ui-qt4 = %{version}-%{release}
+Obsoletes:      zlibrary-ui-qt4 < %{version}-%{release}
+
+Requires(posttrans): /sbin/update-alternatives
+Requires(postun):    /sbin/update-alternatives
+
+%description -n zlibrary-ui-qt
+ZLibrary is a cross-platform library to build applications running on
+desktop Linux, Windows, and different Linux-based PDAs.
+
+This package provides a Qt4-based UI for ZLibrary.
+
+%prep
+%setup -q
+%patch0 -p1 -b .desktop-file
+%patch1 -p0 -b .optflags
+#%patch2 -p0 -b .debug
+%patch3 -p0 -b .defaults
+cp -p %{SOURCE1} .
+
+
+%build
+## export $QTDIR
+unset QTDIR || : ; . /etc/profile.d/qt4.sh
+
+%my_make %{?_smp_mflags} -C zlibrary/core TARGET_ARCH=desktop \
+     LIBDIR=%{_libdir} UI_TYPE=dummy
+%my_make %{?_smp_mflags} -C zlibrary/text TARGET_ARCH=desktop \
+     LIBDIR=%{_libdir} UI_TYPE=dummy
+%my_make %{?_smp_mflags} -C zlibrary/ui TARGET_ARCH=desktop \
+     LIBDIR=%{_libdir} UI_TYPE=gtk
+%my_make %{?_smp_mflags} -C zlibrary/ui TARGET_ARCH=desktop \
+     LIBDIR=%{_libdir} UI_TYPE=qt4
+%my_make %{?_smp_mflags} -C fbreader TARGET_ARCH=desktop \
+     LIBDIR=%{_libdir} UI_TYPE=dummy
+
+
+%install
+%__rm -rf $RPM_BUILD_ROOT
+%__make -C zlibrary/core do_install do_install_dev \
+     DESTDIR=$RPM_BUILD_ROOT TARGET_ARCH=desktop \
+     LIBDIR=%{_libdir} UI_TYPE=dummy
+%__make -C zlibrary/text do_install do_install_dev \
+     DESTDIR=$RPM_BUILD_ROOT TARGET_ARCH=desktop \
+     LIBDIR=%{_libdir} UI_TYPE=dummy
+%__make -C zlibrary/ui do_install DESTDIR=$RPM_BUILD_ROOT TARGET_ARCH=desktop \
+     LIBDIR=%{_libdir} UI_TYPE=gtk
+%__make -C zlibrary/ui do_install DESTDIR=$RPM_BUILD_ROOT TARGET_ARCH=desktop \
+     LIBDIR=%{_libdir} UI_TYPE=qt4
+%__make -C fbreader do_install DESTDIR=$RPM_BUILD_ROOT TARGET_ARCH=desktop \
+     UI_TYPE=dummy
+
+desktop-file-install --vendor="vine" \
+    --remove-category="Application" \
+    --delete-original \
+    --dir=%{buildroot}%{_datadir}/applications \
+    %{buildroot}%{_datadir}/applications/FBReader.desktop
+
+
+%clean
+%__rm -rf $RPM_BUILD_ROOT
+
+
+%post -n zlibrary -p /sbin/ldconfig
+
+%postun -n zlibrary -p /sbin/ldconfig
+
+%posttrans -n zlibrary-ui-gtk
+/sbin/update-alternatives \
+  --install \
+  %{_libdir}/zlibrary/ui/zlui-active.so \
+  zlibrary-ui \
+  %{_libdir}/zlibrary/ui/zlui-gtk.so \
+  2
+
+%posttrans -n zlibrary-ui-qt
+/sbin/update-alternatives \
+  --install \
+  %{_libdir}/zlibrary/ui/zlui-active.so \
+  zlibrary-ui \
+  %{_libdir}/zlibrary/ui/zlui-qt4.so \
+  1
+
+%postun -n zlibrary-ui-gtk
+if [ $1 -eq 0 ]; then
+    /sbin/update-alternatives --remove zlibrary-ui \
+	%{_libdir}/zlibrary/ui/zlui-gtk.so
+fi
+exit 0
+
+%postun -n zlibrary-ui-qt
+if [ $1 -eq 0 ]; then
+    /sbin/update-alternatives --remove unison \
+	%{_libdir}/zlibrary/ui/zlui-qt4.so
+fi
+exit 0
+
+%files
+%defattr(-,root,root,-)
+%doc fbreader/LICENSE README.Fedora
+%{_bindir}/FBReader
+%{_datadir}/FBReader
+%{_datadir}/applications/*-FBReader.desktop
+%{_datadir}/pixmaps/FBReader.png
+%{_datadir}/pixmaps/FBReader
+
+%files gtk
+%files qt
+
+%files -n zlibrary
+%defattr(-,root,root,-)
+%doc fbreader/LICENSE
+%{_libdir}/lib*.so.*
+%dir %{_libdir}/zlibrary
+%dir %{_libdir}/zlibrary/ui
+%exclude %{_datadir}/zlibrary/keynames-*.xml
+%{_datadir}/zlibrary
+
+%files -n zlibrary-devel
+%defattr(-,root,root,-)
+%{_includedir}/*
+%{_libdir}/lib*.so
+
+%files -n zlibrary-ui-gtk
+%defattr(-,root,root,-)
+%{_libdir}/zlibrary/ui/zlui-gtk.so
+%{_datadir}/zlibrary/keynames-gtk.xml
+
+%files -n zlibrary-ui-qt
+%defattr(-,root,root,-)
+%{_libdir}/zlibrary/ui/zlui-qt4.so
+%{_datadir}/zlibrary/keynames-qt4.xml
+
+
+
+%changelog
+* Thu Aug 12 2010 Munehiro Yamamoto <munepi@vinelinux.org> - 0.12.10-1
+- initial build based on Fedora development
+
+* Mon Jun  7 2010 Michel Salim <salimma@fedoraproject.org> - 0.12.10-1
+- Update to 0.12.10
+
+* Sun Mar 28 2010 Michel Salim <salimma@fedoraproject.org> - 0.12.9-1
+- Update to 0.12.9
+
+* Sat Feb 13 2010 Michel Salim <salimma@fedoraproject.org> - 0.12.2-1
+- Update to 0.12.2
+- Fix overlap between fbreader and zlibrary
+
+* Tue Jan 26 2010 Michel Salim <salimma@fedoraproject.org> - 0.12.1-1
+- Update to 0.12.1
+
+* Sat Oct 17 2009 Michel Salim <salimma@fedoraproject.org> - 0.10.7-4
+- Provide virtual packages for each available interface
+- Use alternatives to select the user interface (see README.Fedora)
+
+* Thu Sep 17 2009 Michel Salim <salimma@fedoraproject.org> - 0.10.7-3
+- Split out zlibrary and zlibrary-ui subpackages (fixes bz# 523946)
+
+* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.10.7-2
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
+
+* Tue Mar 31 2009 Michel Salim <salimma@fedoraproject.org> - 0.10.7-1
+- Update to 0.10.7
+
+* Tue Feb 24 2009 Michel Salim <salimma@fedoraproject.org> - 0.10.3-3
+- Fix for GCC 4.4
+
+* Tue Feb 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.10.3-2
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
+
+* Thu Feb  5 2009 Michel Salim <salimma@fedoraproject.org> - 0.10.3-1
+- Update to 0.10.3
+
+* Wed Jan 28 2009 Michel Salim <salimma@fedoraproject.org> - 0.10.2-1
+- Update to 0.10.2
+
+* Wed Jan 14 2009 Michel Salim <salimma@fedoraproject.org> - 0.10.0-1
+- Update to 0.10.0
+
+* Thu Jul 31 2008 Michel Alexandre Salim <salimma@fedoraproject.org> - 0.8.17-1
+- Update to 0.8.17
+
+* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 0.8.12-2
+- Autorebuild for GCC 4.3
+
+* Sun Jan 20 2008 Michel Alexandre Salim <michel.sylvan@gmail.com> - 0.8.12-1
+- Update to 0.8.12
+
+* Mon Jan  7 2008 Michel Alexandre Salim <michel.sylvan@gmail.com> - 0.8.10-1
+- Update to 0.8.10
+- Remove workaround for PDB issues on x86_64; fixed upstream
+
+* Thu Dec 20 2007 Michel Alexandre Salim <michel.sylvan@gmail.com> - 0.8.8a-1
+- Update to 0.8.8a
+- Workaround for PDB format handler when reading certain files
+
+* Wed Dec 19 2007 Michel Alexandre Salim <michel.sylvan@gmail.com> - 0.8.8-2
+- Fix inclusion of debug files where libdir=/usr/lib (bz #411891)
+
+* Sun Dec  2 2007 Michel Alexandre Salim <michel.sylvan@gmail.com> - 0.8.8-1
+- Update to 0.8.8
+
+* Thu Oct 18 2007 Michel Alexandre Salim <michel.sylvan@gmail.com> - 0.8.6d-3
+- Generate proper -debuginfo subpackage (bz #329841, Ville Skytta)
+- Add README.Fedora detailing zTXT bug on x86_64
+
+* Sat Sep 22 2007 Michel Alexandre Salim <michel.sylvan@gmail.com> - 0.8.6d-2
+- Fix vendor tag
+- Use compiler flags provided by the system
+
+* Sun Sep 16 2007 Michel Alexandre Salim <michel.sylvan@gmail.com> - 0.8.6d-1
+- Initial package

+ 93 - 0
lib/libl/liblinebreak-vl.spec

@@ -0,0 +1,93 @@
+Name:           liblinebreak
+Version:        2.0
+Release:        1%{?_dist_release}
+Summary:        A Unicode line-breaking library
+
+Group:          Development/Libraries
+License:        zlib
+URL:            http://sourceforge.net/projects/vimgadgets/
+Source0:        http://downloads.sourceforge.net/vimgadgets/%{name}-%{version}.tar.gz
+BuildRoot:      %{_tmppath}/%{name}-%{version}-root
+
+BuildRequires:  autoconf automake libtool
+
+%description
+liblinebreak is an implementation of the line breaking algorithm as
+described in Unicode 5.0.0 Standard Annex 14, Revision 19, available
+at http://www.unicode.org/reports/tr14/tr14-19.html
+
+
+%package      devel
+Summary:      Development files for %{name}
+Group:        Development/Libraries
+Requires:     %{name} = %{version}-%{release}
+
+%description  devel
+The %{name}-devel package contains libraries and header files for
+developing applications that use %{name}.
+
+
+%prep
+%setup -q
+%configure --disable-static
+
+
+%build
+%__make %{?_smp_mflags}
+
+
+%install
+%__rm -rf $RPM_BUILD_ROOT
+%__make install DESTDIR=$RPM_BUILD_ROOT
+find $RPM_BUILD_ROOT -name '*.la' -exec %__rm -f {} ';'
+
+
+%clean
+%__rm -rf $RPM_BUILD_ROOT
+
+
+%post -p /sbin/ldconfig
+
+%postun -p /sbin/ldconfig
+
+
+%files
+%defattr(-,root,root,-)
+%doc ChangeLog LICENCE NEWS README
+%{_libdir}/*.so.*
+
+%files devel
+%{_includedir}/*
+%{_libdir}/*.so
+
+
+%changelog
+* Thu Aug 12 2010 Munehiro Yamamoto <munepi@vinelinux.org> - 2.0-1
+- initial build based on Fedora development
+
+* Sat Jul  3 2010 Michel Salim <salimma@fedoraproject.org> - 2.0-1
+- Update to 2.0
+
+* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2-2
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
+
+* Thu Jul  2 2009 Michel Salim <salimma@fedoraproject.org> - 1.2-1
+- Update to 1.2
+- Build as dynamic library, instead of static
+
+* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.6-0.5.20080421cvs
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
+
+* Thu Jul 31 2008 Michel Salim <michel@berlin.local> - 0.9.6-0.4.20080421cvs%{?dist}
+- Rename package to liblinebreak, providing -{devel,static}
+
+* Mon Jul 14 2008 Michel Alexandre Salim <salimma@fedoraproject.org> - 0.9.6-0.3.20080421cvs
+- Change versioning scheme
+- Updated checkout instructions
+
+* Mon Jun  9 2008 Michel Alexandre Salim <salimma@fedoraproject.org> - 0.9.6-0.2
+- Rename to liblinebreak-devel, provides liblinebreak-static
+
+* Wed Jun  4 2008 Michel Alexandre Salim <salimma@fedoraproject.org> - 0.9.6-0.1
+- Initial package
+