[Pkg-ocaml-maint-commits] [SCM] ocaml-sha packaging branch, master, updated. debian/1.6-1-13-g1c5ab0c
Eric Cooper
ecc at cmu.edu
Fri Feb 25 20:29:30 UTC 2011
The following commit has been merged in the master branch:
commit 4791225c15e7e754ff9b3ac29b33369044bd73b3
Author: Eric Cooper <ecc at cmu.edu>
Date: Fri Feb 25 13:58:28 2011 -0500
update patches
diff --git a/debian/patches/0001-install-mli-files.patch b/debian/patches/0001-install-mli-files.patch
new file mode 100644
index 0000000..0c221c1
--- /dev/null
+++ b/debian/patches/0001-install-mli-files.patch
@@ -0,0 +1,23 @@
+From: Eric Cooper <ecc at cmu.edu>
+Date: Fri, 25 Feb 2011 12:30:00 -0500
+Subject: install mli files
+
+Signed-off-by: Eric Cooper <ecc at cmu.edu>
+---
+ Makefile | 2 +-
+ 1 files changed, 1 insertions(+), 1 deletions(-)
+
+diff --git a/Makefile b/Makefile
+index 334847d..6f7b45e 100644
+--- a/Makefile
++++ b/Makefile
+@@ -105,7 +105,7 @@ clean:
+ rm -f *.$(OBJ) *.$(A) *.$(SO) *.cmo *.cmi *.cma *.cmx *.cmxa sha.test $(PROGRAMS)
+
+ install: sha1.cma sha1.cmxa sha256.cma sha256.cmxa sha512.cma sha512.cmxa sha.cma sha.cmxa META
+- ocamlfind install sha META *.cmx sha1.cmi sha1.cma sha1.cmxa sha256.cmi sha256.cma sha256.cmxa sha512.cmi sha512.cma sha512.cmxa sha.cma sha.cmxa *.$(A) *.$(SO)
++ ocamlfind install sha META *.mli sha1.cmi sha1.cma sha1.cmxa sha256.cmi sha256.cma sha256.cmxa sha512.cmi sha512.cma sha512.cmxa sha.cma sha.cmxa *.$(A) *.$(SO)
+
+ uninstall:
+ ocamlfind remove sha
+--
diff --git a/debian/patches/0001-update-checksums-of-README-file.patch b/debian/patches/0001-update-checksums-of-README-file.patch
deleted file mode 100644
index 47c94be..0000000
--- a/debian/patches/0001-update-checksums-of-README-file.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From: Eric Cooper <ecc at cmu.edu>
-Date: Fri, 9 Oct 2009 14:55:26 -0400
-Subject: update checksums of README file
-
-
-Signed-off-by: Eric Cooper <ecc at cmu.edu>
----
- sha.test.ml | 6 +++---
- 1 files changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/sha.test.ml b/sha.test.ml
-index 0442c01..2a508a0 100644
---- a/sha.test.ml
-+++ b/sha.test.ml
-@@ -42,15 +42,15 @@ let ex_strings_sha512 = [
-
- let ex_files_sha1 =
- [ ("README",
-- "8da1775cea8540cf22a32765eadcb2239cc4d392") ]
-+ "ebd97ba45cd1668d242d98522dc0004bb70df4a8") ]
-
- let ex_files_sha256 =
- [ ("README",
-- "4eea769a1a5c7be83342923a240d68bc8170f170f4b6265a044261e0f7a88af0") ]
-+ "7f8213da9acc755d57f3650827176dcdf2f101ea486d5fa357e705d728480878") ]
-
- let ex_files_sha512 =
- [ ("README",
-- "ed93656a1581965acf5cb49e56bff52e56ae1e8a96f3ca7b305e2fbeeeea64adf90943611aea97b372243ea300eda6214d5552bcf5176fda161a6590f946262b") ]
-+ "da82cac10002a838aceedc7910b76735ec87b2dce08755680910b8ff287c0f48a1910989f8e3a94f9cb5a391e66d811d190bc3568135514229051c06c6e93f6e") ]
-
- let ex_channels_sha1 =
- [ ("sha.test.ml", "e13052afa4916d56994378f847f157596f9638a2") ]
---
diff --git a/debian/patches/0002-compile-C-files-with-fPIC.patch b/debian/patches/0002-compile-C-files-with-fPIC.patch
new file mode 100644
index 0000000..03c1b53
--- /dev/null
+++ b/debian/patches/0002-compile-C-files-with-fPIC.patch
@@ -0,0 +1,22 @@
+From: Eric Cooper <ecc at cmu.edu>
+Date: Fri, 25 Feb 2011 13:51:15 -0500
+Subject: compile C files with -fPIC
+
+closes: #518038
+
+Signed-off-by: Eric Cooper <ecc at cmu.edu>
+---
+ Makefile | 2 +-
+ 1 files changed, 1 insertions(+), 1 deletions(-)
+
+diff --git a/Makefile b/Makefile
+index 6f7b45e..64819c9 100644
+--- a/Makefile
++++ b/Makefile
+@@ -1,4 +1,4 @@
+-CFLAGS = -Wall -O3 -funroll-loops -I/usr/include
++CFLAGS = -Wall -O3 -funroll-loops -fPIC -DPIC
+ OCAMLC = ocamlc
+ OCAMLOPT = ocamlopt
+ OCAMLMKLIB = ocamlmklib
+--
diff --git a/debian/patches/0002-modify-Makefile.patch b/debian/patches/0002-modify-Makefile.patch
deleted file mode 100644
index 51acb93..0000000
--- a/debian/patches/0002-modify-Makefile.patch
+++ /dev/null
@@ -1,153 +0,0 @@
-From: Eric Cooper <ecc at cmu.edu>
-Date: Fri, 25 Feb 2011 08:56:49 -0500
-Subject: modify Makefile
-
-handle bytecode-only architectures
-
-add separate all-byte and install-byte targets
-
-add targets for bytecode version of tests
-
-include Shacommon module in libraries
-
-install DLLs for additional libraries
-
-use internal $(ccopts) variable so that we still get
-correct settings when CFLAGS is set by cdbs
-
-Signed-off-by: Eric Cooper <ecc at cmu.edu>
----
- Makefile | 61 +++++++++++++++++++++++++++++++++++++++----------------------
- 1 files changed, 39 insertions(+), 22 deletions(-)
-
-diff --git a/Makefile b/Makefile
-index 3224c59..3b0afb5 100644
---- a/Makefile
-+++ b/Makefile
-@@ -1,4 +1,4 @@
--CFLAGS = -Wall -O3 -funroll-loops -I/usr/include
-+ccopts = $(CFLAGS) -Wall -O3 -funroll-loops -fPIC -DPIC
- OCAMLC = ocamlc
- OCAMLOPT = ocamlopt
- OCAMLMKLIB = ocamlmklib
-@@ -6,18 +6,20 @@ OCAMLMKLIB = ocamlmklib
- OCAMLOPTFLAGS =
-
- OCAML_TEST_INC = -I `ocamlfind query oUnit`
--OCAML_TEST_LIB = `ocamlfind query oUnit`/oUnit.cmxa
-+OCAML_TEST_LIB = `ocamlfind query oUnit`/oUnit
-
- PROGRAMS = sha1sum sha256sum sha512sum
-
--allshabytes = $(foreach n, 1 256 512, sha$(n).lib.o sha$(n)_stubs.o sha$(n).cmo)
--allshaopts = $(foreach n, 1 256 512, sha$(n).lib.o sha$(n)_stubs.o sha$(n).cmx)
-+allshabytes = shacommon.cmo $(foreach n, 1 256 512, sha$(n).lib.o sha$(n)_stubs.o sha$(n).cmo)
-+allshaopts = shacommon.cmx $(foreach n, 1 256 512, sha$(n).lib.o sha$(n)_stubs.o sha$(n).cmx)
-
--all: sha1.cmi sha1.cma sha1.cmxa sha256.cma sha256.cmxa sha512.cma sha512.cmxa sha.cma sha.cmxa
-+all: all-byte all-opt
-+all-byte: $(foreach n, 1 256 512, sha$(n).cma) sha.cma
-+all-opt: $(foreach n, 1 256 512, sha$(n).cmxa) sha.cmxa
-
- bins: $(PROGRAMS)
-
--sha1sum: shacommon.cmx sha1.cmxa sha256.cmxa sha512.cmxa shasum.cmx
-+sha1sum: sha.cmxa shasum.cmx
- $(OCAMLOPT) $(OCAMLOPTFLAGS) -o $@ -cclib -L. $+
-
- sha256sum: sha1sum
-@@ -26,43 +28,53 @@ sha256sum: sha1sum
- sha512sum: sha1sum
- cp $< $@
-
--sha.cma: shacommon.cmo $(allshabytes)
-+cmi_files = $(foreach n, 1 256 512, sha$(n).cmi)
-+
-+sha.cma: $(cmi_files) $(allshabytes)
- $(OCAMLMKLIB) -o sha $(allshabytes)
-
--sha.cmxa: shacommon.cmo $(allshaopts)
-+sha.cmxa: $(cmi_files) $(allshaopts)
- $(OCAMLMKLIB) -o sha $(allshaopts)
-
- sha1.cma: shacommon.cmo sha1.cmi sha1.lib.o sha1_stubs.o sha1.cmo
-- $(OCAMLMKLIB) -o sha1 sha1.lib.o sha1_stubs.o sha1.cmo
-+ $(OCAMLMKLIB) -o sha1 shacommon.cmo sha1.lib.o sha1_stubs.o sha1.cmo
-
- sha1.cmxa: shacommon.cmx sha1.cmi sha1.lib.o sha1_stubs.o sha1.cmx
-- $(OCAMLMKLIB) -o sha1 sha1.lib.o sha1_stubs.o sha1.cmx
-+ $(OCAMLMKLIB) -o sha1 shacommon.cmx sha1.lib.o sha1_stubs.o sha1.cmx
-
- sha256.cma: shacommon.cmo sha256.cmi sha256.lib.o sha256_stubs.o sha256.cmo
-- $(OCAMLMKLIB) -o sha256 sha256.lib.o sha256_stubs.o sha256.cmo
-+ $(OCAMLMKLIB) -o sha256 shacommon.cmo sha256.lib.o sha256_stubs.o sha256.cmo
-
- sha256.cmxa: shacommon.cmx sha256.cmi sha256.lib.o sha256_stubs.o sha256.cmx
-- $(OCAMLMKLIB) -o sha256 sha256.lib.o sha256_stubs.o sha256.cmx
-+ $(OCAMLMKLIB) -o sha256 shacommon.cmx sha256.lib.o sha256_stubs.o sha256.cmx
-
- sha512.cma: shacommon.cmo sha512.cmi sha512.lib.o sha512_stubs.o sha512.cmo
-- $(OCAMLMKLIB) -o sha512 sha512.lib.o sha512_stubs.o sha512.cmo
-+ $(OCAMLMKLIB) -o sha512 shacommon.cmo sha512.lib.o sha512_stubs.o sha512.cmo
-
- sha512.cmxa: shacommon.cmx sha512.cmi sha512.lib.o sha512_stubs.o sha512.cmx
-- $(OCAMLMKLIB) -o sha512 sha512.lib.o sha512_stubs.o sha512.cmx
-+ $(OCAMLMKLIB) -o sha512 shacommon.cmx sha512.lib.o sha512_stubs.o sha512.cmx
-
- tests: sha.test
- ./sha.test
-
--sha.test: sha1.cmxa sha256.cmxa sha512.cmxa sha.test.cmx
-+sha.test: sha.cmxa sha.test.cmx
-
- %.test:
-- $(OCAMLOPT) -o $@ $(OCAML_BFLAGS) unix.cmxa $(OCAML_TEST_INC) $(OCAML_TEST_LIB) $+
-+ $(OCAMLOPT) -o $@ -cclib -L. $(OCAML_BFLAGS) unix.cmxa $(OCAML_TEST_INC) $(OCAML_TEST_LIB).cmxa $+
-+
-+bytetests: sha.bytetest
-+ ./sha.bytetest
-+
-+sha.bytetest: sha.cma sha.test.cmo
-+
-+%.bytetest:
-+ $(OCAMLC) -o $@ -cclib -L. $(OCAML_BFLAGS) unix.cma $(OCAML_TEST_INC) $(OCAML_TEST_LIB).cma $+
-
- %.test.cmo: %.test.ml
-- $(OCAMLC) -c -o $@ $(OCAML_BFLAGS) -custom $(OCAML_TEST_INC) $<
-+ $(OCAMLC) -c -o $@ -w x $(OCAML_BFLAGS) $(OCAML_TEST_INC) $<
-
- %.test.cmx: %.test.ml
-- $(OCAMLOPT) -c -o $@ $(OCAML_BFLAGS) $(OCAML_TEST_INC) $<
-+ $(OCAMLOPT) -c -o $@ -w x $(OCAML_BFLAGS) $(OCAML_TEST_INC) $<
-
- %.cmo: %.ml
- $(OCAMLC) -c -o $@ $<
-@@ -74,7 +86,7 @@ sha.test: sha1.cmxa sha256.cmxa sha512.cmxa sha.test.cmx
- $(OCAMLOPT) $(OCAMLOPTFLAGS) -c -o $@ $<
-
- %.o: %.c
-- $(OCAMLC) -ccopt "$(CFLAGS)" -c -o $@ $<
-+ $(OCAMLC) -ccopt "$(ccopts)" -c -o $@ $<
-
- %.lib.o: %.o
- mv $< $@
-@@ -85,10 +97,15 @@ doc:
- ocamldoc -html -d html *.mli
-
- clean:
-- rm -f *.o *.a *.cmo *.cmi *.cma *.cmx *.cmxa sha.test $(PROGRAMS)
-+ rm -f *.o *.a *.so *.cmo *.cmi *.cma *.cmx *.cmxa sha.test sha.bytetest $(PROGRAMS)
-+
-+interfaces = $(cmi_files) $(cmi_files:.cmi=.mli)
-+
-+install: all
-+ ocamlfind install sha META $(interfaces) *.cma *.cmxa *.a *.so
-
--install: sha1.cma sha1.cmxa sha256.cma sha256.cmxa sha512.cma sha512.cmxa sha.cma sha.cmxa META
-- ocamlfind install sha META *.cmx sha1.cmi sha1.cma sha1.cmxa sha256.cmi sha256.cma sha256.cmxa sha512.cmi sha512.cma sha512.cmxa sha.cma sha.cmxa *.a *.so
-+install-byte: all-byte
-+ ocamlfind install sha META $(interfaces) *.cma *.a *.so
-
- uninstall:
- ocamlfind remove sha
---
diff --git a/debian/patches/0003-use-internal-ccopts-variable.patch b/debian/patches/0003-use-internal-ccopts-variable.patch
new file mode 100644
index 0000000..950b956
--- /dev/null
+++ b/debian/patches/0003-use-internal-ccopts-variable.patch
@@ -0,0 +1,32 @@
+From: Eric Cooper <ecc at cmu.edu>
+Date: Fri, 25 Feb 2011 11:43:56 -0500
+Subject: use internal ccopts variable
+
+use $(ccopts) instead of $(CFLAGS) so that we still get
+correct settings when CFLAGS is set by the build system
+
+Signed-off-by: Eric Cooper <ecc at cmu.edu>
+---
+ Makefile | 4 ++--
+ 1 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/Makefile b/Makefile
+index 64819c9..82bd445 100644
+--- a/Makefile
++++ b/Makefile
+@@ -1,4 +1,4 @@
+-CFLAGS = -Wall -O3 -funroll-loops -fPIC -DPIC
++ccopts = $(CFLAGS) -Wall -O3 -funroll-loops -fPIC -DPIC
+ OCAMLC = ocamlc
+ OCAMLOPT = ocamlopt
+ OCAMLMKLIB = ocamlmklib
+@@ -91,7 +91,7 @@ sha.test: sha1.cmxa sha256.cmxa sha512.cmxa sha.test.cmx
+ $(OCAMLOPT) $(OCAMLOPTFLAGS) -c -o $@ $<
+
+ %.$(OBJ): %.c
+- $(OCAMLC) -ccopt "$(CFLAGS)" -c -o $@ $<
++ $(OCAMLC) -ccopt "$(ccopts)" -c -o $@ $<
+
+ %.lib.$(OBJ): %.$(OBJ)
+ mv $< $@
+--
diff --git a/debian/patches/series b/debian/patches/series
index b77f009..e9d101e 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,2 +1,3 @@
-0001-update-checksums-of-README-file.patch
-0002-modify-Makefile.patch
+0001-install-mli-files.patch
+0002-compile-C-files-with-fPIC.patch
+0003-use-internal-ccopts-variable.patch
--
ocaml-sha packaging
More information about the Pkg-ocaml-maint-commits
mailing list