From 89883c6a7f04976ab1c6078ae6ac5f1a9401972b Mon Sep 17 00:00:00 2001 From: Jerry James Date: Tue, 29 Nov 2016 08:09:48 -0700 Subject: [PATCH] Initial import. --- .gitignore | 1 + ocaml-ocplib-simplex.spec | 83 +++++++++++++++++++++++++++++++++++++++ sources | 1 + 3 files changed, 85 insertions(+) create mode 100644 ocaml-ocplib-simplex.spec diff --git a/.gitignore b/.gitignore index e69de29..df76606 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/ocplib-simplex-0.3.tar.gz diff --git a/ocaml-ocplib-simplex.spec b/ocaml-ocplib-simplex.spec new file mode 100644 index 0000000..7a9cfe6 --- /dev/null +++ b/ocaml-ocplib-simplex.spec @@ -0,0 +1,83 @@ +%global opt %(test -x %{_bindir}/ocamlopt && echo 1 || echo 0) +%if !%{opt} +%global debug_package %{nil} +%endif + +%global pkgname ocplib-simplex + +Name: ocaml-%{pkgname} +Version: 0.3 +Release: 2%{?dist} +Summary: Simplex algorithm for solving systems of linear inequalities + +# The same exception to clause 6 as provided by ocaml applies to this package. +License: LGPLv2 with exceptions +URL: https://github.com/OCamlPro-Iguernlala/ocplib-simplex +Source0: https://github.com/OCamlPro-Iguernlala/%{pkgname}/archive/%{version}/%{pkgname}-%{version}.tar.gz + +BuildRequires: autoconf +BuildRequires: ocaml +BuildRequires: ocaml-findlib + +%description +This package contains a library implementing a simplex algorithm, in a +functional style, for solving systems of linear inequalities and +optimizing linear objective functions. + +%package devel +Summary: Development files for %{name} +Requires: %{name}%{?_isa} = %{version}-%{release} + +%description devel +The %{name}-devel package contains libraries and signature +files for developing applications that use %{name}. + +%prep +%autosetup -n %{pkgname}-%{version} +autoconf + +%build +%configure +%if %opt +make %{?_smp_mflags} opt +%else +make %{?_smp_mflags} byte +%endif + +%install +export DESTDIR=%{buildroot} +export OCAMLFIND_DESTDIR=%{buildroot}%{_libdir}/ocaml +mkdir -p $OCAMLFIND_DESTDIR +make install + +%check +make local-tests + +%files +%doc README.md +%license LICENSE +%{_libdir}/ocaml/%{pkgname}/ +%if %opt +%exclude %{_libdir}/ocaml/*/*.a +%exclude %{_libdir}/ocaml/*/*.cmxa +%exclude %{_libdir}/ocaml/*/*.cmx +%endif +%exclude %{_libdir}/ocaml/*/*.mli + +%files devel +%doc extra/simplex_invariants.txt +%if %opt +%{_libdir}/ocaml/*/*.a +%{_libdir}/ocaml/*/*.cmxa +%{_libdir}/ocaml/*/*.cmx +%endif +%{_libdir}/ocaml/*/*.mli + +%changelog +* Mon Nov 28 2016 Jerry James - 0.3-2 +- Use the _isa macro in the -devel dependency on the main package +- Let the install step create META implicitly +- Use a more verbose Source0 URL + +* Mon Nov 28 2016 Jerry James - 0.3-1 +- Initial RPM diff --git a/sources b/sources index e69de29..612e3c1 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +ef6d61360bc1ed6c6f273dd723c71016 ocplib-simplex-0.3.tar.gz