]> git.pld-linux.org Git - packages/crossmingw32-expat.git/blob - crossmingw32-expat.spec
- filer out compiler options not supported by mingw
[packages/crossmingw32-expat.git] / crossmingw32-expat.spec
1 Summary:        XML 1.0 parser - Ming32 cross version
2 Summary(pl.UTF-8):      Analizator składni XML-a 1.0 - wersja skrośna dla Ming32
3 %define         realname                expat
4 Name:           crossmingw32-%{realname}
5 Version:        2.0.1
6 Release:        4
7 License:        Thai Open Source Software Center Ltd (distributable)
8 Group:          Development/Libraries
9 Source0:        http://dl.sourceforge.net/expat/%{realname}-%{version}.tar.gz
10 # Source0-md5:  ee8b492592568805593f81f8cdf2a04c
11 Patch0:         %{realname}-ac_fixes.patch
12 Patch1:         %{realname}-soname.patch
13 URL:            http://expat.sourceforge.net/
14 BuildRequires:  autoconf
15 BuildRequires:  automake
16 BuildRequires:  crossmingw32-gcc
17 BuildRequires:  libtool
18 Requires:       crossmingw32-runtime
19 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
20
21 %define         no_install_post_strip   1
22
23 %define         target                  i386-mingw32
24 %define         target_platform         i386-pc-mingw32
25
26 %define         _sysprefix              /usr
27 %define         _prefix                 %{_sysprefix}/%{target}
28 %define         _libdir                 %{_prefix}/lib
29 %define         _dlldir                 /usr/share/wine/windows/system
30 %define         __cc                    %{target}-gcc
31 %define         __cxx                   %{target}-g++
32
33 %ifnarch %{ix86}
34 # arch-specific flags (like alpha's -mieee) are not valid for i386 gcc
35 %define         optflags        -O2
36 %endif
37 # -z options are invalid for mingw linker
38 %define         filterout_ld    -Wl,-z,.*
39 %define         filterout_c     -f[-a-z0-9=]*
40 %define         filterout_cxx   -f[-a-z0-9=]*
41
42 %description
43 Expat is an XML parser written in C. It aims to be fully conforming.
44 It is currently not a validating XML parser.
45
46 This package contains the cross version for Win32.
47
48 %description -l pl.UTF-8
49 Expat to napisany w języku C analizator składni XML-a. Dąży do pełnej
50 zgodności ze specyfikacją. Aktualnie nie jest analizatorem, który
51 potwiedzał by zgodność ze specyfikacją.
52
53 Ten pakiet zawiera wersję skrośną dla Win32.
54
55 %package static
56 Summary:        Static expat library (cross mingw32 version)
57 Summary(pl.UTF-8):      Statyczna biblioteka expat (wersja skrośna mingw32)
58 Group:          Development/Libraries
59 Requires:       %{name} = %{version}-%{release}
60
61 %description static
62 Static expat library (cross mingw32 version).
63
64 %description static -l pl.UTF-8
65 Statyczna biblioteka expat (wersja skrośna mingw32).
66
67 %package dll
68 Summary:        DLL expat library for Windows
69 Summary(pl.UTF-8):      Biblioteka DLL expat dla Windows
70 Group:          Applications/Emulators
71 Requires:       wine
72
73 %description dll
74 DLL expat library for Windows.
75
76 %description dll -l pl.UTF-8
77 Biblioteka DLL expat dla Windows.
78
79 %prep
80 %setup -q -n %{realname}-%{version}
81 %patch0 -p1
82 %patch1 -p1
83
84 %build
85 %{__libtoolize}
86 %{__aclocal}
87 %{__autoconf}
88 %configure \
89         --target=%{target} \
90         --host=%{target}
91
92 %{__make} buildlib
93
94 %install
95 rm -rf $RPM_BUILD_ROOT
96
97 %{__make} installlib \
98         DESTDIR=$RPM_BUILD_ROOT
99
100 install -d $RPM_BUILD_ROOT%{_dlldir}
101 mv -f $RPM_BUILD_ROOT%{_prefix}/bin/*.dll $RPM_BUILD_ROOT%{_dlldir}
102
103 %if 0%{!?debug:1}
104 %{target}-strip --strip-unneeded -R.comment -R.note $RPM_BUILD_ROOT%{_dlldir}/*.dll
105 %{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{_libdir}/*.a
106 %endif
107
108 rm -rf $RPM_BUILD_ROOT%{_datadir}/man
109
110 %clean
111 rm -rf $RPM_BUILD_ROOT
112
113 %files
114 %defattr(644,root,root,755)
115 %{_libdir}/libexpat.dll.a
116 %{_libdir}/libexpat.la
117 %{_includedir}/expat*.h
118
119 %files static
120 %defattr(644,root,root,755)
121 %{_libdir}/libexpat.a
122
123 %files dll
124 %defattr(644,root,root,755)
125 %{_dlldir}/libexpat-0.dll
This page took 0.256148 seconds and 4 git commands to generate.