]> git.pld-linux.org Git - packages/crossmingw32-gettext.git/blame - crossmingw32-gettext.spec
- added bootstrap mode
[packages/crossmingw32-gettext.git] / crossmingw32-gettext.spec
CommitLineData
5afd9185
ŁK
1#
2%bcond_with bootstrap # use system GLib
3#
e5e5fbcf 4Summary: gettext libraries - cross mingw32 version
615485e8 5Summary(pl.UTF-8): Biblioteki gettext - wersja skrośna dla mingw32
fb17fcec
JB
6%define realname gettext
7Name: crossmingw32-%{realname}
8Version: 0.17
e86b7230 9Release: 1
fb17fcec 10License: LGPL v2+
c9e435aa 11Group: Development/Libraries
ab7c136d 12Source0: http://ftp.gnu.org/gnu/gettext/%{realname}-%{version}.tar.gz
fb17fcec
JB
13# Source0-md5: 58a2bc6d39c0ba57823034d55d65d606
14Patch0: %{realname}-info.patch
5afd9185
ŁK
15Patch1: %{realname}-libintl_by_gcj.patch
16Patch2: %{realname}-removed_macros.patch
17Patch3: %{name}-kill_tools.patch
e86b7230 18URL: http://www.gnu.org/software/gettext/
024b6753
JB
19BuildRequires: autoconf >= 2.60
20BuildRequires: automake >= 1:1.10
e5e5fbcf 21BuildRequires: crossmingw32-gcc
db148317 22BuildRequires: crossmingw32-gcc-c++
fb17fcec 23# just to shorten build (libgettextlib is not packaged anyway)
5afd9185 24%{!?with_bootstrap:BuildRequires: crossmingw32-glib2 >= 2.0}
e5e5fbcf 25BuildRequires: crossmingw32-libiconv
e86b7230 26BuildRequires: libtool
b3175891 27BuildRequires: texinfo
59d0034b
JB
28Requires: crossmingw32-libiconv
29BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
e86b7230 30
31%define no_install_post_strip 1
32
33%define target i386-mingw32
34%define target_platform i386-pc-mingw32
db148317 35
59d0034b
JB
36%define _sysprefix /usr
37%define _prefix %{_sysprefix}/%{target}
80f32cc3 38%define _libdir %{_prefix}/lib
db148317 39%define _pkgconfigdir %{_prefix}/lib/pkgconfig
c9e435aa 40%define _dlldir /usr/share/wine/windows/system
e86b7230 41%define __cc %{target}-gcc
42%define __cxx %{target}-g++
43
44%description
e5e5fbcf
JB
45gettext libraries - cross mingw32 version.
46
8f9ab6bc
JR
47%description -l pl.UTF-8
48Biblioteki gettext - wersja skrośna dla mingw32.
e86b7230 49
c9e435aa
JB
50%package static
51Summary: Static gettext libraries (cross mingw32 version)
52Summary(pl.UTF-8): Statyczne biblioteki gettext (wersja skrośna mingw32)
53Group: Development/Libraries
54Requires: %{name} = %{version}-%{release}
55
56%description static
57Static gettext libraries (cross mingw32 version).
58
59%description static -l pl.UTF-8
60Statyczne biblioteki gettext (wersja skrośna mingw32).
61
62%package dll
63Summary: DLL gettext libraries for Windows
64Summary(pl.UTF-8): Biblioteki DLL gettext dla Windows
65Group: Applications/Emulators
d17eea6e 66Requires: crossmingw32-libiconv-dll
c9e435aa
JB
67Requires: wine
68
69%description dll
70DLL gettext libraries for Windows.
71
72%description dll -l pl.UTF-8
73Biblioteki DLL gettext dla Windows.
74
e86b7230 75%prep
fb17fcec 76%setup -q -n %{realname}-%{version}
3cf55ad9 77%patch0 -p1
6a3f6222 78%patch1 -p1
5afd9185
ŁK
79%patch2 -p1
80%patch3 -p1
e86b7230 81
82%build
e86b7230 83%{__libtoolize}
f9b2d210 84cd autoconf-lib-link
221fdc2c 85%{__aclocal} -I m4 -I ../m4
f9b2d210
JB
86%{__autoconf}
87%{__automake}
88cd ../gettext-runtime
5afd9185 89%{__libtoolize}
4047acdd 90%{__aclocal} -I m4 -I gnulib-m4 -I ../autoconf-lib-link/m4 -I ../m4
6a3f6222 91%{__autoconf}
5afd9185
ŁK
92%{__autoheader}
93%{__automake}
94cd libasprintf
95%{__aclocal} -I ../m4 -I ../../m4
96%{__autoconf}
97%{__autoheader}
98%{__automake}
99cd ../..
100%{__aclocal}
101%{__autoconf}
6a3f6222 102%{__automake}
e86b7230 103
104%configure \
105 --target=%{target} \
9738850f 106 --host=%{target} \
f9b2d210 107 --disable-csharp \
9738850f 108 --enable-static
109
fb17fcec
JB
110%{__make} \
111 SHELL=bash
e86b7230 112
113%install
114rm -rf $RPM_BUILD_ROOT
e86b7230 115
116%{__make} install \
117 DESTDIR=$RPM_BUILD_ROOT
118
c9e435aa
JB
119install -d $RPM_BUILD_ROOT%{_dlldir}
120mv -f $RPM_BUILD_ROOT%{_prefix}/bin/*.dll $RPM_BUILD_ROOT%{_dlldir}
121
59d0034b 122%if 0%{!?debug:1}
c9e435aa 123%{target}-strip --strip-unneeded -R.comment -R.note $RPM_BUILD_ROOT%{_dlldir}/*.dll
59d0034b
JB
124%{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{_libdir}/*.a
125%endif
c9e435aa
JB
126
127rm -f $RPM_BUILD_ROOT%{_libdir}/charset.alias
128rm -rf $RPM_BUILD_ROOT%{_datadir}/{aclocal,doc,gettext,locale,man}
129rm -rf $RPM_BUILD_ROOT%{_infodir}
130
e86b7230 131%clean
132rm -rf $RPM_BUILD_ROOT
133
134%files
e5e5fbcf 135%defattr(644,root,root,755)
0449639a 136%{_libdir}/libintl.dll.a
7063962d 137%{_libdir}/libintl.la
7063962d 138%{_libdir}/libasprintf.dll.a
4c54fa9e 139%{_libdir}/libasprintf.la
c9e435aa
JB
140%{_includedir}/*.h
141
142%files static
143%defattr(644,root,root,755)
144%{_libdir}/libintl.a
145%{_libdir}/libasprintf.a
146
147%files dll
148%defattr(644,root,root,755)
149%{_dlldir}/libintl-8.dll
150%{_dlldir}/libasprintf-0.dll
This page took 0.04842 seconds and 4 git commands to generate.