]> git.pld-linux.org Git - packages/fail.git/blob - fail.spec
d4f2fa1aa892dd5aacdc3169afc117821ffb6e97
[packages/fail.git] / fail.spec
1 # TODO:
2 # - register gnome thumbnailer in more package-friendly way (not multiple gconftool runs)
3 # - webapp config for -html5? (optional, may be used also locally)
4 #
5 # Conditional build:
6 %bcond_without  html5   # HTML5 viewer
7 %bcond_without  magick  # ImageMagick coder
8 #
9 # html5 requires cito that requires mono that is not available yet on x32
10 %ifarch x32
11 %undefine       with_html5
12 %endif
13
14 Summary:        FAIL - First Atari Image Library
15 Summary(pl.UTF-8):      FAIL (First Atari Image Library) - biblioteka do obrazów w formatach Atari
16 Name:           fail
17 Version:        2.0.1
18 Release:        5
19 License:        GPL v2+
20 Group:          Applications/Graphics
21 Source0:        http://downloads.sourceforge.net/fail/%{name}-%{version}.tar.gz
22 # Source0-md5:  b9362106f9a23a1f99ff7bece94d9aa7
23 URL:            http://fail.sourceforge.net/
24 %{?with_magick:BuildRequires:   ImageMagick-devel >= 1:6.8}
25 %{?with_html5:BuildRequires:    asciidoc}
26 %{?with_html5:BuildRequires:    cito}
27 BuildRequires:  libpng-devel
28 BuildRequires:  libxslt-progs
29 BuildRequires:  zlib-devel
30 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
31
32 %if %{with magick}
33 %define         im_coders_dir   %{_libdir}/%(MagickCore-config --version | sed -e 's,^\\([.0-9]\\+\\) \\+\\(Q[0-9]\\+\\)\\( \\+\\(HDRI\\)\\)\\?.*,ImageMagick-\\1/modules-\\2\\4,')/coders
34 %endif
35
36 %description
37 FAIL is a viewer of pictures in native formats of Atari 8-bit, Atari
38 ST, Atari Falcon and Atari Portfolio computers.
39
40 %description -l pl.UTF-8
41 FAIL to narzędzia do przeglądania obrazów w natywnych formatach
42 komputerów Atari 8-bitowych, Atari ST, Atari Falcon oraz Atari
43 Portfolio.
44
45 %package gnome
46 Summary:        FAIL support for viewing Atari files in GNOME
47 Summary(pl.UTF-8):      Wsparcie FAIL do oglądania plików z Atari w GNOME
48 Group:          X11/Applications/Graphics
49 Requires:       %{name} = %{version}-%{release}
50
51 %description gnome
52 FAIL support for viewing Atari files in GNOME.
53
54 %description gnome -l pl.UTF-8
55 Wsparcie FAIL do oglądania plików z Atari w GNOME.
56
57 %package html5
58 Summary:        HTML5 FAIL viewer for Atari files
59 Summary(pl.UTF-8):      Przeglądarka FAIL do plików z Atari w HTML5
60 Group:          Applications/WWW
61
62 %description html5
63 HTML5 FAIL viewer for Atari files.
64
65 %description html5 -l pl.UTF-8
66 Przeglądarka FAIL do plików z Atari w HTML5.
67
68 %package -n ImageMagick-coder-fail
69 Summary:        FAIL coder for ImageMagick
70 Summary(pl.UTF-8):      Koder FAIL dla ImageMagicka
71 Group:          Libraries
72 %requires_ge_to ImageMagick ImageMagick-devel
73
74 %description -n ImageMagick-coder-fail
75 FAIL coder for ImageMagick to read Atari formats.
76
77 %description -n ImageMagick-coder-fail -l pl.UTF-8
78 Koder FAIL dla ImageMagicka, czytający formaty Atari.
79
80 %prep
81 %setup -q
82
83 %build
84 %{__make} all fail-mime.xml \
85         CC="%{__cc}" \
86         CFLAGS="%{rpmcflags} -Wall" \
87 %if %{with magick}
88         MAGICK_INCLUDE_PATH=/usr/include/ImageMagick-6/private \
89         CAN_INSTALL_MAGICK=1
90 %endif
91
92 %if %{with html5}
93 %{__make} -C html5
94 %endif
95
96 %install
97 rm -rf $RPM_BUILD_ROOT
98
99 %{__make} install-fail2png \
100         PREFIX=$RPM_BUILD_ROOT%{_prefix}
101
102 # install-thumbnailer is ugly; for now, install only this one
103 install -D fail-mime.xml $RPM_BUILD_ROOT%{_datadir}/mime/packages/fail-mime.xml
104
105 %if %{with magick}
106 install -D fail.so $RPM_BUILD_ROOT%{im_coders_dir}/fail.so
107 echo "dlname='fail.so'" >$RPM_BUILD_ROOT%{im_coders_dir}/fail.la
108 %endif
109
110 %if %{with html5}
111 install -d $RPM_BUILD_ROOT%{_datadir}/fail-html5
112 cp -p html5/*.{js,html} $RPM_BUILD_ROOT%{_datadir}/fail-html5
113 %endif
114
115 %clean
116 rm -rf $RPM_BUILD_ROOT
117
118 %files
119 %defattr(644,root,root,755)
120 %doc README.html
121 %attr(755,root,root) %{_bindir}/fail2png
122
123 %files gnome
124 %defattr(644,root,root,755)
125 %{_datadir}/mime/packages/fail-mime.xml
126 # TODO: gconf files?
127
128 %if %{with html5}
129 %files html5
130 %defattr(644,root,root,755)
131 %{_datadir}/fail-html5
132 %endif
133
134 %if %{with magick}
135 %files -n ImageMagick-coder-fail
136 %defattr(644,root,root,755)
137 %attr(755,root,root) %{im_coders_dir}/fail.so
138 %{im_coders_dir}/fail.la
139 %endif
This page took 0.067083 seconds and 3 git commands to generate.