Bump all spec releases for mass rebuild to mingw32-gcc 4.4
[fedora-mingw.git] / ocaml-libvirt / mingw32-ocaml-libvirt.spec
1 %define __strip %{_mingw32_strip}
2 %define __objdump %{_mingw32_objdump}
3 %define _use_internal_dependency_generator 0
4 %define __find_requires %{_mingw32_findrequires}
5 %define __find_provides %{_mingw32_findprovides}
6
7 Name:           mingw32-ocaml-libvirt
8 Version:        0.4.4.2
9 Release:        4%{?dist}
10 Summary:        MinGW Windows port of OCaml binding for libvirt
11
12 License:        LGPLv2+
13 Group:          Development/Libraries
14
15 URL:            http://libvirt.org/ocaml/
16 Source0:        http://libvirt.org/sources/ocaml/ocaml-libvirt-%{version}.tar.gz
17
18 Patch1000:      mingw32-ocaml-libvirt-0.4.4.2-build.patch
19
20 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
21 BuildArch:      noarch
22
23 BuildRequires:  mingw32-filesystem >= 35
24 BuildRequires:  mingw32-gcc
25 BuildRequires:  mingw32-binutils
26 BuildRequires:  mingw32-ocaml >= 3.11.0-0.15.beta1
27 BuildRequires:  mingw32-ocaml-findlib
28 BuildRequires:  mingw32-libvirt >= 0.2.1
29 BuildRequires:  perl
30 BuildRequires:  gawk
31 BuildRequires:  autoconf, automake, libtool
32
33 Requires:       mingw32-libvirt
34
35
36 %description
37 OCaml binding for libvirt.
38
39
40 %prep
41 %setup -q -n ocaml-libvirt-%{version}
42
43 %patch1000 -p1
44
45 autoreconf
46
47
48 %build
49 # Avoid some tail-recursion problem in flexdll.
50 ulimit -s unlimited
51
52 export OCAMLFIND_CONF=%{_sysconfdir}/%{_mingw32_target}-ocamlfind.conf
53 %{_mingw32_configure}
54 make OCAMLMKLIB=%{_mingw32_target}-ocamlmklib opt
55
56
57 %install
58 rm -rf $RPM_BUILD_ROOT
59
60 export OCAMLFIND_CONF=/etc/i686-pc-mingw32-ocamlfind.conf
61 export DESTDIR=$RPM_BUILD_ROOT
62 export OCAMLFIND_DESTDIR=$RPM_BUILD_ROOT%{_libdir}/%{_mingw32_target}-ocaml
63
64 mkdir -p $OCAMLFIND_DESTDIR $OCAMLFIND_DESTDIR/stublibs
65
66 #make install-opt
67 pushd libvirt
68 ocamlfind install -ldconf ignore libvirt ../META *.a *.cmx *.cmxa *.cmi *.mli
69 popd
70 pushd mlvirsh
71 make install-opt
72 popd
73
74
75 %clean
76 rm -rf $RPM_BUILD_ROOT
77
78
79 %files
80 %defattr(-,root,root)
81 %{_mingw32_bindir}/mlvirsh
82 %{_libdir}/%{_mingw32_target}-ocaml/libvirt/
83
84
85 %changelog
86 * Fri Feb 20 2009 Richard W.M. Jones <rjones@redhat.com> - 0.4.4.2-4
87 - Rebuild for mingw32-gcc 4.4
88
89 * Sun Nov 23 2008 Richard W.M. Jones <rjones@redhat.com> - 0.4.4.2-3
90 - Rebuild against latest OCaml cross-compiler.
91
92 * Mon Nov 17 2008 Richard W.M. Jones <rjones@redhat.com> - 0.4.4.2-2
93 - Requires mingw32-libvirt package.
94
95 * Sun Nov 16 2008 Richard W.M. Jones <rjones@redhat.com> - 0.4.4.2-1
96 - Initial RPM release.