]>
Commit | Line | Data |
---|---|---|
bc13ea8e JB |
1 | Summary: A C++ interface for glib library - cross MinGW32 version |
2 | Summary(pl.UTF-8): Interfejs C++ dla biblioteki glib - wersja skrośna MinGW32 | |
03cf31c3 JB |
3 | %define realname glibmm |
4 | Name: crossmingw32-%{realname} | |
15f7ed63 | 5 | Version: 2.48.1 |
46493872 | 6 | Release: 1 |
fa9e202d | 7 | License: LGPL v2+ |
759ce599 | 8 | Group: Development/Libraries |
15f7ed63 JB |
9 | Source0: http://ftp.gnome.org/pub/GNOME/sources/glibmm/2.48/%{realname}-%{version}.tar.xz |
10 | # Source0-md5: f08b2c7f09b984b0df05f0bf4d20ad11 | |
11 | Patch0: glibmm-mingw32.patch | |
1f8cfdf1 | 12 | URL: http://www.gtkmm.org/ |
bc13ea8e | 13 | BuildRequires: autoconf >= 2.59 |
85f6f607 | 14 | BuildRequires: automake >= 1:1.11 |
b6e3aa78 | 15 | BuildRequires: crossmingw32-gcc-c++ >= 1:4.6 |
15f7ed63 JB |
16 | BuildRequires: crossmingw32-glib2 >= 2.48.0 |
17 | BuildRequires: crossmingw32-libsigc++ >= 2.8.0 | |
18 | BuildRequires: crossmingw32-std-threads | |
35bf2c84 | 19 | BuildRequires: libtool >= 2:2.0 |
bc13ea8e | 20 | BuildRequires: m4 |
15f7ed63 | 21 | BuildRequires: mm-common >= 0.9.10 |
fa9e202d | 22 | BuildRequires: pkgconfig >= 1:0.15 |
03a6960c JB |
23 | BuildRequires: tar >= 1:1.22 |
24 | BuildRequires: xz | |
b6e3aa78 | 25 | Requires: crossmingw32-gcc-c++ >= 1:4.6 |
15f7ed63 JB |
26 | Requires: crossmingw32-glib2 >= 2.48.0 |
27 | Requires: crossmingw32-libsigc++ >= 2.8.0 | |
28 | Requires: crossmingw32-std-threads | |
cbc44f5b | 29 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
30 | ||
31 | %define no_install_post_strip 1 | |
32 | ||
33 | %define target i386-mingw32 | |
34 | %define target_platform i386-pc-mingw32 | |
cbc44f5b | 35 | |
36 | %define _sysprefix /usr | |
37 | %define _prefix %{_sysprefix}/%{target} | |
32a5567a | 38 | %define _libdir %{_prefix}/lib |
759ce599 JB |
39 | %define _pkgconfigdir %{_prefix}/lib/pkgconfig |
40 | %define _dlldir /usr/share/wine/windows/system | |
cbc44f5b | 41 | %define __cc %{target}-gcc |
42 | %define __cxx %{target}-g++ | |
de0bc545 | 43 | %define __pkgconfig_provides %{nil} |
be43f551 | 44 | %define __pkgconfig_requires %{nil} |
cbc44f5b | 45 | |
d573ab95 JB |
46 | %ifnarch %{ix86} |
47 | # arch-specific flags (like alpha's -mieee) are not valid for i386 gcc | |
48 | %define optflags -O2 | |
49 | %endif | |
e882ae34 | 50 | # -z options are invalid for mingw linker, most of -f options are Linux-specific |
d573ab95 | 51 | %define filterout_ld -Wl,-z,.* |
e882ae34 JB |
52 | %define filterout_c -f[-a-z0-9=]* |
53 | %define filterout_cxx -f[-a-z0-9=]* | |
d573ab95 | 54 | |
cbc44f5b | 55 | %description |
bc13ea8e | 56 | A C++ interface for glib library - cross MinGW32 version. |
cbc44f5b | 57 | |
f45ed5c9 | 58 | %description -l pl.UTF-8 |
bc13ea8e | 59 | Interfejs C++ dla biblioteki glib - wersja skrośna MinGW32. |
cbc44f5b | 60 | |
759ce599 | 61 | %package static |
bc13ea8e JB |
62 | Summary: Static glibmm library (cross MinGW32 version) |
63 | Summary(pl.UTF-8): Statyczna biblioteka glibmm (wersja skrośna MinGW32) | |
759ce599 JB |
64 | Group: Development/Libraries |
65 | Requires: %{name} = %{version}-%{release} | |
66 | ||
67 | %description static | |
bc13ea8e | 68 | Static glibmm library (cross MinGW32 version). |
759ce599 JB |
69 | |
70 | %description static -l pl.UTF-8 | |
bc13ea8e | 71 | Statyczna biblioteka glibmm (wersja skrośna MinGW32). |
759ce599 JB |
72 | |
73 | %package dll | |
74 | Summary: DLL glibmm library for Windows | |
75 | Summary(pl.UTF-8): Biblioteka DLL glibmm dla Windows | |
76 | Group: Applications/Emulators | |
15f7ed63 JB |
77 | Requires: crossmingw32-glib2-dll >= 2.48.0 |
78 | Requires: crossmingw32-libsigc++-dll >= 2.8.0 | |
759ce599 JB |
79 | Requires: wine |
80 | ||
81 | %description dll | |
82 | DLL glibmm library for Windows. | |
83 | ||
84 | %description dll -l pl.UTF-8 | |
85 | Biblioteka DLL glibmm dla Windows. | |
86 | ||
cbc44f5b | 87 | %prep |
03cf31c3 | 88 | %setup -q -n %{realname}-%{version} |
15f7ed63 | 89 | %patch0 -p1 |
cbc44f5b | 90 | |
91 | %build | |
667b9562 | 92 | export PKG_CONFIG_LIBDIR=%{_prefix}/lib/pkgconfig |
cbc44f5b | 93 | %{__libtoolize} |
6b2b65e2 | 94 | %{__aclocal} -I build |
cbc44f5b | 95 | %{__autoconf} |
96 | %{__automake} | |
b6e3aa78 JB |
97 | # mingw32 requires gnu++11 (instead of c++11) for off[64]_t |
98 | CXXFLAGS="%{rpmcxxflags} -std=gnu++11" | |
cbc44f5b | 99 | %configure \ |
b7ddf918 | 100 | --target=%{target} \ |
cbc44f5b | 101 | --host=%{target} \ |
b7ddf918 | 102 | --disable-fulldocs \ |
103 | --enable-static | |
cbc44f5b | 104 | |
105 | %{__make} | |
106 | ||
107 | %install | |
108 | rm -rf $RPM_BUILD_ROOT | |
109 | ||
110 | %{__make} install \ | |
111 | DESTDIR=$RPM_BUILD_ROOT | |
112 | ||
759ce599 JB |
113 | install -d $RPM_BUILD_ROOT%{_dlldir} |
114 | mv -f $RPM_BUILD_ROOT%{_prefix}/bin/*.dll $RPM_BUILD_ROOT%{_dlldir} | |
115 | ||
116 | %if 0%{!?debug:1} | |
117 | %{target}-strip --strip-unneeded -R.comment -R.note $RPM_BUILD_ROOT%{_dlldir}/*.dll | |
118 | %{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{_libdir}/*.a | |
119 | %endif | |
120 | ||
bc13ea8e | 121 | %{__rm} -r $RPM_BUILD_ROOT%{_datadir}/{doc,devhelp} |
759ce599 | 122 | # use these from native glibmm if needed |
03a6960c | 123 | %{__rm} -r $RPM_BUILD_ROOT%{_libdir}/glibmm-2.4/proc |
759ce599 | 124 | |
cbc44f5b | 125 | %clean |
126 | rm -rf $RPM_BUILD_ROOT | |
127 | ||
128 | %files | |
129 | %defattr(644,root,root,755) | |
e5e7a5f4 JB |
130 | %doc AUTHORS ChangeLog NEWS README |
131 | %{_libdir}/libgiomm-2.4.dll.a | |
759ce599 JB |
132 | %{_libdir}/libglibmm-2.4.dll.a |
133 | %{_libdir}/libglibmm_generate_extra_defs-2.4.dll.a | |
e5e7a5f4 | 134 | %{_libdir}/libgiomm-2.4.la |
759ce599 JB |
135 | %{_libdir}/libglibmm-2.4.la |
136 | %{_libdir}/libglibmm_generate_extra_defs-2.4.la | |
e5e7a5f4 JB |
137 | %dir %{_libdir}/giomm-2.4 |
138 | %{_libdir}/giomm-2.4/include | |
03cf31c3 JB |
139 | %dir %{_libdir}/glibmm-2.4 |
140 | %{_libdir}/glibmm-2.4/include | |
e5e7a5f4 | 141 | %{_includedir}/giomm-2.4 |
03cf31c3 | 142 | %{_includedir}/glibmm-2.4 |
e5e7a5f4 | 143 | %{_pkgconfigdir}/giomm-2.4.pc |
759ce599 JB |
144 | %{_pkgconfigdir}/glibmm-2.4.pc |
145 | ||
146 | %files static | |
147 | %defattr(644,root,root,755) | |
e5e7a5f4 | 148 | %{_libdir}/libgiomm-2.4.a |
759ce599 JB |
149 | %{_libdir}/libglibmm-2.4.a |
150 | %{_libdir}/libglibmm_generate_extra_defs-2.4.a | |
151 | ||
152 | %files dll | |
153 | %defattr(644,root,root,755) | |
e5e7a5f4 | 154 | %{_dlldir}/libgiomm-2.4-*.dll |
759ce599 JB |
155 | %{_dlldir}/libglibmm-2.4-*.dll |
156 | %{_dlldir}/libglibmm_generate_extra_defs-2.4-*.dll |