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}
7 Name: mingw32-ocaml-csv
10 Summary: MinGW Windows OCaml library for reading and writing CSV files
13 Group: Development/Libraries
15 URL: http://merjis.com/developers/csv
16 Source0: http://merjis.com/_file/ocaml-csv-%{version}.tar.gz
18 # Patches from native Fedora package:
19 Patch0: csv-extlib.patch
20 Patch1: csv-install.patch
22 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
25 BuildRequires: mingw32-filesystem >= 35
26 BuildRequires: mingw32-gcc
27 BuildRequires: mingw32-binutils
28 BuildRequires: mingw32-ocaml
29 BuildRequires: mingw32-ocaml-extlib
33 This OCaml library can read and write CSV files, including all
34 extensions used by Excel - eg. quotes, newlines, 8 bit characters in
37 The library comes with a handy command line tool called csvtool for
38 handling CSV files from shell scripts.
42 %setup -q -n ocaml-csv-%{version}
49 %{_mingw32_target}-ocamlopt -I +extlib extLib.cmxa -c csv.mli
50 %{_mingw32_target}-ocamlopt -I +extlib extLib.cmxa -c csv.ml
51 %{_mingw32_target}-ocamlopt -a -o csv.cmxa csv.cmx
52 %{_mingw32_target}-ocamlopt -I +extlib extLib.cmxa csv.cmxa csvtool.ml \
57 rm -rf $RPM_BUILD_ROOT
59 mkdir -p $RPM_BUILD_ROOT%{_libdir}/%{_mingw32_target}-ocaml/csv
60 mkdir -p $RPM_BUILD_ROOT%{_mingw32_bindir}
62 install csv.cmxa *.a *.mli *.cmi *.cmx \
63 $RPM_BUILD_ROOT%{_libdir}/%{_mingw32_target}-ocaml/csv
64 install META $RPM_BUILD_ROOT%{_libdir}/%{_mingw32_target}-ocaml/csv
66 install csvtool.exe $RPM_BUILD_ROOT%{_mingw32_bindir}
70 rm -rf $RPM_BUILD_ROOT
75 %{_mingw32_bindir}/csvtool.exe
76 %{_libdir}/%{_mingw32_target}-ocaml/csv
80 * Sat Nov 15 2008 Richard W.M. Jones <rjones@redhat.com> - 1.1.7-1
81 - Initial RPM release.