From 34320df33bb07b937b21c255251e78375593574f Mon Sep 17 00:00:00 2001 From: Stephane Glondu Date: Wed, 20 Jun 2012 13:54:41 +0200 Subject: [PATCH] Fix testsuite on bytecode architectures (again and again...) This patch is minimal wrt upstream source, but the testsuite makefiles should probably be rewritten from scratch... --- ...-testsuite-on-bytecode-architectures.patch | 48 +++++++++++++++++++ debian/patches/series | 1 + 2 files changed, 49 insertions(+) create mode 100644 debian/patches/0013-Fix-testsuite-on-bytecode-architectures.patch diff --git a/debian/patches/0013-Fix-testsuite-on-bytecode-architectures.patch b/debian/patches/0013-Fix-testsuite-on-bytecode-architectures.patch new file mode 100644 index 00000000..e370a49a --- /dev/null +++ b/debian/patches/0013-Fix-testsuite-on-bytecode-architectures.patch @@ -0,0 +1,48 @@ +From: Stephane Glondu +Date: Wed, 20 Jun 2012 13:50:25 +0200 +Subject: Fix testsuite on bytecode architectures + +--- + testsuite/makefiles/Makefile.one | 3 ++- + testsuite/tests/lib-scanf-2/Makefile | 3 ++- + 2 files changed, 4 insertions(+), 2 deletions(-) + +diff --git a/testsuite/makefiles/Makefile.one b/testsuite/makefiles/Makefile.one +index 7b25216..edb6ead 100644 +--- a/testsuite/makefiles/Makefile.one ++++ b/testsuite/makefiles/Makefile.one +@@ -20,7 +20,7 @@ ADD_CFLAGS+=$(CUSTOM_FLAG) + + default: compile run + +-compile: $(ML_FILES) $(CMO_FILES) $(CMX_FILES) $(MAIN_MODULE).cmo $(MAIN_MODULE).cmx ++compile: $(ML_FILES) $(CMO_FILES) $(MAIN_MODULE).cmo + @for file in $(C_FILES); do \ + $(NATIVECC) $(NATIVECCCOMPOPTS) -c -I$(TOPDIR)/byterun $$file.c; \ + done; +@@ -28,6 +28,7 @@ compile: $(ML_FILES) $(CMO_FILES) $(CMX_FILES) $(MAIN_MODULE).cmo $(MAIN_MODULE) + @$(OCAMLC) $(ADD_COMPFLAGS) $(ADD_CFLAGS) -o program.byte $(O_FILES) $(CMA_FILES) $(CMO_FILES) $(ADD_CMO_FILES) $(MAIN_MODULE).cmo + @if [ -z "$(BYTECODE_ONLY)" ]; then \ + rm -f program.native program.native.exe; \ ++ $(MAKE) $(CMX_FILES) $(MAIN_MODULE).cmx; \ + $(OCAMLOPT) $(ADD_COMPFLAGS) -o program.native $(O_FILES) $(CMXA_FILES) $(CMX_FILES) $(ADD_CMX_FILES) $(MAIN_MODULE).cmx; \ + fi + +diff --git a/testsuite/tests/lib-scanf-2/Makefile b/testsuite/tests/lib-scanf-2/Makefile +index 216b396..7362fad 100644 +--- a/testsuite/tests/lib-scanf-2/Makefile ++++ b/testsuite/tests/lib-scanf-2/Makefile +@@ -2,10 +2,11 @@ BASEDIR=../.. + + default: compile run + +-compile: tscanf2_io.cmo tscanf2_io.cmx ++compile: tscanf2_io.cmo + @$(OCAMLC) unix.cma tscanf2_io.cmo -o master.byte tscanf2_master.ml + @$(OCAMLC) tscanf2_io.cmo -o slave.byte tscanf2_slave.ml + @if [ -z "$(BYTECODE_ONLY)" ]; then \ ++ $(MAKE) tscanf2_io.cmx; \ + $(OCAMLOPT) unix.cmxa tscanf2_io.cmx -o master.native tscanf2_master.ml; \ + $(OCAMLOPT) tscanf2_io.cmx -o slave.native tscanf2_slave.ml; \ + fi +-- diff --git a/debian/patches/series b/debian/patches/series index 7d15357f..5bc804a4 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -10,3 +10,4 @@ 0010-Properly-initialize-executable-name-in-caml_startup_.patch 0011-Embed-bytecode-in-C-object-when-using-custom.patch 0012-Fix-asmcomp-tests-on-Hurd.patch +0013-Fix-testsuite-on-bytecode-architectures.patch -- 2.30.2