From 0a4dfb6fe57db446503db2c000f53b89da2c17a6 Mon Sep 17 00:00:00 2001 From: Michel Alexandre Salim Date: Fri, 14 Feb 2014 10:16:38 +0700 Subject: yojson: review done --- ocaml/ocaml-yojson.spec | 107 ------------------------------------------------ 1 file changed, 107 deletions(-) delete mode 100644 ocaml/ocaml-yojson.spec diff --git a/ocaml/ocaml-yojson.spec b/ocaml/ocaml-yojson.spec deleted file mode 100644 index fa09af1..0000000 --- a/ocaml/ocaml-yojson.spec +++ /dev/null @@ -1,107 +0,0 @@ -%global opt %(test -x %{_bindir}/ocamlopt && echo 1 || echo 0) -%if !%{opt} -%global debug_package %{nil} -%endif - -Name: ocaml-yojson -Version: 1.1.8 -Release: 2%{?dist} -Summary: An optimized parsing and printing library for the JSON format - -License: BSD -URL: http://mjambon.com/yojson.html -Source0: http://mjambon.com/releases/yojson/yojson-%{version}.tar.gz -# Example JSON files for testing -Source1: test-valid.json -Source2: test-invalid.json - -ExclusiveArch: %{ocaml_arches} - -BuildRequires: ocaml >= 3.10.0 -BuildRequires: ocaml-findlib -BuildRequires: ocaml-ocamldoc -BuildRequires: ocaml-biniou-devel -BuildRequires: ocaml-cppo -BuildRequires: ocaml-easy-format-devel - -%global libname %(sed -e 's/^ocaml-//' <<< %{name}) - -%description -Yojson is an optimized parsing and printing library for the JSON -format. It addresses a few shortcomings of json-wheel including 2x -speedup, polymorphic variants and optional syntax for tuples and -variants. - -ydump is a pretty-printing command-line program provided with the -yojson package. - -The program atdgen can be used to derive OCaml-JSON serializers and -deserializers from type definitions. - - -%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 -%setup -q -n %{libname}-%{version} -#patch0 -p1 -b .destdir - - -%build -# not SMP-safe -make META all -%if %opt -make opt -%endif - - -%install -# These rules work if the library uses 'ocamlfind install' to install itself. -export PREFIX=$RPM_BUILD_ROOT%{_prefix} -export OCAMLFIND_DESTDIR=$RPM_BUILD_ROOT%{_libdir}/ocaml -mkdir -p $RPM_BUILD_ROOT%{_bindir} -mkdir -p $OCAMLFIND_DESTDIR -make install - - -%check -# Against valid JSON -$RPM_BUILD_ROOT%{_bindir}/ydump %{SOURCE1} >/dev/null 2>valid-err.log -[ -z "$(cat valid-err.log)" ] - -# Against invalid JSON -[ ! $($RPM_BUILD_ROOT%{_bindir}/ydump %{SOURCE2} 2>/dev/null) ] - - -%files -%doc LICENSE -%{_libdir}/ocaml/%{libname}/ -%if %opt -%{_bindir}/ydump -%exclude %{_libdir}/ocaml/*/*.cmx -%exclude %{_libdir}/ocaml/*/*.o -%endif -%exclude %{_libdir}/ocaml/*/*.mli - - -%files devel -%doc LICENSE README.md Changes examples -%if %opt -%{_libdir}/ocaml/*/*.cmx -%{_libdir}/ocaml/*/*.o -%endif -%{_libdir}/ocaml/*/*.mli - - -%changelog -* Sat Feb 8 2014 Michel Salim - 1.1.8-2 -- Incorporate review feedback - -* Mon Jan 20 2014 Michel Salim - 1.1.8-1 -- Initial package -- cgit