[ocaml-json-wheel] Rebuild for OCaml 4.01.0.

Richard W.M. Jones rjones at fedoraproject.org
Sat Sep 14 17:50:44 UTC 2013


commit 0572630881d1293bf0904c15da5067b2584d4e3d
Author: Richard W.M. Jones <rjones at redhat.com>
Date:   Sat Sep 14 18:43:34 2013 +0100

    Rebuild for OCaml 4.01.0.
    
    - Enable debuginfo.
    - Modernize spec file.

 ocaml-json-wheel.spec |   45 +++++++++++++++++++--------------------------
 1 files changed, 19 insertions(+), 26 deletions(-)
---
diff --git a/ocaml-json-wheel.spec b/ocaml-json-wheel.spec
index 99f9d96..3929a38 100644
--- a/ocaml-json-wheel.spec
+++ b/ocaml-json-wheel.spec
@@ -1,16 +1,14 @@
-%define opt %(test -x %{_bindir}/ocamlopt && echo 1 || echo 0)
-%define debug_package %{nil}
+%global opt %(test -x %{_bindir}/ocamlopt && echo 1 || echo 0)
 
 Name:           ocaml-json-wheel
 Version:        1.0.6
-Release:        12%{?dist}
+Release:        13%{?dist}
 Summary:        OCaml library for parsing JSON
-
-Group:          Development/Libraries
 License:        BSD
+
 URL:            http://martin.jambon.free.fr/json-wheel.html
 Source0:        http://martin.jambon.free.fr/json-wheel-%{version}.tar.bz2
-BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+
 ExcludeArch:    sparc64 s390 s390x
 
 BuildRequires:  ocaml >= 3.10.0
@@ -20,10 +18,6 @@ BuildRequires:  ocaml-ocamlnet-devel
 BuildRequires:  ocaml-pcre-devel
 BuildRequires:  pcre-devel
 
-%define _use_internal_dependency_generator 0
-%define __find_requires /usr/lib/rpm/ocaml-find-requires.sh
-%define __find_provides /usr/lib/rpm/ocaml-find-provides.sh
-
 
 %description
 JSON library for OCaml following RFC 4627.
@@ -34,7 +28,6 @@ syntax extension to the language which makes using JSON much easier.
 
 %package        devel
 Summary:        Development files for %{name}
-Group:          Development/Libraries
 Requires:       %{name} = %{version}-%{release}
 
 
@@ -48,13 +41,15 @@ developing applications that use %{name}.
 
 
 %build
-make
-
-strip jsoncat
+# Parallel builds don't work.
+unset MAKEFLAGS
+make \
+%if %opt
+  OCAMLOPT="ocamlopt -g"
+%endif
 
 
 %install
-rm -rf $RPM_BUILD_ROOT
 export DESTDIR=$RPM_BUILD_ROOT
 export OCAMLFIND_DESTDIR=$RPM_BUILD_ROOT%{_libdir}/ocaml
 mkdir -p $OCAMLFIND_DESTDIR $OCAMLFIND_DESTDIR/stublibs
@@ -62,43 +57,41 @@ mkdir -p $RPM_BUILD_ROOT%{_bindir}
 
 make BINDIR=$RPM_BUILD_ROOT%{_bindir} install
 
-# Remove *.cmo and *.o files.  These aren't needed for
-# anything because they are included in the *.cma/*.a.
-rm $RPM_BUILD_ROOT%{_libdir}/ocaml/json-wheel/*.cmo
-rm $RPM_BUILD_ROOT%{_libdir}/ocaml/json-wheel/*.o
-
-
-%clean
-rm -rf $RPM_BUILD_ROOT
-
 
 %files
-%defattr(-,root,root,-)
 %doc LICENSE
 %{_libdir}/ocaml/json-wheel
 %if %opt
 %exclude %{_libdir}/ocaml/json-wheel/*.a
+%exclude %{_libdir}/ocaml/json-wheel/*.o
 %exclude %{_libdir}/ocaml/json-wheel/*.cmxa
 %exclude %{_libdir}/ocaml/json-wheel/*.cmx
 %endif
+%exclude %{_libdir}/ocaml/json-wheel/*.cmo
 %exclude %{_libdir}/ocaml/json-wheel/*.mli
 %exclude %{_libdir}/ocaml/json-wheel/*.ml
 %{_bindir}/jsoncat
 
 
 %files devel
-%defattr(-,root,root,-)
 %doc LICENSE Changes README html
 %if %opt
 %{_libdir}/ocaml/json-wheel/*.a
+%{_libdir}/ocaml/json-wheel/*.o
 %{_libdir}/ocaml/json-wheel/*.cmxa
 %{_libdir}/ocaml/json-wheel/*.cmx
 %endif
+%{_libdir}/ocaml/json-wheel/*.cmo
 %{_libdir}/ocaml/json-wheel/*.mli
 %{_libdir}/ocaml/json-wheel/*.ml
 
 
 %changelog
+* Sat Sep 14 2013 Richard W.M. Jones <rjones at redhat.com> - 1.0.6-13
+- Rebuild for OCaml 4.01.0.
+- Enable debuginfo.
+- Modernize spec file.
+
 * Sat Aug 03 2013 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1.0.6-12
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
 


More information about the scm-commits mailing list