]> git.pld-linux.org Git - packages/calibre.git/blame - calibre.spec
- try to revert to separated .mo files
[packages/calibre.git] / calibre.spec
CommitLineData
17e051e1 1#
0d2e0555 2# TODO: - xdg stuff (put desktops and icons in proper place)
b856ebb4 3#
17e051e1 4# NOTE:
5# Upstream packages some unfree fonts which we cannot redistribute,
6# so when upgrading calibre we should download upstream tarball by hand from
3c9d3d2b 7# http://downloads.sourceforge.net/calibre and run generate-tarball.sh script
8# included as SourceX.
17e051e1 9#
02229893 10Summary: E-book converter and library management
cee72504 11Summary(pl.UTF-8): Konwerter oraz biblioteka dla e-booków
0e501b81 12Name: calibre
596b97c3 13Version: 0.8.7
f6f5b3d6 14Release: 0.1
6d15f615 15License: GPL v3+
02229893 16Group: Applications/Multimedia
23304c7f 17Source0: %{name}-%{version}-nofonts.tar.xz
596b97c3 18# Source0-md5: f6243502d832893845d8f59bc847ce2f
3c9d3d2b 19Source1: generate-tarball.sh
5cf7f03b 20Source2: %{name}-mount-helper
0e501b81 21Patch0: %{name}-prefix.patch
7b500ff7 22Patch1: %{name}-manpages.patch
804e0619 23Patch2: %{name}-no-update.patch
73a1f5ed 24Patch3: %{name}-env_module.patch
f6f5b3d6 25Patch4: %{name}-locales.patch
26Patch5: shebang-python-fix.patch
02229893 27URL: http://www.calibre-ebook.com/
3b8cf9a9 28BuildRequires: ImageMagick-devel >= 6.6.4.7
0e501b81 29BuildRequires: chmlib-devel
212c1324 30BuildRequires: libicu-devel
f0879852 31BuildRequires: pkgconfig
0e501b81 32BuildRequires: podofo-devel
64b69419 33BuildRequires: poppler-Qt-devel
bdbd4238 34BuildRequires: python-BeautifulSoup
307ba398 35BuildRequires: python-PIL
0e501b81 36BuildRequires: python-PyQt4-devel
7b88f8fb 37BuildRequires: python-cssutils >= 1:0.9.7
307ba398 38BuildRequires: python-dateutil
72cd9da3 39BuildRequires: python-devel >= 1:2.7.1
0e501b81 40BuildRequires: python-lxml
41BuildRequires: python-mechanize
6d15f615 42BuildRequires: python-modules-sqlite
0e501b81 43BuildRequires: python-sip-devel
44BuildRequires: rpm-pythonprov
23304c7f 45BuildRequires: rpmbuild(macros) >= 1.586
ddb4b081 46BuildRequires: sed >= 4.0
212c1324 47BuildRequires: sqlite3-devel
23304c7f 48BuildRequires: tar >= 1:1.22
f6f5b3d6 49BuildRequires: unzip
3c9d3d2b 50BuildRequires: xdg-utils
23304c7f 51BuildRequires: xz >= 1:4.999.7
e27d2bb7 52Requires: ImageMagick-coder-jpeg
0b8a8150 53Requires: ImageMagick-coder-png
82b553c6 54Requires: python-BeautifulSoup
2f356583 55Requires: python-PIL
6d15f615 56Requires: python-cssutils
2f356583 57Requires: python-dateutil
6d15f615 58Requires: python-lxml
59Requires: python-mechanize
60Requires: python-modules-sqlite
0e501b81 61BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
62
63%description
02229893
ER
64Calibre is meant to be a complete e-library solution. It includes
65library management, format conversion, news feeds to ebook conversion
66as well as e-book reader sync features.
67
68Calibre is primarily a ebook cataloging program. It manages your ebook
69collection for you. It is designed around the concept of the logical
70book, i.e. a single entry in the database that may correspond to
71ebooks in several formats. It also supports conversion to and from a
72dozen different ebook formats.
73
74Supported input formats are: MOBI, LIT, PRC, EPUB, CHM, ODT, HTML,
75CBR, CBZ, RTF, TXT, PDF and LRS.
0e501b81 76
cee72504 77%description -l pl.UTF-8
78Calibre to bardzo dobry i darmowy program do czytania e-książek.
79
80Calibre umożliwia zarówno czytanie e-książek jak i konwersję wielu
81formatów do ich postaci. Program obsługuje następujące typy plików:
82import: LRF, PDF, LIT, RTF, OPF, MOBI, PRC, EPUB, FB2, IMP, RB i HTML
83eksport: Mobi, LRF i EPUB oraz do aplikacji iPhone-reader i Stanza.
84
85Ten czytnik e-książek oferuje również pobieranie okładek, komiksów i
86najnowszych wiadomości z serwisów poświęconym e-książkom. Twórcy
87dołączyli również aplikację, którą użytkownik może wykorzystać jako
88swój własny serwer darmowych książek.
89
62c1bf99 90%package -n bash-completion-calibre
91Summary: bash-completion for calibre
92Summary(pl.UTF-8): bashowe uzupełnianie nazw dla calibre
93Group: Applications/Shells
94Requires: %{name} = %{version}-%{release}
956f97d9 95Requires: bash-completion
62c1bf99 96
97%description -n bash-completion-calibre
98bash-completion for calibre.
99
100%description -n bash-completion-calibre -l pl.UTF-8
101Pakiet ten dostarcza bashowe uzupełnianie nazw dla calibre.
102
0e501b81 103%prep
104%setup -q -n %{name}
105%patch0 -p1
7b500ff7 106%patch1 -p1
804e0619 107%patch2 -p1
73a1f5ed 108%patch3 -p1
ddb4b081 109%patch4 -p1
f6f5b3d6 110%patch5 -p1
111
112mkdir resources/localization/locales
113unzip resources/localization/locales.zip -d resources/localization/locales
114chmod 755 resources/localization/locales/*
0e501b81 115
116%build
5c163f25 117%{__python} setup.py build
0e501b81 118
119%install
120rm -rf $RPM_BUILD_ROOT
121
122%{__python} setup.py install \
9c8cebf1 123 --root=$RPM_BUILD_ROOT \
ab1a9c7b 124 --libdir="%{_libdir}"
0e501b81 125
e154a7c1
JP
126%py_ocomp $RPM_BUILD_ROOT%{_libdir}/%{name}
127%py_comp $RPM_BUILD_ROOT%{_libdir}/%{name}
128%py_postclean %{_libdir}/%{name}
129
ddb4b081 130# move manpages and locales to proper place
7b500ff7 131mv $RPM_BUILD_ROOT%{_datadir}/%{name}/man $RPM_BUILD_ROOT%{_mandir}
f6f5b3d6 132mv $RPM_BUILD_ROOT%{_datadir}/%{name}/localization/locales $RPM_BUILD_ROOT%{_datadir}/locale
133
134# set proper filenames for locales (TODO: switch to patch if possible)
135for file in $RPM_BUILD_ROOT%{_datadir}/locale/*/LC_MESSAGES/messages.mo; do
136 lang=$(echo $file|%{__sed} 's:.*locale/\(.*\)/LC_MESSAGES.*:\1:')
137 mv $RPM_BUILD_ROOT%{_datadir}/locale/$lang/LC_MESSAGES/messages.mo \
138 $RPM_BUILD_ROOT%{_datadir}/locale/$lang/LC_MESSAGES/%{name}.mo
139done;
140for file in $RPM_BUILD_ROOT%{_datadir}/locale/*/LC_MESSAGES/iso639.mo; do
141 lang=$(echo $file|%{__sed} 's:.*locale/\(.*\)/LC_MESSAGES.*:\1:')
142 mv $RPM_BUILD_ROOT%{_datadir}/locale/$lang/LC_MESSAGES/iso639.mo \
143 $RPM_BUILD_ROOT%{_datadir}/locale/$lang/LC_MESSAGES/%{name}_iso639.mo
144done;
145for file in $RPM_BUILD_ROOT%{_datadir}/locale/*/LC_MESSAGES/qt.qm; do
146 lang=$(echo $file|%{__sed} 's:.*locale/\(.*\)/LC_MESSAGES.*:\1:')
147 mv $file $RPM_BUILD_ROOT%{_datadir}/locale/$lang/LC_MESSAGES/%{name}.$lang.qm
148done;
ddb4b081 149
e9035516 150%{__rm} $RPM_BUILD_ROOT%{_bindir}/%{name}-uninstall
ddb4b081 151
f6f5b3d6 152# unsupported
153%{__rm} -r $RPM_BUILD_ROOT%{_datadir}/locale/ltg
154
d383d054
MM
155install %{SOURCE2} $RPM_BUILD_ROOT%{_bindir}
156
0e501b81 157%clean
158rm -rf $RPM_BUILD_ROOT
159
596b97c3 160%files
0e501b81 161%defattr(644,root,root,755)
23304c7f 162%doc Changelog.yaml COPYRIGHT README
163%attr(755,root,root) %{_bindir}/calibre
164%attr(755,root,root) %{_bindir}/calibre-complete
165%attr(755,root,root) %{_bindir}/calibre-customize
166%attr(755,root,root) %{_bindir}/calibre-debug
d383d054 167%attr(755,root,root) %{_bindir}/calibre-mount-helper
23304c7f 168%attr(755,root,root) %{_bindir}/calibre-parallel
169%attr(755,root,root) %{_bindir}/calibre-server
170%attr(755,root,root) %{_bindir}/calibre-smtp
171%attr(755,root,root) %{_bindir}/calibredb
172%attr(755,root,root) %{_bindir}/ebook-convert
173%attr(755,root,root) %{_bindir}/ebook-device
174%attr(755,root,root) %{_bindir}/ebook-meta
175%attr(755,root,root) %{_bindir}/ebook-viewer
176%attr(755,root,root) %{_bindir}/epub-fix
177%attr(755,root,root) %{_bindir}/fetch-ebook-metadata
23304c7f 178%attr(755,root,root) %{_bindir}/lrf2lrs
179%attr(755,root,root) %{_bindir}/lrfviewer
180%attr(755,root,root) %{_bindir}/lrs2lrf
181%attr(755,root,root) %{_bindir}/markdown-calibre
182%attr(755,root,root) %{_bindir}/pdfmanipulate
183%attr(755,root,root) %{_bindir}/web2disk
0e501b81 184%{_datadir}/%{name}
185%{_libdir}/%{name}
7b500ff7 186%{_mandir}/man1/*.1*
62c1bf99 187
188%files -n bash-completion-calibre
189%defattr(644,root,root,755)
190%{_sysconfdir}/bash_completion.d/*
This page took 0.097774 seconds and 4 git commands to generate.