]> granicus.if.org Git - zziplib/blob - zziplib.spec
Merge pull request #135 from JackBoosY/dev/jack/export-targets
[zziplib] / zziplib.spec
1 # norootforbuild
2 Summary:      ZZipLib - libZ-based ZIP-access Library with an Easy-to-Use API
3 Name:         zziplib
4 Version:      0.13.72
5 Release:      1
6 License:      LGPLv2.1+
7 Group:        System/Libraries
8 URL:          https://github.com/gdraheim/zziplib
9 Vendor:       Guido Draheim <guidod@gmx.de>
10 Source0:      https://github.com/gdraheim/zziplib/archive/v%{version}.tar.gz
11 BuildRoot:    /var/tmp/%{name}-%{version}-%{release}
12
13 Distribution: Original
14 Packager:     Guido Draheim <guidod@gmx.de>
15 Requires:      zlib
16 BuildRequires: zlib-devel
17 BuildRequires: SDL-devel
18 BuildRequires: zip
19
20 Provides:     libzzip0 = %version
21 Provides:     libzzip-0.so.10
22 Provides:     zziplib-lib010 = %version
23
24 #Begin3
25 # Author1:        too@iki.fi (Tomi Ollila)
26 # Author2:        guidod@gmx.de (Guido Draheim)
27 # Maintained-by:  guidod@gmx.de (Guido Draheim)
28 # Primary-Site:   zziplib.sf.net
29 # Keywords:       zip zlib inflate archive gamedata
30 # Platforms:      zlib posix
31 # Copying-Policy: Lesser GPL Version 2
32 #End
33
34 %package doc
35 Summary:      ZZipLib - Documentation Files
36 Group:        Development/Languages/C and C++
37 BuildRequires: python
38 # BuildRequires: xmlto
39 PreReq: scrollkeeper
40
41 %package devel
42 Summary:      ZZipLib - Development Files
43 Group:        Development/Languages/C and C++
44 Requires:     zziplib = %version
45 Requires:     pkgconfig
46
47 %package SDL_rwops-devel
48 Summary:      ZZipLib - Development Files for SDL_rwops
49 Group:        Development/Languages/C and C++
50 Requires:     zziplib = %version
51 Requires:     pkgconfig
52 BuildRequires: SDL-devel
53
54 %description
55  : zziplib provides read access to zipped files in a zip-archive,
56  : using compression based solely on free algorithms provided by zlib.
57  zziplib provides an additional API to transparently access files
58  being either real files or zipped files with the same filepath argument.
59  This is handy to package many files being shared data into a single
60  zip file - as it is sometimes used with gamedata or script repositories.
61  The library itself is fully multithreaded, and it is namespace clean
62  using the zzip_ prefix for its exports and declarations.
63
64 %description doc
65  : zziplib provides read access to zipped files in a zip-archive,
66  : using compression based solely on free algorithms provided by zlib.
67  these are the (html) docs, mostly generated actually.
68
69 %description devel
70  : zziplib provides read access to zipped files in a zip-archive,
71  : using compression based solely on free algorithms provided by zlib.
72  these are the header files needed to develop programs using zziplib.
73  there are test binaries to hint usage of the library in user programs.
74
75 %description SDL_rwops-devel
76  : zziplib provides read access to zipped files in a zip-archive,
77  : using compression based solely on free algorithms provided by zlib.
78  these are example headers and implementation along with a pkgconfig
79  script that allows to easily use zziplib through SDL_rwops calls.
80
81 %prep
82 #'
83 %setup
84
85
86 CFLAGS="$RPM_OPT_FLAGS" \
87 sh configure --prefix=%{_prefix} \
88              --mandir=%{_mandir} \
89              --bindir=%{_bindir} \
90              --libdir=%{_libdir} \
91              --with-docdir=%{_docdir} \
92              --disable-static --with-pic \
93              --enable-sdl  TIMEOUT=9
94 %__make zzip64-setup
95
96 %build
97 %__make %{?jobs:-j%jobs}
98 %__make %{?jobs:-j%jobs} zzip64-build
99 %__make %{?jobs:-j%jobs} doc
100
101 %check
102 %__make check
103 %__make test-sdl
104
105 %install
106 %__rm -rf %{buildroot}
107 %__make zzip64-install DESTDIR=%{buildroot}
108 %__make install DESTDIR=%{buildroot}
109 %__make zzip32-postinstall DESTDIR=%{buildroot}
110 %__make zzip-postinstall
111 %__make install-doc DESTDIR=%{buildroot}
112 %__make install-mans DESTDIR=%{buildroot}
113 %__make install-sdl DESTDIR=%{buildroot}
114
115 %clean
116 %__rm -rf %{buildroot}
117
118 %files
119       %defattr(-,root,root)
120       %{_libdir}/lib*.so.*
121
122 %post -p /sbin/ldconfig 
123 %postun -p /sbin/ldconfig
124
125 %files doc
126       %defattr(-,root,root)
127       %{_datadir}/doc/*
128 %dir  %{_datadir}/omf/%{name}
129       %{_datadir}/omf/%{name}/*
130
131 %post doc
132 test ! -f %_bindir/scrollkeeper-update || %_bindir/scrollkeeper-update
133 %postun doc
134 test ! -f %_bindir/scrollkeeper-update || %_bindir/scrollkeeper-update
135
136 %files devel
137       %defattr(-,root,root)
138 %doc  ChangeLog README TODO
139       %{_bindir}/*
140 %dir  %{_includedir}/zzip
141       %{_includedir}/zzip/*
142       %{_includedir}/*.h
143       %{_libdir}/lib*.so
144       %{_libdir}/lib*.a
145       %{_libdir}/lib*.la
146       %{_libdir}/pkgconfig/zzip*
147       %{_datadir}/aclocal/%{name}*.m4
148       %{_mandir}/man3/*
149
150 %files SDL_rwops-devel
151       %defattr(-,root,root)
152       %{_libdir}/pkgconfig/SDL*zzip*
153 %dir  %{_includedir}/SDL_rwops_zzip
154       %{_includedir}/SDL_rwops_zzip/*
155
156 %changelog
157 * So Mar 11 2012 guidod <guidod@gmx.de> 0.13.62-1
158 - next version