Blame SPECS/ocaml-csv.spec

5f15f6
%global opt %(test -x %{_bindir}/ocamlopt && echo 1 || echo 0)
5f15f6
%global debug_package %{nil}
5f15f6
5f15f6
Name:           ocaml-csv
5f15f6
Version:        1.2.3
5f15f6
Release:        4%{?dist}
5f15f6
Summary:        OCaml library for reading and writing CSV files
5f15f6
5f15f6
License:        LGPLv2+
5f15f6
URL:            https://forge.ocamlcore.org/projects/csv/
5f15f6
Source0:        https://forge.ocamlcore.org/frs/download.php/978/csv-%{version}.tar.gz
5f15f6
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
5f15f6
ExcludeArch:    sparc64 s390 s390x
5f15f6
5f15f6
BuildRequires:  ocaml >= 4.00.1
5f15f6
BuildRequires:  ocaml-ocamldoc
5f15f6
BuildRequires:  ocaml-findlib-devel >= 1.3.3-3
5f15f6
BuildRequires:  ocaml-extlib-devel >= 1.5.3-2
5f15f6
BuildRequires:  gawk
5f15f6
5f15f6
5f15f6
%description
5f15f6
This OCaml library can read and write CSV files, including all
5f15f6
extensions used by Excel - eg. quotes, newlines, 8 bit characters in
5f15f6
fields, quote-0 etc.
5f15f6
5f15f6
The library comes with a handy command line tool called csvtool for
5f15f6
handling CSV files from shell scripts.
5f15f6
5f15f6
5f15f6
%package        devel
5f15f6
Summary:        Development files for %{name}
5f15f6
Requires:       %{name} = %{version}-%{release}
5f15f6
5f15f6
5f15f6
%description    devel
5f15f6
The %{name}-devel package contains libraries and signature files for
5f15f6
developing applications that use %{name}.
5f15f6
5f15f6
5f15f6
%prep
5f15f6
%setup -q -n csv-%{version}
5f15f6
5f15f6
5f15f6
%build
5f15f6
ocaml setup.ml -configure --prefix %{_prefix} --destdir $RPM_BUILD_ROOT
5f15f6
make
5f15f6
5f15f6
5f15f6
%install
5f15f6
export DESTDIR=$RPM_BUILD_ROOT
5f15f6
export OCAMLFIND_DESTDIR=$RPM_BUILD_ROOT%{_libdir}/ocaml
5f15f6
mkdir -p $OCAMLFIND_DESTDIR
5f15f6
5f15f6
make install
5f15f6
5f15f6
%if %opt
5f15f6
strip csvtool.native
5f15f6
mkdir -p $DESTDIR%{_bindir}
5f15f6
install -m 0755 csvtool.native $DESTDIR%{_bindir}/csvtool
5f15f6
%endif
5f15f6
5f15f6
5f15f6
%check
5f15f6
make test
5f15f6
5f15f6
5f15f6
%files
5f15f6
%doc LICENSE.txt
5f15f6
%{_libdir}/ocaml/csv
5f15f6
%if %opt
5f15f6
%exclude %{_libdir}/ocaml/csv/*.a
5f15f6
%exclude %{_libdir}/ocaml/csv/*.cmxa
5f15f6
%exclude %{_libdir}/ocaml/csv/*.cmx
5f15f6
%endif
5f15f6
%exclude %{_libdir}/ocaml/csv/*.mli
5f15f6
%if %opt
5f15f6
%{_bindir}/csvtool
5f15f6
%endif
5f15f6
5f15f6
5f15f6
%files devel
5f15f6
%doc AUTHORS.txt LICENSE.txt README.txt
5f15f6
%if %opt
5f15f6
%{_libdir}/ocaml/csv/*.a
5f15f6
%{_libdir}/ocaml/csv/*.cmxa
5f15f6
%{_libdir}/ocaml/csv/*.cmx
5f15f6
%endif
5f15f6
%{_libdir}/ocaml/csv/*.mli
5f15f6
5f15f6
5f15f6
%changelog
5f15f6
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2.3-4
5f15f6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
5f15f6
5f15f6
* Tue Nov 27 2012 Richard W.M. Jones <rjones@redhat.com> - 1.2.3-3
5f15f6
- BR >= OCaml 4.00.1 so we can't be built against the wrong OCaml.
5f15f6
5f15f6
* Mon Nov 26 2012 Richard W.M. Jones <rjones@redhat.com> - 1.2.3-2
5f15f6
- New upstream version 1.2.3.
5f15f6
- New upstream location.
5f15f6
- Clean up the spec file.
5f15f6
- Remove patches since they are no longer relevant.
5f15f6
- New setup appears to require ocamldoc.
5f15f6
5f15f6
* Mon Oct 29 2012 Richard W.M. Jones <rjones@redhat.com> - 1.1.7-13
5f15f6
- Rebuild for OCaml 4.00.1.
5f15f6
5f15f6
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.7-12
5f15f6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
5f15f6
5f15f6
* Thu Jun  7 2012 Richard W.M. Jones <rjones@redhat.com> - 1.1.7-11
5f15f6
- Rebuild for OCaml 4.00.0.
5f15f6
5f15f6
* Fri Jan 06 2012 Richard W.M. Jones <rjones@redhat.com> - 1.1.7-10
5f15f6
- Rebuild for OCaml 3.12.1.
5f15f6
5f15f6
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.7-9
5f15f6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
5f15f6
5f15f6
* Wed Jan 05 2011 Richard W.M. Jones <rjones@redhat.com> - 1.1.7-8
5f15f6
- Rebuild for OCaml 3.12 (http://fedoraproject.org/wiki/Features/OCaml3.12).
5f15f6
5f15f6
* Wed Dec 30 2009 Richard W.M. Jones <rjones@redhat.com> - 1.1.7-7
5f15f6
- Rebuild for OCaml 3.11.2.
5f15f6
5f15f6
* Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.7-6
5f15f6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
5f15f6
5f15f6
* Sat May 23 2009 Richard W.M. Jones <rjones@redhat.com> - 1.1.7-5
5f15f6
- Rebuild for OCaml 3.11.1
5f15f6
5f15f6
* Thu Apr 16 2009 S390x secondary arch maintainer <fedora-s390x@lists.fedoraproject.org>
5f15f6
- ExcludeArch sparc64, s390, s390x as we don't have OCaml on those archs
5f15f6
  (added sparc64 per request from the sparc maintainer)
5f15f6
5f15f6
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.7-4
5f15f6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
5f15f6
5f15f6
* Thu Dec  4 2008 Richard W.M. Jones <rjones@redhat.com> - 1.1.7-3
5f15f6
- Rebuild.
5f15f6
5f15f6
* Wed Nov 19 2008 Richard W.M. Jones <rjones@redhat.com> - 1.1.7-2
5f15f6
- Rebuild for OCaml 3.11.0
5f15f6
5f15f6
* Mon Oct 27 2008 Richard W.M. Jones <rjones@redhat.com> - 1.1.7-1
5f15f6
- New upstream version 1.1.7.
5f15f6
5f15f6
* Wed Apr 23 2008 Richard W.M. Jones <rjones@redhat.com> - 1.1.6-8
5f15f6
- Rebuild for OCaml 3.10.2
5f15f6
5f15f6
* Sat Mar  1 2008 Richard W.M. Jones <rjones@redhat.com> - 1.1.6-7
5f15f6
- Rebuild for ppc64.
5f15f6
5f15f6
* Tue Feb 12 2008 Richard W.M. Jones <rjones@redhat.com> - 1.1.6-6
5f15f6
- Force rebuild for OCaml 3.10.1.
5f15f6
5f15f6
* Thu Sep  6 2007 Richard W.M. Jones <rjones@redhat.com> - 1.1.6-5
5f15f6
- Force rebuild because of base OCaml.
5f15f6
5f15f6
* Thu Aug 30 2007 Richard W.M. Jones <rjones@redhat.com> - 1.1.6-4
5f15f6
- Force rebuild because of changed BRs in base OCaml.
5f15f6
5f15f6
* Fri Aug 24 2007 Richard W.M. Jones <rjones@redhat.com> - 1.1.6-3
5f15f6
- License clarified to LGPLv2+ (and fixed/clarified upstream).
5f15f6
- Added ExcludeArch ppc64
5f15f6
5f15f6
* Mon Jun 11 2007 Richard W.M. Jones <rjones@redhat.com> - 1.1.6-2
5f15f6
- Updated to latest packaging guidelines.
5f15f6
5f15f6
* Tue May 29 2007 Richard W.M. Jones <rjones@redhat.com> - 1.1.6-1
5f15f6
- Initial RPM release.