[packages/ocaml-curl] - updated opt patch - install META where dune expects it
baggins
baggins at pld-linux.org
Wed Mar 24 21:53:35 CET 2021
commit 9ed041617ad24ff2bdda905b637b98b35fc538f4
Author: Jan Rękorajski <baggins at pld-linux.org>
Date: Wed Mar 24 21:53:03 2021 +0100
- updated opt patch
- install META where dune expects it
ocaml-curl.spec | 8 +++++---
ocaml_opt.patch | 19 ++++++++-----------
2 files changed, 13 insertions(+), 14 deletions(-)
---
diff --git a/ocaml-curl.spec b/ocaml-curl.spec
index ffa199a..355d4ef 100644
--- a/ocaml-curl.spec
+++ b/ocaml-curl.spec
@@ -45,7 +45,7 @@ developing applications that use %{name}.
%prep
%setup -q -n ocurl-%{version}
-#%patch0 -p1
+%patch0 -p1
%build
%configure
@@ -62,8 +62,7 @@ install -d $OCAMLFIND_DESTDIR $OCAMLFIND_DESTDIR/stublibs
# Install curl.mli
cp -p curl.mli $OCAMLFIND_DESTDIR/curl
-install -d $RPM_BUILD_ROOT%{_libdir}/ocaml/site-lib/curl
-cat > $RPM_BUILD_ROOT%{_libdir}/ocaml/site-lib/curl/META <<EOF
+cat > $RPM_BUILD_ROOT%{_libdir}/ocaml/curl/META <<EOF
requires = ""
version = "%{version}"
directory = "+curl"
@@ -72,6 +71,9 @@ archive(native) = "curl.cmxa"
linkopts = ""
EOF
+install -d $RPM_BUILD_ROOT%{_libdir}/ocaml/site-lib/curl
+ln -sr $RPM_BUILD_ROOT%{_libdir}/ocaml/{curl,site-lib/curl}/META
+
# Make clean in the examples dir so our docs don't contain binaries.
%{__make} -C examples clean
diff --git a/ocaml_opt.patch b/ocaml_opt.patch
index 26c071a..1c4c675 100644
--- a/ocaml_opt.patch
+++ b/ocaml_opt.patch
@@ -1,30 +1,27 @@
--- ocurl-0.7.1/Makefile.in~ 2014-05-12 22:10:26.000000000 +0200
+++ ocurl-0.7.1/Makefile.in 2015-07-25 14:46:23.107163100 +0200
-@@ -32,10 +32,13 @@
+@@ -32,7 +32,10 @@
endif
endif
--INSTALL_TARGETS = curl.a curl.cmi curl.mli $(TARGETS)
+-INSTALL_TARGETS = curl$(EXT_LIB) curl.cmi curl.mli $(TARGETS)
+INSTALL_TARGETS = curl.cmi curl.mli $(TARGETS)
- ifneq (@OCAML_PKG_lwt@,no)
- INSTALL_TARGETS += curl_lwt.cmi curl_lwt.mli curl_lwt.o
- endif
+ifeq (@OCAMLBEST@,opt)
+INSTALL_TARGETS += curl.a
+endif
-
- all:
- @$(MAKE) depend
+ ifeq (@OCAML_HAS_BIN_ANNOT@,yes)
+ INSTALL_TARGETS += curl.cmt curl.cmti
+ endif
@@ -97,10 +97,10 @@
mkdir -p $(INSTALLDIR)
$(INSTALLDATA) curl.cma $(INSTALLDIR)
ifeq (@OCAMLBEST@,opt)
- $(INSTALLDATA) curl.cmxa $(INSTALLDIR)
-+ $(INSTALLDATA) curl.cmxa curl.a $(INSTALLDIR)
++ $(INSTALLDATA) curl.cmxa curl$(EXT_LIB) $(INSTALLDIR)
endif
$(INSTALLDATA) curl.mli curl.cmi $(INSTALLDIR)
-- $(INSTALLDATA) curl.a libcurl-helper.a $(INSTALLDIR)
-+ $(INSTALLDATA) libcurl-helper.a $(INSTALLDIR)
+- $(INSTALLDATA) curl$(EXT_LIB) libcurl-helper$(EXT_LIB) $(INSTALLDIR)
++ $(INSTALLDATA) libcurl-helper$(EXT_LIB) $(INSTALLDIR)
endif
uninstall:
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/ocaml-curl.git/commitdiff/9ed041617ad24ff2bdda905b637b98b35fc538f4
More information about the pld-cvs-commit
mailing list