]> git.pld-linux.org Git - SPECS.git/blob - xchm.spec
SPECS updated Wed 28 Jul 14:48:01 CEST 2021
[SPECS.git] / xchm.spec
1 #
2 # Conditional build:
3 %bcond_with     xmlrpc          # enable XmlRpc functionality
4 %bcond_without  unicode         # unicode version of wxGTK2
5 #
6 Summary:        CHM viewer for UNIX
7 Summary(pl.UTF-8):      Przeglądarka CHM dla Uniksów
8 Name:           xchm
9 Version:        1.23
10 Release:        4
11 License:        GPL v2+
12 Group:          X11/Applications
13 Source0:        http://downloads.sourceforge.net/xchm/%{name}-%{version}.tar.gz
14 # Source0-md5:  486d029bd81071a2d04e7181909b1602
15 Source1:        %{name}.desktop
16 Patch0:         wxWidgets3.patch
17 Patch1:         %{name}-pl.po-update.patch
18 URL:            http://xchm.sourceforge.net/
19 BuildRequires:  autoconf >= 2.50
20 BuildRequires:  automake
21 BuildRequires:  chmlib-devel
22 BuildRequires:  gettext-tools >= 0.14.3
23 BuildRequires:  wxGTK2-%{?with_unicode:unicode-}devel >= 2.8.0
24 %if %{with xmlrpc}
25 # for configure check
26 BuildRequires:  openssl-devel
27 BuildRequires:  xmlrpc++-devel
28 %endif
29 Requires(post,postun):  desktop-file-utils
30 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
31
32 %description
33 xCHM is a CHM viewer for UNIX, based on Jed Wing's CHMLIB and written
34 with wxWidgets.
35
36 %description -l pl.UTF-8
37 xCHM to przeglądarka plików CHM dla Uniksa, napisana w oparciu o
38 CHMLIB Jeda Winga, z użyciem wxWidgets.
39
40 %prep
41 %setup -q
42 %patch0 -p1
43 %patch1 -p1
44
45 %{__rm} po/stamp-po
46
47 %build
48 %{__gettextize}
49 %{__aclocal}
50 %{__autoconf}
51 %{__autoheader}
52 %{__automake}
53 %configure \
54         %{?with_xmlrpc:--enable-xmlrpc} \
55         WX_CONFIG_NAME=%{_bindir}/wx-gtk2-%{!?with_unicode:ansi}%{?with_unicode:unicode}-config
56 %{__make}
57
58 %install
59 rm -rf $RPM_BUILD_ROOT
60 install -d $RPM_BUILD_ROOT{%{_pixmapsdir},%{_desktopdir}}
61
62 %{__make} install \
63         DESTDIR=$RPM_BUILD_ROOT
64
65 install art/xchm-48.xpm $RPM_BUILD_ROOT%{_pixmapsdir}/xchm.xpm
66 install %{SOURCE1}      $RPM_BUILD_ROOT%{_desktopdir}
67
68 # unify to short code pt=pt_PT
69 %{__mv} $RPM_BUILD_ROOT%{_datadir}/locale/{pt_PT,pt}
70 # fix Greek language code
71 %{__mv} $RPM_BUILD_ROOT%{_datadir}/locale/{gr,el}
72
73 %find_lang %{name}
74
75 %clean
76 rm -rf $RPM_BUILD_ROOT
77
78 %post
79 %update_desktop_database
80
81 %postun
82 %update_desktop_database_postun
83
84 %files -f %{name}.lang
85 %defattr(644,root,root,755)
86 %doc AUTHORS ChangeLog README %{?with_xmlrpc:README.xmlrpc}
87 %attr(755,root,root) %{_bindir}/xchm
88 %{_desktopdir}/xchm.desktop
89 %{_pixmapsdir}/xchm*.png
90 %{_pixmapsdir}/xchm*.xpm
This page took 0.205113 seconds and 3 git commands to generate.