[Pkg-ocaml-maint-commits] [SCM] ocaml-sha packaging branch, master, updated. debian/1.4-5-18-gc5d410d
Eric Cooper
ecc at cmu.edu
Wed Oct 7 15:00:58 UTC 2009
The following commit has been merged in the master branch:
commit 88ce3db4972f1f4a56dda92d91578d4a5a6d25ab
Author: Eric Cooper <ecc at cmu.edu>
Date: Wed Oct 7 10:52:45 2009 -0400
use DESTDIR with ocamlfind for install target
use debian/META.in as template for META file
diff --git a/Makefile b/Makefile
index 069d9df..638a1e2 100644
--- a/Makefile
+++ b/Makefile
@@ -1,6 +1,7 @@
OCAMLC = ocamlc
OCAMLOPT = ocamlopt
OCAMLMKLIB = ocamlmklib
+OCAMLFIND = ocamlfind
override CFLAGS += -O3 -funroll-loops -fPIC -DPIC
all: byte-code-library native-code-library
@@ -30,5 +31,8 @@ sha.cmxa: $(cmi_files) $(native_files)
%_lib.c: %.c
cp $< $@
+install:
+ $(OCAMLFIND) install sha META *.mli *.cmi *.cmx *.cma *.cmxa *.a *.so
+
clean:
rm -f *.o *.a *.cm* dll*.so sha*_lib.c
diff --git a/debian/META.in b/debian/META.in
new file mode 100644
index 0000000..0a0d0fe
--- /dev/null
+++ b/debian/META.in
@@ -0,0 +1,5 @@
+name="sha"
+description="SHA cryptographic hash functions"
+version="@VERSION@"
+archive(byte)="sha.cma"
+archive(native)="sha.cmxa"
diff --git a/debian/libsha-ocaml-dev.examples b/debian/libsha-ocaml-dev.examples
new file mode 100644
index 0000000..03f20ce
--- /dev/null
+++ b/debian/libsha-ocaml-dev.examples
@@ -0,0 +1 @@
+shasum.ml
diff --git a/debian/libsha-ocaml-dev.install.in b/debian/libsha-ocaml-dev.install.in
index 6d9cad7..fdce417 100644
--- a/debian/libsha-ocaml-dev.install.in
+++ b/debian/libsha-ocaml-dev.install.in
@@ -1 +1,4 @@
-{META,sha{1,256,512}.{mli,cmi},*.cm*a,*.a} @OCamlStdlibDir@/sha
+ at OCamlStdlibDir@/sha/META
+ at OCamlStdlibDir@/sha/*.a
+ at OCamlStdlibDir@/sha/*.cm*
+ at OCamlStdlibDir@/sha/*.ml*
diff --git a/debian/libsha-ocaml.install.in b/debian/libsha-ocaml.install.in
index 486832c..befe37f 100644
--- a/debian/libsha-ocaml.install.in
+++ b/debian/libsha-ocaml.install.in
@@ -1 +1 @@
-dllsha.so @OCamlDllDir@
+ at OCamlStdlibDir@/sha/dllsha.so @OCamlDllDir@
diff --git a/debian/rules b/debian/rules
index a66fc73..15b6197 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,25 +1,20 @@
#!/usr/bin/make -f
include /usr/share/cdbs/1/rules/debhelper.mk
-include /usr/share/cdbs/1/class/makefile.mk
include /usr/share/cdbs/1/rules/ocaml.mk
+include /usr/share/cdbs/1/class/makefile.mk
-OCAML_OCAMLDOC_PACKAGES = $(OCAML_LIBDEV_PACKAGES)
+DESTDIR = $(CURDIR)/debian/tmp/$(OCAML_STDLIB_DIR)
+DEB_MAKE_INSTALL_TARGET = install OCAMLFIND_DESTDIR=$(DESTDIR) OCAMLFIND_LDCONF=ignore
DEB_MAKE_BUILD_TARGET = byte-code-library
ifeq ($(OCAML_HAVE_OCAMLOPT),yes)
DEB_MAKE_BUILD_TARGET += native-code-library
endif
-DEB_INSTALL_EXAMPLES_libsha-ocaml-dev := shasum.ml
-
-META:
- echo 'name="sha"' > META
- echo 'description="SHA cryptographic hash functions"' >> META
- echo 'version="'$(DEB_NOEPOCH_VERSION)'"' >> META
- echo 'archive(byte)="sha.cma"' >> META
- echo 'archive(native)="sha.cmxa"' >> META
-build/libsha-ocaml-dev:: META
+build/libsha-ocaml::
+ cp debian/META .
+ mkdir -p $(DESTDIR)
clean::
rm -f META
--
ocaml-sha packaging
More information about the Pkg-ocaml-maint-commits
mailing list