ccac1945fca22ce2395cfa6c59bd766091a0fa57
[packages/crossmingw32-gettext.git] / crossmingw32-gettext.spec
1 #
2 # Conditional build:
3 %bcond_without  asprintf        # without libasprintf (in C++)
4 #
5 %define         realname                gettext
6 Summary:        gettext libraries - cross mingw32 version
7 Summary(pl):    Biblioteki gettext - wersja skro¶na dla mingw32
8 Name:           crossmingw32-%{realname}
9 Version:        0.14
10 Release:        1
11 License:        LGPL
12 Group:          Libraries
13 Source0:        ftp://ftp.gnu.org/pub/gnu/gettext/%{realname}-%{version}.tar.gz
14 # Source0-md5:  e715be150bbe32439ae68fab32df0299
15 Patch0:         %{realname}-info.patch
16 Patch1:         %{realname}-killkillkill.patch
17 Patch2:         %{name}.patch
18 URL:            http://www.gnu.org/software/gettext/
19 BuildRequires:  autoconf >= 2.57
20 BuildRequires:  automake >= 1.7.5
21 BuildRequires:  crossmingw32-gcc
22 %{?with_asprintf:BuildRequires: crossmingw32-gcc-c++}
23 BuildRequires:  crossmingw32-libiconv
24 BuildRequires:  libtool
25 Requires:       crossmingw32-libiconv
26 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
27
28 %define         no_install_post_strip   1
29
30 %define         target                  i386-mingw32
31 %define         target_platform         i386-pc-mingw32
32 %define         _sysprefix              /usr
33 %define         _prefix                 %{_sysprefix}/%{target}
34
35 %define         __cc                    %{target}-gcc
36 %define         __cxx                   %{target}-g++
37
38 %description
39 gettext libraries - cross mingw32 version.
40
41 %description -l pl
42 Biblioteki gettext - wersja skro¶na dla mingw32.
43
44 %prep
45 %setup -q -n %{realname}-%{version}
46 %patch0 -p1
47 %patch1 -p1
48 %patch2 -p1
49
50 %build
51 # it's m4_included somewhere
52 install %{_aclocaldir}/libtool.m4 config/m4/libtool.m4
53 %{__libtoolize}
54 %{__aclocal}
55 %{__autoconf}
56 %{__automake}
57 cd autoconf-lib-link
58 %{__aclocal} -I m4 -I ../config/m4
59 %{__autoconf}
60 %{__automake}
61 cd ../gettext-runtime
62 %{__aclocal} -I m4 -I ../autoconf-lib-link/m4 -I ../gettext-tools/m4 -I ../config/m4
63 %{__autoconf}
64 %{__automake}
65 cd ..
66
67 %configure \
68         AR="%{target}-ar" \
69         RANLIB="%{target}-ranlib" \
70         --target=%{target} \
71         --host=%{target_platform} \
72         --disable-csharp \
73         --disable-static
74 %{__make}
75
76 %install
77 rm -rf $RPM_BUILD_ROOT
78
79 %{__make} install \
80         DESTDIR=$RPM_BUILD_ROOT
81
82 %if 0%{!?debug:1}
83 %{target}-strip --strip-unneeded -R.comment -R.note $RPM_BUILD_ROOT%{_bindir}/*.dll
84 %{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{_libdir}/*.a
85 %endif
86
87 %clean
88 rm -rf $RPM_BUILD_ROOT
89
90 %files
91 %defattr(644,root,root,755)
92 %{_bindir}/libintl-3.dll
93 %if %{with asprintf}
94 %{_libdir}/libasprintf.a
95 %{_libdir}/libasprintf.la
96 %endif
97 %{_libdir}/libintl.dll.a
98 %{_libdir}/libintl.la
99 %{_includedir}/*.h
This page took 0.037075 seconds and 2 git commands to generate.