]>
Commit | Line | Data |
---|---|---|
1c2c06ec | 1 | Summary: Character set conversion library - mingw32 cross version |
83f8bd69 | 2 | Summary(pl.UTF-8): Biblioteka konwersji zestawów znaków - wersja skrośna dla mingw32 |
4bed20cc | 3 | %define _realname libiconv |
4 | Name: crossmingw32-%{_realname} | |
20246ebc | 5 | Version: 1.11 |
d448d73b | 6 | Release: 1 |
61701235 | 7 | License: LGPL |
bdbdd5a9 | 8 | Group: Development/Libraries |
4bed20cc | 9 | Source0: ftp://ftp.gnu.org/gnu/libiconv/%{_realname}-%{version}.tar.gz |
20246ebc | 10 | # Source0-md5: b77a17e4a5a817100ad4b2613935055e |
ceff60a8 | 11 | Patch0: %{name}.patch |
61701235 | 12 | URL: http://www.gnu.org/software/libiconv/ |
02669876 | 13 | BuildRequires: automake |
1c2c06ec | 14 | BuildRequires: crossmingw32-gcc |
d448d73b JB |
15 | # because of broken w32 relink in libtool |
16 | BuildConflicts: crossmingw32-libiconv < 1.10 | |
ceff60a8 JB |
17 | Requires: crossmingw32-runtime |
18 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
61701235 | 19 | |
20 | %define no_install_post_strip 1 | |
21 | ||
22 | %define target i386-mingw32 | |
23 | %define target_platform i386-pc-mingw32 | |
4bed20cc | 24 | %define arch %{_prefix}/%{target} |
25 | %define gccarch %{_prefix}/lib/gcc-lib/%{target} | |
26 | %define gcclib %{_prefix}/lib/gcc-lib/%{target}/%{version} | |
27 | ||
ceff60a8 JB |
28 | %define _sysprefix /usr |
29 | %define _prefix %{_sysprefix}/%{target} | |
4bed20cc | 30 | %define _pkgconfigdir %{_prefix}/lib/pkgconfig |
bdbdd5a9 | 31 | %define _dlldir /usr/share/wine/windows/system |
61701235 | 32 | %define __cc %{target}-gcc |
33 | %define __cxx %{target}-g++ | |
34 | ||
bdbdd5a9 | 35 | %ifnarch alpha sparc sparc64 sparcv9 |
4308b81c | 36 | %define optflags -O2 |
37 | %endif | |
38 | ||
61701235 | 39 | %description |
d57663a5 | 40 | The libiconv library provides an iconv() implementation, for use on |
41 | systems which don't have one, or whose implementation cannot convert | |
42 | from/to Unicode. | |
43 | ||
1c2c06ec JB |
44 | This package contains the cross version for mingw32. |
45 | ||
46dadd27 JR |
46 | %description -l pl.UTF-8 |
47 | Ta biblioteka dostarcza implementację iconv() do używania z systemami, | |
48 | które takiej funkcji nie posiadają, lub na których implementacja nie | |
49 | potrafi konwertować z/do Unikodu. | |
d57663a5 | 50 | |
46dadd27 | 51 | Ten pakiet zawiera wersję skrośną dla mingw32. |
61701235 | 52 | |
bdbdd5a9 JB |
53 | %package static |
54 | Summary: Static iconv libraries (cross mingw32 version) | |
55 | Summary(pl.UTF-8): Statyczne biblioteki iconv (wersja skrośna mingw32) | |
56 | Group: Development/Libraries | |
57 | Requires: %{name} = %{version}-%{release} | |
58 | ||
59 | %description static | |
60 | Static iconv libraries (cross mingw32 version). | |
61 | ||
62 | %description static -l pl.UTF-8 | |
63 | Statyczne biblioteki iconv (wersja skrośna mingw32). | |
64 | ||
02669876 | 65 | %package dll |
bdbdd5a9 JB |
66 | Summary: DLL iconv libraries for Windows |
67 | Summary(pl.UTF-8): Biblioteki DLL iconv dla Windows | |
02669876 | 68 | Group: Applications/Emulators |
bdbdd5a9 | 69 | Requires: wine |
02669876 | 70 | |
71 | %description dll | |
bdbdd5a9 | 72 | DLL iconv libraries for Windows. |
02669876 | 73 | |
46dadd27 | 74 | %description dll -l pl.UTF-8 |
bdbdd5a9 | 75 | Biblioteki DLL iconv dla Windows. |
02669876 | 76 | |
61701235 | 77 | %prep |
4bed20cc | 78 | %setup -q -n %{_realname}-%{version} |
61701235 | 79 | %patch0 -p1 |
80 | ||
81 | %build | |
4c6026be | 82 | cp -f /usr/share/automake/config.sub libcharset/autoconf |
83 | cp -f /usr/share/automake/config.sub autoconf | |
61701235 | 84 | %configure \ |
02669876 | 85 | --target="%{target}" \ |
c28ed475 | 86 | --host="%{target}" \ |
02669876 | 87 | --enable-static |
ceff60a8 | 88 | |
61701235 | 89 | %{__make} |
90 | ||
91 | %install | |
92 | rm -rf $RPM_BUILD_ROOT | |
bdbdd5a9 | 93 | install -d $RPM_BUILD_ROOT%{_dlldir} |
61701235 | 94 | |
95 | %{__make} install \ | |
96 | DESTDIR=$RPM_BUILD_ROOT | |
97 | ||
bdbdd5a9 JB |
98 | mv -f $RPM_BUILD_ROOT%{_prefix}/bin/*.dll $RPM_BUILD_ROOT%{_dlldir} |
99 | ||
100 | %if 0%{!?debug:1} | |
101 | %{target}-strip -R.comment -R.note $RPM_BUILD_ROOT%{_dlldir}/*.dll | |
102 | %{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{_libdir}/*.a | |
103 | %endif | |
104 | ||
105 | # not used on win32 | |
106 | rm -f $RPM_BUILD_ROOT%{_libdir}/charset.alias | |
107 | # runtime only | |
108 | rm -f $RPM_BUILD_ROOT%{_bindir}/iconv | |
109 | rm -rf $RPM_BUILD_ROOT%{_datadir}/locale | |
110 | ||
111 | rm -rf $RPM_BUILD_ROOT%{_datadir}/{doc,man} | |
ceff60a8 | 112 | |
61701235 | 113 | %clean |
114 | rm -rf $RPM_BUILD_ROOT | |
115 | ||
116 | %files | |
1c2c06ec | 117 | %defattr(644,root,root,755) |
bdbdd5a9 JB |
118 | %{_libdir}/libcharset.dll.a |
119 | %{_libdir}/libiconv.dll.a | |
120 | %{_libdir}/libcharset.la | |
121 | %{_libdir}/libiconv.la | |
122 | %{_includedir}/iconv.h | |
123 | %{_includedir}/libcharset.h | |
124 | %{_includedir}/localcharset.h | |
125 | ||
126 | %files static | |
127 | %defattr(644,root,root,755) | |
128 | %{_libdir}/libcharset.a | |
129 | %{_libdir}/libiconv.a | |
02669876 | 130 | |
131 | %files dll | |
132 | %defattr(644,root,root,755) | |
bdbdd5a9 JB |
133 | %{_dlldir}/libcharset-*.dll |
134 | %{_dlldir}/libiconv-*.dll |