diff options
224 files changed, 1511 insertions, 8497 deletions
@@ -392,7 +392,7 @@ installoptopt: # Run all tests tests: opt.opt - cd testsuite; $(MAKE) clean && $(MAKE) all + cd testsuite && $(MAKE) # The clean target diff --git a/config/Makefile.mingw b/config/Makefile.mingw index c204980367..f343973107 100644 --- a/config/Makefile.mingw +++ b/config/Makefile.mingw @@ -172,6 +172,6 @@ MAKECMD=$(MAKE) OTOPDIR=$(WINTOPDIR) CTOPDIR=$(TOPDIR) CYGPATH=cygpath -m -DIFF=diff -q --strip-trailing-cr +DIFF=diff --strip-trailing-cr CANKILL=false SET_LD_PATH=PATH="$(PATH):$(LD_PATH)" diff --git a/config/Makefile.mingw64 b/config/Makefile.mingw64 index 0a3bdfbd09..866921e0de 100644 --- a/config/Makefile.mingw64 +++ b/config/Makefile.mingw64 @@ -172,6 +172,6 @@ MAKECMD=$(MAKE) OTOPDIR=$(WINTOPDIR) CTOPDIR=$(TOPDIR) CYGPATH=cygpath -m -DIFF=diff -q --strip-trailing-cr +DIFF=diff --strip-trailing-cr CANKILL=false SET_LD_PATH=PATH="$(PATH):$(LD_PATH)" diff --git a/config/Makefile.msvc b/config/Makefile.msvc index abe37bf324..50b08c8bdc 100644 --- a/config/Makefile.msvc +++ b/config/Makefile.msvc @@ -173,7 +173,7 @@ MAKECMD=$(MAKE) OTOPDIR=$(WINTOPDIR) CTOPDIR=$(WINTOPDIR) CYGPATH=cygpath -m -DIFF=diff -q --strip-trailing-cr +DIFF=diff --strip-trailing-cr CANKILL=false FIND=/usr/bin/find SORT=/usr/bin/sort diff --git a/config/Makefile.msvc64 b/config/Makefile.msvc64 index c33ba1fb70..7ab86ddbbc 100644 --- a/config/Makefile.msvc64 +++ b/config/Makefile.msvc64 @@ -177,7 +177,7 @@ MAKECMD=$(MAKE) OTOPDIR=$(WINTOPDIR) CTOPDIR=$(WINTOPDIR) CYGPATH=cygpath -m -DIFF=diff -q --strip-trailing-cr +DIFF=diff --strip-trailing-cr CANKILL=false FIND=/usr/bin/find SORT=/usr/bin/sort diff --git a/testsuite/.ignore b/testsuite/.ignore index a333a8b0a0..8ad0ae5621 100644 --- a/testsuite/.ignore +++ b/testsuite/.ignore @@ -1 +1,2 @@ _log +_full-log diff --git a/testsuite/Makefile b/testsuite/Makefile index 668f0833ae..90ebd6abdf 100644 --- a/testsuite/Makefile +++ b/testsuite/Makefile @@ -2,103 +2,129 @@ # # # OCaml # # # -# Xavier Clerc, SED, INRIA Rocquencourt # +# Damien Doligez, Jane Street Capital # # # -# Copyright 2010 Institut National de Recherche en Informatique et # +# Copyright 2014 Institut National de Recherche en Informatique et # # en Automatique. All rights reserved. This file is distributed # # under the terms of the Q Public License version 1.0. # # # ######################################################################### -BASEDIR := $(shell pwd) -NO_PRINT=`$(MAKE) empty --no-print-directory >/dev/null 2>&1 \ - && echo --no-print-directory` +# usage: +# +# make +# run all tests +# +# make { all | byte | opt | none } +# run all tests, only byte-code tests, only native-code tests, or no tests +# +# make [ all | byte | opt | none ] file=<f> +# run tests in all the directories listed in file <f> +# +# make [ all | byte | opt | none ] dir=<d> +# run tests in directory <d> +# +# make [ all | byte | opt | none ] dir=<file>.t +# run the tests described by <file>.t +# +# make [ all | byte | opt | none ] dir="<d1> ... <dn> <f1>.t ... <fn>.t" +# run tests in the directories <d1> to <dn> and in files <f1>.t ... <fn>.t -FIND=find -include ../config/Makefile +ifeq "$(file)" "" + dir=tests +else + dir=$(shell cat $(file)) +endif -.PHONY: default -default: - @echo "Available targets:" - @echo " all launch all tests" - @echo " list FILE=f launch the tests listed in f (one per line)" - @echo " one DIR=p launch the tests located in path p" - @echo " promote DIR=p promote the reference files for the tests in p" - @echo " lib build library modules" - @echo " clean delete generated files" - @echo " report print the report for the last execution" +######################################################################### +# set up configuration variables + +TOPDIR=$(shell cd .. && pwd) +WINTOPDIR=$(shell cygpath -m $(TOPDIR)) + +# TOPDIR is the root directory of the OCaml sources, in Unix syntax. +# WINTOPDIR is the same directory, in Windows syntax. + +OTOPDIR=$(TOPDIR) +CTOPDIR=$(TOPDIR) +CYGPATH=echo +DIFF=diff +CANKILL=true +SORT=sort +SET_LD_PATH=CAML_LD_LIBRARY_PATH="$$LD_PATH" + +# The variables above may be overridden by .../config/Makefile +# OTOPDIR is either TOPDIR or WINTOPDIR, whichever is appropriate for +# arguments given to the OCaml compiler. +# CTOPDIR is either TOPDIR or WINTOPDIR, whichever is appropriate for +# arguments given to the C and Fortran compilers. +# CYGPATH is the command that translates unix-style file names into +# whichever syntax is appropriate for arguments of OCaml programs. +# DIFF is a "diff" command that ignores trailing CRs under Windows. +# CANKILL is true if a script launched by Make can kill an OCaml process, +# and false for the mingw and MSVC ports. +# SORT is the Unix "sort" command. Usually a simple command, but may be an +# absolute name if the Windows "sort" command is in the PATH. +# SET_LD_PATH is a command prefix that sets the path for dynamic libraries +# (CAML_LD_LIBRARY_PATH for Unix, PATH for Windows) using the LD_PATH make +# variable. Note that for Windows we add Unix-syntax directory names in +# PATH, and Cygwin will translate it to Windows syntax. + +include $(TOPDIR)/config/Makefile + +# Transmit Makefile configuration variables to the test scripts +unexport WINTOPDIR +export +export MAKE .PHONY: all -all: lib - @for dir in tests/*; do \ - $(MAKE) $(NO_PRINT) exec-one DIR=$$dir; \ - done 2>&1 | tee _log - @$(MAKE) report +all: + rm -f _log _full-log + $(MAKE) clean >>_full-log 2>&1 + $(MAKE) -C lib byte opt >>_full-log 2>&1 + ./scripts/do_tests $(dir) + +byte: + rm -f _log _full-log + $(MAKE) clean >>_full-log 2>&1 + $(MAKE) -C lib byte >>_full-log 2>&1 + ./scripts/do_tests -no-opt $(dir) + +opt: + rm -f _log _full-log + $(MAKE) clean >>_full-log 2>&1 + $(MAKE) -C lib opt >>_full-log 2>&1 + ./scripts/do_tests -no-byte $(dir) + +none: + rm -f _log _full-log + $(MAKE) clean >>_full-log 2>&1 + ./scripts/do_tests -no-byte -no-opt $(dir) + +.PHONY: clean +clean: + scripts/do_clean tests + +##### +# For compatibility with the old test makefile .PHONY: list -list: lib - @if [ -z "$(FILE)" ]; \ - then echo "No value set for variable 'FILE'."; \ - exit 1; \ - fi - @while read LINE; do \ - $(MAKE) $(NO_PRINT) exec-one DIR=$$LINE; \ - done <$(FILE) 2>&1 | tee _log - @$(MAKE) report +list: + $(MAKE) file=$(FILE) .PHONY: one -one: lib - @if [ -z "$(DIR)" ]; then \ - echo "No value set for variable 'DIR'."; \ - exit 1; \ - fi - @if [ ! -d $(DIR) ]; then \ - echo "Directory '$(DIR)' does not exist."; \ - exit 1; \ - fi - @$(MAKE) $(NO_PRINT) exec-one DIR=$(DIR) - -.PHONY: exec-one -exec-one: - @if [ ! -f $(DIR)/Makefile ]; then \ - for dir in $(DIR)/*; do \ - if [ -d $$dir ]; then \ - $(MAKE) exec-one DIR=$$dir; \ - fi; \ - done; \ - else \ - echo "Running tests from '$$DIR' ..."; \ - cd $(DIR) && \ - $(MAKE) TERM=dumb BASEDIR=$(BASEDIR) || echo '=> unexpected error'; \ - fi +one: + $(MAKE) dir=$(DIR) .PHONY: promote promote: - @if [ -z "$(DIR)" ]; then \ - echo "No value set for variable 'DIR'."; \ - exit 1; \ - fi - @if [ ! -d $(DIR) ]; then \ - echo "Directory '$(DIR)' does not exist."; \ - exit 1; \ - fi - @cd $(DIR) && $(MAKE) TERM=dumb BASEDIR=$(BASEDIR) promote + echo '"make promote" is deprecated, you must promote by hand' + exit 2 .PHONY: lib lib: - @cd lib && $(MAKE) -s BASEDIR=$(BASEDIR) - -.PHONY: clean -clean: - @cd lib && $(MAKE) BASEDIR=$(BASEDIR) clean - @for file in `$(FIND) interactive tests -name Makefile`; do \ - (cd `dirname $$file` && $(MAKE) BASEDIR=$(BASEDIR) clean); \ - done + : .PHONY: report report: - @if [ ! -f _log ]; then echo "No '_log' file."; exit 1; fi - @awk -f makefiles/summarize.awk <_log - -.PHONY: empty -empty: + awk -f scripts/summary _log expected= diff --git a/testsuite/external/.ignore b/testsuite/external/.ignore deleted file mode 100644 index 39e14de915..0000000000 --- a/testsuite/external/.ignore +++ /dev/null @@ -1,152 +0,0 @@ -*.tar.gz -*.tar.bz2 -*.tgz -*.tbz -*.zip - -log-* -log_* - -advi -advi-1.10.2 -altergo -alt-ergo-0.95.2 -binprot -bin_prot-109.30.00 -bitstring -ocaml-bitstring-2.0.3 -boomerang -boomerang-0.2 -calendar -calendar-2.03.2 -camlimages -camlimages-4.0.1 -camlpdf -camlpdf-0.5 -camlp4 -camlp4-trunk -camlp5 -camlp5-git -camlzip -camlzip-1.04 -camomile -camomile-0.8.4 -comparelib -comparelib-109.15.00 -compcert -compcert-1.13 -configfile -config-file-1.1 -coq -coq-8.4pl2 -core -core-109.37.00 -coreextended -core_extended-109.36.00 -corekernel -core_kernel-109.37.00 -cryptokit -cryptokit-1.6 -csv -csv-1.3.1 -customprintf -custom_printf-109.27.00 -dbm -camldbm-1.0 -expect -ocaml-expect-0.0.3 -extlib -extlib-1.5.2 -fieldslib -fieldslib-109.15.00 -fileutils -ocaml-fileutils-0.4.4 -findlib -findlib-1.4.1 -framac -frama-c-Oxygen-20120901 -geneweb -gw-6.05-src -herelib -herelib-109.35.00 -hevea -hevea-2.09 -kaputt -kaputt-1.2 -lablgtk -lablgtk-2.18.0 -lablgtkextras -lablgtkextras-1.3 -lwt -lwt-2.4.0 -menhir -menhir-20120123 -mldonkey -mldonkey-3.1.2 -mysql -ocaml-mysql-1.0.4 -oasis -oasis-0.3.0 -obrowser -obrowser-1.1.1 -ocamlgraph -ocamlgraph-1.8.2 -ocamlify -ocamlify-0.0.1 -ocamlmod -ocamlmod-0.0.3 -ocamlnet -ocamlnet-3.5.1 -ocamlscript -ocamlscript-2.0.3 -ocamlssl -ocaml-ssl-0.4.6 -ocamltext -ocaml-text-0.5 -ocgi -ocgi-0.5 -ocsigen -ocsigen-bundle-2.2.2 -odn -ocaml-data-notation-0.0.10 -omake -omake-0.9.8.6 -ounit -ounit-1.1.2 -paounit -pa_ounit-109.36.00 -pcre -pcre-ocaml-6.2.5 -pipebang -pipebang-109.28.00 -react -react-0.9.3 -res -res-3.2.0 -rss -ocamlrss-2.2.2 -sexplib -sexplib-109.15.00 -sks -sks-1.1.3 -sqlite -sqlite3-ocaml-2.0.1 -textutils -textutils-109.36.00 -typeconv -type_conv-109.28.00 -unison -unison-2.45.4 -variantslib -variantslib-109.15.00 -vsyml -vsyml-2010-04-06 -xmllight -xml-light.2.3 -xmlm -xmlm-1.1.0 -zarith -zarith-1.2.1 -zen -zen_2.3.2 -._ZEN_2.3.2 diff --git a/testsuite/external/Makefile b/testsuite/external/Makefile deleted file mode 100644 index 566aaf3921..0000000000 --- a/testsuite/external/Makefile +++ /dev/null @@ -1,1747 +0,0 @@ -######################################################################### -# # -# OCaml # -# # -# Damien Doligez, projet Gallium, INRIA Rocquencourt # -# # -# Copyright 2012 Institut National de Recherche en Informatique et # -# en Automatique. All rights reserved. This file is distributed # -# under the terms of the Q Public License version 1.0. # -# # -######################################################################### - -# To use this test set, you need OCaml installed in a directory where -# you have write rights. - -# Warning: use of this Makefile will install lots of software -# in the same place where OCaml is installed. - -# It is recommended that you install OCaml in some isolated -# directory D (for example /usr/local/ocaml/test), add D/bin -# at the front of your PATH, then use this Makefile to test -# your OCaml installation. - -WGET = wget --no-check-certificate --progress=dot:mega - -PREFIX = "`ocamlc -where | sed -e 's|/[^/]*/[^/]*$$||'`" -VERSION = `ocamlc -vnum` - -.PHONY: default -default: - @printf "\n\n########## Starting make at " >>log-${VERSION} - @date >>log-${VERSION} - ${MAKE} platform >>log-${VERSION} 2>&1 - @printf '\n' - mv log-${VERSION} log_${VERSION}_`date -u '+%Y-%m-%d:%H:%M:%S'` - -# Platform-dependent subsets: add your own here. - -.PHONY: all-cygwin -all-cygwin: findlib ounit res pcre react ocamltext ocamlssl camlzip cryptokit \ - sqlite ocgi xmllight configfile xmlm omake \ - camomile zen vsyml extlib fileutils ocamlify ocamlmod \ - calendar dbm ocamlscript coq compcert - -all-macos: findlib res pcre react ocamltext \ - ocamlssl camlzip cryptokit sqlite menhir hevea \ - xmllight xmlm omake zen \ - altergo boomerang vsyml extlib \ - ocamlify calendar \ - dbm geneweb framac coq compcert - -platform: - case `uname -s` in \ - CYGWIN*) ${MAKE} all-cygwin;; \ - Darwin) ${MAKE} all-macos;; \ - *) ${MAKE} all;; \ - esac - -# https://github.com/ocaml/camlp4/ -CAMLP4=camlp4-trunk -${CAMLP4}.zip: - ${WGET} https://github.com/ocaml/camlp4/archive/trunk.zip - mv trunk.zip ${CAMLP4}.zip -xxcamlp4: ${CAMLP4}.zip - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${CAMLP4} - unzip -q ${CAMLP4}.zip - ./Patcher.sh ${CAMLP4} - ( cd ${CAMLP4} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure --prefix ${PREFIX} && \ - ${MAKE} all && \ - ocamlfind remove camlp4 && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${CAMLP4} camlp4 -distclean:: - rm -f ${CAMLP4}.tar.gz -all: camlp4 - -# http://projects.camlcity.org/projects/findlib.html -FINDLIB=findlib-1.4.1 -${FINDLIB}.tar.gz: - ${WGET} http://download.camlcity.org/download/$@ -findlib: ${FINDLIB}.tar.gz - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${FINDLIB} - tar zxf ${FINDLIB}.tar.gz - ./Patcher.sh ${FINDLIB} - ( cd ${FINDLIB} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ./configure && \ - ${MAKE} all && \ - ${MAKE} opt && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${FINDLIB} findlib -distclean:: - rm -f ${FINDLIB}.tar.gz -all: findlib - -# http://lablgtk.forge.ocamlcore.org/ -LABLGTK=lablgtk-2.18.0 -${LABLGTK}.tar.gz: - ${WGET} https://forge.ocamlcore.org/frs/download.php/1261/$@ -xxlablgtk: ${LABLGTK}.tar.gz findlib camlp4 # TODO: add lablgl - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${LABLGTK} - tar zxf ${LABLGTK}.tar.gz - ./Patcher.sh ${LABLGTK} - ( cd ${LABLGTK} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ./configure -prefix ${PREFIX} && \ - ${MAKE} world && \ - ocamlfind remove lablgtk2 && \ - ${MAKE} install && \ - rm -f ${PREFIX}/lib/ocaml/lablgtk2 && \ - ln -f -s ${PREFIX}/lib/ocaml/site-lib/lablgtk2 \ - ${PREFIX}/lib/ocaml/lablgtk2 ) - echo ${VERSION} >$@ -clean:: - rm -rf ${LABLGTK} lablgtk -distclean:: - rm -f ${LABLGTK}.tar.gz -all: lablgtk - -# http://ocamlgraph.lri.fr/ -OCAMLGRAPH=ocamlgraph-1.8.2 -${OCAMLGRAPH}.tar.gz: - ${WGET} http://ocamlgraph.lri.fr/download/$@ -ocamlgraph: ${OCAMLGRAPH}.tar.gz findlib - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${OCAMLGRAPH} - tar zxf ${OCAMLGRAPH}.tar.gz - ./Patcher.sh ${OCAMLGRAPH} - ( cd ${OCAMLGRAPH} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ./configure -prefix ${PREFIX} && \ - ${MAKE} && \ - rm -rf ${PREFIX}/lib/ocaml/ocamlgraph && \ - ocamlfind remove ocamlgraph && \ - ${MAKE} install install-findlib && \ - ln -s ${PREFIX}/lib/ocaml/site-lib/ocamlgraph \ - ${PREFIX}/lib/ocaml/ocamlgraph ) - echo ${VERSION} >$@ -clean:: - rm -rf ${OCAMLGRAPH} ocamlgraph -distclean:: - rm -f ${OCAMLGRAPH}.tar.gz -all: ocamlgraph - -# http://ounit.forge.ocamlcore.org/ -OUNIT=ounit-1.1.2 -${OUNIT}.tar.gz: - ${WGET} http://forge.ocamlcore.org/frs/download.php/886/$@ -xxounit: ${OUNIT}.tar.gz findlib camlp4 - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${OUNIT} - tar zxf ${OUNIT}.tar.gz - ./Patcher.sh ${OUNIT} - ( cd ${OUNIT} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ${MAKE} && \ - ocamlfind remove oUnit && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${OUNIT} ounit -distclean:: - rm -f ${OUNIT}.tar.gz -all: ounit - -# https://bitbucket.org/mmottl/res -RES=res-3.2.0 -${RES}.tar.gz: - ${WGET} https://bitbucket.org/mmottl/res/downloads/$@ -res: ${RES}.tar.gz findlib - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${RES} - tar zxf ${RES}.tar.gz - ./Patcher.sh ${RES} - ( cd ${RES} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ${MAKE} && \ - ocamlfind remove res && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${RES} res -distclean:: - rm -f ${RES}.tar.gz -all: res - -# https://bitbucket.org/mmottl/pcre-ocaml -PCRE=pcre-ocaml-6.2.5 -${PCRE}.tar.gz: - ${WGET} https://bitbucket.org/mmottl/pcre-ocaml/downloads/$@ -pcre: ${PCRE}.tar.gz findlib - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${PCRE} - tar zxf ${PCRE}.tar.gz - ./Patcher.sh ${PCRE} - ( cd ${PCRE} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ${MAKE} && \ - ocamlfind remove pcre && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${PCRE} pcre -distclean:: - rm -f ${PCRE}.tar.gz -all: pcre - -########################################################################### - -## Jane Street Core - -# https://ocaml.janestreet.com/ocaml-core/109.28.00/individual/ -TYPECONV=type_conv-109.28.00 -${TYPECONV}.tar.gz: - ${WGET} https://ocaml.janestreet.com/ocaml-core/109.28.00/individual/$@ -xxtypeconv: ${TYPECONV}.tar.gz findlib camlp4 - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${TYPECONV} - tar zxf ${TYPECONV}.tar.gz - ./Patcher.sh ${TYPECONV} - ( cd ${TYPECONV} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure && \ - ocaml setup.ml -build && \ - ocamlfind remove type_conv && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${TYPECONV} typeconv -distclean:: - rm -f ${TYPECONV}.tar.gz -all: typeconv - -# https://ocaml.janestreet.com/ocaml-core/109.15.00/individual/ -VARIANTSLIB=variantslib-109.15.00 -${VARIANTSLIB}.tar.gz: - ${WGET} https://ocaml.janestreet.com/ocaml-core/109.15.00/individual/$@ -xxvariantslib: ${VARIANTSLIB}.tar.gz findlib typeconv - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${VARIANTSLIB} - tar zxf ${VARIANTSLIB}.tar.gz - ./Patcher.sh ${VARIANTSLIB} - ( cd ${VARIANTSLIB} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure && \ - ocaml setup.ml -build && \ - ocamlfind remove variantslib && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${VARIANTSLIB} variantslib -distclean:: - rm -f ${VARIANTSLIB}.tar.gz -all: variantslib - -# https://ocaml.janestreet.com/ocaml-core/109.28.00/individual/ -PIPEBANG=pipebang-109.28.00 -${PIPEBANG}.tar.gz: - ${WGET} https://ocaml.janestreet.com/ocaml-core/109.28.00/individual/$@ -pipebang: ${PIPEBANG}.tar.gz findlib typeconv - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${PIPEBANG} - tar zxf ${PIPEBANG}.tar.gz - ./Patcher.sh ${PIPEBANG} - ( cd ${PIPEBANG} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure && \ - ocaml setup.ml -build && \ - ocamlfind remove pa_pipebang && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${PIPEBANG} pipebang -distclean:: - rm -f ${PIPEBANG}.tar.gz -all: pipebang - -# https://ocaml.janestreet.com/ocaml-core/109.36.00/individual/ -PAOUNIT=pa_ounit-109.36.00 -${PAOUNIT}.tar.gz: - ${WGET} https://ocaml.janestreet.com/ocaml-core/109.36.00/individual/$@ -paounit: ${PAOUNIT}.tar.gz findlib typeconv - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${PAOUNIT} - tar zxf ${PAOUNIT}.tar.gz - ./Patcher.sh ${PAOUNIT} - ( cd ${PAOUNIT} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure && \ - ocaml setup.ml -build && \ - ocamlfind remove pa_ounit && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${PAOUNIT} paounit -distclean:: - rm -f ${PAOUNIT}.tar.gz -all: paounit - -# https://ocaml.janestreet.com/ocaml-core/109.15.00/individual/ -COMPARELIB=comparelib-109.15.00 -${COMPARELIB}.tar.gz: - ${WGET} https://ocaml.janestreet.com/ocaml-core/109.15.00/individual/$@ -comparelib: ${COMPARELIB}.tar.gz findlib typeconv - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${COMPARELIB} - tar zxf ${COMPARELIB}.tar.gz - ./Patcher.sh ${COMPARELIB} - ( cd ${COMPARELIB} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure && \ - ocaml setup.ml -build && \ - ocamlfind remove comparelib && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${COMPARELIB} comparelib -distclean:: - rm -f ${COMPARELIB}.tar.gz -all: comparelib - -# https://ocaml.janestreet.com/ocaml-core/109.30.00/individual/ -BINPROT=bin_prot-109.30.00 -${BINPROT}.tar.gz: - ${WGET} https://ocaml.janestreet.com/ocaml-core/109.30.00/individual/$@ -binprot: ${BINPROT}.tar.gz findlib typeconv ounit - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${BINPROT} - tar zxf ${BINPROT}.tar.gz - ./Patcher.sh ${BINPROT} - ( cd ${BINPROT} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure && \ - ocaml setup.ml -build && \ - ocamlfind remove bin_prot && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${BINPROT} binprot -distclean:: - rm -f ${BINPROT}.tar.gz -all: binprot - -# https://ocaml.janestreet.com/ocaml-core/109.15.00/individual/ -FIELDSLIB=fieldslib-109.15.00 -${FIELDSLIB}.tar.gz: - ${WGET} https://ocaml.janestreet.com/ocaml-core/109.15.00/individual/$@ -fieldslib: ${FIELDSLIB}.tar.gz findlib typeconv - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${FIELDSLIB} - tar zxf ${FIELDSLIB}.tar.gz - ./Patcher.sh ${FIELDSLIB} - ( cd ${FIELDSLIB} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure && \ - ocaml setup.ml -build && \ - ocamlfind remove fieldslib && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${FIELDSLIB} fieldslib -distclean:: - rm -f ${FIELDSLIB}.tar.gz -all: fieldslib - -# https://ocaml.janestreet.com/ocaml-core/109.15.00/individual/ -SEXPLIB=sexplib-109.15.00 -${SEXPLIB}.tar.gz: - ${WGET} https://ocaml.janestreet.com/ocaml-core/109.15.00/individual/$@ -sexplib: ${SEXPLIB}.tar.gz findlib typeconv - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${SEXPLIB} - tar zxf ${SEXPLIB}.tar.gz - ./Patcher.sh ${SEXPLIB} - ( cd ${SEXPLIB} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure && \ - ocaml setup.ml -build && \ - ocamlfind remove sexplib && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${SEXPLIB} sexplib -distclean:: - rm -f ${SEXPLIB}.tar.gz -all: sexplib - -# https://ocaml.janestreet.com/ocaml-core/109.35.00/individual/ -HERELIB=herelib-109.35.00 -${HERELIB}.tar.gz: - ${WGET} https://ocaml.janestreet.com/ocaml-core/109.35.00/individual/$@ -herelib: ${HERELIB}.tar.gz - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${HERELIB} - tar zxf ${HERELIB}.tar.gz - ./Patcher.sh ${HERELIB} - ( cd ${HERELIB} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure --prefix ${PREFIX} && \ - ${MAKE} && \ - ocamlfind remove herelib && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${HERELIB} herelib -distclean:: - rm -f ${HERELIB}.tar.gz -all: herelib - -# https://ocaml.janestreet.com/ocaml-core/109.37.00/individual/ -COREKERNEL=core_kernel-109.37.00 -${COREKERNEL}.tar.gz: - ${WGET} https://ocaml.janestreet.com/ocaml-core/109.37.00/individual/$@ -corekernel: ${COREKERNEL}.tar.gz findlib variantslib sexplib fieldslib \ - binprot comparelib paounit pipebang res ounit herelib - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${COREKERNEL} - tar zxf ${COREKERNEL}.tar.gz - ./Patcher.sh ${COREKERNEL} - ( cd ${COREKERNEL} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure && \ - ocaml setup.ml -build && \ - ocamlfind remove core_kernel && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${COREKERNEL} corekernel -distclean:: - rm -f ${COREKERNEL}.tar.gz -all: core - -# https://ocaml.janestreet.com/ocaml-core/109.37.00/individual/ -CORE=core-109.37.00 -${CORE}.tar.gz: - ${WGET} https://ocaml.janestreet.com/ocaml-core/109.37.00/individual/$@ -xxcore: ${CORE}.tar.gz findlib variantslib sexplib fieldslib binprot comparelib \ - paounit pipebang res ounit corekernel - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${CORE} - tar zxf ${CORE}.tar.gz - ./Patcher.sh ${CORE} - ( cd ${CORE} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure && \ - ocaml setup.ml -build && \ - ocamlfind remove core && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${CORE} core -distclean:: - rm -f ${CORE}.tar.gz -all: core - -# https://ocaml.janestreet.com/ocaml-core/109.27.00/individual/ -CUSTOMPRINTF=custom_printf-109.27.00 -${CUSTOMPRINTF}.tar.gz: - ${WGET} https://ocaml.janestreet.com/ocaml-core/109.27.00/individual/$@ -customprintf: ${CUSTOMPRINTF}.tar.gz - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${CUSTOMPRINTF} - tar zxf ${CUSTOMPRINTF}.tar.gz - ./Patcher.sh ${CUSTOMPRINTF} - ( cd ${CUSTOMPRINTF} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure --prefix ${PREFIX} && \ - ${MAKE} && \ - ocamlfind remove customprintf && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${CUSTOMPRINTF} customprintf -distclean:: - rm -f ${CUSTOMPRINTF}.tar.gz -all: customprintf - -# https://ocaml.janestreet.com/ocaml-core/109.36.00/individual/ -TEXTUTILS=textutils-109.36.00 -${TEXTUTILS}.tar.gz: - ${WGET} https://ocaml.janestreet.com/ocaml-core/109.36.00/individual/$@ -textutils: ${TEXTUTILS}.tar.gz - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${TEXTUTILS} - tar zxf ${TEXTUTILS}.tar.gz - ./Patcher.sh ${TEXTUTILS} - ( cd ${TEXTUTILS} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure --prefix ${PREFIX} && \ - ${MAKE} && \ - ocamlfind remove textutils && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${TEXTUTILS} textutils -distclean:: - rm -f ${TEXTUTILS}.tar.gz -all: textutils - -# https://ocaml.janestreet.com/ocaml-core/109.36.00/individual/ -COREEXTENDED=core_extended-109.36.00 -${COREEXTENDED}.tar.gz: - ${WGET} https://ocaml.janestreet.com/ocaml-core/109.36.00/individual/$@ -coreextended: ${COREEXTENDED}.tar.gz findlib sexplib fieldslib binprot paounit \ - pipebang core pcre res comparelib ounit - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${COREEXTENDED} - tar zxf ${COREEXTENDED}.tar.gz - ./Patcher.sh ${COREEXTENDED} - ( cd ${COREEXTENDED} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure && \ - ocaml setup.ml -build && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${COREEXTENDED} coreextended -distclean:: - rm -f ${COREEXTENDED}.tar.gz -all: coreextended - -########################################################################### - -# http://erratique.ch/software/react -REACT=react-0.9.3 -${REACT}.tbz: - ${WGET} http://erratique.ch/software/react/releases/$@ -react: ${REACT}.tbz findlib - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${REACT} - tar jxf ${REACT}.tbz - ./Patcher.sh ${REACT} oasis-common.patch - ( cd ${REACT} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure && \ - ocaml setup.ml -build && \ - ./test.native && \ - ocamlfind remove react && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${REACT} react -distclean:: - rm -f ${REACT}.tbz -all: react - -# http://forge.ocamlcore.org/projects/ocaml-text/ -OCAMLTEXT=ocaml-text-0.5 -${OCAMLTEXT}.tar.gz: - ${WGET} http://forge.ocamlcore.org/frs/download.php/641/$@ -ocamltext: ${OCAMLTEXT}.tar.gz findlib - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${OCAMLTEXT} - tar zxf ${OCAMLTEXT}.tar.gz - ./Patcher.sh ${OCAMLTEXT} oasis-common.patch - ( cd ${OCAMLTEXT} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ${MAKE} build && \ - ${MAKE} test && \ - ocamlfind remove text && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${OCAMLTEXT} ocamltext -distclean:: - rm -f ${OCAMLTEXT}.tar.gz -all: ocamltext - -# https://github.com/savonet/ocaml-ssl -OCAMLSSL=ocaml-ssl-0.4.6 -${OCAMLSSL}.tar.gz: - ${WGET} https://github.com/savonet/ocaml-ssl/archive/$@ -ocamlssl: ${OCAMLSSL}.tar.gz findlib - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${OCAMLSSL} - tar zxf ${OCAMLSSL}.tar.gz && mv ocaml-ssl-${OCAMLSSL} ${OCAMLSSL} - ./Patcher.sh ${OCAMLSSL} - ( cd ${OCAMLSSL} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - autoconf configure.ac >configure && \ - sh ./configure && \ - ${MAKE} && \ - ocamlfind remove ssl && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${OCAMLSSL} ocamlssl -distclean:: - rm -f ${OCAMLSSL}.tar.gz -all: ocamlssl - -# http://ocsigen.org/lwt/install -LWT=lwt-2.4.0 -${LWT}.tar.gz: - ${WGET} http://ocsigen.org/download/$@ -xxlwt: ${LWT}.tar.gz findlib react ocamltext ocamlssl camlp4 lablgtk - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${LWT} - tar zxf ${LWT}.tar.gz - ./Patcher.sh ${LWT} - ( cd ${LWT} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - export C_INCLUDE_PATH=/usr/include:/opt/local/include && \ - export LIBRARY_PATH=/usr/lib:/opt/local/lib && \ - ./configure --enable-ssl --enable-react && \ - ${MAKE} && \ - ocamlfind remove lwt && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${LWT} lwt -distclean:: - rm -f ${LWT}.tar.gz -all: lwt - -# http://forge.ocamlcore.org/projects/camlzip/ -CAMLZIP=camlzip-1.04 -${CAMLZIP}.tar.gz: - ${WGET} http://forge.ocamlcore.org/frs/download.php/328/$@ -camlzip: ${CAMLZIP}.tar.gz findlib - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${CAMLZIP} - tar zxf ${CAMLZIP}.tar.gz - ./Patcher.sh ${CAMLZIP} - ( cd ${CAMLZIP} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ${MAKE} all && \ - ${MAKE} allopt && \ - ${MAKE} install && \ - ${MAKE} installopt && \ - ocamlfind remove camlzip && \ - ocamlfind install camlzip META ) - echo ${VERSION} >$@ -clean:: - rm -rf ${CAMLZIP} camlzip -distclean:: - rm -f ${CAMLZIP}.tar.gz -all: camlzip - -# http://forge.ocamlcore.org/projects/cryptokit/ -CRYPTOKIT=cryptokit-1.6 -${CRYPTOKIT}.tar.gz: - ${WGET} http://forge.ocamlcore.org/frs/download.php/891/$@ -cryptokit: ${CRYPTOKIT}.tar.gz findlib - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${CRYPTOKIT} - tar zxf ${CRYPTOKIT}.tar.gz - ./Patcher.sh ${CRYPTOKIT} - ( cd ${CRYPTOKIT} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ${MAKE} build && \ - ${MAKE} test && \ - ocamlfind remove cryptokit && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${CRYPTOKIT} cryptokit -distclean:: - rm -f ${CRYPTOKIT}.tar.gz -all: cryptokit - -# https://bitbucket.org/mmottl -SQLITE=sqlite3-ocaml-2.0.1 -${SQLITE}.tar.gz: - ${WGET} https://bitbucket.org/mmottl/sqlite3-ocaml/downloads/$@ -sqlite: ${SQLITE}.tar.gz findlib - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${SQLITE} - tar zxf ${SQLITE}.tar.gz - ./Patcher.sh ${SQLITE} oasis-common.patch - ( cd ${SQLITE} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure && \ - ocaml setup.ml -build && \ - ocamlfind remove sqlite3 && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${SQLITE} sqlite -distclean:: - rm -f ${SQLITE}.tar.gz -all: sqlite - -# http://gallium.inria.fr/~fpottier/menhir/ -MENHIR=menhir-20120123 -${MENHIR}.tar.gz: - ${WGET} http://gallium.inria.fr/~fpottier/menhir/$@ -menhir: ${MENHIR}.tar.gz - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${MENHIR} - tar zxf ${MENHIR}.tar.gz - ./Patcher.sh ${MENHIR} - ( cd ${MENHIR} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ${MAKE} PREFIX=${PREFIX} && \ - ocamlfind remove MenhirLib && \ - ${MAKE} PREFIX=${PREFIX} install) - echo ${VERSION} >$@ -clean:: - rm -rf ${MENHIR} menhir -distclean:: - rm -f ${MENHIR}.tar.gz -all: menhir - -# disabled: cannot find module Js -# # http://ocsigen.org/obrowser/install -# OBROWSER=obrowser-1.1.1 -# ${OBROWSER}.tar.gz: -# ${WGET} http://ocsigen.org/download/$@ -# obrowser: ${OBROWSER}.tar.gz lwt menhir ocsigen -# printf "%s " "$@" >/dev/tty -# test -d ${PREFIX} -# rm -rf ${OBROWSER} -# tar zxf ${OBROWSER}.tar.gz -# ./Patcher.sh ${OBROWSER} -# ( cd ${OBROWSER} && \ -# export PATH=${PREFIX}/bin:$$PATH && \ -# ${MAKE} && \ -# ocamlfind remove obrowser && \ -# ${MAKE} install ) -# echo ${VERSION} >$@ -# clean:: -# rm -rf ${OBROWSER} obrowser -# distclean:: -# rm -f ${OBROWSER}.tar.gz -# all: obrowser - -# http://hevea.inria.fr/old/ -HEVEA=hevea-2.09 -${HEVEA}.tar.gz: - ${WGET} http://hevea.inria.fr/old/$@ -hevea: ${HEVEA}.tar.gz - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${HEVEA} - tar zxf ${HEVEA}.tar.gz - ./Patcher.sh ${HEVEA} - ( cd ${HEVEA} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ${MAKE} PREFIX=${PREFIX} && \ - ${MAKE} PREFIX=${PREFIX} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${HEVEA} hevea -distclean:: - rm -f ${HEVEA}.tar.gz -all: hevea - -# http://www.seas.upenn.edu/~bcpierce/unison/download/releases/ -UNISON=unison-2.45.4 -${UNISON}.tar.gz: - ${WGET} http://www.seas.upenn.edu/~bcpierce/unison/download/releases/unison-2.45.4/$@ -unison: ${UNISON}.tar.gz lablgtk - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${UNISON} - tar zxf ${UNISON}.tar.gz - ./Patcher.sh ${UNISON} - ( cd ${UNISON} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ${MAKE} UISTYLE=gtk2 && \ - touch ${PREFIX}/bin/unison && \ - ${MAKE} UISTYLE=gtk2 INSTALLDIR=${PREFIX}/bin/ install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${UNISON} unison -distclean:: - rm -f ${UNISON}.tar.gz -all: unison - -# http://raevnos.pennmush.org/code/ocaml-mysql/ -MYSQL=ocaml-mysql-1.0.4 -${MYSQL}.tar.gz: - ${WGET} http://raevnos.pennmush.org/code/ocaml-mysql/$@ -mysql: ${MYSQL}.tar.gz findlib - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${MYSQL} - tar zxf ${MYSQL}.tar.gz - ./Patcher.sh ${MYSQL} - ( cd ${MYSQL} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - export CPPFLAGS=-I/opt/local/include/mysql5 && \ - export LDFLAGS=-L/opt/local/lib/mysql5/mysql && \ - ./configure -prefix ${PREFIX} && \ - ${MAKE} && \ - ${MAKE} opt && \ - ocamlfind remove mysql && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${MYSQL} mysql -distclean:: - rm -f ${MYSQL}.tar.gz -all: mysql - -# http://gallium.inria.fr/~guesdon/Tools/ocgi/ -OCGI=ocgi-0.5 -${OCGI}.tar.gz: - ${WGET} http://pauillac.inria.fr/~guesdon/Tools/Tars/$@ -ocgi: ${OCGI}.tar.gz camlp4 - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${OCGI} - tar zxf ${OCGI}.tar.gz - ./Patcher.sh ${OCGI} - ( cd ${OCGI} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ./configure && \ - ${MAKE} && \ - ${MAKE} opt && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${OCGI} ocgi -distclean:: - rm -f ${OCGI}.tar.gz -all: ocgi - -# http://tech.motion-twin.com/xmllight -XMLLIGHT=xml-light.2.3 -${XMLLIGHT}.tar.gz: - ${WGET} https://github.com/bguil/ocamllibs/releases/download/xml-light.2.3/$@ -xmllight: ${XMLLIGHT}.tar.gz - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf xml-light ${XMLLIGHT} - tar zxf ${XMLLIGHT}.tar.gz - ./Patcher.sh ${XMLLIGHT} - ( cd ${XMLLIGHT} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ${MAKE} xml_parser.ml && \ - ${MAKE} all opt && \ - ${MAKE} install_ocamlfind ) - echo ${VERSION} >$@ -clean:: - rm -rf ${XMLLIGHT} xml-light xmllight -distclean:: - rm -f ${XMLLIGHT}.zip -all: xmllight - -# http://config-file.forge.ocamlcore.org/ -CONFIGFILE=config-file-1.1 -${CONFIGFILE}.tar.gz: - ${WGET} https://forge.ocamlcore.org/frs/download.php/845/$@ -configfile: ${CONFIGFILE}.tar.gz camlp4 - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${CONFIGFILE} - tar zxf ${CONFIGFILE}.tar.gz - ./Patcher.sh ${CONFIGFILE} - ( cd ${CONFIGFILE} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure --prefix=${PREFIX} && \ - ${MAKE} all && \ - ocamlfind remove config-file && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${CONFIGFILE} configfile -distclean:: - rm -f ${CONFIGFILE}.tar.gz -all: configfile - -# http://erratique.ch/software/xmlm -XMLM=xmlm-1.1.0 -${XMLM}.tbz: - ${WGET} http://erratique.ch/software/xmlm/releases/$@ -xmlm: ${XMLM}.tbz findlib - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${XMLM} - tar jxf ${XMLM}.tbz - ./Patcher.sh ${XMLM} oasis-common.patch - ( cd ${XMLM} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure --prefix ${PREFIX} && \ - ocaml setup.ml -build && \ - ocamlfind remove xmlm && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${XMLM} xmlm -distclean:: - rm -f ${XMLM}.tbz -all: xmlm - -# http://forge.ocamlcore.org/projects/gtk-extras/ -LABLGTKEXTRAS=lablgtkextras-1.3 -${LABLGTKEXTRAS}.tar.gz: - ${WGET} http://forge.ocamlcore.org/frs/download.php/1072/$@ -lablgtkextras: ${LABLGTKEXTRAS}.tar.gz lablgtk configfile xmlm - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${LABLGTKEXTRAS} - tar zxf ${LABLGTKEXTRAS}.tar.gz - ./Patcher.sh ${LABLGTKEXTRAS} - ( cd ${LABLGTKEXTRAS} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure --prefix ${PREFIX} && \ - ${MAKE} all && \ - ocamlfind remove lablgtk2-extras && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${LABLGTKEXTRAS} lablgtkextras -distclean:: - rm -f ${LABLGTKEXTRAS}.tar.gz -all: lablgtkextras - -# https://bitbucket.org/skskeyserver/sks-keyserver/downloads -SKS=sks-1.1.3 -${SKS}.tgz: - ${WGET} https://bitbucket.org/skskeyserver/sks-keyserver/downloads/$@ -sks: ${SKS}.tgz camlp4 - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${SKS} - tar zxf ${SKS}.tgz - ./Patcher.sh ${SKS} - ( cd ${SKS} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ${MAKE} dep PREFIX=${PREFIX} && \ - ${MAKE} all PREFIX=${PREFIX} && \ - ${MAKE} all.bc PREFIX=${PREFIX} && \ - ${MAKE} install PREFIX=${PREFIX} ) - echo ${VERSION} >$@ -clean:: - rm -rf ${SKS} sks -distclean:: - rm -f ${SKS}.tgz -all: sks - -# http://omake.metaprl.org/download.html -OMAKE=omake-0.9.8.6 -${OMAKE}-0.rc1.tar.gz: - ${WGET} http://omake.metaprl.org/downloads/$@ -omake: ${OMAKE}-0.rc1.tar.gz - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${OMAKE} - tar zxf ${OMAKE}-0.rc1.tar.gz - ./Patcher.sh ${OMAKE} - ( cd ${OMAKE} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - export PREFIX=${PREFIX} && \ - ${MAKE} all && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${OMAKE} omake -distclean:: - rm -f ${OMAKE}-0.rc1.tar.gz -all: omake - -# http://forge.ocamlcore.org/projects/zarith -ZARITH=zarith-1.2.1 -${ZARITH}.tar.gz: - ${WGET} http://forge.ocamlcore.org/frs/download.php/1199/$@ -zarith: ${ZARITH}.tar.gz - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${ZARITH} - tar zxf ${ZARITH}.tar.gz - ./Patcher.sh ${ZARITH} - ( cd ${ZARITH} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure && \ - ${MAKE} && \ - ocamlfind remove zarith && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${ZARITH} zarith -distclean:: - rm -f ${ZARITH}.tar.gz -all: zarith - -# http://alt-ergo.ocamlpro.com -ALTERGO=alt-ergo-0.95.2 -${ALTERGO}.tar.gz: - ${WGET} http://alt-ergo.ocamlpro.com/download_manager.php?target=$@ -O $@ -altergo: ${ALTERGO}.tar.gz ocamlgraph zarith - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${ALTERGO} - tar zxf ${ALTERGO}.tar.gz - ./Patcher.sh ${ALTERGO} - ( cd ${ALTERGO} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ./configure -prefix ${PREFIX} && \ - ${MAKE} && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${ALTERGO} altergo -distclean:: - rm -f ${ALTERGO}.tar.gz -all: altergo - -# http://www.seas.upenn.edu/~harmony/ -BOOMERANG=boomerang-0.2 -${BOOMERANG}-source.tar.gz: - ${WGET} http://www.seas.upenn.edu/~harmony/download/$@ -boomerang: ${BOOMERANG}-source.tar.gz omake - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${BOOMERANG} - tar zxf ${BOOMERANG}-source.tar.gz && mv boomerang-20090902 ${BOOMERANG} - ./Patcher.sh ${BOOMERANG} - ( cd ${BOOMERANG} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - omake ) - echo ${VERSION} >$@ -clean:: - rm -rf ${BOOMERANG} boomerang -distclean:: - rm -f ${BOOMERANG}-source.tar.gz -all: boomerang - -# https://github.com/yoriyuki/Camomile/wiki -CAMOMILE=camomile-0.8.4 -${CAMOMILE}.tar.bz2: - ${WGET} https://github.com/downloads/yoriyuki/Camomile/$@ -camomile: ${CAMOMILE}.tar.bz2 camlp4 - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${CAMOMILE} - tar xf ${CAMOMILE}.tar.bz2 - ./Patcher.sh ${CAMOMILE} - ( cd ${CAMOMILE} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ./configure -prefix ${PREFIX} && \ - ${MAKE} && \ - ocamlfind remove camomile && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${CAMOMILE} camomile -distclean:: - rm -f ${CAMOMILE}.tar.bz2 -all: camomile - -# http://sanskrit.inria.fr/ZEN/ -ZEN=zen_2.3.2 -${ZEN}.tar.gz: - ${WGET} http://sanskrit.inria.fr/ZEN/$@ -zen: ${ZEN}.tar.gz camlp4 - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${ZEN} - tar zxf ${ZEN}.tar.gz && mv ZEN_* ${ZEN} - ./Patcher.sh ${ZEN} - ( cd ${ZEN} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ${MAKE} depend && \ - ${MAKE} all && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${ZEN} zen -distclean:: - rm -f ${ZEN}.tar.gz -all: zen - -# http://users-tima.imag.fr/vds/ouchet/index_fichiers/vsyml.html -VSYML=vsyml-2010-04-06 -${VSYML}.tar.gz: - ${WGET} http://users-tima.imag.fr/vds/ouchet/vsyml/$@ -vsyml: ${VSYML}.tar.gz - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${VSYML} - tar zxf ${VSYML}.tar.gz - ./Patcher.sh ${VSYML} - ( cd ${VSYML} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ${MAKE} ) - echo ${VERSION} >$@ -clean:: - rm -rf ${VSYML} vsyml -distclean:: - rm -f ${VSYML}.tar.gz -all: vsyml - -# http://projects.camlcity.org/projects/ocamlnet.html -OCAMLNET=ocamlnet-3.5.1 -${OCAMLNET}.tar.gz: - ${WGET} http://download.camlcity.org/download/$@ -ocamlnet: ${OCAMLNET}.tar.gz findlib pcre camlp4 ocamlssl camlzip cryptokit - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${OCAMLNET} - tar zxf ${OCAMLNET}.tar.gz - ./Patcher.sh ${OCAMLNET} - ( cd ${OCAMLNET} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ./configure && \ - ${MAKE} all && \ - ${MAKE} opt && \ - ocamlfind remove netsys && \ - ocamlfind remove netshm && \ - ocamlfind remove netstring && \ - ocamlfind remove equeue && \ - ocamlfind remove shell && \ - ocamlfind remove rpc-generator && \ - ocamlfind remove rpc-auth-local && \ - ocamlfind remove rpc && \ - ocamlfind remove pop && \ - ocamlfind remove smtp && \ - ocamlfind remove netclient && \ - ocamlfind remove netcgi2 && \ - ocamlfind remove netplex && \ - ocamlfind remove netcgi2-plex && \ - ocamlfind remove netcamlbox && \ - ocamlfind remove netmulticore && \ - ocamlfind remove netgssapi && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${OCAMLNET} ocamlnet -distclean:: - rm -f ${OCAMLNET}.tar.gz -all: ocamlnet - -# http://zoggy.github.io/ocamlrss/ -RSS=ocamlrss-2.2.2 -${RSS}.tar.gz: - ${WGET} http://zoggy.github.io/ocamlrss/$@ -rss: ${RSS}.tar.gz xmlm ocamlnet - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${RSS} - tar zxf ${RSS}.tar.gz - ./Patcher.sh ${RSS} - ( cd ${RSS} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ${MAKE} all && \ - ocamlfind remove ocaml-rss && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${RSS} rss -distclean:: - rm -f ${RSS}.tar.gz -all: rss - -# http://code.google.com/p/ocaml-extlib/ -EXTLIB=extlib-1.5.2 -${EXTLIB}.tar.gz: - ${WGET} http://ocaml-extlib.googlecode.com/files/$@ -extlib: ${EXTLIB}.tar.gz - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${EXTLIB} - tar zxf ${EXTLIB}.tar.gz - ./Patcher.sh ${EXTLIB} - ( cd ${EXTLIB} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocamlfind remove extlib && \ - ocaml install.ml -b -n -doc ) - echo ${VERSION} >$@ -clean:: - rm -rf ${EXTLIB} extlib -distclean:: - rm -f ${EXTLIB}.tar.gz -all: extlib - -# http://forge.ocamlcore.org/projects/ocaml-fileutils -FILEUTILS=ocaml-fileutils-0.4.4 -${FILEUTILS}.tar.gz: - ${WGET} http://forge.ocamlcore.org/frs/download.php/892/$@ -xxfileutils: ${FILEUTILS}.tar.gz findlib ounit - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${FILEUTILS} - tar xf ${FILEUTILS}.tar.gz - ./Patcher.sh ${FILEUTILS} - ( cd ${FILEUTILS} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure --prefix ${PREFIX} && \ - ${MAKE} && \ - ocamlfind remove fileutils && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${FILEUTILS} fileutils -distclean:: - rm -f ${FILEUTILS}.tar.gz -all: fileutils - -# http://forge.ocamlcore.org/projects/odn -ODN=ocaml-data-notation-0.0.10 -${ODN}.tar.gz: - ${WGET} http://forge.ocamlcore.org/frs/download.php/1029/$@ -odn: ${ODN}.tar.gz findlib core ounit fileutils - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${ODN} - tar zxf ${ODN}.tar.gz - ./Patcher.sh ${ODN} oasis-common.patch - ( cd ${ODN} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure && \ - ocaml setup.ml -build && \ - ocamlfind remove odn && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${ODN} odn -distclean:: - rm -f ${ODN}.tar.gz -all: odn - -# http://forge.ocamlcore.org/projects/ocamlify -OCAMLIFY=ocamlify-0.0.1 -${OCAMLIFY}.tar.gz: - ${WGET} http://forge.ocamlcore.org/frs/download.php/379/$@ -ocamlify: ${OCAMLIFY}.tar.gz findlib - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${OCAMLIFY} - tar zxf ${OCAMLIFY}.tar.gz - ./Patcher.sh ${OCAMLIFY} oasis-common.patch - ( cd ${OCAMLIFY} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure --prefix ${PREFIX} && \ - ocaml setup.ml -build && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${OCAMLIFY} ocamlify -distclean:: - rm -f ${OCAMLIFY}.tar.gz -all: ocamlify - -# http://forge.ocamlcore.org/projects/ocaml-expect -EXPECT=ocaml-expect-0.0.3 -${EXPECT}.tar.gz: - ${WGET} http://forge.ocamlcore.org/frs/download.php/894/$@ -expect: ${EXPECT}.tar.gz findlib extlib pcre ounit - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${EXPECT} - tar zxf ${EXPECT}.tar.gz - ./Patcher.sh ${EXPECT} oasis-common.patch - ( cd ${EXPECT} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure && \ - ocaml setup.ml -build && \ - ocamlfind remove expect && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${EXPECT} expect -distclean:: - rm -f ${EXPECT}.tar.gz -all: expect - -# http://forge.ocamlcore.org/projects/ocamlmod/ -OCAMLMOD=ocamlmod-0.0.3 -${OCAMLMOD}.tar.gz: - ${WGET} http://forge.ocamlcore.org/frs/download.php/856/$@ -ocamlmod: ${OCAMLMOD}.tar.gz findlib fileutils pcre - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${OCAMLMOD} - tar zxf ${OCAMLMOD}.tar.gz - ./Patcher.sh ${OCAMLMOD} - ( cd ${OCAMLMOD} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure --prefix ${PREFIX} && \ - ${MAKE} && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${OCAMLMOD} ocamlmod -distclean:: - rm -f ${OCAMLMOD}.tar.gz -all: ocamlmod - -# http://forge.ocamlcore.org/projects/oasis -OASIS=oasis-0.3.0 -${OASIS}.tar.gz: - ${WGET} http://forge.ocamlcore.org/frs/download.php/918/$@ -oasis: ${OASIS}.tar.gz findlib fileutils pcre extlib odn ocamlgraph ocamlify \ - ounit expect ocamlmod - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${OASIS} - tar zxf ${OASIS}.tar.gz - ./Patcher.sh ${OASIS} oasis-common.patch - ( cd ${OASIS} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure --prefix ${PREFIX} && \ - ocaml setup.ml -build && \ - ocamlfind remove oasis && \ - ocamlfind remove userconf && \ - ocamlfind remove plugin-loader && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${OASIS} oasis -distclean:: - rm -f ${OASIS}.tar.gz -all: oasis - -# http://calendar.forge.ocamlcore.org/ -CALENDAR=calendar-2.03.2 -${CALENDAR}.tar.gz: - ${WGET} https://forge.ocamlcore.org/frs/download.php/915/$@ -calendar: ${CALENDAR}.tar.gz - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${CALENDAR} - tar zxf ${CALENDAR}.tar.gz - ./Patcher.sh ${CALENDAR} - ( cd ${CALENDAR} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure --prefix ${PREFIX} && \ - ${MAKE} && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${CALENDAR} calendar -distclean:: - rm -f ${CALENDAR}.tar.gz -all: calendar - -# http://gallium.inria.fr/camlimages/ -CAMLIMAGES=camlimages-4.0.1 -${CAMLIMAGES}.tar.gz: - ${WGET} https://bitbucket.org/camlspotter/camlimages/get/v4.0.1.tar.gz - mv v4.0.1.tar.gz $@ -xxcamlimages: ${CAMLIMAGES}.tar.gz findlib omake lablgtk - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${CAMLIMAGES} - tar xf ${CAMLIMAGES}.tar.gz - mv camlspotter-camlimages-c803efa9d5d3 ${CAMLIMAGES} - mv ${CAMLIMAGES}/doc/old/* ${CAMLIMAGES}/doc/ - ./Patcher.sh ${CAMLIMAGES} - ( cd ${CAMLIMAGES} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - omake && \ - ocamlfind remove camlimages && \ - omake install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${CAMLIMAGES} camlimages -distclean:: - rm -f ${CAMLIMAGES}.tar.gz -all: camlimages - -# http://advi.inria.fr/ -ADVI=advi-1.10.2 -${ADVI}.tar.gz: - ${WGET} http://advi.inria.fr/$@ -advi: ${ADVI}.tar.gz findlib camlimages - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${ADVI} - tar zxf ${ADVI}.tar.gz - ./Patcher.sh ${ADVI} - ( cd ${ADVI} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure --prefix ${PREFIX} && \ - ${MAKE} && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${ADVI} advi -distclean:: - rm -f ${ADVI}.tar.gz -all: advi - -# http://forge.ocamlcore.org/projects/camldbm -DBM=camldbm-1.0 -${DBM}.tgz: - ${WGET} http://forge.ocamlcore.org/frs/download.php/728/$@ -dbm: ${DBM}.tgz - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${DBM} - tar zxf ${DBM}.tgz - ./Patcher.sh ${DBM} - ( cd ${DBM} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure --prefix ${PREFIX} && \ - ${MAKE} && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${DBM} dbm -distclean:: - rm -f ${DBM}.tgz -all: dbm - -# http://ocsigen.org/ -OCSIGEN=ocsigen-bundle-2.2.2 -${OCSIGEN}.tar.gz: - ${WGET} http://ocsigen.org/download/$@ -ocsigen: ${OCSIGEN}.tar.gz findlib lwt pcre ocamlnet ocamlssl \ - sqlite camlzip cryptokit calendar dbm - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${OCSIGEN} - tar zxf ${OCSIGEN}.tar.gz - ./Patcher.sh ${OCSIGEN} - ( cd ${OCSIGEN} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - export OCSIGEN_USER=${USER}; export OCSIGEN_GROUP=everyone && \ - ./configure --prefix=${PREFIX} && \ - ${MAKE} && \ - rm -rf ${PREFIX}/lib/ocaml/ocsigenserver/extensions && \ - ocamlfind remove -destdir ${PREFIX}/lib/ocaml deriving-ocsigen && \ - ocamlfind remove -destdir ${PREFIX}/lib/ocaml js_of_ocaml && \ - ocamlfind remove -destdir ${PREFIX}/lib/ocaml ocsigenserver && \ - ocamlfind remove -destdir ${PREFIX}/lib/ocaml tyxml && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${OCSIGEN} ocsigen -distclean:: - rm -f ${OCSIGEN}.tar.gz -all: ocsigen - -# http://mldonkey.sourceforge.net/ -MLDONKEY=mldonkey-3.1.2 -${MLDONKEY}.tar.bz2: - ${WGET} http://freefr.dl.sourceforge.net/project/mldonkey/mldonkey/3.1.2/$@ -mldonkey: ${MLDONKEY}.tar.bz2 lablgtk - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${MLDONKEY} - tar zxf ${MLDONKEY}.tar.bz2 - ./Patcher.sh ${MLDONKEY} - ( cd ${MLDONKEY} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure && \ - ${MAKE} ) - echo ${VERSION} >$@ -clean:: - rm -rf ${MLDONKEY} mldonkey -distclean:: - rm -f ${MLDONKEY}.tar.bz2 -all: mldonkey - -# http://mjambon.com/releases/ocamlscript -OCAMLSCRIPT=ocamlscript-2.0.3 -${OCAMLSCRIPT}.tar.gz: - ${WGET} http://mjambon.com/releases/ocamlscript/$@ -ocamlscript: ${OCAMLSCRIPT}.tar.gz findlib camlp4 - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${OCAMLSCRIPT} - tar xf ${OCAMLSCRIPT}.tar.gz - ./Patcher.sh ${OCAMLSCRIPT} - ( cd ${OCAMLSCRIPT} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ${MAKE} && \ - ocamlfind remove ocamlscript && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${OCAMLSCRIPT} ocamlscript -distclean:: - rm -f ${OCAMLSCRIPT}.tar.bz2 -all: ocamlscript - -# https://forge.ocamlcore.org/projects/kaputt/ -KAPUTT=kaputt-1.2 -${KAPUTT}.tar.gz: - ${WGET} https://forge.ocamlcore.org/frs/download.php/987/$@ -kaputt: ${KAPUTT}.tar.gz findlib - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${KAPUTT} - tar zxf ${KAPUTT}.tar.gz - ./Patcher.sh ${KAPUTT} - ( cd ${KAPUTT} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure -ocaml-prefix ${PREFIX} && \ - ${MAKE} all && \ - ocamlfind remove kaputt && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${KAPUTT} kaputt -distclean:: - rm -f ${KAPUTT}.tar.gz -all: kaputt - -# http://www.coherentpdf.com/ocaml-libraries.html -CAMLPDF=camlpdf-0.5 -${CAMLPDF}.tar.bz2: - ${WGET} http://www.coherentpdf.com/$@ -camlpdf: ${CAMLPDF}.tar.bz2 - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${CAMLPDF} - tar zxf ${CAMLPDF}.tar.bz2 - ./Patcher.sh ${CAMLPDF} - ( cd ${CAMLPDF} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ${MAKE} all && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${CAMLPDF} camlpdf -distclean:: - rm -f ${CAMLPDF}.tar.gz -all: camlpdf - -# https://forge.ocamlcore.org/projects/csv -CSV=csv-1.3.1 -${CSV}.tar.gz: - ${WGET} https://forge.ocamlcore.org/frs/download.php/1235/$@ -csv: ${CSV}.tar.gz findlib - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${CSV} - tar zxf ${CSV}.tar.gz - ./Patcher.sh ${CSV} - ( cd ${CSV} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ocaml setup.ml -configure --enable-tests --prefix ${PREFIX} && \ - ocaml setup.ml -build && \ - ocamlfind remove csv && \ - ocaml setup.ml -install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${CSV} csv -distclean:: - rm -f ${CSV}.tar.gz -all: csv - -# http://pauillac.inria.fr/~ddr/camlp5/ -CAMLP5=camlp5-git -camlp5: - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${CAMLP5} - git clone git://scm.gforge.inria.fr/camlp5/camlp5.git ${CAMLP5} - ./Patcher.sh ${CAMLP5} - ( cd ${CAMLP5} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ./configure --transitional && \ - ${MAKE} world.opt && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${CAMLP5} camlp5 -distclean:: - rm -f ${CAMLP5}-git -all: camlp5 - -disabled: depends on camlp5 -# http://opensource.geneanet.org/projects/geneweb -GENEWEB=gw-6.05-src -${GENEWEB}.tgz: - ${WGET} http://opensource.geneanet.org/attachments/download/190/$@ -geneweb: ${GENEWEB}.tgz camlp5 - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${GENEWEB} - tar zxf ${GENEWEB}.tgz - ./Patcher.sh ${GENEWEB} - ( cd ${GENEWEB} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure && \ - ${MAKE} ) - echo ${VERSION} >$@ -clean:: - rm -rf ${GENEWEB} geneweb -distclean:: - rm -f ${GENEWEB}.tgz -all: geneweb - -# http://coq.inria.fr/download -COQ=coq-8.4pl2 -${COQ}.tar.gz: - ${WGET} http://coq.inria.fr/distrib/V8.4pl2/files/$@ -coq: ${COQ}.tar.gz camlp5 - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${COQ} - tar zxf ${COQ}.tar.gz - ./Patcher.sh ${COQ} - ( cd ${COQ} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ./configure -prefix ${PREFIX} -with-doc no && \ - ${MAKE} world && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${COQ} coq -distclean:: - rm -f ${COQ}.tar.gz -all: coq - -# http://code.google.com/p/bitstring/ - -BITSTRING=ocaml-bitstring-2.0.3 -${BITSTRING}.tar.gz: - ${WGET} http://bitstring.googlecode.com/files/$@ -bitstring: ${BITSTRING}.tar.gz findlib # cil FIXME ? - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${BITSTRING} - tar zxf ${BITSTRING}.tar.gz - ./Patcher.sh ${BITSTRING} - ( cd ${BITSTRING} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure --prefix ${PREFIX} && \ - ${MAKE} && \ - ${MAKE} check && \ - ${MAKE} examples && \ - ocamlfind remove bitstring && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${BITSTRING} bitstring -distclean:: - rm -f ${BITSTRING}.tar.gz -all: bitstring - -# http://compcert.inria.fr -COMPCERT=compcert-1.13 -${COMPCERT}.tgz: - ${WGET} http://compcert.inria.fr/release/$@ -compcert: ${COMPCERT}.tgz coq bitstring - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${COMPCERT} - tar zxf ${COMPCERT}.tgz - ./Patcher.sh ${COMPCERT} - ( cd ${COMPCERT} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure -prefix ${PREFIX} ppc-linux && \ - ${MAKE} all && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${COMPCERT} compcert -distclean:: - rm -f ${COMPCERT}.tgz -all: compcert - -# http://frama-c.com/ -FRAMAC=frama-c-Oxygen-20120901 -${FRAMAC}.tar.gz: - ${WGET} http://frama-c.com/download/$@ -framac: ${FRAMAC}.tar.gz - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${FRAMAC} - tar zxf ${FRAMAC}.tar.gz - ./Patcher.sh ${FRAMAC} - ( cd ${FRAMAC} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - ./configure --enable-verbosemake --prefix ${PREFIX} && \ - ${MAKE} && \ - ${MAKE} oracles && \ - ${MAKE} install ) - echo ${VERSION} >$@ -clean:: - rm -rf ${FRAMAC} framac -distclean:: - rm -f ${FRAMAC}.tar.gz -all: framac - -################################################################## -### Template for new entries -################################################################## - -FOO= -${FOO}.tar.gz: - ${WGET} http://foo.bar.com/.../$@ -foo: ${FOO}.tar.gz - printf "%s " "$@" >/dev/tty - test -d ${PREFIX} - rm -rf ${FOO} - tar zxf ${FOO}.tar.gz - ./Patcher.sh ${FOO} - ( cd ${FOO} && \ - export PATH=${PREFIX}/bin:$$PATH && \ - sh ./configure --prefix ${PREFIX} && \ - ${MAKE} && \ - ocamlfind remove foo && \ - ${MAKE} install ) - echo ${VERSION} >$@ -xxclean:: - rm -rf ${FOO} foo -xxdistclean:: - rm -f ${FOO}.tar.gz -xxall: foo - -################################################################## - -.PHONY: clean - -.PHONY: distclean -distclean:: - ${MAKE} clean - -.PHONY: all -all: - echo >/dev/tty diff --git a/testsuite/external/TODO.txt b/testsuite/external/TODO.txt deleted file mode 100644 index 18a5460ed0..0000000000 --- a/testsuite/external/TODO.txt +++ /dev/null @@ -1,26 +0,0 @@ -TODO: -Understand why ocamlnet does not detect lablgtk, ocamlssl, camlzip, cryptokit - -TODO: cryptogps -http://www.ocaml-programming.de/packages -and make ocamlnet depend on it - -# TODO: lablgl -# http://wwwfun.kurims.kyoto-u.ac.jp/soft/lsl/lablgl.html - -Haxe: missing a source archive of released version... -# # http://code.google.com/p/haxe/source/browse/#svn%2Ftrunk -# HAXE=haxe-2.10dev -# haxe: -# printf "%s " "$@" >/dev/tty -# test -d ${PREFIX} -# rm -rf ${HAXE} -# tar zxf ${HAXE}.tar.gz -# ./Patcher.sh ${HAXE} -# ( cd ${HAXE} && \ -# export PATH=${PREFIX}/bin:$$PATH && \ -# make ) -# echo ${VERSION} >$@ -# clean:: -# rm -rf ${HAXE} haxe -# all: haxe diff --git a/testsuite/external/boomerang-0.2.patch b/testsuite/external/boomerang-0.2.patch deleted file mode 100644 index 0bb8eb3702..0000000000 --- a/testsuite/external/boomerang-0.2.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- boomerang-0.2/OMakefile.orig 2010-06-07 15:01:55.000000000 +0200 -+++ boomerang-0.2/OMakefile 2010-06-07 15:02:08.000000000 +0200 -@@ -126,7 +126,7 @@ - ############################################################################## - # Include sub-directories - --SUBDIRS = common src lenses examples doc -+SUBDIRS = common src lenses examples #doc - - .SUBDIRS: $(SUBDIRS) - diff --git a/testsuite/external/camlimages-4.0.1.patch b/testsuite/external/camlimages-4.0.1.patch deleted file mode 100644 index ff2f93e50b..0000000000 --- a/testsuite/external/camlimages-4.0.1.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- camlimages-4.0.1.orig/OMakefile 2011-06-22 20:04:32.000000000 +0200 -+++ camlimages-4.0.1/OMakefile 2013-02-19 15:35:38.000000000 +0100 -@@ -138,7 +138,7 @@ - SUPPORTED_FORMATS+=jpeg - export - -- HAVE_TIFF = $(Check_header_library tiff, tiff.h, TIFFOpen) -+ HAVE_TIFF = false # $(Check_header_library tiff, tiff.h, TIFFOpen) - SUPPORT_TIFF = $(and $(HAVE_Z) $(HAVE_JPEG) $(HAVE_TIFF)) - LDFLAGS_tiff= - if $(SUPPORT_TIFF) diff --git a/testsuite/external/camlp5-6.06.patch b/testsuite/external/camlp5-6.06.patch deleted file mode 100644 index 8b7e58a380..0000000000 --- a/testsuite/external/camlp5-6.06.patch +++ /dev/null @@ -1,2243 +0,0 @@ -diff -r -u -N camlp5-6.06.orig/ocaml_src/lib/versdep/4.00.1.ml camlp5-6.06/ocaml_src/lib/versdep/4.00.1.ml ---- camlp5-6.06.orig/ocaml_src/lib/versdep/4.00.1.ml 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_src/lib/versdep/4.00.1.ml 2012-07-31 16:52:22.000000000 +0200 -@@ -0,0 +1,465 @@ -+(* camlp5r pa_macro.cmo *) -+(* File generated by program: edit only if it does not compile. *) -+(* Copyright (c) INRIA 2007-2012 *) -+ -+open Parsetree;; -+open Longident;; -+open Asttypes;; -+ -+type ('a, 'b) choice = -+ Left of 'a -+ | Right of 'b -+;; -+ -+let sys_ocaml_version = Sys.ocaml_version;; -+ -+let ocaml_location (fname, lnum, bolp, lnuml, bolpl, bp, ep) = -+ let loc_at n lnum bolp = -+ {Lexing.pos_fname = if lnum = -1 then "" else fname; -+ Lexing.pos_lnum = lnum; Lexing.pos_bol = bolp; Lexing.pos_cnum = n} -+ in -+ {Location.loc_start = loc_at bp lnum bolp; -+ Location.loc_end = loc_at ep lnuml bolpl; -+ Location.loc_ghost = bp = 0 && ep = 0} -+;; -+ -+let loc_none = -+ let loc = -+ {Lexing.pos_fname = "_none_"; Lexing.pos_lnum = 1; Lexing.pos_bol = 0; -+ Lexing.pos_cnum = -1} -+ in -+ {Location.loc_start = loc; Location.loc_end = loc; -+ Location.loc_ghost = true} -+;; -+ -+let mkloc loc txt = {Location.txt = txt; Location.loc = loc};; -+let mknoloc txt = mkloc loc_none txt;; -+ -+let ocaml_id_or_li_of_string_list loc sl = -+ let mkli s = -+ let rec loop f = -+ function -+ i :: il -> loop (fun s -> Ldot (f i, s)) il -+ | [] -> f s -+ in -+ loop (fun s -> Lident s) -+ in -+ match List.rev sl with -+ [] -> None -+ | s :: sl -> Some (mkli s (List.rev sl)) -+;; -+ -+let list_map_check f l = -+ let rec loop rev_l = -+ function -+ x :: l -> -+ begin match f x with -+ Some s -> loop (s :: rev_l) l -+ | None -> None -+ end -+ | [] -> Some (List.rev rev_l) -+ in -+ loop [] l -+;; -+ -+let ocaml_value_description t p = -+ {pval_type = t; pval_prim = p; pval_loc = t.ptyp_loc} -+;; -+ -+let ocaml_class_type_field loc ctfd = {pctf_desc = ctfd; pctf_loc = loc};; -+ -+let ocaml_class_field loc cfd = {pcf_desc = cfd; pcf_loc = loc};; -+ -+let ocaml_type_declaration params cl tk pf tm loc variance = -+ match list_map_check (fun s_opt -> s_opt) params with -+ Some params -> -+ let params = List.map (fun os -> Some (mknoloc os)) params in -+ Right -+ {ptype_params = params; ptype_cstrs = cl; ptype_kind = tk; -+ ptype_private = pf; ptype_manifest = tm; ptype_loc = loc; -+ ptype_variance = variance} -+ | None -> Left "no '_' type param in this ocaml version" -+;; -+ -+let ocaml_class_type = Some (fun d loc -> {pcty_desc = d; pcty_loc = loc});; -+ -+let ocaml_class_expr = Some (fun d loc -> {pcl_desc = d; pcl_loc = loc});; -+ -+let ocaml_class_structure p cil = {pcstr_pat = p; pcstr_fields = cil};; -+ -+let ocaml_pmty_ident loc li = Pmty_ident (mkloc loc li);; -+ -+let ocaml_pmty_functor sloc s mt1 mt2 = -+ Pmty_functor (mkloc sloc s, mt1, mt2) -+;; -+ -+let ocaml_pmty_typeof = Some (fun me -> Pmty_typeof me);; -+ -+let ocaml_pmty_with mt lcl = -+ let lcl = List.map (fun (s, c) -> mknoloc s, c) lcl in Pmty_with (mt, lcl) -+;; -+ -+let ocaml_ptype_abstract = Ptype_abstract;; -+ -+let ocaml_ptype_record ltl priv = -+ Ptype_record -+ (List.map (fun (s, mf, ct, loc) -> mkloc loc s, mf, ct, loc) ltl) -+;; -+ -+let ocaml_ptype_variant ctl priv = -+ try -+ let ctl = -+ List.map -+ (fun (c, tl, rto, loc) -> -+ if rto <> None then raise Exit else mknoloc c, tl, None, loc) -+ ctl -+ in -+ Some (Ptype_variant ctl) -+ with Exit -> None -+;; -+ -+let ocaml_ptyp_arrow lab t1 t2 = Ptyp_arrow (lab, t1, t2);; -+ -+let ocaml_ptyp_class li tl ll = Ptyp_class (mknoloc li, tl, ll);; -+ -+let ocaml_ptyp_constr li tl = Ptyp_constr (mknoloc li, tl);; -+ -+let ocaml_ptyp_package = Some (fun pt -> Ptyp_package pt);; -+ -+let ocaml_ptyp_poly = Some (fun cl t -> Ptyp_poly (cl, t));; -+ -+let ocaml_ptyp_variant catl clos sl_opt = -+ let catl = -+ List.map -+ (function -+ Left (c, a, tl) -> Rtag (c, a, tl) -+ | Right t -> Rinherit t) -+ catl -+ in -+ Some (Ptyp_variant (catl, clos, sl_opt)) -+;; -+ -+let ocaml_package_type li ltl = -+ mknoloc li, List.map (fun (li, t) -> mkloc t.ptyp_loc li, t) ltl -+;; -+ -+let ocaml_const_int32 = Some (fun s -> Const_int32 (Int32.of_string s));; -+ -+let ocaml_const_int64 = Some (fun s -> Const_int64 (Int64.of_string s));; -+ -+let ocaml_const_nativeint = -+ Some (fun s -> Const_nativeint (Nativeint.of_string s)) -+;; -+ -+let ocaml_pexp_apply f lel = Pexp_apply (f, lel);; -+ -+let ocaml_pexp_assertfalse fname loc = Pexp_assertfalse;; -+ -+let ocaml_pexp_assert fname loc e = Pexp_assert e;; -+ -+let ocaml_pexp_construct li po chk_arity = -+ Pexp_construct (mknoloc li, po, chk_arity) -+;; -+ -+let ocaml_pexp_field e li = Pexp_field (e, mknoloc li);; -+ -+let ocaml_pexp_for i e1 e2 df e = Pexp_for (mknoloc i, e1, e2, df, e);; -+ -+let ocaml_pexp_function lab eo pel = Pexp_function (lab, eo, pel);; -+ -+let ocaml_pexp_lazy = Some (fun e -> Pexp_lazy e);; -+ -+let ocaml_pexp_ident li = Pexp_ident (mknoloc li);; -+ -+let ocaml_pexp_letmodule = -+ Some (fun i me e -> Pexp_letmodule (mknoloc i, me, e)) -+;; -+ -+let ocaml_pexp_new loc li = Pexp_new (mkloc loc li);; -+ -+let ocaml_pexp_newtype = Some (fun s e -> Pexp_newtype (s, e));; -+ -+let ocaml_pexp_object = Some (fun cs -> Pexp_object cs);; -+ -+let ocaml_pexp_open = Some (fun li e -> Pexp_open (mknoloc li, e));; -+ -+let ocaml_pexp_override sel = -+ let sel = List.map (fun (s, e) -> mknoloc s, e) sel in Pexp_override sel -+;; -+ -+let ocaml_pexp_pack : ('a -> 'b -> 'c, 'd) choice option = -+ Some (Right ((fun me -> Pexp_pack me), (fun pt -> Ptyp_package pt))) -+;; -+ -+let ocaml_pexp_poly = Some (fun e t -> Pexp_poly (e, t));; -+ -+let ocaml_pexp_record lel eo = -+ let lel = List.map (fun (li, loc, e) -> mkloc loc li, e) lel in -+ Pexp_record (lel, eo) -+;; -+ -+let ocaml_pexp_setinstvar s e = Pexp_setinstvar (mknoloc s, e);; -+ -+let ocaml_pexp_variant = -+ let pexp_variant_pat = -+ function -+ Pexp_variant (lab, eo) -> Some (lab, eo) -+ | _ -> None -+ in -+ let pexp_variant (lab, eo) = Pexp_variant (lab, eo) in -+ Some (pexp_variant_pat, pexp_variant) -+;; -+ -+let ocaml_ppat_alias p i iloc = Ppat_alias (p, mkloc iloc i);; -+ -+let ocaml_ppat_array = Some (fun pl -> Ppat_array pl);; -+ -+let ocaml_ppat_construct li li_loc po chk_arity = -+ Ppat_construct (mkloc li_loc li, po, chk_arity) -+;; -+ -+let ocaml_ppat_construct_args = -+ function -+ Ppat_construct (li, po, chk_arity) -> Some (li.txt, li.loc, po, chk_arity) -+ | _ -> None -+;; -+ -+let ocaml_ppat_lazy = Some (fun p -> Ppat_lazy p);; -+ -+let ocaml_ppat_record lpl is_closed = -+ let lpl = List.map (fun (li, loc, p) -> mkloc loc li, p) lpl in -+ Ppat_record (lpl, (if is_closed then Closed else Open)) -+;; -+ -+let ocaml_ppat_type = Some (fun loc li -> Ppat_type (mkloc loc li));; -+ -+let ocaml_ppat_unpack = -+ Some ((fun loc s -> Ppat_unpack (mkloc loc s)), (fun pt -> Ptyp_package pt)) -+;; -+ -+let ocaml_ppat_var loc s = Ppat_var (mkloc loc s);; -+ -+let ocaml_ppat_variant = -+ let ppat_variant_pat = -+ function -+ Ppat_variant (lab, po) -> Some (lab, po) -+ | _ -> None -+ in -+ let ppat_variant (lab, po) = Ppat_variant (lab, po) in -+ Some (ppat_variant_pat, ppat_variant) -+;; -+ -+let ocaml_psig_class_type = Some (fun ctl -> Psig_class_type ctl);; -+ -+let ocaml_psig_exception s ed = Psig_exception (mknoloc s, ed);; -+ -+let ocaml_psig_module s mt = Psig_module (mknoloc s, mt);; -+ -+let ocaml_psig_modtype s mtd = Psig_modtype (mknoloc s, mtd);; -+ -+let ocaml_psig_open li = Psig_open (mknoloc li);; -+ -+let ocaml_psig_recmodule = -+ let f ntl = -+ let ntl = List.map (fun (s, mt) -> mknoloc s, mt) ntl in -+ Psig_recmodule ntl -+ in -+ Some f -+;; -+ -+let ocaml_psig_type stl = -+ let stl = List.map (fun (s, t) -> mknoloc s, t) stl in Psig_type stl -+;; -+ -+let ocaml_psig_value s vd = Psig_value (mknoloc s, vd);; -+ -+let ocaml_pstr_class_type = Some (fun ctl -> Pstr_class_type ctl);; -+ -+let ocaml_pstr_exception s ed = Pstr_exception (mknoloc s, ed);; -+ -+let ocaml_pstr_exn_rebind = -+ Some (fun s li -> Pstr_exn_rebind (mknoloc s, mknoloc li)) -+;; -+ -+let ocaml_pstr_include = Some (fun me -> Pstr_include me);; -+ -+let ocaml_pstr_modtype s mt = Pstr_modtype (mknoloc s, mt);; -+ -+let ocaml_pstr_module s me = Pstr_module (mknoloc s, me);; -+ -+let ocaml_pstr_open li = Pstr_open (mknoloc li);; -+ -+let ocaml_pstr_primitive s vd = Pstr_primitive (mknoloc s, vd);; -+ -+let ocaml_pstr_recmodule = -+ let f nel = -+ Pstr_recmodule (List.map (fun (s, mt, me) -> mknoloc s, mt, me) nel) -+ in -+ Some f -+;; -+ -+let ocaml_pstr_type stl = -+ let stl = List.map (fun (s, t) -> mknoloc s, t) stl in Pstr_type stl -+;; -+ -+let ocaml_class_infos = -+ Some -+ (fun virt (sl, sloc) name expr loc variance -> -+ let params = List.map (fun s -> mkloc loc s) sl, sloc in -+ {pci_virt = virt; pci_params = params; pci_name = mkloc loc name; -+ pci_expr = expr; pci_loc = loc; pci_variance = variance}) -+;; -+ -+let ocaml_pmod_ident li = Pmod_ident (mknoloc li);; -+ -+let ocaml_pmod_functor s mt me = Pmod_functor (mknoloc s, mt, me);; -+ -+let ocaml_pmod_unpack : ('a -> 'b -> 'c, 'd) choice option = -+ Some (Right ((fun e -> Pmod_unpack e), (fun pt -> Ptyp_package pt))) -+;; -+ -+let ocaml_pcf_cstr = Some (fun (t1, t2, loc) -> Pcf_constr (t1, t2));; -+ -+let ocaml_pcf_inher ce pb = Pcf_inher (Fresh, ce, pb);; -+ -+let ocaml_pcf_init = Some (fun e -> Pcf_init e);; -+ -+let ocaml_pcf_meth (s, pf, ovf, e, loc) = -+ let pf = if pf then Private else Public in -+ let ovf = if ovf then Override else Fresh in -+ Pcf_meth (mkloc loc s, pf, ovf, e) -+;; -+ -+let ocaml_pcf_val (s, mf, ovf, e, loc) = -+ let mf = if mf then Mutable else Immutable in -+ let ovf = if ovf then Override else Fresh in -+ Pcf_val (mkloc loc s, mf, ovf, e) -+;; -+ -+let ocaml_pcf_valvirt = -+ let ocaml_pcf (s, mf, t, loc) = -+ let mf = if mf then Mutable else Immutable in -+ Pcf_valvirt (mkloc loc s, mf, t) -+ in -+ Some ocaml_pcf -+;; -+ -+let ocaml_pcf_virt (s, pf, t, loc) = Pcf_virt (mkloc loc s, pf, t);; -+ -+let ocaml_pcl_apply = Some (fun ce lel -> Pcl_apply (ce, lel));; -+ -+let ocaml_pcl_constr = Some (fun li ctl -> Pcl_constr (mknoloc li, ctl));; -+ -+let ocaml_pcl_constraint = Some (fun ce ct -> Pcl_constraint (ce, ct));; -+ -+let ocaml_pcl_fun = Some (fun lab ceo p ce -> Pcl_fun (lab, ceo, p, ce));; -+ -+let ocaml_pcl_let = Some (fun rf pel ce -> Pcl_let (rf, pel, ce));; -+ -+let ocaml_pcl_structure = Some (fun cs -> Pcl_structure cs);; -+ -+let ocaml_pctf_cstr = Some (fun (t1, t2, loc) -> Pctf_cstr (t1, t2));; -+ -+let ocaml_pctf_meth (s, pf, t, loc) = Pctf_meth (s, pf, t);; -+ -+let ocaml_pctf_val (s, mf, t, loc) = Pctf_val (s, mf, Concrete, t);; -+ -+let ocaml_pctf_virt (s, pf, t, loc) = Pctf_virt (s, pf, t);; -+ -+let ocaml_pcty_constr = Some (fun li ltl -> Pcty_constr (mknoloc li, ltl));; -+ -+let ocaml_pcty_fun = Some (fun lab t ct -> Pcty_fun (lab, t, ct));; -+ -+let ocaml_pcty_signature = -+ let f (t, ctfl) = -+ let cs = {pcsig_self = t; pcsig_fields = ctfl; pcsig_loc = t.ptyp_loc} in -+ Pcty_signature cs -+ in -+ Some f -+;; -+ -+let ocaml_pdir_bool = Some (fun b -> Pdir_bool b);; -+ -+let ocaml_pwith_modsubst = -+ Some (fun loc me -> Pwith_modsubst (mkloc loc me)) -+;; -+ -+let ocaml_pwith_module loc me = Pwith_module (mkloc loc me);; -+ -+let ocaml_pwith_typesubst = Some (fun td -> Pwith_typesubst td);; -+ -+let module_prefix_can_be_in_first_record_label_only = true;; -+ -+let split_or_patterns_with_bindings = false;; -+ -+let has_records_with_with = true;; -+ -+(* *) -+ -+let jocaml_pstr_def : (_ -> _) option = None;; -+ -+let jocaml_pexp_def : (_ -> _ -> _) option = None;; -+ -+let jocaml_pexp_par : (_ -> _ -> _) option = None;; -+ -+let jocaml_pexp_reply : (_ -> _ -> _ -> _) option = None;; -+ -+let jocaml_pexp_spawn : (_ -> _) option = None;; -+ -+let arg_rest = -+ function -+ Arg.Rest r -> Some r -+ | _ -> None -+;; -+ -+let arg_set_string = -+ function -+ Arg.Set_string r -> Some r -+ | _ -> None -+;; -+ -+let arg_set_int = -+ function -+ Arg.Set_int r -> Some r -+ | _ -> None -+;; -+ -+let arg_set_float = -+ function -+ Arg.Set_float r -> Some r -+ | _ -> None -+;; -+ -+let arg_symbol = -+ function -+ Arg.Symbol (s, f) -> Some (s, f) -+ | _ -> None -+;; -+ -+let arg_tuple = -+ function -+ Arg.Tuple t -> Some t -+ | _ -> None -+;; -+ -+let arg_bool = -+ function -+ Arg.Bool f -> Some f -+ | _ -> None -+;; -+ -+let char_escaped = Char.escaped;; -+ -+let hashtbl_mem = Hashtbl.mem;; -+ -+let list_rev_append = List.rev_append;; -+ -+let list_rev_map = List.rev_map;; -+ -+let list_sort = List.sort;; -+ -+let pervasives_set_binary_mode_out = Pervasives.set_binary_mode_out;; -+ -+let printf_ksprintf = Printf.ksprintf;; -+ -+let string_contains = String.contains;; -diff -r -u -N camlp5-6.06.orig/ocaml_stuff/4.00.1/parsing/.cvsignore camlp5-6.06/ocaml_stuff/4.00.1/parsing/.cvsignore ---- camlp5-6.06.orig/ocaml_stuff/4.00.1/parsing/.cvsignore 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.1/parsing/.cvsignore 2012-07-31 16:52:22.000000000 +0200 -@@ -0,0 +1 @@ -+*.cm[oi] -diff -r -u -N camlp5-6.06.orig/ocaml_stuff/4.00.1/parsing/.depend camlp5-6.06/ocaml_stuff/4.00.1/parsing/.depend ---- camlp5-6.06.orig/ocaml_stuff/4.00.1/parsing/.depend 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.1/parsing/.depend 2012-07-31 16:52:22.000000000 +0200 -@@ -0,0 +1,4 @@ -+asttypes.cmi : location.cmi -+location.cmi : ../utils/warnings.cmi -+longident.cmi : -+parsetree.cmi : longident.cmi location.cmi asttypes.cmi -diff -r -u -N camlp5-6.06.orig/ocaml_stuff/4.00.1/parsing/Makefile camlp5-6.06/ocaml_stuff/4.00.1/parsing/Makefile ---- camlp5-6.06.orig/ocaml_stuff/4.00.1/parsing/Makefile 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.1/parsing/Makefile 2012-07-31 16:52:22.000000000 +0200 -@@ -0,0 +1,19 @@ -+# Id -+ -+FILES=asttypes.cmi location.cmi longident.cmi parsetree.cmi -+INCL=-I ../utils -+ -+all: $(FILES) -+ -+clean: -+ rm -f *.cmi -+ -+depend: -+ ocamldep $(INCL) *.ml* | sed -e 's/ *$$//' > .depend -+ -+.SUFFIXES: .mli .cmi -+ -+.mli.cmi: -+ $(OCAMLN)c $(INCL) -c $< -+ -+include .depend -diff -r -u -N camlp5-6.06.orig/ocaml_stuff/4.00.1/parsing/asttypes.mli camlp5-6.06/ocaml_stuff/4.00.1/parsing/asttypes.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.1/parsing/asttypes.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.1/parsing/asttypes.mli 2012-07-31 16:52:22.000000000 +0200 -@@ -0,0 +1,45 @@ -+(***********************************************************************) -+(* *) -+(* OCaml *) -+(* *) -+(* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) -+(* *) -+(* Copyright 1996 Institut National de Recherche en Informatique et *) -+(* en Automatique. All rights reserved. This file is distributed *) -+(* under the terms of the Q Public License version 1.0. *) -+(* *) -+(***********************************************************************) -+ -+(* Id *) -+ -+(* Auxiliary a.s.t. types used by parsetree and typedtree. *) -+ -+type constant = -+ Const_int of int -+ | Const_char of char -+ | Const_string of string -+ | Const_float of string -+ | Const_int32 of int32 -+ | Const_int64 of int64 -+ | Const_nativeint of nativeint -+ -+type rec_flag = Nonrecursive | Recursive | Default -+ -+type direction_flag = Upto | Downto -+ -+type private_flag = Private | Public -+ -+type mutable_flag = Immutable | Mutable -+ -+type virtual_flag = Virtual | Concrete -+ -+type override_flag = Override | Fresh -+ -+type closed_flag = Closed | Open -+ -+type label = string -+ -+type 'a loc = 'a Location.loc = { -+ txt : 'a; -+ loc : Location.t; -+} -diff -r -u -N camlp5-6.06.orig/ocaml_stuff/4.00.1/parsing/location.mli camlp5-6.06/ocaml_stuff/4.00.1/parsing/location.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.1/parsing/location.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.1/parsing/location.mli 2012-07-31 16:52:22.000000000 +0200 -@@ -0,0 +1,80 @@ -+(***********************************************************************) -+(* *) -+(* OCaml *) -+(* *) -+(* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) -+(* *) -+(* Copyright 1996 Institut National de Recherche en Informatique et *) -+(* en Automatique. All rights reserved. This file is distributed *) -+(* under the terms of the Q Public License version 1.0. *) -+(* *) -+(***********************************************************************) -+ -+(* Id *) -+ -+(* Source code locations (ranges of positions), used in parsetree. *) -+ -+open Format -+ -+type t = { -+ loc_start: Lexing.position; -+ loc_end: Lexing.position; -+ loc_ghost: bool; -+} -+ -+(* Note on the use of Lexing.position in this module. -+ If [pos_fname = ""], then use [!input_name] instead. -+ If [pos_lnum = -1], then [pos_bol = 0]. Use [pos_cnum] and -+ re-parse the file to get the line and character numbers. -+ Else all fields are correct. -+*) -+ -+val none : t -+(** An arbitrary value of type [t]; describes an empty ghost range. *) -+val in_file : string -> t;; -+(** Return an empty ghost range located in a given file. *) -+val init : Lexing.lexbuf -> string -> unit -+(** Set the file name and line number of the [lexbuf] to be the start -+ of the named file. *) -+val curr : Lexing.lexbuf -> t -+(** Get the location of the current token from the [lexbuf]. *) -+ -+val symbol_rloc: unit -> t -+val symbol_gloc: unit -> t -+ -+(** [rhs_loc n] returns the location of the symbol at position [n], starting -+ at 1, in the current parser rule. *) -+val rhs_loc: int -> t -+ -+val input_name: string ref -+val input_lexbuf: Lexing.lexbuf option ref -+ -+val get_pos_info: Lexing.position -> string * int * int (* file, line, char *) -+val print_loc: formatter -> t -> unit -+val print_error: formatter -> t -> unit -+val print_error_cur_file: formatter -> unit -+val print_warning: t -> formatter -> Warnings.t -> unit -+val prerr_warning: t -> Warnings.t -> unit -+val echo_eof: unit -> unit -+val reset: unit -> unit -+ -+val highlight_locations: formatter -> t -> t -> bool -+ -+type 'a loc = { -+ txt : 'a; -+ loc : t; -+} -+ -+val mknoloc : 'a -> 'a loc -+val mkloc : 'a -> t -> 'a loc -+ -+val print: formatter -> t -> unit -+val print_filename: formatter -> string -> unit -+ -+val show_filename: string -> string -+ (** In -absname mode, return the absolute path for this filename. -+ Otherwise, returns the filename unchanged. *) -+ -+ -+val absname: bool ref -+ -diff -r -u -N camlp5-6.06.orig/ocaml_stuff/4.00.1/parsing/longident.mli camlp5-6.06/ocaml_stuff/4.00.1/parsing/longident.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.1/parsing/longident.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.1/parsing/longident.mli 2012-07-31 16:52:22.000000000 +0200 -@@ -0,0 +1,24 @@ -+(***********************************************************************) -+(* *) -+(* OCaml *) -+(* *) -+(* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) -+(* *) -+(* Copyright 1996 Institut National de Recherche en Informatique et *) -+(* en Automatique. All rights reserved. This file is distributed *) -+(* under the terms of the Q Public License version 1.0. *) -+(* *) -+(***********************************************************************) -+ -+(* Id *) -+ -+(* Long identifiers, used in parsetree. *) -+ -+type t = -+ Lident of string -+ | Ldot of t * string -+ | Lapply of t * t -+ -+val flatten: t -> string list -+val last: t -> string -+val parse: string -> t -diff -r -u -N camlp5-6.06.orig/ocaml_stuff/4.00.1/parsing/parsetree.mli camlp5-6.06/ocaml_stuff/4.00.1/parsing/parsetree.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.1/parsing/parsetree.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.1/parsing/parsetree.mli 2012-07-31 16:52:22.000000000 +0200 -@@ -0,0 +1,307 @@ -+(***********************************************************************) -+(* *) -+(* OCaml *) -+(* *) -+(* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) -+(* *) -+(* Copyright 1996 Institut National de Recherche en Informatique et *) -+(* en Automatique. All rights reserved. This file is distributed *) -+(* under the terms of the Q Public License version 1.0. *) -+(* *) -+(***********************************************************************) -+ -+(* Id *) -+ -+(* Abstract syntax tree produced by parsing *) -+ -+open Asttypes -+ -+(* Type expressions for the core language *) -+ -+type core_type = -+ { ptyp_desc: core_type_desc; -+ ptyp_loc: Location.t } -+ -+and core_type_desc = -+ Ptyp_any -+ | Ptyp_var of string -+ | Ptyp_arrow of label * core_type * core_type -+ | Ptyp_tuple of core_type list -+ | Ptyp_constr of Longident.t loc * core_type list -+ | Ptyp_object of core_field_type list -+ | Ptyp_class of Longident.t loc * core_type list * label list -+ | Ptyp_alias of core_type * string -+ | Ptyp_variant of row_field list * bool * label list option -+ | Ptyp_poly of string list * core_type -+ | Ptyp_package of package_type -+ -+ -+and package_type = Longident.t loc * (Longident.t loc * core_type) list -+ -+and core_field_type = -+ { pfield_desc: core_field_desc; -+ pfield_loc: Location.t } -+ -+and core_field_desc = -+ Pfield of string * core_type -+ | Pfield_var -+ -+and row_field = -+ Rtag of label * bool * core_type list -+ | Rinherit of core_type -+ -+(* Type expressions for the class language *) -+ -+type 'a class_infos = -+ { pci_virt: virtual_flag; -+ pci_params: string loc list * Location.t; -+ pci_name: string loc; -+ pci_expr: 'a; -+ pci_variance: (bool * bool) list; -+ pci_loc: Location.t } -+ -+(* Value expressions for the core language *) -+ -+type pattern = -+ { ppat_desc: pattern_desc; -+ ppat_loc: Location.t } -+ -+and pattern_desc = -+ Ppat_any -+ | Ppat_var of string loc -+ | Ppat_alias of pattern * string loc -+ | Ppat_constant of constant -+ | Ppat_tuple of pattern list -+ | Ppat_construct of Longident.t loc * pattern option * bool -+ | Ppat_variant of label * pattern option -+ | Ppat_record of (Longident.t loc * pattern) list * closed_flag -+ | Ppat_array of pattern list -+ | Ppat_or of pattern * pattern -+ | Ppat_constraint of pattern * core_type -+ | Ppat_type of Longident.t loc -+ | Ppat_lazy of pattern -+ | Ppat_unpack of string loc -+ -+type expression = -+ { pexp_desc: expression_desc; -+ pexp_loc: Location.t } -+ -+and expression_desc = -+ Pexp_ident of Longident.t loc -+ | Pexp_constant of constant -+ | Pexp_let of rec_flag * (pattern * expression) list * expression -+ | Pexp_function of label * expression option * (pattern * expression) list -+ | Pexp_apply of expression * (label * expression) list -+ | Pexp_match of expression * (pattern * expression) list -+ | Pexp_try of expression * (pattern * expression) list -+ | Pexp_tuple of expression list -+ | Pexp_construct of Longident.t loc * expression option * bool -+ | Pexp_variant of label * expression option -+ | Pexp_record of (Longident.t loc * expression) list * expression option -+ | Pexp_field of expression * Longident.t loc -+ | Pexp_setfield of expression * Longident.t loc * expression -+ | Pexp_array of expression list -+ | Pexp_ifthenelse of expression * expression * expression option -+ | Pexp_sequence of expression * expression -+ | Pexp_while of expression * expression -+ | Pexp_for of string loc * expression * expression * direction_flag * expression -+ | Pexp_constraint of expression * core_type option * core_type option -+ | Pexp_when of expression * expression -+ | Pexp_send of expression * string -+ | Pexp_new of Longident.t loc -+ | Pexp_setinstvar of string loc * expression -+ | Pexp_override of (string loc * expression) list -+ | Pexp_letmodule of string loc * module_expr * expression -+ | Pexp_assert of expression -+ | Pexp_assertfalse -+ | Pexp_lazy of expression -+ | Pexp_poly of expression * core_type option -+ | Pexp_object of class_structure -+ | Pexp_newtype of string * expression -+ | Pexp_pack of module_expr -+ | Pexp_open of Longident.t loc * expression -+ -+(* Value descriptions *) -+ -+and value_description = -+ { pval_type: core_type; -+ pval_prim: string list; -+ pval_loc : Location.t -+ } -+ -+(* Type declarations *) -+ -+and type_declaration = -+ { ptype_params: string loc option list; -+ ptype_cstrs: (core_type * core_type * Location.t) list; -+ ptype_kind: type_kind; -+ ptype_private: private_flag; -+ ptype_manifest: core_type option; -+ ptype_variance: (bool * bool) list; -+ ptype_loc: Location.t } -+ -+and type_kind = -+ Ptype_abstract -+ | Ptype_variant of -+ (string loc * core_type list * core_type option * Location.t) list -+ | Ptype_record of -+ (string loc * mutable_flag * core_type * Location.t) list -+ -+and exception_declaration = core_type list -+ -+(* Type expressions for the class language *) -+ -+and class_type = -+ { pcty_desc: class_type_desc; -+ pcty_loc: Location.t } -+ -+and class_type_desc = -+ Pcty_constr of Longident.t loc * core_type list -+ | Pcty_signature of class_signature -+ | Pcty_fun of label * core_type * class_type -+ -+and class_signature = { -+ pcsig_self : core_type; -+ pcsig_fields : class_type_field list; -+ pcsig_loc : Location.t; -+ } -+ -+and class_type_field = { -+ pctf_desc : class_type_field_desc; -+ pctf_loc : Location.t; -+ } -+ -+and class_type_field_desc = -+ Pctf_inher of class_type -+ | Pctf_val of (string * mutable_flag * virtual_flag * core_type) -+ | Pctf_virt of (string * private_flag * core_type) -+ | Pctf_meth of (string * private_flag * core_type) -+ | Pctf_cstr of (core_type * core_type) -+ -+and class_description = class_type class_infos -+ -+and class_type_declaration = class_type class_infos -+ -+(* Value expressions for the class language *) -+ -+and class_expr = -+ { pcl_desc: class_expr_desc; -+ pcl_loc: Location.t } -+ -+and class_expr_desc = -+ Pcl_constr of Longident.t loc * core_type list -+ | Pcl_structure of class_structure -+ | Pcl_fun of label * expression option * pattern * class_expr -+ | Pcl_apply of class_expr * (label * expression) list -+ | Pcl_let of rec_flag * (pattern * expression) list * class_expr -+ | Pcl_constraint of class_expr * class_type -+ -+and class_structure = { -+ pcstr_pat : pattern; -+ pcstr_fields : class_field list; -+ } -+ -+and class_field = { -+ pcf_desc : class_field_desc; -+ pcf_loc : Location.t; -+ } -+ -+and class_field_desc = -+ Pcf_inher of override_flag * class_expr * string option -+ | Pcf_valvirt of (string loc * mutable_flag * core_type) -+ | Pcf_val of (string loc * mutable_flag * override_flag * expression) -+ | Pcf_virt of (string loc * private_flag * core_type) -+ | Pcf_meth of (string loc * private_flag *override_flag * expression) -+ | Pcf_constr of (core_type * core_type) -+ | Pcf_init of expression -+ -+and class_declaration = class_expr class_infos -+ -+(* Type expressions for the module language *) -+ -+and module_type = -+ { pmty_desc: module_type_desc; -+ pmty_loc: Location.t } -+ -+and module_type_desc = -+ Pmty_ident of Longident.t loc -+ | Pmty_signature of signature -+ | Pmty_functor of string loc * module_type * module_type -+ | Pmty_with of module_type * (Longident.t loc * with_constraint) list -+ | Pmty_typeof of module_expr -+ -+and signature = signature_item list -+ -+and signature_item = -+ { psig_desc: signature_item_desc; -+ psig_loc: Location.t } -+ -+and signature_item_desc = -+ Psig_value of string loc * value_description -+ | Psig_type of (string loc * type_declaration) list -+ | Psig_exception of string loc * exception_declaration -+ | Psig_module of string loc * module_type -+ | Psig_recmodule of (string loc * module_type) list -+ | Psig_modtype of string loc * modtype_declaration -+ | Psig_open of Longident.t loc -+ | Psig_include of module_type -+ | Psig_class of class_description list -+ | Psig_class_type of class_type_declaration list -+ -+and modtype_declaration = -+ Pmodtype_abstract -+ | Pmodtype_manifest of module_type -+ -+and with_constraint = -+ Pwith_type of type_declaration -+ | Pwith_module of Longident.t loc -+ | Pwith_typesubst of type_declaration -+ | Pwith_modsubst of Longident.t loc -+ -+(* Value expressions for the module language *) -+ -+and module_expr = -+ { pmod_desc: module_expr_desc; -+ pmod_loc: Location.t } -+ -+and module_expr_desc = -+ Pmod_ident of Longident.t loc -+ | Pmod_structure of structure -+ | Pmod_functor of string loc * module_type * module_expr -+ | Pmod_apply of module_expr * module_expr -+ | Pmod_constraint of module_expr * module_type -+ | Pmod_unpack of expression -+ -+and structure = structure_item list -+ -+and structure_item = -+ { pstr_desc: structure_item_desc; -+ pstr_loc: Location.t } -+ -+and structure_item_desc = -+ Pstr_eval of expression -+ | Pstr_value of rec_flag * (pattern * expression) list -+ | Pstr_primitive of string loc * value_description -+ | Pstr_type of (string loc * type_declaration) list -+ | Pstr_exception of string loc * exception_declaration -+ | Pstr_exn_rebind of string loc * Longident.t loc -+ | Pstr_module of string loc * module_expr -+ | Pstr_recmodule of (string loc * module_type * module_expr) list -+ | Pstr_modtype of string loc * module_type -+ | Pstr_open of Longident.t loc -+ | Pstr_class of class_declaration list -+ | Pstr_class_type of class_type_declaration list -+ | Pstr_include of module_expr -+ -+(* Toplevel phrases *) -+ -+type toplevel_phrase = -+ Ptop_def of structure -+ | Ptop_dir of string * directive_argument -+ -+and directive_argument = -+ Pdir_none -+ | Pdir_string of string -+ | Pdir_int of int -+ | Pdir_ident of Longident.t -+ | Pdir_bool of bool -diff -r -u -N camlp5-6.06.orig/ocaml_stuff/4.00.1/utils/.cvsignore camlp5-6.06/ocaml_stuff/4.00.1/utils/.cvsignore ---- camlp5-6.06.orig/ocaml_stuff/4.00.1/utils/.cvsignore 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.1/utils/.cvsignore 2012-07-31 16:52:22.000000000 +0200 -@@ -0,0 +1 @@ -+*.cm[oix] -diff -r -u -N camlp5-6.06.orig/ocaml_stuff/4.00.1/utils/.depend camlp5-6.06/ocaml_stuff/4.00.1/utils/.depend ---- camlp5-6.06.orig/ocaml_stuff/4.00.1/utils/.depend 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.1/utils/.depend 2012-07-31 16:52:22.000000000 +0200 -@@ -0,0 +1,4 @@ -+pconfig.cmo : pconfig.cmi -+pconfig.cmx : pconfig.cmi -+pconfig.cmi : -+warnings.cmi : -diff -r -u -N camlp5-6.06.orig/ocaml_stuff/4.00.1/utils/Makefile camlp5-6.06/ocaml_stuff/4.00.1/utils/Makefile ---- camlp5-6.06.orig/ocaml_stuff/4.00.1/utils/Makefile 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.1/utils/Makefile 2012-07-31 16:52:22.000000000 +0200 -@@ -0,0 +1,27 @@ -+# Id -+ -+FILES=warnings.cmi pconfig.cmo -+INCL= -+ -+all: $(FILES) -+ -+opt: pconfig.cmx -+ -+clean: -+ rm -f *.cm[oix] *.o -+ -+depend: -+ ocamldep $(INCL) *.ml* | sed -e 's/ *$$//' > .depend -+ -+.SUFFIXES: .mli .cmi .ml .cmo .cmx -+ -+.mli.cmi: -+ $(OCAMLN)c $(INCL) -c $< -+ -+.ml.cmo: -+ $(OCAMLN)c $(INCL) -c $< -+ -+.ml.cmx: -+ $(OCAMLN)opt $(INCL) -c $< -+ -+include .depend -diff -r -u -N camlp5-6.06.orig/ocaml_stuff/4.00.1/utils/pconfig.ml camlp5-6.06/ocaml_stuff/4.00.1/utils/pconfig.ml ---- camlp5-6.06.orig/ocaml_stuff/4.00.1/utils/pconfig.ml 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.1/utils/pconfig.ml 2012-07-31 16:53:40.000000000 +0200 -@@ -0,0 +1,4 @@ -+let ocaml_version = "4.00.1" -+let ocaml_name = "ocaml" -+let ast_impl_magic_number = "Caml1999M015" -+let ast_intf_magic_number = "Caml1999N014" -diff -r -u -N camlp5-6.06.orig/ocaml_stuff/4.00.1/utils/pconfig.mli camlp5-6.06/ocaml_stuff/4.00.1/utils/pconfig.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.1/utils/pconfig.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.1/utils/pconfig.mli 2012-07-31 16:52:22.000000000 +0200 -@@ -0,0 +1,4 @@ -+val ocaml_version : string -+val ocaml_name : string -+val ast_impl_magic_number : string -+val ast_intf_magic_number : string -diff -r -u -N camlp5-6.06.orig/ocaml_stuff/4.00.1/utils/warnings.mli camlp5-6.06/ocaml_stuff/4.00.1/utils/warnings.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.1/utils/warnings.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.1/utils/warnings.mli 2012-07-31 16:52:22.000000000 +0200 -@@ -0,0 +1,75 @@ -+(***********************************************************************) -+(* *) -+(* OCaml *) -+(* *) -+(* Pierre Weis && Damien Doligez, INRIA Rocquencourt *) -+(* *) -+(* Copyright 1998 Institut National de Recherche en Informatique et *) -+(* en Automatique. All rights reserved. This file is distributed *) -+(* under the terms of the Q Public License version 1.0. *) -+(* *) -+(***********************************************************************) -+ -+(* Id *) -+ -+open Format -+ -+type t = -+ | Comment_start (* 1 *) -+ | Comment_not_end (* 2 *) -+ | Deprecated (* 3 *) -+ | Fragile_match of string (* 4 *) -+ | Partial_application (* 5 *) -+ | Labels_omitted (* 6 *) -+ | Method_override of string list (* 7 *) -+ | Partial_match of string (* 8 *) -+ | Non_closed_record_pattern of string (* 9 *) -+ | Statement_type (* 10 *) -+ | Unused_match (* 11 *) -+ | Unused_pat (* 12 *) -+ | Instance_variable_override of string list (* 13 *) -+ | Illegal_backslash (* 14 *) -+ | Implicit_public_methods of string list (* 15 *) -+ | Unerasable_optional_argument (* 16 *) -+ | Undeclared_virtual_method of string (* 17 *) -+ | Not_principal of string (* 18 *) -+ | Without_principality of string (* 19 *) -+ | Unused_argument (* 20 *) -+ | Nonreturning_statement (* 21 *) -+ | Camlp4 of string (* 22 *) -+ | Useless_record_with (* 23 *) -+ | Bad_module_name of string (* 24 *) -+ | All_clauses_guarded (* 25 *) -+ | Unused_var of string (* 26 *) -+ | Unused_var_strict of string (* 27 *) -+ | Wildcard_arg_to_constant_constr (* 28 *) -+ | Eol_in_string (* 29 *) -+ | Duplicate_definitions of string * string * string * string (*30 *) -+ | Multiple_definition of string * string * string (* 31 *) -+ | Unused_value_declaration of string (* 32 *) -+ | Unused_open of string (* 33 *) -+ | Unused_type_declaration of string (* 34 *) -+ | Unused_for_index of string (* 35 *) -+ | Unused_ancestor of string (* 36 *) -+ | Unused_constructor of string * bool * bool (* 37 *) -+ | Unused_exception of string * bool (* 38 *) -+ | Unused_rec_flag (* 39 *) -+;; -+ -+val parse_options : bool -> string -> unit;; -+ -+val is_active : t -> bool;; -+val is_error : t -> bool;; -+ -+val defaults_w : string;; -+val defaults_warn_error : string;; -+ -+val print : formatter -> t -> int;; -+ (* returns the number of newlines in the printed string *) -+ -+ -+exception Errors of int;; -+ -+val check_fatal : unit -> unit;; -+ -+val help_warnings: unit -> unit ---- camlp5-6.06/ocaml_stuff/4.01.0/utils/warnings.mli.orig 2013-02-18 15:14:16.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.01.0/utils/warnings.mli 2013-02-18 15:14:31.000000000 +0100 -@@ -54,6 +54,10 @@ - | Unused_constructor of string * bool * bool (* 37 *) - | Unused_exception of string * bool (* 38 *) - | Unused_rec_flag (* 39 *) -+ | Name_out_of_scope of string list * bool (* 40 *) -+ | Ambiguous_name of string list * bool (* 41 *) -+ | Disambiguated_name of string (* 42 *) -+ | Nonoptional_label of string (* 43 *) - ;; - - val parse_options : bool -> string -> unit;; -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/.cvsignore camlp5-6.06/ocaml_stuff/4.00.2/parsing/.cvsignore ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/.cvsignore 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/parsing/.cvsignore 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1 @@ -+*.cm[oi] -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/.depend camlp5-6.06/ocaml_stuff/4.00.2/parsing/.depend ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/.depend 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/parsing/.depend 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,4 @@ -+asttypes.cmi : location.cmi -+location.cmi : ../utils/warnings.cmi -+longident.cmi : -+parsetree.cmi : longident.cmi location.cmi asttypes.cmi -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/Makefile camlp5-6.06/ocaml_stuff/4.00.2/parsing/Makefile ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/Makefile 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/parsing/Makefile 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,19 @@ -+# Id -+ -+FILES=asttypes.cmi location.cmi longident.cmi parsetree.cmi -+INCL=-I ../utils -+ -+all: $(FILES) -+ -+clean: -+ rm -f *.cmi -+ -+depend: -+ ocamldep $(INCL) *.ml* | sed -e 's/ *$$//' > .depend -+ -+.SUFFIXES: .mli .cmi -+ -+.mli.cmi: -+ $(OCAMLN)c $(INCL) -c $< -+ -+include .depend -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/asttypes.mli camlp5-6.06/ocaml_stuff/4.00.2/parsing/asttypes.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/asttypes.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/parsing/asttypes.mli 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,45 @@ -+(***********************************************************************) -+(* *) -+(* OCaml *) -+(* *) -+(* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) -+(* *) -+(* Copyright 1996 Institut National de Recherche en Informatique et *) -+(* en Automatique. All rights reserved. This file is distributed *) -+(* under the terms of the Q Public License version 1.0. *) -+(* *) -+(***********************************************************************) -+ -+(* Id *) -+ -+(* Auxiliary a.s.t. types used by parsetree and typedtree. *) -+ -+type constant = -+ Const_int of int -+ | Const_char of char -+ | Const_string of string -+ | Const_float of string -+ | Const_int32 of int32 -+ | Const_int64 of int64 -+ | Const_nativeint of nativeint -+ -+type rec_flag = Nonrecursive | Recursive | Default -+ -+type direction_flag = Upto | Downto -+ -+type private_flag = Private | Public -+ -+type mutable_flag = Immutable | Mutable -+ -+type virtual_flag = Virtual | Concrete -+ -+type override_flag = Override | Fresh -+ -+type closed_flag = Closed | Open -+ -+type label = string -+ -+type 'a loc = 'a Location.loc = { -+ txt : 'a; -+ loc : Location.t; -+} -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/location.mli camlp5-6.06/ocaml_stuff/4.00.2/parsing/location.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/location.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/parsing/location.mli 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,80 @@ -+(***********************************************************************) -+(* *) -+(* OCaml *) -+(* *) -+(* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) -+(* *) -+(* Copyright 1996 Institut National de Recherche en Informatique et *) -+(* en Automatique. All rights reserved. This file is distributed *) -+(* under the terms of the Q Public License version 1.0. *) -+(* *) -+(***********************************************************************) -+ -+(* Id *) -+ -+(* Source code locations (ranges of positions), used in parsetree. *) -+ -+open Format -+ -+type t = { -+ loc_start: Lexing.position; -+ loc_end: Lexing.position; -+ loc_ghost: bool; -+} -+ -+(* Note on the use of Lexing.position in this module. -+ If [pos_fname = ""], then use [!input_name] instead. -+ If [pos_lnum = -1], then [pos_bol = 0]. Use [pos_cnum] and -+ re-parse the file to get the line and character numbers. -+ Else all fields are correct. -+*) -+ -+val none : t -+(** An arbitrary value of type [t]; describes an empty ghost range. *) -+val in_file : string -> t;; -+(** Return an empty ghost range located in a given file. *) -+val init : Lexing.lexbuf -> string -> unit -+(** Set the file name and line number of the [lexbuf] to be the start -+ of the named file. *) -+val curr : Lexing.lexbuf -> t -+(** Get the location of the current token from the [lexbuf]. *) -+ -+val symbol_rloc: unit -> t -+val symbol_gloc: unit -> t -+ -+(** [rhs_loc n] returns the location of the symbol at position [n], starting -+ at 1, in the current parser rule. *) -+val rhs_loc: int -> t -+ -+val input_name: string ref -+val input_lexbuf: Lexing.lexbuf option ref -+ -+val get_pos_info: Lexing.position -> string * int * int (* file, line, char *) -+val print_loc: formatter -> t -> unit -+val print_error: formatter -> t -> unit -+val print_error_cur_file: formatter -> unit -+val print_warning: t -> formatter -> Warnings.t -> unit -+val prerr_warning: t -> Warnings.t -> unit -+val echo_eof: unit -> unit -+val reset: unit -> unit -+ -+val highlight_locations: formatter -> t -> t -> bool -+ -+type 'a loc = { -+ txt : 'a; -+ loc : t; -+} -+ -+val mknoloc : 'a -> 'a loc -+val mkloc : 'a -> t -> 'a loc -+ -+val print: formatter -> t -> unit -+val print_filename: formatter -> string -> unit -+ -+val show_filename: string -> string -+ (** In -absname mode, return the absolute path for this filename. -+ Otherwise, returns the filename unchanged. *) -+ -+ -+val absname: bool ref -+ -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/longident.mli camlp5-6.06/ocaml_stuff/4.00.2/parsing/longident.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/longident.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/parsing/longident.mli 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,24 @@ -+(***********************************************************************) -+(* *) -+(* OCaml *) -+(* *) -+(* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) -+(* *) -+(* Copyright 1996 Institut National de Recherche en Informatique et *) -+(* en Automatique. All rights reserved. This file is distributed *) -+(* under the terms of the Q Public License version 1.0. *) -+(* *) -+(***********************************************************************) -+ -+(* Id *) -+ -+(* Long identifiers, used in parsetree. *) -+ -+type t = -+ Lident of string -+ | Ldot of t * string -+ | Lapply of t * t -+ -+val flatten: t -> string list -+val last: t -> string -+val parse: string -> t -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/parsetree.mli camlp5-6.06/ocaml_stuff/4.00.2/parsing/parsetree.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/parsetree.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/parsing/parsetree.mli 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,307 @@ -+(***********************************************************************) -+(* *) -+(* OCaml *) -+(* *) -+(* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) -+(* *) -+(* Copyright 1996 Institut National de Recherche en Informatique et *) -+(* en Automatique. All rights reserved. This file is distributed *) -+(* under the terms of the Q Public License version 1.0. *) -+(* *) -+(***********************************************************************) -+ -+(* Id *) -+ -+(* Abstract syntax tree produced by parsing *) -+ -+open Asttypes -+ -+(* Type expressions for the core language *) -+ -+type core_type = -+ { ptyp_desc: core_type_desc; -+ ptyp_loc: Location.t } -+ -+and core_type_desc = -+ Ptyp_any -+ | Ptyp_var of string -+ | Ptyp_arrow of label * core_type * core_type -+ | Ptyp_tuple of core_type list -+ | Ptyp_constr of Longident.t loc * core_type list -+ | Ptyp_object of core_field_type list -+ | Ptyp_class of Longident.t loc * core_type list * label list -+ | Ptyp_alias of core_type * string -+ | Ptyp_variant of row_field list * bool * label list option -+ | Ptyp_poly of string list * core_type -+ | Ptyp_package of package_type -+ -+ -+and package_type = Longident.t loc * (Longident.t loc * core_type) list -+ -+and core_field_type = -+ { pfield_desc: core_field_desc; -+ pfield_loc: Location.t } -+ -+and core_field_desc = -+ Pfield of string * core_type -+ | Pfield_var -+ -+and row_field = -+ Rtag of label * bool * core_type list -+ | Rinherit of core_type -+ -+(* Type expressions for the class language *) -+ -+type 'a class_infos = -+ { pci_virt: virtual_flag; -+ pci_params: string loc list * Location.t; -+ pci_name: string loc; -+ pci_expr: 'a; -+ pci_variance: (bool * bool) list; -+ pci_loc: Location.t } -+ -+(* Value expressions for the core language *) -+ -+type pattern = -+ { ppat_desc: pattern_desc; -+ ppat_loc: Location.t } -+ -+and pattern_desc = -+ Ppat_any -+ | Ppat_var of string loc -+ | Ppat_alias of pattern * string loc -+ | Ppat_constant of constant -+ | Ppat_tuple of pattern list -+ | Ppat_construct of Longident.t loc * pattern option * bool -+ | Ppat_variant of label * pattern option -+ | Ppat_record of (Longident.t loc * pattern) list * closed_flag -+ | Ppat_array of pattern list -+ | Ppat_or of pattern * pattern -+ | Ppat_constraint of pattern * core_type -+ | Ppat_type of Longident.t loc -+ | Ppat_lazy of pattern -+ | Ppat_unpack of string loc -+ -+type expression = -+ { pexp_desc: expression_desc; -+ pexp_loc: Location.t } -+ -+and expression_desc = -+ Pexp_ident of Longident.t loc -+ | Pexp_constant of constant -+ | Pexp_let of rec_flag * (pattern * expression) list * expression -+ | Pexp_function of label * expression option * (pattern * expression) list -+ | Pexp_apply of expression * (label * expression) list -+ | Pexp_match of expression * (pattern * expression) list -+ | Pexp_try of expression * (pattern * expression) list -+ | Pexp_tuple of expression list -+ | Pexp_construct of Longident.t loc * expression option * bool -+ | Pexp_variant of label * expression option -+ | Pexp_record of (Longident.t loc * expression) list * expression option -+ | Pexp_field of expression * Longident.t loc -+ | Pexp_setfield of expression * Longident.t loc * expression -+ | Pexp_array of expression list -+ | Pexp_ifthenelse of expression * expression * expression option -+ | Pexp_sequence of expression * expression -+ | Pexp_while of expression * expression -+ | Pexp_for of string loc * expression * expression * direction_flag * expression -+ | Pexp_constraint of expression * core_type option * core_type option -+ | Pexp_when of expression * expression -+ | Pexp_send of expression * string -+ | Pexp_new of Longident.t loc -+ | Pexp_setinstvar of string loc * expression -+ | Pexp_override of (string loc * expression) list -+ | Pexp_letmodule of string loc * module_expr * expression -+ | Pexp_assert of expression -+ | Pexp_assertfalse -+ | Pexp_lazy of expression -+ | Pexp_poly of expression * core_type option -+ | Pexp_object of class_structure -+ | Pexp_newtype of string * expression -+ | Pexp_pack of module_expr -+ | Pexp_open of Longident.t loc * expression -+ -+(* Value descriptions *) -+ -+and value_description = -+ { pval_type: core_type; -+ pval_prim: string list; -+ pval_loc : Location.t -+ } -+ -+(* Type declarations *) -+ -+and type_declaration = -+ { ptype_params: string loc option list; -+ ptype_cstrs: (core_type * core_type * Location.t) list; -+ ptype_kind: type_kind; -+ ptype_private: private_flag; -+ ptype_manifest: core_type option; -+ ptype_variance: (bool * bool) list; -+ ptype_loc: Location.t } -+ -+and type_kind = -+ Ptype_abstract -+ | Ptype_variant of -+ (string loc * core_type list * core_type option * Location.t) list -+ | Ptype_record of -+ (string loc * mutable_flag * core_type * Location.t) list -+ -+and exception_declaration = core_type list -+ -+(* Type expressions for the class language *) -+ -+and class_type = -+ { pcty_desc: class_type_desc; -+ pcty_loc: Location.t } -+ -+and class_type_desc = -+ Pcty_constr of Longident.t loc * core_type list -+ | Pcty_signature of class_signature -+ | Pcty_fun of label * core_type * class_type -+ -+and class_signature = { -+ pcsig_self : core_type; -+ pcsig_fields : class_type_field list; -+ pcsig_loc : Location.t; -+ } -+ -+and class_type_field = { -+ pctf_desc : class_type_field_desc; -+ pctf_loc : Location.t; -+ } -+ -+and class_type_field_desc = -+ Pctf_inher of class_type -+ | Pctf_val of (string * mutable_flag * virtual_flag * core_type) -+ | Pctf_virt of (string * private_flag * core_type) -+ | Pctf_meth of (string * private_flag * core_type) -+ | Pctf_cstr of (core_type * core_type) -+ -+and class_description = class_type class_infos -+ -+and class_type_declaration = class_type class_infos -+ -+(* Value expressions for the class language *) -+ -+and class_expr = -+ { pcl_desc: class_expr_desc; -+ pcl_loc: Location.t } -+ -+and class_expr_desc = -+ Pcl_constr of Longident.t loc * core_type list -+ | Pcl_structure of class_structure -+ | Pcl_fun of label * expression option * pattern * class_expr -+ | Pcl_apply of class_expr * (label * expression) list -+ | Pcl_let of rec_flag * (pattern * expression) list * class_expr -+ | Pcl_constraint of class_expr * class_type -+ -+and class_structure = { -+ pcstr_pat : pattern; -+ pcstr_fields : class_field list; -+ } -+ -+and class_field = { -+ pcf_desc : class_field_desc; -+ pcf_loc : Location.t; -+ } -+ -+and class_field_desc = -+ Pcf_inher of override_flag * class_expr * string option -+ | Pcf_valvirt of (string loc * mutable_flag * core_type) -+ | Pcf_val of (string loc * mutable_flag * override_flag * expression) -+ | Pcf_virt of (string loc * private_flag * core_type) -+ | Pcf_meth of (string loc * private_flag *override_flag * expression) -+ | Pcf_constr of (core_type * core_type) -+ | Pcf_init of expression -+ -+and class_declaration = class_expr class_infos -+ -+(* Type expressions for the module language *) -+ -+and module_type = -+ { pmty_desc: module_type_desc; -+ pmty_loc: Location.t } -+ -+and module_type_desc = -+ Pmty_ident of Longident.t loc -+ | Pmty_signature of signature -+ | Pmty_functor of string loc * module_type * module_type -+ | Pmty_with of module_type * (Longident.t loc * with_constraint) list -+ | Pmty_typeof of module_expr -+ -+and signature = signature_item list -+ -+and signature_item = -+ { psig_desc: signature_item_desc; -+ psig_loc: Location.t } -+ -+and signature_item_desc = -+ Psig_value of string loc * value_description -+ | Psig_type of (string loc * type_declaration) list -+ | Psig_exception of string loc * exception_declaration -+ | Psig_module of string loc * module_type -+ | Psig_recmodule of (string loc * module_type) list -+ | Psig_modtype of string loc * modtype_declaration -+ | Psig_open of Longident.t loc -+ | Psig_include of module_type -+ | Psig_class of class_description list -+ | Psig_class_type of class_type_declaration list -+ -+and modtype_declaration = -+ Pmodtype_abstract -+ | Pmodtype_manifest of module_type -+ -+and with_constraint = -+ Pwith_type of type_declaration -+ | Pwith_module of Longident.t loc -+ | Pwith_typesubst of type_declaration -+ | Pwith_modsubst of Longident.t loc -+ -+(* Value expressions for the module language *) -+ -+and module_expr = -+ { pmod_desc: module_expr_desc; -+ pmod_loc: Location.t } -+ -+and module_expr_desc = -+ Pmod_ident of Longident.t loc -+ | Pmod_structure of structure -+ | Pmod_functor of string loc * module_type * module_expr -+ | Pmod_apply of module_expr * module_expr -+ | Pmod_constraint of module_expr * module_type -+ | Pmod_unpack of expression -+ -+and structure = structure_item list -+ -+and structure_item = -+ { pstr_desc: structure_item_desc; -+ pstr_loc: Location.t } -+ -+and structure_item_desc = -+ Pstr_eval of expression -+ | Pstr_value of rec_flag * (pattern * expression) list -+ | Pstr_primitive of string loc * value_description -+ | Pstr_type of (string loc * type_declaration) list -+ | Pstr_exception of string loc * exception_declaration -+ | Pstr_exn_rebind of string loc * Longident.t loc -+ | Pstr_module of string loc * module_expr -+ | Pstr_recmodule of (string loc * module_type * module_expr) list -+ | Pstr_modtype of string loc * module_type -+ | Pstr_open of Longident.t loc -+ | Pstr_class of class_declaration list -+ | Pstr_class_type of class_type_declaration list -+ | Pstr_include of module_expr -+ -+(* Toplevel phrases *) -+ -+type toplevel_phrase = -+ Ptop_def of structure -+ | Ptop_dir of string * directive_argument -+ -+and directive_argument = -+ Pdir_none -+ | Pdir_string of string -+ | Pdir_int of int -+ | Pdir_ident of Longident.t -+ | Pdir_bool of bool -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/.cvsignore camlp5-6.06/ocaml_stuff/4.00.2/utils/.cvsignore ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/.cvsignore 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/utils/.cvsignore 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1 @@ -+*.cm[oix] -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/.depend camlp5-6.06/ocaml_stuff/4.00.2/utils/.depend ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/.depend 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/utils/.depend 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,2 @@ -+pconfig.cmo: pconfig.cmi -+pconfig.cmx: pconfig.cmi -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/Makefile camlp5-6.06/ocaml_stuff/4.00.2/utils/Makefile ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/Makefile 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/utils/Makefile 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,27 @@ -+# Id -+ -+FILES=warnings.cmi pconfig.cmo -+INCL= -+ -+all: $(FILES) -+ -+opt: pconfig.cmx -+ -+clean: -+ rm -f *.cm[oix] *.o -+ -+depend: -+ ocamldep $(INCL) *.ml* | sed -e 's/ *$$//' > .depend -+ -+.SUFFIXES: .mli .cmi .ml .cmo .cmx -+ -+.mli.cmi: -+ $(OCAMLN)c $(INCL) -c $< -+ -+.ml.cmo: -+ $(OCAMLN)c $(INCL) -c $< -+ -+.ml.cmx: -+ $(OCAMLN)opt $(INCL) -c $< -+ -+include .depend -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/pconfig.ml camlp5-6.06/ocaml_stuff/4.00.2/utils/pconfig.ml ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/pconfig.ml 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/utils/pconfig.ml 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,4 @@ -+let ocaml_version = "4.00.2" -+let ocaml_name = "ocaml" -+let ast_impl_magic_number = "Caml1999M015" -+let ast_intf_magic_number = "Caml1999N014" -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/pconfig.mli camlp5-6.06/ocaml_stuff/4.00.2/utils/pconfig.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/pconfig.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/utils/pconfig.mli 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,4 @@ -+val ocaml_version : string -+val ocaml_name : string -+val ast_impl_magic_number : string -+val ast_intf_magic_number : string -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/warnings.mli camlp5-6.06/ocaml_stuff/4.00.2/utils/warnings.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/warnings.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/utils/warnings.mli 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,75 @@ -+(***********************************************************************) -+(* *) -+(* OCaml *) -+(* *) -+(* Pierre Weis && Damien Doligez, INRIA Rocquencourt *) -+(* *) -+(* Copyright 1998 Institut National de Recherche en Informatique et *) -+(* en Automatique. All rights reserved. This file is distributed *) -+(* under the terms of the Q Public License version 1.0. *) -+(* *) -+(***********************************************************************) -+ -+(* Id *) -+ -+open Format -+ -+type t = -+ | Comment_start (* 1 *) -+ | Comment_not_end (* 2 *) -+ | Deprecated (* 3 *) -+ | Fragile_match of string (* 4 *) -+ | Partial_application (* 5 *) -+ | Labels_omitted (* 6 *) -+ | Method_override of string list (* 7 *) -+ | Partial_match of string (* 8 *) -+ | Non_closed_record_pattern of string (* 9 *) -+ | Statement_type (* 10 *) -+ | Unused_match (* 11 *) -+ | Unused_pat (* 12 *) -+ | Instance_variable_override of string list (* 13 *) -+ | Illegal_backslash (* 14 *) -+ | Implicit_public_methods of string list (* 15 *) -+ | Unerasable_optional_argument (* 16 *) -+ | Undeclared_virtual_method of string (* 17 *) -+ | Not_principal of string (* 18 *) -+ | Without_principality of string (* 19 *) -+ | Unused_argument (* 20 *) -+ | Nonreturning_statement (* 21 *) -+ | Camlp4 of string (* 22 *) -+ | Useless_record_with (* 23 *) -+ | Bad_module_name of string (* 24 *) -+ | All_clauses_guarded (* 25 *) -+ | Unused_var of string (* 26 *) -+ | Unused_var_strict of string (* 27 *) -+ | Wildcard_arg_to_constant_constr (* 28 *) -+ | Eol_in_string (* 29 *) -+ | Duplicate_definitions of string * string * string * string (*30 *) -+ | Multiple_definition of string * string * string (* 31 *) -+ | Unused_value_declaration of string (* 32 *) -+ | Unused_open of string (* 33 *) -+ | Unused_type_declaration of string (* 34 *) -+ | Unused_for_index of string (* 35 *) -+ | Unused_ancestor of string (* 36 *) -+ | Unused_constructor of string * bool * bool (* 37 *) -+ | Unused_exception of string * bool (* 38 *) -+ | Unused_rec_flag (* 39 *) -+;; -+ -+val parse_options : bool -> string -> unit;; -+ -+val is_active : t -> bool;; -+val is_error : t -> bool;; -+ -+val defaults_w : string;; -+val defaults_warn_error : string;; -+ -+val print : formatter -> t -> int;; -+ (* returns the number of newlines in the printed string *) -+ -+ -+exception Errors of int;; -+ -+val check_fatal : unit -> unit;; -+ -+val help_warnings: unit -> unit -diff -r -u -N camlp5-6.06.orig/ocaml_src/lib/versdep/4.00.2.ml camlp5-6.06/ocaml_src/lib/versdep/4.00.2.ml ---- camlp5-6.06.orig/ocaml_src/lib/versdep/4.00.2.ml 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_src/lib/versdep/4.00.2.ml 2012-07-31 16:52:22.000000000 +0200 -@@ -0,0 +1,465 @@ -+(* camlp5r pa_macro.cmo *) -+(* File generated by program: edit only if it does not compile. *) -+(* Copyright (c) INRIA 2007-2012 *) -+ -+open Parsetree;; -+open Longident;; -+open Asttypes;; -+ -+type ('a, 'b) choice = -+ Left of 'a -+ | Right of 'b -+;; -+ -+let sys_ocaml_version = Sys.ocaml_version;; -+ -+let ocaml_location (fname, lnum, bolp, lnuml, bolpl, bp, ep) = -+ let loc_at n lnum bolp = -+ {Lexing.pos_fname = if lnum = -1 then "" else fname; -+ Lexing.pos_lnum = lnum; Lexing.pos_bol = bolp; Lexing.pos_cnum = n} -+ in -+ {Location.loc_start = loc_at bp lnum bolp; -+ Location.loc_end = loc_at ep lnuml bolpl; -+ Location.loc_ghost = bp = 0 && ep = 0} -+;; -+ -+let loc_none = -+ let loc = -+ {Lexing.pos_fname = "_none_"; Lexing.pos_lnum = 1; Lexing.pos_bol = 0; -+ Lexing.pos_cnum = -1} -+ in -+ {Location.loc_start = loc; Location.loc_end = loc; -+ Location.loc_ghost = true} -+;; -+ -+let mkloc loc txt = {Location.txt = txt; Location.loc = loc};; -+let mknoloc txt = mkloc loc_none txt;; -+ -+let ocaml_id_or_li_of_string_list loc sl = -+ let mkli s = -+ let rec loop f = -+ function -+ i :: il -> loop (fun s -> Ldot (f i, s)) il -+ | [] -> f s -+ in -+ loop (fun s -> Lident s) -+ in -+ match List.rev sl with -+ [] -> None -+ | s :: sl -> Some (mkli s (List.rev sl)) -+;; -+ -+let list_map_check f l = -+ let rec loop rev_l = -+ function -+ x :: l -> -+ begin match f x with -+ Some s -> loop (s :: rev_l) l -+ | None -> None -+ end -+ | [] -> Some (List.rev rev_l) -+ in -+ loop [] l -+;; -+ -+let ocaml_value_description t p = -+ {pval_type = t; pval_prim = p; pval_loc = t.ptyp_loc} -+;; -+ -+let ocaml_class_type_field loc ctfd = {pctf_desc = ctfd; pctf_loc = loc};; -+ -+let ocaml_class_field loc cfd = {pcf_desc = cfd; pcf_loc = loc};; -+ -+let ocaml_type_declaration params cl tk pf tm loc variance = -+ match list_map_check (fun s_opt -> s_opt) params with -+ Some params -> -+ let params = List.map (fun os -> Some (mknoloc os)) params in -+ Right -+ {ptype_params = params; ptype_cstrs = cl; ptype_kind = tk; -+ ptype_private = pf; ptype_manifest = tm; ptype_loc = loc; -+ ptype_variance = variance} -+ | None -> Left "no '_' type param in this ocaml version" -+;; -+ -+let ocaml_class_type = Some (fun d loc -> {pcty_desc = d; pcty_loc = loc});; -+ -+let ocaml_class_expr = Some (fun d loc -> {pcl_desc = d; pcl_loc = loc});; -+ -+let ocaml_class_structure p cil = {pcstr_pat = p; pcstr_fields = cil};; -+ -+let ocaml_pmty_ident loc li = Pmty_ident (mkloc loc li);; -+ -+let ocaml_pmty_functor sloc s mt1 mt2 = -+ Pmty_functor (mkloc sloc s, mt1, mt2) -+;; -+ -+let ocaml_pmty_typeof = Some (fun me -> Pmty_typeof me);; -+ -+let ocaml_pmty_with mt lcl = -+ let lcl = List.map (fun (s, c) -> mknoloc s, c) lcl in Pmty_with (mt, lcl) -+;; -+ -+let ocaml_ptype_abstract = Ptype_abstract;; -+ -+let ocaml_ptype_record ltl priv = -+ Ptype_record -+ (List.map (fun (s, mf, ct, loc) -> mkloc loc s, mf, ct, loc) ltl) -+;; -+ -+let ocaml_ptype_variant ctl priv = -+ try -+ let ctl = -+ List.map -+ (fun (c, tl, rto, loc) -> -+ if rto <> None then raise Exit else mknoloc c, tl, None, loc) -+ ctl -+ in -+ Some (Ptype_variant ctl) -+ with Exit -> None -+;; -+ -+let ocaml_ptyp_arrow lab t1 t2 = Ptyp_arrow (lab, t1, t2);; -+ -+let ocaml_ptyp_class li tl ll = Ptyp_class (mknoloc li, tl, ll);; -+ -+let ocaml_ptyp_constr li tl = Ptyp_constr (mknoloc li, tl);; -+ -+let ocaml_ptyp_package = Some (fun pt -> Ptyp_package pt);; -+ -+let ocaml_ptyp_poly = Some (fun cl t -> Ptyp_poly (cl, t));; -+ -+let ocaml_ptyp_variant catl clos sl_opt = -+ let catl = -+ List.map -+ (function -+ Left (c, a, tl) -> Rtag (c, a, tl) -+ | Right t -> Rinherit t) -+ catl -+ in -+ Some (Ptyp_variant (catl, clos, sl_opt)) -+;; -+ -+let ocaml_package_type li ltl = -+ mknoloc li, List.map (fun (li, t) -> mkloc t.ptyp_loc li, t) ltl -+;; -+ -+let ocaml_const_int32 = Some (fun s -> Const_int32 (Int32.of_string s));; -+ -+let ocaml_const_int64 = Some (fun s -> Const_int64 (Int64.of_string s));; -+ -+let ocaml_const_nativeint = -+ Some (fun s -> Const_nativeint (Nativeint.of_string s)) -+;; -+ -+let ocaml_pexp_apply f lel = Pexp_apply (f, lel);; -+ -+let ocaml_pexp_assertfalse fname loc = Pexp_assertfalse;; -+ -+let ocaml_pexp_assert fname loc e = Pexp_assert e;; -+ -+let ocaml_pexp_construct li po chk_arity = -+ Pexp_construct (mknoloc li, po, chk_arity) -+;; -+ -+let ocaml_pexp_field e li = Pexp_field (e, mknoloc li);; -+ -+let ocaml_pexp_for i e1 e2 df e = Pexp_for (mknoloc i, e1, e2, df, e);; -+ -+let ocaml_pexp_function lab eo pel = Pexp_function (lab, eo, pel);; -+ -+let ocaml_pexp_lazy = Some (fun e -> Pexp_lazy e);; -+ -+let ocaml_pexp_ident li = Pexp_ident (mknoloc li);; -+ -+let ocaml_pexp_letmodule = -+ Some (fun i me e -> Pexp_letmodule (mknoloc i, me, e)) -+;; -+ -+let ocaml_pexp_new loc li = Pexp_new (mkloc loc li);; -+ -+let ocaml_pexp_newtype = Some (fun s e -> Pexp_newtype (s, e));; -+ -+let ocaml_pexp_object = Some (fun cs -> Pexp_object cs);; -+ -+let ocaml_pexp_open = Some (fun li e -> Pexp_open (mknoloc li, e));; -+ -+let ocaml_pexp_override sel = -+ let sel = List.map (fun (s, e) -> mknoloc s, e) sel in Pexp_override sel -+;; -+ -+let ocaml_pexp_pack : ('a -> 'b -> 'c, 'd) choice option = -+ Some (Right ((fun me -> Pexp_pack me), (fun pt -> Ptyp_package pt))) -+;; -+ -+let ocaml_pexp_poly = Some (fun e t -> Pexp_poly (e, t));; -+ -+let ocaml_pexp_record lel eo = -+ let lel = List.map (fun (li, loc, e) -> mkloc loc li, e) lel in -+ Pexp_record (lel, eo) -+;; -+ -+let ocaml_pexp_setinstvar s e = Pexp_setinstvar (mknoloc s, e);; -+ -+let ocaml_pexp_variant = -+ let pexp_variant_pat = -+ function -+ Pexp_variant (lab, eo) -> Some (lab, eo) -+ | _ -> None -+ in -+ let pexp_variant (lab, eo) = Pexp_variant (lab, eo) in -+ Some (pexp_variant_pat, pexp_variant) -+;; -+ -+let ocaml_ppat_alias p i iloc = Ppat_alias (p, mkloc iloc i);; -+ -+let ocaml_ppat_array = Some (fun pl -> Ppat_array pl);; -+ -+let ocaml_ppat_construct li li_loc po chk_arity = -+ Ppat_construct (mkloc li_loc li, po, chk_arity) -+;; -+ -+let ocaml_ppat_construct_args = -+ function -+ Ppat_construct (li, po, chk_arity) -> Some (li.txt, li.loc, po, chk_arity) -+ | _ -> None -+;; -+ -+let ocaml_ppat_lazy = Some (fun p -> Ppat_lazy p);; -+ -+let ocaml_ppat_record lpl is_closed = -+ let lpl = List.map (fun (li, loc, p) -> mkloc loc li, p) lpl in -+ Ppat_record (lpl, (if is_closed then Closed else Open)) -+;; -+ -+let ocaml_ppat_type = Some (fun loc li -> Ppat_type (mkloc loc li));; -+ -+let ocaml_ppat_unpack = -+ Some ((fun loc s -> Ppat_unpack (mkloc loc s)), (fun pt -> Ptyp_package pt)) -+;; -+ -+let ocaml_ppat_var loc s = Ppat_var (mkloc loc s);; -+ -+let ocaml_ppat_variant = -+ let ppat_variant_pat = -+ function -+ Ppat_variant (lab, po) -> Some (lab, po) -+ | _ -> None -+ in -+ let ppat_variant (lab, po) = Ppat_variant (lab, po) in -+ Some (ppat_variant_pat, ppat_variant) -+;; -+ -+let ocaml_psig_class_type = Some (fun ctl -> Psig_class_type ctl);; -+ -+let ocaml_psig_exception s ed = Psig_exception (mknoloc s, ed);; -+ -+let ocaml_psig_module s mt = Psig_module (mknoloc s, mt);; -+ -+let ocaml_psig_modtype s mtd = Psig_modtype (mknoloc s, mtd);; -+ -+let ocaml_psig_open li = Psig_open (mknoloc li);; -+ -+let ocaml_psig_recmodule = -+ let f ntl = -+ let ntl = List.map (fun (s, mt) -> mknoloc s, mt) ntl in -+ Psig_recmodule ntl -+ in -+ Some f -+;; -+ -+let ocaml_psig_type stl = -+ let stl = List.map (fun (s, t) -> mknoloc s, t) stl in Psig_type stl -+;; -+ -+let ocaml_psig_value s vd = Psig_value (mknoloc s, vd);; -+ -+let ocaml_pstr_class_type = Some (fun ctl -> Pstr_class_type ctl);; -+ -+let ocaml_pstr_exception s ed = Pstr_exception (mknoloc s, ed);; -+ -+let ocaml_pstr_exn_rebind = -+ Some (fun s li -> Pstr_exn_rebind (mknoloc s, mknoloc li)) -+;; -+ -+let ocaml_pstr_include = Some (fun me -> Pstr_include me);; -+ -+let ocaml_pstr_modtype s mt = Pstr_modtype (mknoloc s, mt);; -+ -+let ocaml_pstr_module s me = Pstr_module (mknoloc s, me);; -+ -+let ocaml_pstr_open li = Pstr_open (mknoloc li);; -+ -+let ocaml_pstr_primitive s vd = Pstr_primitive (mknoloc s, vd);; -+ -+let ocaml_pstr_recmodule = -+ let f nel = -+ Pstr_recmodule (List.map (fun (s, mt, me) -> mknoloc s, mt, me) nel) -+ in -+ Some f -+;; -+ -+let ocaml_pstr_type stl = -+ let stl = List.map (fun (s, t) -> mknoloc s, t) stl in Pstr_type stl -+;; -+ -+let ocaml_class_infos = -+ Some -+ (fun virt (sl, sloc) name expr loc variance -> -+ let params = List.map (fun s -> mkloc loc s) sl, sloc in -+ {pci_virt = virt; pci_params = params; pci_name = mkloc loc name; -+ pci_expr = expr; pci_loc = loc; pci_variance = variance}) -+;; -+ -+let ocaml_pmod_ident li = Pmod_ident (mknoloc li);; -+ -+let ocaml_pmod_functor s mt me = Pmod_functor (mknoloc s, mt, me);; -+ -+let ocaml_pmod_unpack : ('a -> 'b -> 'c, 'd) choice option = -+ Some (Right ((fun e -> Pmod_unpack e), (fun pt -> Ptyp_package pt))) -+;; -+ -+let ocaml_pcf_cstr = Some (fun (t1, t2, loc) -> Pcf_constr (t1, t2));; -+ -+let ocaml_pcf_inher ce pb = Pcf_inher (Fresh, ce, pb);; -+ -+let ocaml_pcf_init = Some (fun e -> Pcf_init e);; -+ -+let ocaml_pcf_meth (s, pf, ovf, e, loc) = -+ let pf = if pf then Private else Public in -+ let ovf = if ovf then Override else Fresh in -+ Pcf_meth (mkloc loc s, pf, ovf, e) -+;; -+ -+let ocaml_pcf_val (s, mf, ovf, e, loc) = -+ let mf = if mf then Mutable else Immutable in -+ let ovf = if ovf then Override else Fresh in -+ Pcf_val (mkloc loc s, mf, ovf, e) -+;; -+ -+let ocaml_pcf_valvirt = -+ let ocaml_pcf (s, mf, t, loc) = -+ let mf = if mf then Mutable else Immutable in -+ Pcf_valvirt (mkloc loc s, mf, t) -+ in -+ Some ocaml_pcf -+;; -+ -+let ocaml_pcf_virt (s, pf, t, loc) = Pcf_virt (mkloc loc s, pf, t);; -+ -+let ocaml_pcl_apply = Some (fun ce lel -> Pcl_apply (ce, lel));; -+ -+let ocaml_pcl_constr = Some (fun li ctl -> Pcl_constr (mknoloc li, ctl));; -+ -+let ocaml_pcl_constraint = Some (fun ce ct -> Pcl_constraint (ce, ct));; -+ -+let ocaml_pcl_fun = Some (fun lab ceo p ce -> Pcl_fun (lab, ceo, p, ce));; -+ -+let ocaml_pcl_let = Some (fun rf pel ce -> Pcl_let (rf, pel, ce));; -+ -+let ocaml_pcl_structure = Some (fun cs -> Pcl_structure cs);; -+ -+let ocaml_pctf_cstr = Some (fun (t1, t2, loc) -> Pctf_cstr (t1, t2));; -+ -+let ocaml_pctf_meth (s, pf, t, loc) = Pctf_meth (s, pf, t);; -+ -+let ocaml_pctf_val (s, mf, t, loc) = Pctf_val (s, mf, Concrete, t);; -+ -+let ocaml_pctf_virt (s, pf, t, loc) = Pctf_virt (s, pf, t);; -+ -+let ocaml_pcty_constr = Some (fun li ltl -> Pcty_constr (mknoloc li, ltl));; -+ -+let ocaml_pcty_fun = Some (fun lab t ct -> Pcty_fun (lab, t, ct));; -+ -+let ocaml_pcty_signature = -+ let f (t, ctfl) = -+ let cs = {pcsig_self = t; pcsig_fields = ctfl; pcsig_loc = t.ptyp_loc} in -+ Pcty_signature cs -+ in -+ Some f -+;; -+ -+let ocaml_pdir_bool = Some (fun b -> Pdir_bool b);; -+ -+let ocaml_pwith_modsubst = -+ Some (fun loc me -> Pwith_modsubst (mkloc loc me)) -+;; -+ -+let ocaml_pwith_module loc me = Pwith_module (mkloc loc me);; -+ -+let ocaml_pwith_typesubst = Some (fun td -> Pwith_typesubst td);; -+ -+let module_prefix_can_be_in_first_record_label_only = true;; -+ -+let split_or_patterns_with_bindings = false;; -+ -+let has_records_with_with = true;; -+ -+(* *) -+ -+let jocaml_pstr_def : (_ -> _) option = None;; -+ -+let jocaml_pexp_def : (_ -> _ -> _) option = None;; -+ -+let jocaml_pexp_par : (_ -> _ -> _) option = None;; -+ -+let jocaml_pexp_reply : (_ -> _ -> _ -> _) option = None;; -+ -+let jocaml_pexp_spawn : (_ -> _) option = None;; -+ -+let arg_rest = -+ function -+ Arg.Rest r -> Some r -+ | _ -> None -+;; -+ -+let arg_set_string = -+ function -+ Arg.Set_string r -> Some r -+ | _ -> None -+;; -+ -+let arg_set_int = -+ function -+ Arg.Set_int r -> Some r -+ | _ -> None -+;; -+ -+let arg_set_float = -+ function -+ Arg.Set_float r -> Some r -+ | _ -> None -+;; -+ -+let arg_symbol = -+ function -+ Arg.Symbol (s, f) -> Some (s, f) -+ | _ -> None -+;; -+ -+let arg_tuple = -+ function -+ Arg.Tuple t -> Some t -+ | _ -> None -+;; -+ -+let arg_bool = -+ function -+ Arg.Bool f -> Some f -+ | _ -> None -+;; -+ -+let char_escaped = Char.escaped;; -+ -+let hashtbl_mem = Hashtbl.mem;; -+ -+let list_rev_append = List.rev_append;; -+ -+let list_rev_map = List.rev_map;; -+ -+let list_sort = List.sort;; -+ -+let pervasives_set_binary_mode_out = Pervasives.set_binary_mode_out;; -+ -+let printf_ksprintf = Printf.ksprintf;; -+ -+let string_contains = String.contains;; diff --git a/testsuite/external/camlp5-6.08.patch b/testsuite/external/camlp5-6.08.patch deleted file mode 100644 index 60d708d60c..0000000000 --- a/testsuite/external/camlp5-6.08.patch +++ /dev/null @@ -1,1127 +0,0 @@ ---- camlp5-6.06/ocaml_stuff/4.01.0/utils/warnings.mli.orig 2013-02-18 15:14:16.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.01.0/utils/warnings.mli 2013-02-18 15:14:31.000000000 +0100 -@@ -54,6 +54,10 @@ - | Unused_constructor of string * bool * bool (* 37 *) - | Unused_exception of string * bool (* 38 *) - | Unused_rec_flag (* 39 *) -+ | Name_out_of_scope of string list * bool (* 40 *) -+ | Ambiguous_name of string list * string list * bool (* 41 *) -+ | Disambiguated_name of string (* 42 *) -+ | Nonoptional_label of string (* 43 *) - ;; - - val parse_options : bool -> string -> unit;; -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/.cvsignore camlp5-6.06/ocaml_stuff/4.00.2/parsing/.cvsignore ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/.cvsignore 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/parsing/.cvsignore 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1 @@ -+*.cm[oi] -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/.depend camlp5-6.06/ocaml_stuff/4.00.2/parsing/.depend ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/.depend 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/parsing/.depend 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,4 @@ -+asttypes.cmi : location.cmi -+location.cmi : ../utils/warnings.cmi -+longident.cmi : -+parsetree.cmi : longident.cmi location.cmi asttypes.cmi -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/Makefile camlp5-6.06/ocaml_stuff/4.00.2/parsing/Makefile ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/Makefile 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/parsing/Makefile 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,19 @@ -+# Id -+ -+FILES=asttypes.cmi location.cmi longident.cmi parsetree.cmi -+INCL=-I ../utils -+ -+all: $(FILES) -+ -+clean: -+ rm -f *.cmi -+ -+depend: -+ ocamldep $(INCL) *.ml* | sed -e 's/ *$$//' > .depend -+ -+.SUFFIXES: .mli .cmi -+ -+.mli.cmi: -+ $(OCAMLN)c $(INCL) -c $< -+ -+include .depend -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/asttypes.mli camlp5-6.06/ocaml_stuff/4.00.2/parsing/asttypes.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/asttypes.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/parsing/asttypes.mli 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,45 @@ -+(***********************************************************************) -+(* *) -+(* OCaml *) -+(* *) -+(* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) -+(* *) -+(* Copyright 1996 Institut National de Recherche en Informatique et *) -+(* en Automatique. All rights reserved. This file is distributed *) -+(* under the terms of the Q Public License version 1.0. *) -+(* *) -+(***********************************************************************) -+ -+(* Id *) -+ -+(* Auxiliary a.s.t. types used by parsetree and typedtree. *) -+ -+type constant = -+ Const_int of int -+ | Const_char of char -+ | Const_string of string -+ | Const_float of string -+ | Const_int32 of int32 -+ | Const_int64 of int64 -+ | Const_nativeint of nativeint -+ -+type rec_flag = Nonrecursive | Recursive | Default -+ -+type direction_flag = Upto | Downto -+ -+type private_flag = Private | Public -+ -+type mutable_flag = Immutable | Mutable -+ -+type virtual_flag = Virtual | Concrete -+ -+type override_flag = Override | Fresh -+ -+type closed_flag = Closed | Open -+ -+type label = string -+ -+type 'a loc = 'a Location.loc = { -+ txt : 'a; -+ loc : Location.t; -+} -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/location.mli camlp5-6.06/ocaml_stuff/4.00.2/parsing/location.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/location.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/parsing/location.mli 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,80 @@ -+(***********************************************************************) -+(* *) -+(* OCaml *) -+(* *) -+(* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) -+(* *) -+(* Copyright 1996 Institut National de Recherche en Informatique et *) -+(* en Automatique. All rights reserved. This file is distributed *) -+(* under the terms of the Q Public License version 1.0. *) -+(* *) -+(***********************************************************************) -+ -+(* Id *) -+ -+(* Source code locations (ranges of positions), used in parsetree. *) -+ -+open Format -+ -+type t = { -+ loc_start: Lexing.position; -+ loc_end: Lexing.position; -+ loc_ghost: bool; -+} -+ -+(* Note on the use of Lexing.position in this module. -+ If [pos_fname = ""], then use [!input_name] instead. -+ If [pos_lnum = -1], then [pos_bol = 0]. Use [pos_cnum] and -+ re-parse the file to get the line and character numbers. -+ Else all fields are correct. -+*) -+ -+val none : t -+(** An arbitrary value of type [t]; describes an empty ghost range. *) -+val in_file : string -> t;; -+(** Return an empty ghost range located in a given file. *) -+val init : Lexing.lexbuf -> string -> unit -+(** Set the file name and line number of the [lexbuf] to be the start -+ of the named file. *) -+val curr : Lexing.lexbuf -> t -+(** Get the location of the current token from the [lexbuf]. *) -+ -+val symbol_rloc: unit -> t -+val symbol_gloc: unit -> t -+ -+(** [rhs_loc n] returns the location of the symbol at position [n], starting -+ at 1, in the current parser rule. *) -+val rhs_loc: int -> t -+ -+val input_name: string ref -+val input_lexbuf: Lexing.lexbuf option ref -+ -+val get_pos_info: Lexing.position -> string * int * int (* file, line, char *) -+val print_loc: formatter -> t -> unit -+val print_error: formatter -> t -> unit -+val print_error_cur_file: formatter -> unit -+val print_warning: t -> formatter -> Warnings.t -> unit -+val prerr_warning: t -> Warnings.t -> unit -+val echo_eof: unit -> unit -+val reset: unit -> unit -+ -+val highlight_locations: formatter -> t -> t -> bool -+ -+type 'a loc = { -+ txt : 'a; -+ loc : t; -+} -+ -+val mknoloc : 'a -> 'a loc -+val mkloc : 'a -> t -> 'a loc -+ -+val print: formatter -> t -> unit -+val print_filename: formatter -> string -> unit -+ -+val show_filename: string -> string -+ (** In -absname mode, return the absolute path for this filename. -+ Otherwise, returns the filename unchanged. *) -+ -+ -+val absname: bool ref -+ -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/longident.mli camlp5-6.06/ocaml_stuff/4.00.2/parsing/longident.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/longident.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/parsing/longident.mli 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,24 @@ -+(***********************************************************************) -+(* *) -+(* OCaml *) -+(* *) -+(* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) -+(* *) -+(* Copyright 1996 Institut National de Recherche en Informatique et *) -+(* en Automatique. All rights reserved. This file is distributed *) -+(* under the terms of the Q Public License version 1.0. *) -+(* *) -+(***********************************************************************) -+ -+(* Id *) -+ -+(* Long identifiers, used in parsetree. *) -+ -+type t = -+ Lident of string -+ | Ldot of t * string -+ | Lapply of t * t -+ -+val flatten: t -> string list -+val last: t -> string -+val parse: string -> t -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/parsetree.mli camlp5-6.06/ocaml_stuff/4.00.2/parsing/parsetree.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/parsing/parsetree.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/parsing/parsetree.mli 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,307 @@ -+(***********************************************************************) -+(* *) -+(* OCaml *) -+(* *) -+(* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) -+(* *) -+(* Copyright 1996 Institut National de Recherche en Informatique et *) -+(* en Automatique. All rights reserved. This file is distributed *) -+(* under the terms of the Q Public License version 1.0. *) -+(* *) -+(***********************************************************************) -+ -+(* Id *) -+ -+(* Abstract syntax tree produced by parsing *) -+ -+open Asttypes -+ -+(* Type expressions for the core language *) -+ -+type core_type = -+ { ptyp_desc: core_type_desc; -+ ptyp_loc: Location.t } -+ -+and core_type_desc = -+ Ptyp_any -+ | Ptyp_var of string -+ | Ptyp_arrow of label * core_type * core_type -+ | Ptyp_tuple of core_type list -+ | Ptyp_constr of Longident.t loc * core_type list -+ | Ptyp_object of core_field_type list -+ | Ptyp_class of Longident.t loc * core_type list * label list -+ | Ptyp_alias of core_type * string -+ | Ptyp_variant of row_field list * bool * label list option -+ | Ptyp_poly of string list * core_type -+ | Ptyp_package of package_type -+ -+ -+and package_type = Longident.t loc * (Longident.t loc * core_type) list -+ -+and core_field_type = -+ { pfield_desc: core_field_desc; -+ pfield_loc: Location.t } -+ -+and core_field_desc = -+ Pfield of string * core_type -+ | Pfield_var -+ -+and row_field = -+ Rtag of label * bool * core_type list -+ | Rinherit of core_type -+ -+(* Type expressions for the class language *) -+ -+type 'a class_infos = -+ { pci_virt: virtual_flag; -+ pci_params: string loc list * Location.t; -+ pci_name: string loc; -+ pci_expr: 'a; -+ pci_variance: (bool * bool) list; -+ pci_loc: Location.t } -+ -+(* Value expressions for the core language *) -+ -+type pattern = -+ { ppat_desc: pattern_desc; -+ ppat_loc: Location.t } -+ -+and pattern_desc = -+ Ppat_any -+ | Ppat_var of string loc -+ | Ppat_alias of pattern * string loc -+ | Ppat_constant of constant -+ | Ppat_tuple of pattern list -+ | Ppat_construct of Longident.t loc * pattern option * bool -+ | Ppat_variant of label * pattern option -+ | Ppat_record of (Longident.t loc * pattern) list * closed_flag -+ | Ppat_array of pattern list -+ | Ppat_or of pattern * pattern -+ | Ppat_constraint of pattern * core_type -+ | Ppat_type of Longident.t loc -+ | Ppat_lazy of pattern -+ | Ppat_unpack of string loc -+ -+type expression = -+ { pexp_desc: expression_desc; -+ pexp_loc: Location.t } -+ -+and expression_desc = -+ Pexp_ident of Longident.t loc -+ | Pexp_constant of constant -+ | Pexp_let of rec_flag * (pattern * expression) list * expression -+ | Pexp_function of label * expression option * (pattern * expression) list -+ | Pexp_apply of expression * (label * expression) list -+ | Pexp_match of expression * (pattern * expression) list -+ | Pexp_try of expression * (pattern * expression) list -+ | Pexp_tuple of expression list -+ | Pexp_construct of Longident.t loc * expression option * bool -+ | Pexp_variant of label * expression option -+ | Pexp_record of (Longident.t loc * expression) list * expression option -+ | Pexp_field of expression * Longident.t loc -+ | Pexp_setfield of expression * Longident.t loc * expression -+ | Pexp_array of expression list -+ | Pexp_ifthenelse of expression * expression * expression option -+ | Pexp_sequence of expression * expression -+ | Pexp_while of expression * expression -+ | Pexp_for of string loc * expression * expression * direction_flag * expression -+ | Pexp_constraint of expression * core_type option * core_type option -+ | Pexp_when of expression * expression -+ | Pexp_send of expression * string -+ | Pexp_new of Longident.t loc -+ | Pexp_setinstvar of string loc * expression -+ | Pexp_override of (string loc * expression) list -+ | Pexp_letmodule of string loc * module_expr * expression -+ | Pexp_assert of expression -+ | Pexp_assertfalse -+ | Pexp_lazy of expression -+ | Pexp_poly of expression * core_type option -+ | Pexp_object of class_structure -+ | Pexp_newtype of string * expression -+ | Pexp_pack of module_expr -+ | Pexp_open of Longident.t loc * expression -+ -+(* Value descriptions *) -+ -+and value_description = -+ { pval_type: core_type; -+ pval_prim: string list; -+ pval_loc : Location.t -+ } -+ -+(* Type declarations *) -+ -+and type_declaration = -+ { ptype_params: string loc option list; -+ ptype_cstrs: (core_type * core_type * Location.t) list; -+ ptype_kind: type_kind; -+ ptype_private: private_flag; -+ ptype_manifest: core_type option; -+ ptype_variance: (bool * bool) list; -+ ptype_loc: Location.t } -+ -+and type_kind = -+ Ptype_abstract -+ | Ptype_variant of -+ (string loc * core_type list * core_type option * Location.t) list -+ | Ptype_record of -+ (string loc * mutable_flag * core_type * Location.t) list -+ -+and exception_declaration = core_type list -+ -+(* Type expressions for the class language *) -+ -+and class_type = -+ { pcty_desc: class_type_desc; -+ pcty_loc: Location.t } -+ -+and class_type_desc = -+ Pcty_constr of Longident.t loc * core_type list -+ | Pcty_signature of class_signature -+ | Pcty_fun of label * core_type * class_type -+ -+and class_signature = { -+ pcsig_self : core_type; -+ pcsig_fields : class_type_field list; -+ pcsig_loc : Location.t; -+ } -+ -+and class_type_field = { -+ pctf_desc : class_type_field_desc; -+ pctf_loc : Location.t; -+ } -+ -+and class_type_field_desc = -+ Pctf_inher of class_type -+ | Pctf_val of (string * mutable_flag * virtual_flag * core_type) -+ | Pctf_virt of (string * private_flag * core_type) -+ | Pctf_meth of (string * private_flag * core_type) -+ | Pctf_cstr of (core_type * core_type) -+ -+and class_description = class_type class_infos -+ -+and class_type_declaration = class_type class_infos -+ -+(* Value expressions for the class language *) -+ -+and class_expr = -+ { pcl_desc: class_expr_desc; -+ pcl_loc: Location.t } -+ -+and class_expr_desc = -+ Pcl_constr of Longident.t loc * core_type list -+ | Pcl_structure of class_structure -+ | Pcl_fun of label * expression option * pattern * class_expr -+ | Pcl_apply of class_expr * (label * expression) list -+ | Pcl_let of rec_flag * (pattern * expression) list * class_expr -+ | Pcl_constraint of class_expr * class_type -+ -+and class_structure = { -+ pcstr_pat : pattern; -+ pcstr_fields : class_field list; -+ } -+ -+and class_field = { -+ pcf_desc : class_field_desc; -+ pcf_loc : Location.t; -+ } -+ -+and class_field_desc = -+ Pcf_inher of override_flag * class_expr * string option -+ | Pcf_valvirt of (string loc * mutable_flag * core_type) -+ | Pcf_val of (string loc * mutable_flag * override_flag * expression) -+ | Pcf_virt of (string loc * private_flag * core_type) -+ | Pcf_meth of (string loc * private_flag *override_flag * expression) -+ | Pcf_constr of (core_type * core_type) -+ | Pcf_init of expression -+ -+and class_declaration = class_expr class_infos -+ -+(* Type expressions for the module language *) -+ -+and module_type = -+ { pmty_desc: module_type_desc; -+ pmty_loc: Location.t } -+ -+and module_type_desc = -+ Pmty_ident of Longident.t loc -+ | Pmty_signature of signature -+ | Pmty_functor of string loc * module_type * module_type -+ | Pmty_with of module_type * (Longident.t loc * with_constraint) list -+ | Pmty_typeof of module_expr -+ -+and signature = signature_item list -+ -+and signature_item = -+ { psig_desc: signature_item_desc; -+ psig_loc: Location.t } -+ -+and signature_item_desc = -+ Psig_value of string loc * value_description -+ | Psig_type of (string loc * type_declaration) list -+ | Psig_exception of string loc * exception_declaration -+ | Psig_module of string loc * module_type -+ | Psig_recmodule of (string loc * module_type) list -+ | Psig_modtype of string loc * modtype_declaration -+ | Psig_open of Longident.t loc -+ | Psig_include of module_type -+ | Psig_class of class_description list -+ | Psig_class_type of class_type_declaration list -+ -+and modtype_declaration = -+ Pmodtype_abstract -+ | Pmodtype_manifest of module_type -+ -+and with_constraint = -+ Pwith_type of type_declaration -+ | Pwith_module of Longident.t loc -+ | Pwith_typesubst of type_declaration -+ | Pwith_modsubst of Longident.t loc -+ -+(* Value expressions for the module language *) -+ -+and module_expr = -+ { pmod_desc: module_expr_desc; -+ pmod_loc: Location.t } -+ -+and module_expr_desc = -+ Pmod_ident of Longident.t loc -+ | Pmod_structure of structure -+ | Pmod_functor of string loc * module_type * module_expr -+ | Pmod_apply of module_expr * module_expr -+ | Pmod_constraint of module_expr * module_type -+ | Pmod_unpack of expression -+ -+and structure = structure_item list -+ -+and structure_item = -+ { pstr_desc: structure_item_desc; -+ pstr_loc: Location.t } -+ -+and structure_item_desc = -+ Pstr_eval of expression -+ | Pstr_value of rec_flag * (pattern * expression) list -+ | Pstr_primitive of string loc * value_description -+ | Pstr_type of (string loc * type_declaration) list -+ | Pstr_exception of string loc * exception_declaration -+ | Pstr_exn_rebind of string loc * Longident.t loc -+ | Pstr_module of string loc * module_expr -+ | Pstr_recmodule of (string loc * module_type * module_expr) list -+ | Pstr_modtype of string loc * module_type -+ | Pstr_open of Longident.t loc -+ | Pstr_class of class_declaration list -+ | Pstr_class_type of class_type_declaration list -+ | Pstr_include of module_expr -+ -+(* Toplevel phrases *) -+ -+type toplevel_phrase = -+ Ptop_def of structure -+ | Ptop_dir of string * directive_argument -+ -+and directive_argument = -+ Pdir_none -+ | Pdir_string of string -+ | Pdir_int of int -+ | Pdir_ident of Longident.t -+ | Pdir_bool of bool -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/.cvsignore camlp5-6.06/ocaml_stuff/4.00.2/utils/.cvsignore ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/.cvsignore 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/utils/.cvsignore 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1 @@ -+*.cm[oix] -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/.depend camlp5-6.06/ocaml_stuff/4.00.2/utils/.depend ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/.depend 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/utils/.depend 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,2 @@ -+pconfig.cmo: pconfig.cmi -+pconfig.cmx: pconfig.cmi -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/Makefile camlp5-6.06/ocaml_stuff/4.00.2/utils/Makefile ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/Makefile 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/utils/Makefile 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,27 @@ -+# Id -+ -+FILES=warnings.cmi pconfig.cmo -+INCL= -+ -+all: $(FILES) -+ -+opt: pconfig.cmx -+ -+clean: -+ rm -f *.cm[oix] *.o -+ -+depend: -+ ocamldep $(INCL) *.ml* | sed -e 's/ *$$//' > .depend -+ -+.SUFFIXES: .mli .cmi .ml .cmo .cmx -+ -+.mli.cmi: -+ $(OCAMLN)c $(INCL) -c $< -+ -+.ml.cmo: -+ $(OCAMLN)c $(INCL) -c $< -+ -+.ml.cmx: -+ $(OCAMLN)opt $(INCL) -c $< -+ -+include .depend -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/pconfig.ml camlp5-6.06/ocaml_stuff/4.00.2/utils/pconfig.ml ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/pconfig.ml 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/utils/pconfig.ml 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,4 @@ -+let ocaml_version = "4.00.2" -+let ocaml_name = "ocaml" -+let ast_impl_magic_number = "Caml1999M015" -+let ast_intf_magic_number = "Caml1999N014" -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/pconfig.mli camlp5-6.06/ocaml_stuff/4.00.2/utils/pconfig.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/pconfig.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/utils/pconfig.mli 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,4 @@ -+val ocaml_version : string -+val ocaml_name : string -+val ast_impl_magic_number : string -+val ast_intf_magic_number : string -diff -N -r -u camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/warnings.mli camlp5-6.06/ocaml_stuff/4.00.2/utils/warnings.mli ---- camlp5-6.06.orig/ocaml_stuff/4.00.2/utils/warnings.mli 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_stuff/4.00.2/utils/warnings.mli 2013-03-06 14:44:56.000000000 +0100 -@@ -0,0 +1,75 @@ -+(***********************************************************************) -+(* *) -+(* OCaml *) -+(* *) -+(* Pierre Weis && Damien Doligez, INRIA Rocquencourt *) -+(* *) -+(* Copyright 1998 Institut National de Recherche en Informatique et *) -+(* en Automatique. All rights reserved. This file is distributed *) -+(* under the terms of the Q Public License version 1.0. *) -+(* *) -+(***********************************************************************) -+ -+(* Id *) -+ -+open Format -+ -+type t = -+ | Comment_start (* 1 *) -+ | Comment_not_end (* 2 *) -+ | Deprecated (* 3 *) -+ | Fragile_match of string (* 4 *) -+ | Partial_application (* 5 *) -+ | Labels_omitted (* 6 *) -+ | Method_override of string list (* 7 *) -+ | Partial_match of string (* 8 *) -+ | Non_closed_record_pattern of string (* 9 *) -+ | Statement_type (* 10 *) -+ | Unused_match (* 11 *) -+ | Unused_pat (* 12 *) -+ | Instance_variable_override of string list (* 13 *) -+ | Illegal_backslash (* 14 *) -+ | Implicit_public_methods of string list (* 15 *) -+ | Unerasable_optional_argument (* 16 *) -+ | Undeclared_virtual_method of string (* 17 *) -+ | Not_principal of string (* 18 *) -+ | Without_principality of string (* 19 *) -+ | Unused_argument (* 20 *) -+ | Nonreturning_statement (* 21 *) -+ | Camlp4 of string (* 22 *) -+ | Useless_record_with (* 23 *) -+ | Bad_module_name of string (* 24 *) -+ | All_clauses_guarded (* 25 *) -+ | Unused_var of string (* 26 *) -+ | Unused_var_strict of string (* 27 *) -+ | Wildcard_arg_to_constant_constr (* 28 *) -+ | Eol_in_string (* 29 *) -+ | Duplicate_definitions of string * string * string * string (*30 *) -+ | Multiple_definition of string * string * string (* 31 *) -+ | Unused_value_declaration of string (* 32 *) -+ | Unused_open of string (* 33 *) -+ | Unused_type_declaration of string (* 34 *) -+ | Unused_for_index of string (* 35 *) -+ | Unused_ancestor of string (* 36 *) -+ | Unused_constructor of string * bool * bool (* 37 *) -+ | Unused_exception of string * bool (* 38 *) -+ | Unused_rec_flag (* 39 *) -+;; -+ -+val parse_options : bool -> string -> unit;; -+ -+val is_active : t -> bool;; -+val is_error : t -> bool;; -+ -+val defaults_w : string;; -+val defaults_warn_error : string;; -+ -+val print : formatter -> t -> int;; -+ (* returns the number of newlines in the printed string *) -+ -+ -+exception Errors of int;; -+ -+val check_fatal : unit -> unit;; -+ -+val help_warnings: unit -> unit -diff -r -u -N camlp5-6.06.orig/ocaml_src/lib/versdep/4.00.2.ml camlp5-6.06/ocaml_src/lib/versdep/4.00.2.ml ---- camlp5-6.06.orig/ocaml_src/lib/versdep/4.00.2.ml 1970-01-01 01:00:00.000000000 +0100 -+++ camlp5-6.06/ocaml_src/lib/versdep/4.00.2.ml 2012-07-31 16:52:22.000000000 +0200 -@@ -0,0 +1,465 @@ -+(* camlp5r pa_macro.cmo *) -+(* File generated by program: edit only if it does not compile. *) -+(* Copyright (c) INRIA 2007-2012 *) -+ -+open Parsetree;; -+open Longident;; -+open Asttypes;; -+ -+type ('a, 'b) choice = -+ Left of 'a -+ | Right of 'b -+;; -+ -+let sys_ocaml_version = Sys.ocaml_version;; -+ -+let ocaml_location (fname, lnum, bolp, lnuml, bolpl, bp, ep) = -+ let loc_at n lnum bolp = -+ {Lexing.pos_fname = if lnum = -1 then "" else fname; -+ Lexing.pos_lnum = lnum; Lexing.pos_bol = bolp; Lexing.pos_cnum = n} -+ in -+ {Location.loc_start = loc_at bp lnum bolp; -+ Location.loc_end = loc_at ep lnuml bolpl; -+ Location.loc_ghost = bp = 0 && ep = 0} -+;; -+ -+let loc_none = -+ let loc = -+ {Lexing.pos_fname = "_none_"; Lexing.pos_lnum = 1; Lexing.pos_bol = 0; -+ Lexing.pos_cnum = -1} -+ in -+ {Location.loc_start = loc; Location.loc_end = loc; -+ Location.loc_ghost = true} -+;; -+ -+let mkloc loc txt = {Location.txt = txt; Location.loc = loc};; -+let mknoloc txt = mkloc loc_none txt;; -+ -+let ocaml_id_or_li_of_string_list loc sl = -+ let mkli s = -+ let rec loop f = -+ function -+ i :: il -> loop (fun s -> Ldot (f i, s)) il -+ | [] -> f s -+ in -+ loop (fun s -> Lident s) -+ in -+ match List.rev sl with -+ [] -> None -+ | s :: sl -> Some (mkli s (List.rev sl)) -+;; -+ -+let list_map_check f l = -+ let rec loop rev_l = -+ function -+ x :: l -> -+ begin match f x with -+ Some s -> loop (s :: rev_l) l -+ | None -> None -+ end -+ | [] -> Some (List.rev rev_l) -+ in -+ loop [] l -+;; -+ -+let ocaml_value_description t p = -+ {pval_type = t; pval_prim = p; pval_loc = t.ptyp_loc} -+;; -+ -+let ocaml_class_type_field loc ctfd = {pctf_desc = ctfd; pctf_loc = loc};; -+ -+let ocaml_class_field loc cfd = {pcf_desc = cfd; pcf_loc = loc};; -+ -+let ocaml_type_declaration params cl tk pf tm loc variance = -+ match list_map_check (fun s_opt -> s_opt) params with -+ Some params -> -+ let params = List.map (fun os -> Some (mknoloc os)) params in -+ Right -+ {ptype_params = params; ptype_cstrs = cl; ptype_kind = tk; -+ ptype_private = pf; ptype_manifest = tm; ptype_loc = loc; -+ ptype_variance = variance} -+ | None -> Left "no '_' type param in this ocaml version" -+;; -+ -+let ocaml_class_type = Some (fun d loc -> {pcty_desc = d; pcty_loc = loc});; -+ -+let ocaml_class_expr = Some (fun d loc -> {pcl_desc = d; pcl_loc = loc});; -+ -+let ocaml_class_structure p cil = {pcstr_pat = p; pcstr_fields = cil};; -+ -+let ocaml_pmty_ident loc li = Pmty_ident (mkloc loc li);; -+ -+let ocaml_pmty_functor sloc s mt1 mt2 = -+ Pmty_functor (mkloc sloc s, mt1, mt2) -+;; -+ -+let ocaml_pmty_typeof = Some (fun me -> Pmty_typeof me);; -+ -+let ocaml_pmty_with mt lcl = -+ let lcl = List.map (fun (s, c) -> mknoloc s, c) lcl in Pmty_with (mt, lcl) -+;; -+ -+let ocaml_ptype_abstract = Ptype_abstract;; -+ -+let ocaml_ptype_record ltl priv = -+ Ptype_record -+ (List.map (fun (s, mf, ct, loc) -> mkloc loc s, mf, ct, loc) ltl) -+;; -+ -+let ocaml_ptype_variant ctl priv = -+ try -+ let ctl = -+ List.map -+ (fun (c, tl, rto, loc) -> -+ if rto <> None then raise Exit else mknoloc c, tl, None, loc) -+ ctl -+ in -+ Some (Ptype_variant ctl) -+ with Exit -> None -+;; -+ -+let ocaml_ptyp_arrow lab t1 t2 = Ptyp_arrow (lab, t1, t2);; -+ -+let ocaml_ptyp_class li tl ll = Ptyp_class (mknoloc li, tl, ll);; -+ -+let ocaml_ptyp_constr li tl = Ptyp_constr (mknoloc li, tl);; -+ -+let ocaml_ptyp_package = Some (fun pt -> Ptyp_package pt);; -+ -+let ocaml_ptyp_poly = Some (fun cl t -> Ptyp_poly (cl, t));; -+ -+let ocaml_ptyp_variant catl clos sl_opt = -+ let catl = -+ List.map -+ (function -+ Left (c, a, tl) -> Rtag (c, a, tl) -+ | Right t -> Rinherit t) -+ catl -+ in -+ Some (Ptyp_variant (catl, clos, sl_opt)) -+;; -+ -+let ocaml_package_type li ltl = -+ mknoloc li, List.map (fun (li, t) -> mkloc t.ptyp_loc li, t) ltl -+;; -+ -+let ocaml_const_int32 = Some (fun s -> Const_int32 (Int32.of_string s));; -+ -+let ocaml_const_int64 = Some (fun s -> Const_int64 (Int64.of_string s));; -+ -+let ocaml_const_nativeint = -+ Some (fun s -> Const_nativeint (Nativeint.of_string s)) -+;; -+ -+let ocaml_pexp_apply f lel = Pexp_apply (f, lel);; -+ -+let ocaml_pexp_assertfalse fname loc = Pexp_assertfalse;; -+ -+let ocaml_pexp_assert fname loc e = Pexp_assert e;; -+ -+let ocaml_pexp_construct li po chk_arity = -+ Pexp_construct (mknoloc li, po, chk_arity) -+;; -+ -+let ocaml_pexp_field e li = Pexp_field (e, mknoloc li);; -+ -+let ocaml_pexp_for i e1 e2 df e = Pexp_for (mknoloc i, e1, e2, df, e);; -+ -+let ocaml_pexp_function lab eo pel = Pexp_function (lab, eo, pel);; -+ -+let ocaml_pexp_lazy = Some (fun e -> Pexp_lazy e);; -+ -+let ocaml_pexp_ident li = Pexp_ident (mknoloc li);; -+ -+let ocaml_pexp_letmodule = -+ Some (fun i me e -> Pexp_letmodule (mknoloc i, me, e)) -+;; -+ -+let ocaml_pexp_new loc li = Pexp_new (mkloc loc li);; -+ -+let ocaml_pexp_newtype = Some (fun s e -> Pexp_newtype (s, e));; -+ -+let ocaml_pexp_object = Some (fun cs -> Pexp_object cs);; -+ -+let ocaml_pexp_open = Some (fun li e -> Pexp_open (mknoloc li, e));; -+ -+let ocaml_pexp_override sel = -+ let sel = List.map (fun (s, e) -> mknoloc s, e) sel in Pexp_override sel -+;; -+ -+let ocaml_pexp_pack : ('a -> 'b -> 'c, 'd) choice option = -+ Some (Right ((fun me -> Pexp_pack me), (fun pt -> Ptyp_package pt))) -+;; -+ -+let ocaml_pexp_poly = Some (fun e t -> Pexp_poly (e, t));; -+ -+let ocaml_pexp_record lel eo = -+ let lel = List.map (fun (li, loc, e) -> mkloc loc li, e) lel in -+ Pexp_record (lel, eo) -+;; -+ -+let ocaml_pexp_setinstvar s e = Pexp_setinstvar (mknoloc s, e);; -+ -+let ocaml_pexp_variant = -+ let pexp_variant_pat = -+ function -+ Pexp_variant (lab, eo) -> Some (lab, eo) -+ | _ -> None -+ in -+ let pexp_variant (lab, eo) = Pexp_variant (lab, eo) in -+ Some (pexp_variant_pat, pexp_variant) -+;; -+ -+let ocaml_ppat_alias p i iloc = Ppat_alias (p, mkloc iloc i);; -+ -+let ocaml_ppat_array = Some (fun pl -> Ppat_array pl);; -+ -+let ocaml_ppat_construct li li_loc po chk_arity = -+ Ppat_construct (mkloc li_loc li, po, chk_arity) -+;; -+ -+let ocaml_ppat_construct_args = -+ function -+ Ppat_construct (li, po, chk_arity) -> Some (li.txt, li.loc, po, chk_arity) -+ | _ -> None -+;; -+ -+let ocaml_ppat_lazy = Some (fun p -> Ppat_lazy p);; -+ -+let ocaml_ppat_record lpl is_closed = -+ let lpl = List.map (fun (li, loc, p) -> mkloc loc li, p) lpl in -+ Ppat_record (lpl, (if is_closed then Closed else Open)) -+;; -+ -+let ocaml_ppat_type = Some (fun loc li -> Ppat_type (mkloc loc li));; -+ -+let ocaml_ppat_unpack = -+ Some ((fun loc s -> Ppat_unpack (mkloc loc s)), (fun pt -> Ptyp_package pt)) -+;; -+ -+let ocaml_ppat_var loc s = Ppat_var (mkloc loc s);; -+ -+let ocaml_ppat_variant = -+ let ppat_variant_pat = -+ function -+ Ppat_variant (lab, po) -> Some (lab, po) -+ | _ -> None -+ in -+ let ppat_variant (lab, po) = Ppat_variant (lab, po) in -+ Some (ppat_variant_pat, ppat_variant) -+;; -+ -+let ocaml_psig_class_type = Some (fun ctl -> Psig_class_type ctl);; -+ -+let ocaml_psig_exception s ed = Psig_exception (mknoloc s, ed);; -+ -+let ocaml_psig_module s mt = Psig_module (mknoloc s, mt);; -+ -+let ocaml_psig_modtype s mtd = Psig_modtype (mknoloc s, mtd);; -+ -+let ocaml_psig_open li = Psig_open (mknoloc li);; -+ -+let ocaml_psig_recmodule = -+ let f ntl = -+ let ntl = List.map (fun (s, mt) -> mknoloc s, mt) ntl in -+ Psig_recmodule ntl -+ in -+ Some f -+;; -+ -+let ocaml_psig_type stl = -+ let stl = List.map (fun (s, t) -> mknoloc s, t) stl in Psig_type stl -+;; -+ -+let ocaml_psig_value s vd = Psig_value (mknoloc s, vd);; -+ -+let ocaml_pstr_class_type = Some (fun ctl -> Pstr_class_type ctl);; -+ -+let ocaml_pstr_exception s ed = Pstr_exception (mknoloc s, ed);; -+ -+let ocaml_pstr_exn_rebind = -+ Some (fun s li -> Pstr_exn_rebind (mknoloc s, mknoloc li)) -+;; -+ -+let ocaml_pstr_include = Some (fun me -> Pstr_include me);; -+ -+let ocaml_pstr_modtype s mt = Pstr_modtype (mknoloc s, mt);; -+ -+let ocaml_pstr_module s me = Pstr_module (mknoloc s, me);; -+ -+let ocaml_pstr_open li = Pstr_open (mknoloc li);; -+ -+let ocaml_pstr_primitive s vd = Pstr_primitive (mknoloc s, vd);; -+ -+let ocaml_pstr_recmodule = -+ let f nel = -+ Pstr_recmodule (List.map (fun (s, mt, me) -> mknoloc s, mt, me) nel) -+ in -+ Some f -+;; -+ -+let ocaml_pstr_type stl = -+ let stl = List.map (fun (s, t) -> mknoloc s, t) stl in Pstr_type stl -+;; -+ -+let ocaml_class_infos = -+ Some -+ (fun virt (sl, sloc) name expr loc variance -> -+ let params = List.map (fun s -> mkloc loc s) sl, sloc in -+ {pci_virt = virt; pci_params = params; pci_name = mkloc loc name; -+ pci_expr = expr; pci_loc = loc; pci_variance = variance}) -+;; -+ -+let ocaml_pmod_ident li = Pmod_ident (mknoloc li);; -+ -+let ocaml_pmod_functor s mt me = Pmod_functor (mknoloc s, mt, me);; -+ -+let ocaml_pmod_unpack : ('a -> 'b -> 'c, 'd) choice option = -+ Some (Right ((fun e -> Pmod_unpack e), (fun pt -> Ptyp_package pt))) -+;; -+ -+let ocaml_pcf_cstr = Some (fun (t1, t2, loc) -> Pcf_constr (t1, t2));; -+ -+let ocaml_pcf_inher ce pb = Pcf_inher (Fresh, ce, pb);; -+ -+let ocaml_pcf_init = Some (fun e -> Pcf_init e);; -+ -+let ocaml_pcf_meth (s, pf, ovf, e, loc) = -+ let pf = if pf then Private else Public in -+ let ovf = if ovf then Override else Fresh in -+ Pcf_meth (mkloc loc s, pf, ovf, e) -+;; -+ -+let ocaml_pcf_val (s, mf, ovf, e, loc) = -+ let mf = if mf then Mutable else Immutable in -+ let ovf = if ovf then Override else Fresh in -+ Pcf_val (mkloc loc s, mf, ovf, e) -+;; -+ -+let ocaml_pcf_valvirt = -+ let ocaml_pcf (s, mf, t, loc) = -+ let mf = if mf then Mutable else Immutable in -+ Pcf_valvirt (mkloc loc s, mf, t) -+ in -+ Some ocaml_pcf -+;; -+ -+let ocaml_pcf_virt (s, pf, t, loc) = Pcf_virt (mkloc loc s, pf, t);; -+ -+let ocaml_pcl_apply = Some (fun ce lel -> Pcl_apply (ce, lel));; -+ -+let ocaml_pcl_constr = Some (fun li ctl -> Pcl_constr (mknoloc li, ctl));; -+ -+let ocaml_pcl_constraint = Some (fun ce ct -> Pcl_constraint (ce, ct));; -+ -+let ocaml_pcl_fun = Some (fun lab ceo p ce -> Pcl_fun (lab, ceo, p, ce));; -+ -+let ocaml_pcl_let = Some (fun rf pel ce -> Pcl_let (rf, pel, ce));; -+ -+let ocaml_pcl_structure = Some (fun cs -> Pcl_structure cs);; -+ -+let ocaml_pctf_cstr = Some (fun (t1, t2, loc) -> Pctf_cstr (t1, t2));; -+ -+let ocaml_pctf_meth (s, pf, t, loc) = Pctf_meth (s, pf, t);; -+ -+let ocaml_pctf_val (s, mf, t, loc) = Pctf_val (s, mf, Concrete, t);; -+ -+let ocaml_pctf_virt (s, pf, t, loc) = Pctf_virt (s, pf, t);; -+ -+let ocaml_pcty_constr = Some (fun li ltl -> Pcty_constr (mknoloc li, ltl));; -+ -+let ocaml_pcty_fun = Some (fun lab t ct -> Pcty_fun (lab, t, ct));; -+ -+let ocaml_pcty_signature = -+ let f (t, ctfl) = -+ let cs = {pcsig_self = t; pcsig_fields = ctfl; pcsig_loc = t.ptyp_loc} in -+ Pcty_signature cs -+ in -+ Some f -+;; -+ -+let ocaml_pdir_bool = Some (fun b -> Pdir_bool b);; -+ -+let ocaml_pwith_modsubst = -+ Some (fun loc me -> Pwith_modsubst (mkloc loc me)) -+;; -+ -+let ocaml_pwith_module loc me = Pwith_module (mkloc loc me);; -+ -+let ocaml_pwith_typesubst = Some (fun td -> Pwith_typesubst td);; -+ -+let module_prefix_can_be_in_first_record_label_only = true;; -+ -+let split_or_patterns_with_bindings = false;; -+ -+let has_records_with_with = true;; -+ -+(* *) -+ -+let jocaml_pstr_def : (_ -> _) option = None;; -+ -+let jocaml_pexp_def : (_ -> _ -> _) option = None;; -+ -+let jocaml_pexp_par : (_ -> _ -> _) option = None;; -+ -+let jocaml_pexp_reply : (_ -> _ -> _ -> _) option = None;; -+ -+let jocaml_pexp_spawn : (_ -> _) option = None;; -+ -+let arg_rest = -+ function -+ Arg.Rest r -> Some r -+ | _ -> None -+;; -+ -+let arg_set_string = -+ function -+ Arg.Set_string r -> Some r -+ | _ -> None -+;; -+ -+let arg_set_int = -+ function -+ Arg.Set_int r -> Some r -+ | _ -> None -+;; -+ -+let arg_set_float = -+ function -+ Arg.Set_float r -> Some r -+ | _ -> None -+;; -+ -+let arg_symbol = -+ function -+ Arg.Symbol (s, f) -> Some (s, f) -+ | _ -> None -+;; -+ -+let arg_tuple = -+ function -+ Arg.Tuple t -> Some t -+ | _ -> None -+;; -+ -+let arg_bool = -+ function -+ Arg.Bool f -> Some f -+ | _ -> None -+;; -+ -+let char_escaped = Char.escaped;; -+ -+let hashtbl_mem = Hashtbl.mem;; -+ -+let list_rev_append = List.rev_append;; -+ -+let list_rev_map = List.rev_map;; -+ -+let list_sort = List.sort;; -+ -+let pervasives_set_binary_mode_out = Pervasives.set_binary_mode_out;; -+ -+let printf_ksprintf = Printf.ksprintf;; -+ -+let string_contains = String.contains;; diff --git a/testsuite/external/camlp5-6.10.patch b/testsuite/external/camlp5-6.10.patch deleted file mode 100644 index eeaf4c41b3..0000000000 --- a/testsuite/external/camlp5-6.10.patch +++ /dev/null @@ -1,10 +0,0 @@ ---- camlp5-6.10.orig/ocaml_stuff/4.01.0/utils/warnings.mli 2013-06-19 04:17:42.000000000 +0200 -+++ camlp5-6.10/ocaml_stuff/4.01.0/utils/warnings.mli 2013-08-13 16:14:47.000000000 +0200 -@@ -58,6 +58,7 @@ - | Nonoptional_label of string (* 43 *) - | Open_shadow_identifier of string * string (* 44 *) - | Open_shadow_label_constructor of string * string (* 45 *) -+ | Bad_env_variable of string * string - ;; - - val parse_options : bool -> string -> unit;; diff --git a/testsuite/external/camlp5-git.patch b/testsuite/external/camlp5-git.patch deleted file mode 100644 index 8ea012cc5c..0000000000 --- a/testsuite/external/camlp5-git.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff --git a/Makefile b/Makefile -index 13622f7..b33a042 100644 ---- camlp5-git/Makefile.orig -+++ camlp5-git/Makefile -@@ -54,6 +54,7 @@ depend: - cd ocaml_stuff; $(MAKE) depend; cd .. - for i in $(DIRS) compile; do (cd $$i; $(MAKE) depend; cd ..); done - -+.PHONY: install - install: - rm -rf "$(DESTDIR)$(LIBDIR)/$(CAMLP5N)" - for i in $(DIRS) compile; do \ diff --git a/testsuite/external/camlpdf-0.5.patch b/testsuite/external/camlpdf-0.5.patch deleted file mode 100644 index e13ac33997..0000000000 --- a/testsuite/external/camlpdf-0.5.patch +++ /dev/null @@ -1,25 +0,0 @@ ---- camlpdf-0.5.orig/makefile 2010-03-08 17:30:19.000000000 +0100 -+++ camlpdf-0.5/makefile 2013-05-30 17:07:12.000000000 +0200 -@@ -42,7 +42,7 @@ - - CLIBS = z - --CFLAGS = -m32 -+#CFLAGS = -m32 - - #Uncomment for debug build - #OCAMLNCFLAGS = -g -@@ -56,6 +56,13 @@ - #Remove native-code-library if you don't have native compilers - all : byte-code-library native-code-library - -+LIBDIR="`ocamlc -where`"/camlpdf -+.PHONY: install -+install : -+ mkdir -p ${LIBDIR} -+ cp *.mli *.cm[ia] *.cmxa *.a *.so ${LIBDIR}/ -+ cp introduction_to_camlpdf.pdf ${LIBDIR}/ -+ - # Predefined generic makefile - -include OCamlMakefile - diff --git a/testsuite/external/camlzip-1.04.patch b/testsuite/external/camlzip-1.04.patch deleted file mode 100644 index f49bc6a0a0..0000000000 --- a/testsuite/external/camlzip-1.04.patch +++ /dev/null @@ -1,45 +0,0 @@ ---- camlzip-1.04/Makefile 2009-10-20 15:59:55.000000000 +0200 -+++ camlzip-1.04/Makefile.new 2009-10-20 16:00:31.000000000 +0200 -@@ -4,10 +4,10 @@ - ZLIB_LIB=-lz - - # The directory containing the Zlib library (libz.a or libz.so) --ZLIB_LIBDIR=/usr/local/lib -+ZLIB_LIBDIR=/opt/local/lib - - # The directory containing the Zlib header file (zlib.h) --ZLIB_INCLUDE=/usr/local/include -+ZLIB_INCLUDE=/opt/local/include - - # Where to install the library. By default: sub-directory 'zip' of - # OCaml's standard library directory. ---- /dev/null 2009-10-20 16:35:40.000000000 +0200 -+++ camlzip-1.04/META 2009-10-20 16:37:31.000000000 +0200 -@@ -0,0 +1,6 @@ -+name = "camlzip" -+version = "1.04" -+description = "compression library" -+archive(byte) = "zip.cma" -+archive(native) = "zip.cmxa" -+directory = "+zip" ---- camlzip-1.04/Makefile.orig 2011-07-04 18:09:00.000000000 +0200 -+++ camlzip-1.04/Makefile 2011-07-04 18:10:09.000000000 +0200 -@@ -56,7 +56,8 @@ - - install: - mkdir -p $(INSTALLDIR) -- cp zip.cma zip.cmi gzip.cmi zip.mli gzip.mli libcamlzip.a $(INSTALLDIR) -+ cp zip.cma zip.cmi gzip.cmi zlib.cmi zip.mli gzip.mli zlib.mli \ -+ libcamlzip.a $(INSTALLDIR) - if test -f dllcamlzip.so; then \ - cp dllcamlzip.so $(INSTALLDIR); \ - ldconf=`$(OCAMLC) -where`/ld.conf; \ -@@ -66,7 +67,7 @@ - fi - - installopt: -- cp zip.cmxa zip.a zip.cmx gzip.cmx $(INSTALLDIR) -+ cp zip.cmxa zip.a zip.cmx gzip.cmx zlib.cmx $(INSTALLDIR) - - depend: - gcc -MM -I$(ZLIB_INCLUDE) *.c > .depend diff --git a/testsuite/external/coq-8.3pl4.patch b/testsuite/external/coq-8.3pl4.patch deleted file mode 100644 index 310510a501..0000000000 --- a/testsuite/external/coq-8.3pl4.patch +++ /dev/null @@ -1,59 +0,0 @@ ---- coq-8.3pl4.orig/configure 2011-12-19 22:57:30.000000000 +0100 -+++ coq-8.3pl4/configure 2012-03-16 11:44:55.000000000 +0100 -@@ -444,7 +444,7 @@ - - if [ "$coq_debug_flag" = "-g" ]; then - case $CAMLTAG in -- OCAML31*) -+ OCAML31*|OCAML4*) - # Compilation debug flag - coq_debug_flag_opt="-g" - ;; -@@ -494,7 +494,7 @@ - camlp4oexec=`echo $camlp4oexec | sed -e 's/4/5/'` - else - case $CAMLTAG in -- OCAML31*) -+ OCAML31*|OCAML4*) - if [ -x "${CAMLLIB}/camlp5" ]; then - CAMLP4LIB=+camlp5 - elif [ -x "${CAMLLIB}/site-lib/camlp5" ]; then -@@ -538,7 +538,7 @@ - CAMLOPTVERSION=`"$nativecamlc" -v | sed -n -e 's|.*version* *\(.*\)$|\1|p' ` - if [ "`uname -s`" = "Darwin" -a "$ARCH" = "i386" ]; then - case $CAMLOPTVERSION in -- 3.09.3|3.1?*) ;; -+ 3.09.3|3.1?*|4.*) ;; - *) echo "Native compilation on MacOS X Pentium requires Objective-Caml >= 3.09.3," - best_compiler=byte - echo "only the bytecode version of Coq will be available." ---- coq-8.3pl4/scripts/coqmktop.ml.orig 2012-05-26 21:32:12.000000000 +0200 -+++ coq-8.3pl4/scripts/coqmktop.ml 2012-05-26 21:36:35.000000000 +0200 -@@ -63,6 +63,7 @@ - (src_dirs ()) - (["-I"; "\"" ^ camlp4lib ^ "\""] @ - ["-I"; "\"" ^ coqlib ^ "\""] @ -+ ["-I"; "+compiler-libs"] @ - (if !coqide then ["-thread"; "-I"; "+lablgtk2"] else [])) - - (* Transform bytecode object file names in native object file names *) -@@ -274,7 +275,7 @@ - ocamloptexec^" -linkall" - end else - (* bytecode (we shunt ocamlmktop script which fails on win32) *) -- let ocamlmktoplib = " toplevellib.cma" in -+ let ocamlmktoplib = " ocamlcommon.cma ocamlbytecomp.cma ocamltoplevel.cma" in - let ocamlcexec = Filename.concat camlbin "ocamlc" in - let ocamlccustom = Printf.sprintf "%s %s -linkall " - ocamlcexec Coq_config.coqrunbyteflags in ---- coq-8.3pl4/configure.orig 2012-07-18 11:31:08.353180800 +0200 -+++ coq-8.3pl4/configure 2012-07-18 11:31:10.346046400 +0200 -@@ -272,7 +272,7 @@ - no) - # First we test if we are running a Cygwin system - if [ `uname -s | cut -c -6` = "CYGWIN" ] ; then -- ARCH="win32" -+ ARCH=`uname -s` - else - # If not, we determine the architecture - if test -x /bin/arch ; then diff --git a/testsuite/external/coq-8.4pl1.patch b/testsuite/external/coq-8.4pl1.patch deleted file mode 100644 index 058038282a..0000000000 --- a/testsuite/external/coq-8.4pl1.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- coq-8.4pl1/kernel/univ.ml.orig 2013-11-27 15:53:01.000000000 +0100 -+++ coq-8.4pl1/kernel/univ.ml 2013-11-27 15:53:20.000000000 +0100 -@@ -226,7 +226,7 @@ - - - (* between : UniverseLevel.t -> canonical_arc -> canonical_arc list *) --(* between u v = {w|u<=w<=v, w canonical} *) -+(* between u v = {w |u<=w<=v, w canonical} *) - (* between is the most costly operation *) - - let between g arcu arcv = diff --git a/testsuite/external/coq-8.4pl2.patch b/testsuite/external/coq-8.4pl2.patch deleted file mode 100644 index 50a94edb47..0000000000 --- a/testsuite/external/coq-8.4pl2.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- coq-8.4pl2/kernel/univ.ml.orig 2013-11-27 15:53:01.000000000 +0100 -+++ coq-8.4pl2/kernel/univ.ml 2013-11-27 15:53:20.000000000 +0100 -@@ -226,7 +226,7 @@ - - - (* between : UniverseLevel.t -> canonical_arc -> canonical_arc list *) --(* between u v = {w|u<=w<=v, w canonical} *) -+(* between u v = {w |u<=w<=v, w canonical} *) - (* between is the most costly operation *) - - let between g arcu arcv = diff --git a/testsuite/external/core-109.37.00.patch b/testsuite/external/core-109.37.00.patch deleted file mode 100644 index 53e443ee66..0000000000 --- a/testsuite/external/core-109.37.00.patch +++ /dev/null @@ -1,20 +0,0 @@ ---- core-109.37.00.orig/lib/core_unix.ml 2013-08-06 21:52:16.000000000 +0200 -+++ core-109.37.00/lib/core_unix.ml 2013-08-13 15:25:11.000000000 +0200 -@@ -890,6 +890,7 @@ - | O_SYNC - | O_RSYNC - | O_SHARE_DELETE -+| O_CLOEXEC - with sexp - - type file_perm = int with of_sexp ---- core-109.37.00.orig/lib/core_unix.mli 2013-08-06 21:52:16.000000000 +0200 -+++ core-109.37.00/lib/core_unix.mli 2013-08-13 15:25:32.000000000 +0200 -@@ -305,6 +305,7 @@ - | O_SYNC (** Writes complete as `Synchronised I/O file integrity completion' *) - | O_RSYNC (** Reads complete as writes (depending on O_SYNC/O_DSYNC) *) - | O_SHARE_DELETE (** Windows only: allow the file to be deleted while still open *) -+ | O_CLOEXEC - with sexp - - (** The type of file access rights. *) diff --git a/testsuite/external/core-suite-108.00.01.patch b/testsuite/external/core-suite-108.00.01.patch deleted file mode 100644 index 4c454aa803..0000000000 --- a/testsuite/external/core-suite-108.00.01.patch +++ /dev/null @@ -1,213 +0,0 @@ ---- core-suite-108.00.01.orig/sexplib-108.00.01/top/install_printers.ml 2012-05-14 20:53:09.000000000 +0200 -+++ core-suite-108.00.01/sexplib-108.00.01/top/install_printers.ml 2012-07-12 17:33:45.000000000 +0200 -@@ -3,8 +3,11 @@ - let eval_string - ?(print_outcome = false) ?(err_formatter = Format.err_formatter) str = - let lexbuf = Lexing.from_string str in -+assert false -+(* - let phrase = !Toploop.parse_toplevel_phrase lexbuf in - Toploop.execute_phrase print_outcome err_formatter phrase -+*) - - let rec install_printers = function - | [] -> true ---- core-suite-108.00.01.orig/core-108.00.01/lib/core_unix.mli 2012-05-25 23:10:12.000000000 +0200 -+++ core-suite-108.00.01/core-108.00.01/lib/core_unix.mli 2012-07-12 17:39:29.000000000 +0200 -@@ -296,6 +296,7 @@ - | O_DSYNC (** Writes complete as `Synchronised I/O data integrity completion' *) - | O_SYNC (** Writes complete as `Synchronised I/O file integrity completion' *) - | O_RSYNC (** Reads complete as writes (depending on O_SYNC/O_DSYNC) *) -+ | O_SHARE_DELETE - with sexp - - (** The type of file access rights. *) ---- core-suite-108.00.01.orig/core-108.00.01/lib/core_unix.ml 2012-05-25 23:10:12.000000000 +0200 -+++ core-suite-108.00.01/core-108.00.01/lib/core_unix.ml 2012-07-12 17:44:04.000000000 +0200 -@@ -804,6 +804,7 @@ - | O_DSYNC - | O_SYNC - | O_RSYNC -+| O_SHARE_DELETE - with sexp - - type file_perm = int with of_sexp ---- core-suite-108.00.01.orig/core-108.00.01/top/install_printers.ml 2012-05-17 16:50:03.000000000 +0200 -+++ core-suite-108.00.01/core-108.00.01/top/install_printers.ml 2012-07-12 17:48:36.000000000 +0200 -@@ -5,8 +5,11 @@ - let eval_string - ?(print_outcome = false) ?(err_formatter = Format.err_formatter) str = - let lexbuf = Lexing.from_string str in -+assert false -+(* - let phrase = !Toploop.parse_toplevel_phrase lexbuf in - Toploop.execute_phrase print_outcome err_formatter phrase -+*) - - let rec install_printers = function - | [] -> true ---- core-suite-108.00.01.orig/async-108.00.01/myocamlbuild.ml 2012-05-26 00:48:10.000000000 +0200 -+++ core-suite-108.00.01/async-108.00.01/myocamlbuild.ml 2012-07-12 17:59:01.000000000 +0200 -@@ -630,7 +630,7 @@ - List.concat (List.map f flags) - in - flag ["compile"; "c"] (S cflags); -- flag ["compile"; "ocaml"] (S [A "-w"; A "@Aemr-28"; A "-strict-sequence" ]) -+ flag ["compile"; "ocaml"] (S [A "-w"; A "Aemr-28"; A "-strict-sequence" ]) - ;; - - let dispatch = function ---- core-suite-108.00.01.orig/async_core-108.00.01/myocamlbuild.ml 2012-05-26 00:48:09.000000000 +0200 -+++ core-suite-108.00.01/async_core-108.00.01/myocamlbuild.ml 2012-07-12 17:58:57.000000000 +0200 -@@ -630,7 +630,7 @@ - List.concat (List.map f flags) - in - flag ["compile"; "c"] (S cflags); -- flag ["compile"; "ocaml"] (S [A "-w"; A "@Aemr-28"; A "-strict-sequence" ]) -+ flag ["compile"; "ocaml"] (S [A "-w"; A "Aemr-28"; A "-strict-sequence" ]) - ;; - - let dispatch = function ---- core-suite-108.00.01.orig/async_extra-108.00.01/myocamlbuild.ml 2012-05-26 00:48:09.000000000 +0200 -+++ core-suite-108.00.01/async_extra-108.00.01/myocamlbuild.ml 2012-07-12 17:58:53.000000000 +0200 -@@ -630,7 +630,7 @@ - List.concat (List.map f flags) - in - flag ["compile"; "c"] (S cflags); -- flag ["compile"; "ocaml"] (S [A "-w"; A "@Aemr-28"; A "-strict-sequence" ]) -+ flag ["compile"; "ocaml"] (S [A "-w"; A "Aemr-28"; A "-strict-sequence" ]) - ;; - - let dispatch = function ---- core-suite-108.00.01.orig/async_unix-108.00.01/myocamlbuild.ml 2012-05-26 00:48:09.000000000 +0200 -+++ core-suite-108.00.01/async_unix-108.00.01/myocamlbuild.ml 2012-07-12 17:58:48.000000000 +0200 -@@ -630,7 +630,7 @@ - List.concat (List.map f flags) - in - flag ["compile"; "c"] (S cflags); -- flag ["compile"; "ocaml"] (S [A "-w"; A "@Aemr-28"; A "-strict-sequence" ]) -+ flag ["compile"; "ocaml"] (S [A "-w"; A "Aemr-28"; A "-strict-sequence" ]) - ;; - - let dispatch = function ---- core-suite-108.00.01.orig/bin_prot-108.00.01/myocamlbuild.ml 2012-05-26 00:48:07.000000000 +0200 -+++ core-suite-108.00.01/bin_prot-108.00.01/myocamlbuild.ml 2012-07-12 17:15:41.000000000 +0200 -@@ -636,7 +636,7 @@ - List.concat (List.map f flags) - in - flag ["compile"; "c"] (S cflags); -- flag ["compile"; "ocaml"] (S [A "-w"; A "@Aemr-28"; A "-strict-sequence" ]) -+ flag ["compile"; "ocaml"] (S [A "-w"; A "Aemr-28"; A "-strict-sequence" ]) - ;; - - (* We probably will want to set this up in the `configure` script at some ---- core-suite-108.00.01.orig/comparelib-108.00.01/myocamlbuild.ml 2012-05-26 00:48:06.000000000 +0200 -+++ core-suite-108.00.01/comparelib-108.00.01/myocamlbuild.ml 2012-07-12 17:58:40.000000000 +0200 -@@ -631,7 +631,7 @@ - List.concat (List.map f flags) - in - flag ["compile"; "c"] (S cflags); -- flag ["compile"; "ocaml"] (S [A "-w"; A "@Aemr-28"; A "-strict-sequence" ]) -+ flag ["compile"; "ocaml"] (S [A "-w"; A "Aemr-28"; A "-strict-sequence" ]) - ;; - - let dispatch = function ---- core-suite-108.00.01.orig/core-108.00.01/myocamlbuild.ml 2012-05-26 00:48:08.000000000 +0200 -+++ core-suite-108.00.01/core-108.00.01/myocamlbuild.ml 2012-07-12 17:35:18.000000000 +0200 -@@ -643,7 +643,7 @@ - List.concat (List.map f flags) - in - flag ["compile"; "c"] (S cflags); -- flag ["compile"; "ocaml"] (S [A "-w"; A "@Aemr-28"; A "-strict-sequence" ]) -+ flag ["compile"; "ocaml"] (S [A "-w"; A "Aemr-28"; A "-strict-sequence" ]) - ;; - - let dispatch = function ---- core-suite-108.00.01.orig/core_extended-108.00.01/myocamlbuild.ml 2012-05-26 00:48:09.000000000 +0200 -+++ core-suite-108.00.01/core_extended-108.00.01/myocamlbuild.ml 2012-07-12 17:51:57.000000000 +0200 -@@ -645,7 +645,7 @@ - List.concat (List.map f flags) - in - flag ["compile"; "c"] (S cflags); -- flag ["compile"; "ocaml"] (S [A "-w"; A "@Aemr-28"; A "-strict-sequence" ]) -+ flag ["compile"; "ocaml"] (S [A "-w"; A "Aemr-28"; A "-strict-sequence" ]) - ;; - - let dispatch = function ---- core-suite-108.00.01.orig/fieldslib-108.00.01/myocamlbuild.ml 2012-05-26 00:48:06.000000000 +0200 -+++ core-suite-108.00.01/fieldslib-108.00.01/myocamlbuild.ml 2012-07-12 17:07:50.000000000 +0200 -@@ -631,7 +631,7 @@ - List.concat (List.map f flags) - in - flag ["compile"; "c"] (S cflags); -- flag ["compile"; "ocaml"] (S [A "-w"; A "@Aemr-28"; A "-strict-sequence" ]) -+ flag ["compile"; "ocaml"] (S [A "-w"; A "Aemr-28"; A "-strict-sequence" ]) - ;; - - let dispatch = function ---- core-suite-108.00.01.orig/pa_ounit-108.00.01/myocamlbuild.ml 2012-05-26 00:48:06.000000000 +0200 -+++ core-suite-108.00.01/pa_ounit-108.00.01/myocamlbuild.ml 2012-07-12 17:13:58.000000000 +0200 -@@ -630,7 +630,7 @@ - List.concat (List.map f flags) - in - flag ["compile"; "c"] (S cflags); -- flag ["compile"; "ocaml"] (S [A "-w"; A "@Aemr-28"; A "-strict-sequence" ]) -+ flag ["compile"; "ocaml"] (S [A "-w"; A "Aemr-28"; A "-strict-sequence" ]) - ;; - - let dispatch = function ---- core-suite-108.00.01.orig/pipebang-108.00.01/myocamlbuild.ml 2012-05-26 00:48:06.000000000 +0200 -+++ core-suite-108.00.01/pipebang-108.00.01/myocamlbuild.ml 2012-07-12 17:58:22.000000000 +0200 -@@ -630,7 +630,7 @@ - List.concat (List.map f flags) - in - flag ["compile"; "c"] (S cflags); -- flag ["compile"; "ocaml"] (S [A "-w"; A "@Aemr-28"; A "-strict-sequence" ]) -+ flag ["compile"; "ocaml"] (S [A "-w"; A "Aemr-28"; A "-strict-sequence" ]) - ;; - - let dispatch = function ---- core-suite-108.00.01.orig/sexplib-108.00.01/myocamlbuild.ml 2012-05-26 00:48:07.000000000 +0200 -+++ core-suite-108.00.01/sexplib-108.00.01/myocamlbuild.ml 2012-07-12 17:24:42.000000000 +0200 -@@ -635,7 +635,7 @@ - List.concat (List.map f flags) - in - flag ["compile"; "c"] (S cflags); -- flag ["compile"; "ocaml"] (S [A "-w"; A "@Aemr-28"; A "-strict-sequence" ]) -+ flag ["compile"; "ocaml"] (S [A "-w"; A "Aemr-28"; A "-strict-sequence"]) - ;; - - Ocamlbuild_plugin.dispatch ---- core-suite-108.00.01.orig/type_conv-108.00.01/myocamlbuild.ml 2012-05-26 00:48:05.000000000 +0200 -+++ core-suite-108.00.01/type_conv-108.00.01/myocamlbuild.ml 2012-07-12 17:05:31.000000000 +0200 -@@ -630,7 +630,7 @@ - List.concat (List.map f flags) - in - flag ["compile"; "c"] (S cflags); -- flag ["compile"; "ocaml"] (S [A "-w"; A "@Aemr-28"; A "-strict-sequence" ]) -+ flag ["compile"; "ocaml"] (S [A "-w"; A "Aemr-28"; A "-strict-sequence" ]) - ;; - - let dispatch = function ---- core-suite-108.00.01.orig/typehashlib-108.00.01/myocamlbuild.ml 2012-05-26 00:48:06.000000000 +0200 -+++ core-suite-108.00.01/typehashlib-108.00.01/myocamlbuild.ml 2012-07-12 17:58:06.000000000 +0200 -@@ -631,7 +631,7 @@ - List.concat (List.map f flags) - in - flag ["compile"; "c"] (S cflags); -- flag ["compile"; "ocaml"] (S [A "-w"; A "@Aemr-28"; A "-strict-sequence" ]) -+ flag ["compile"; "ocaml"] (S [A "-w"; A "Aemr-28"; A "-strict-sequence" ]) - ;; - - let dispatch = function ---- core-suite-108.00.01.orig/variantslib-108.00.01/myocamlbuild.ml 2012-05-26 00:48:06.000000000 +0200 -+++ core-suite-108.00.01/variantslib-108.00.01/myocamlbuild.ml 2012-07-12 17:11:51.000000000 +0200 -@@ -631,7 +631,7 @@ - List.concat (List.map f flags) - in - flag ["compile"; "c"] (S cflags); -- flag ["compile"; "ocaml"] (S [A "-w"; A "@Aemr-28"; A "-strict-sequence" ]) -+ flag ["compile"; "ocaml"] (S [A "-w"; A "Aemr-28"; A "-strict-sequence" ]) - ;; - - let dispatch = function diff --git a/testsuite/external/extlib-1.5.2.patch b/testsuite/external/extlib-1.5.2.patch deleted file mode 100644 index 56e48b1286..0000000000 --- a/testsuite/external/extlib-1.5.2.patch +++ /dev/null @@ -1,10 +0,0 @@ ---- extlib-1.5.2.orig/extHashtbl.ml 2011-08-06 16:56:39.000000000 +0200 -+++ extlib-1.5.2/extHashtbl.ml 2012-01-12 19:48:28.000000000 +0100 -@@ -32,6 +32,7 @@ - } - - include Hashtbl -+ let create n = Hashtbl.create (* no seed *) n - - external h_conv : ('a, 'b) t -> ('a, 'b) h_t = "%identity" - external h_make : ('a, 'b) h_t -> ('a, 'b) t = "%identity" diff --git a/testsuite/external/frama-c-Nitrogen-20111001.patch b/testsuite/external/frama-c-Nitrogen-20111001.patch deleted file mode 100644 index f7fc29727a..0000000000 --- a/testsuite/external/frama-c-Nitrogen-20111001.patch +++ /dev/null @@ -1,126 +0,0 @@ -diff -r -u frama-c-Nitrogen-20111001.orig/src/type/datatype.mli frama-c-Nitrogen-20111001/src/type/datatype.mli ---- frama-c-Nitrogen-20111001.orig/src/type/datatype.mli 2011-10-10 10:38:09.000000000 +0200 -+++ frama-c-Nitrogen-20111001/src/type/datatype.mli 2012-01-05 18:35:45.000000000 +0100 -@@ -249,10 +249,27 @@ - - end - -+module type Hashtbl_S = sig -+ type key -+ type 'a t -+ val create : int -> 'a t -+ val clear : 'a t -> unit -+ val copy : 'a t -> 'a t -+ val add : 'a t -> key -> 'a -> unit -+ val remove : 'a t -> key -> unit -+ val find : 'a t -> key -> 'a -+ val find_all : 'a t -> key -> 'a list -+ val replace : 'a t -> key -> 'a -> unit -+ val mem : 'a t -> key -> bool -+ val iter : (key -> 'a -> unit) -> 'a t -> unit -+ val fold : (key -> 'a -> 'b -> 'b) -> 'a t -> 'b -> 'b -+ val length : 'a t -> int -+end -+ - (** A standard OCaml hashtbl signature extended with datatype operations. *) - module type Hashtbl = sig - -- include Hashtbl.S -+ include Hashtbl_S - - val memo: 'a t -> key -> (key -> 'a) -> 'a - (** [memo tbl k f] returns the binding of [k] in [tbl]. If there is -@@ -468,7 +485,7 @@ - module Map(M: Map_common_interface.S)(Key: S with type t = M.key)(Info: Functor_info) : - Map with type 'a t = 'a M.t and type key = M.key and module Key = Key - --module Hashtbl(H: Hashtbl.S)(Key: S with type t = H.key)(Info : Functor_info): -+module Hashtbl(H: Hashtbl_S)(Key: S with type t = H.key)(Info : Functor_info): - Hashtbl with type 'a t = 'a H.t and type key = H.key and module Key = Key - - module type Sub_caml_weak_hashtbl = sig -diff -r -u frama-c-Nitrogen-20111001.orig/src/wp/LogicId.mli frama-c-Nitrogen-20111001/src/wp/LogicId.mli ---- frama-c-Nitrogen-20111001.orig/src/wp/LogicId.mli 2011-10-10 10:38:21.000000000 +0200 -+++ frama-c-Nitrogen-20111001/src/wp/LogicId.mli 2012-01-05 18:38:36.000000000 +0100 -@@ -40,7 +40,7 @@ - - module Iset : Set.S with type elt = t - module Imap : Map.S with type key = t --module Ihmap : Hashtbl.S with type key = t -+module Ihmap : Datatype.Hashtbl_S with type key = t - - (** {3 Name Spaces} *) - -diff -r -u frama-c-Nitrogen-20111001.orig/src/wp/fol_formula.ml frama-c-Nitrogen-20111001/src/wp/fol_formula.ml ---- frama-c-Nitrogen-20111001.orig/src/wp/fol_formula.ml 2011-10-10 10:38:21.000000000 +0200 -+++ frama-c-Nitrogen-20111001/src/wp/fol_formula.ml 2012-01-05 18:31:40.000000000 +0100 -@@ -389,7 +389,7 @@ - module type Identifiable = - sig - type t -- module H : Hashtbl.S -+ module H : Datatype.Hashtbl_S - val index : t -> H.key - val prefix : string - val basename : t -> string -diff -r -u frama-c-Nitrogen-20111001.orig/src/wp/formula.mli frama-c-Nitrogen-20111001/src/wp/formula.mli ---- frama-c-Nitrogen-20111001.orig/src/wp/formula.mli 2011-10-10 10:38:21.000000000 +0200 -+++ frama-c-Nitrogen-20111001/src/wp/formula.mli 2012-01-05 18:38:28.000000000 +0100 -@@ -147,7 +147,7 @@ - module type Identifiable = - sig - type t -- module H : Hashtbl.S -+ module H : Datatype.Hashtbl_S - val index : t -> H.key - val prefix : string - val basename : t -> string ---- frama-c-Nitrogen-20111001.orig/src/type/datatype.ml 2011-10-10 10:38:09.000000000 +0200 -+++ frama-c-Nitrogen-20111001/src/type/datatype.ml 2012-01-05 18:46:38.000000000 +0100 -@@ -306,8 +306,26 @@ - module Make(Data: S) : S with type t = Data.t t - end - -+module type Hashtbl_S = -+ sig -+ type key -+ type 'a t -+ val create : int -> 'a t -+ val clear : 'a t -> unit -+ val copy : 'a t -> 'a t -+ val add : 'a t -> key -> 'a -> unit -+ val remove : 'a t -> key -> unit -+ val find : 'a t -> key -> 'a -+ val find_all : 'a t -> key -> 'a list -+ val replace : 'a t -> key -> 'a -> unit -+ val mem : 'a t -> key -> bool -+ val iter : (key -> 'a -> unit) -> 'a t -> unit -+ val fold : (key -> 'a -> 'b -> 'b) -> 'a t -> 'b -> 'b -+ val length : 'a t -> int -+ end -+ - module type Hashtbl = sig -- include Hashtbl.S -+ include Hashtbl_S - val memo: 'a t -> key -> (key -> 'a) -> 'a - module Key: S with type t = key - module Make(Data: S) : S with type t = Data.t t -@@ -970,7 +988,7 @@ - module Initial_caml_hashtbl = Hashtbl - - (* ocaml functors are generative *) --module Hashtbl(H: Hashtbl.S)(Key: S with type t = H.key)(Info : Functor_info) = -+module Hashtbl(H: Hashtbl_S)(Key: S with type t = H.key)(Info : Functor_info) = - struct - - let () = check Key.equal "equal" Key.name Info.module_name ---- frama-c-Nitrogen-20111001/configure.orig 2012-03-12 16:14:45.000000000 +0100 -+++ frama-c-Nitrogen-20111001/configure 2012-03-12 16:15:06.000000000 +0100 -@@ -2675,6 +2675,7 @@ - ;; - 3.10*) echo "${ECHO_T}good!";; - 3.1*) echo "${ECHO_T}good!"; OCAML_ANNOT_OPTION="-annot";; -+ 4.0*) echo "${ECHO_T}good!"; OCAML_ANNOT_OPTION="-annot";; - *) echo "${ECHO_T}Incompatible version!"; exit 2;; - esac - diff --git a/testsuite/external/frama-c-Oxygen-20120901.patch b/testsuite/external/frama-c-Oxygen-20120901.patch deleted file mode 100644 index 2f3ce3e6f2..0000000000 --- a/testsuite/external/frama-c-Oxygen-20120901.patch +++ /dev/null @@ -1,185 +0,0 @@ ---- frama-c-Oxygen-20120901.orig/src/type/datatype.ml 2012-09-19 13:55:23.000000000 +0200 -+++ frama-c-Oxygen-20120901/src/type/datatype.ml 2013-02-19 16:36:36.000000000 +0100 -@@ -285,8 +285,37 @@ - - end - -+module type Set_S = sig -+ type elt -+ type t -+ val empty: t -+ val is_empty: t -> bool -+ val mem: elt -> t -> bool -+ val add: elt -> t -> t -+ val singleton: elt -> t -+ val remove: elt -> t -> t -+ val union: t -> t -> t -+ val inter: t -> t -> t -+ val diff: t -> t -> t -+ val compare: t -> t -> int -+ val equal: t -> t -> bool -+ val subset: t -> t -> bool -+ val iter: (elt -> unit) -> t -> unit -+ val fold: (elt -> 'a -> 'a) -> t -> 'a -> 'a -+ val for_all: (elt -> bool) -> t -> bool -+ val exists: (elt -> bool) -> t -> bool -+ val filter: (elt -> bool) -> t -> t -+ val partition: (elt -> bool) -> t -> t * t -+ val cardinal: t -> int -+ val elements: t -> elt list -+ val min_elt: t -> elt -+ val max_elt: t -> elt -+ val choose: t -> elt -+ val split: elt -> t -> t * bool * t -+end -+ - module type Set = sig -- include Set.S -+ include Set_S - val ty: t Type.t - val name: string - val descr: t Descr.t -@@ -1093,7 +1122,7 @@ - module Initial_caml_set = Set - - (* ocaml functors are generative *) --module Set(S: Set.S)(E: S with type t = S.elt)(Info: Functor_info) = struct -+module Set(S: Set_S)(E: S with type t = S.elt)(Info: Functor_info) = struct - - let () = check E.equal "equal" E.name Info.module_name - let () = check E.compare "compare" E.name Info.module_name ---- frama-c-Oxygen-20120901.orig/src/type/datatype.mli 2012-09-19 13:55:23.000000000 +0200 -+++ frama-c-Oxygen-20120901/src/type/datatype.mli 2013-02-19 16:36:29.000000000 +0100 -@@ -230,9 +230,38 @@ - defining by applying the functor. *) - end - -+module type Set_S = sig -+ type elt -+ type t -+ val empty: t -+ val is_empty: t -> bool -+ val mem: elt -> t -> bool -+ val add: elt -> t -> t -+ val singleton: elt -> t -+ val remove: elt -> t -> t -+ val union: t -> t -> t -+ val inter: t -> t -> t -+ val diff: t -> t -> t -+ val compare: t -> t -> int -+ val equal: t -> t -> bool -+ val subset: t -> t -> bool -+ val iter: (elt -> unit) -> t -> unit -+ val fold: (elt -> 'a -> 'a) -> t -> 'a -> 'a -+ val for_all: (elt -> bool) -> t -> bool -+ val exists: (elt -> bool) -> t -> bool -+ val filter: (elt -> bool) -> t -> t -+ val partition: (elt -> bool) -> t -> t * t -+ val cardinal: t -> int -+ val elements: t -> elt list -+ val min_elt: t -> elt -+ val max_elt: t -> elt -+ val choose: t -> elt -+ val split: elt -> t -> t * bool * t -+end -+ - (** A standard OCaml set signature extended with datatype operations. *) - module type Set = sig -- include Set.S -+ include Set_S - val ty: t Type.t - val name: string - val descr: t Descr.t -@@ -602,7 +631,7 @@ - 'e Type.t -> - ('a -> 'b -> 'c -> 'd -> 'e) Type.t - --module Set(S: Set.S)(E: S with type t = S.elt)(Info : Functor_info): -+module Set(S: Set_S)(E: S with type t = S.elt)(Info : Functor_info): - Set with type t = S.t and type elt = E.t - - module Map ---- frama-c-Oxygen-20120901.orig/src/wp/qed/src/idxset.ml 2012-09-19 13:55:28.000000000 +0200 -+++ frama-c-Oxygen-20120901/src/wp/qed/src/idxset.ml 2013-02-19 16:45:08.000000000 +0100 -@@ -20,9 +20,38 @@ - (* *) - (**************************************************************************) - -+module type Set_S = sig -+ type elt -+ type t -+ val empty: t -+ val is_empty: t -> bool -+ val mem: elt -> t -> bool -+ val add: elt -> t -> t -+ val singleton: elt -> t -+ val remove: elt -> t -> t -+ val union: t -> t -> t -+ val inter: t -> t -> t -+ val diff: t -> t -> t -+ val compare: t -> t -> int -+ val equal: t -> t -> bool -+ val subset: t -> t -> bool -+ val iter: (elt -> unit) -> t -> unit -+ val fold: (elt -> 'a -> 'a) -> t -> 'a -> 'a -+ val for_all: (elt -> bool) -> t -> bool -+ val exists: (elt -> bool) -> t -> bool -+ val filter: (elt -> bool) -> t -> t -+ val partition: (elt -> bool) -> t -> t * t -+ val cardinal: t -> int -+ val elements: t -> elt list -+ val min_elt: t -> elt -+ val max_elt: t -> elt -+ val choose: t -> elt -+ val split: elt -> t -> t * bool * t -+end -+ - module type S = - sig -- include Set.S -+ include Set_S - val map : (elt -> elt) -> t -> t - val intersect : t -> t -> bool - end ---- frama-c-Oxygen-20120901.orig/src/wp/qed/src/idxset.mli 2012-09-19 13:55:28.000000000 +0200 -+++ frama-c-Oxygen-20120901/src/wp/qed/src/idxset.mli 2013-02-19 16:45:19.000000000 +0100 -@@ -22,9 +22,38 @@ - - (** Set of indexed elements implemented as Patricia sets. *) - -+module type Set_S = sig -+ type elt -+ type t -+ val empty: t -+ val is_empty: t -> bool -+ val mem: elt -> t -> bool -+ val add: elt -> t -> t -+ val singleton: elt -> t -+ val remove: elt -> t -> t -+ val union: t -> t -> t -+ val inter: t -> t -> t -+ val diff: t -> t -> t -+ val compare: t -> t -> int -+ val equal: t -> t -> bool -+ val subset: t -> t -> bool -+ val iter: (elt -> unit) -> t -> unit -+ val fold: (elt -> 'a -> 'a) -> t -> 'a -> 'a -+ val for_all: (elt -> bool) -> t -> bool -+ val exists: (elt -> bool) -> t -> bool -+ val filter: (elt -> bool) -> t -> t -+ val partition: (elt -> bool) -> t -> t * t -+ val cardinal: t -> int -+ val elements: t -> elt list -+ val min_elt: t -> elt -+ val max_elt: t -> elt -+ val choose: t -> elt -+ val split: elt -> t -> t * bool * t -+end -+ - module type S = - sig -- include Set.S -+ include Set_S - val map : (elt -> elt) -> t -> t - val intersect : t -> t -> bool - end diff --git a/testsuite/external/hevea-1.10.patch b/testsuite/external/hevea-1.10.patch deleted file mode 100644 index 40aab2b796..0000000000 --- a/testsuite/external/hevea-1.10.patch +++ /dev/null @@ -1,22 +0,0 @@ -diff -r -u hevea-1.10 2/hevea.ml hevea-1.10/hevea.ml ---- hevea-1.10 2/hevea.ml 2007-02-09 15:44:28.000000000 +0100 -+++ hevea-1.10/hevea.ml 2009-08-27 17:51:55.000000000 +0200 -@@ -237,6 +237,7 @@ - *) - end ; - let _ = finalize false in -+ begin try Sys.remove Parse_opts.name_out with _ -> () end; - prerr_endline "Adios" ; - exit 2 - ;; ---- hevea-1.10/Makefile.orig 2009-10-28 12:18:16.000000000 +0100 -+++ hevea-1.10/Makefile 2009-10-28 12:18:00.000000000 +0100 -@@ -48,7 +48,7 @@ - all-make: $(TARGET)-make - - install: config.sh -- ./install.sh $(TARGET) -+ LIBDIR=${LIBDIR} LATEXLIBDIR=${LATEXLIBDIR} ./install.sh $(TARGET) - - byte: ocb-byte - opt: ocb-opt diff --git a/testsuite/external/kaputt-1.2.patch b/testsuite/external/kaputt-1.2.patch deleted file mode 100644 index 279730ed98..0000000000 --- a/testsuite/external/kaputt-1.2.patch +++ /dev/null @@ -1,37 +0,0 @@ ---- kaputt-1.2/src/syntax/kaputt_pp.ml.orig 2012-12-19 16:46:36.000000000 +0100 -+++ kaputt-1.2/src/syntax/kaputt_pp.ml 2012-12-19 16:46:59.000000000 +0100 -@@ -54,6 +54,8 @@ - let temp_name, temp_chan = Filename.open_temp_file "kaputt" ".ml" in - let source_chan = open_in args.(len - 3) in - let test_chan = open_in test_file in -+ let directive = Printf.sprintf "# 1 %S\n" args.(len - 3) in -+ output_string temp_chan directive; - copy source_chan temp_chan; - let directive = Printf.sprintf "# 1 %S\n" test_file in - output_string temp_chan directive; ---- kaputt-1.2/src/syntax/kaputt_pp.ml.orig 2013-01-08 17:05:01.000000000 +0100 -+++ kaputt-1.2/src/syntax/kaputt_pp.ml 2013-01-08 17:05:46.000000000 +0100 -@@ -28,8 +28,7 @@ - Buffer.add_string buff (quote args.(i)); - Buffer.add_char buff ' '; - done; -- let code = Sys.command (Buffer.contents buff) in -- ignore (exit code) -+ Sys.command (Buffer.contents buff) - - let copy from_chan to_chan = - try -@@ -64,9 +63,11 @@ - close_in_noerr test_chan; - close_out_noerr temp_chan; - args.(len - 3) <- temp_name; -- call args -+ let code = call args in -+ (try Sys.remove temp_name with _ -> ()); -+ ignore (exit code) - end else begin -- call args -+ ignore (exit (call args)) - end - else begin - Printf.eprintf "Error: invalid command-line\n"; diff --git a/testsuite/external/lablgtk-2.14.2.patch b/testsuite/external/lablgtk-2.14.2.patch deleted file mode 100644 index 4824726a95..0000000000 --- a/testsuite/external/lablgtk-2.14.2.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- lablgtk-2.14.2/src/Makefile.orig 2012-07-31 17:37:12.000000000 +0200 -+++ lablgtk-2.14.2/src/Makefile 2012-07-31 17:37:17.000000000 +0200 -@@ -191,7 +191,7 @@ - .ml4.cmo: - $(CAMLC) -c -pp "$(CAMLP4O) -impl" -impl $< - .cmxa.cmxs: -- $(CAMLOPT) -verbose -o $@ -shared -linkall -I . \ -+ $(CAMLOPT) -o $@ -shared -linkall -I . \ - -ccopt '$(filter -L%, $(DYNLINKLIBS))' $< - - #.ml4.ml: diff --git a/testsuite/external/lablgtk-2.16.0.patch b/testsuite/external/lablgtk-2.16.0.patch deleted file mode 100644 index c16e10cc4c..0000000000 --- a/testsuite/external/lablgtk-2.16.0.patch +++ /dev/null @@ -1,22 +0,0 @@ ---- lablgtk-2.16.0.orig/src/gMenu.ml 2012-08-23 12:37:48.000000000 +0200 -+++ lablgtk-2.16.0/src/gMenu.ml 2013-02-18 20:12:27.000000000 +0100 -@@ -87,7 +87,7 @@ - - class menu_item_skel = [menu_item] pre_menu_item_skel - --let pack_item self ~packing ~show = -+let pack_item self ?packing ?show = - may packing ~f:(fun f -> (f (self :> menu_item) : unit)); - if show <> Some false then self#misc#show (); - self ---- lablgtk-2.16.0.orig/src/gFile.ml 2012-08-23 12:37:48.000000000 +0200 -+++ lablgtk-2.16.0/src/gFile.ml 2013-02-18 20:13:37.000000000 +0100 -@@ -179,7 +179,7 @@ - FileChooser.P.file_system_backend backend - [ Gobject.param FileChooser.P.action action ]) in - let o = new chooser_widget w in -- GObj.pack_return o ?packing ?show -+ GObj.pack_return o ~packing ~show - - class chooser_button_signals obj = object - inherit GContainer.container_signals_impl obj diff --git a/testsuite/external/lablgtkextras-1.1.patch b/testsuite/external/lablgtkextras-1.1.patch deleted file mode 100644 index 19acf21d09..0000000000 --- a/testsuite/external/lablgtkextras-1.1.patch +++ /dev/null @@ -1,22 +0,0 @@ ---- lablgtkextras-1.1.orig/checkocaml.ml 2012-04-13 16:51:37.000000000 +0200 -+++ lablgtkextras-1.1/checkocaml.ml 2012-05-25 16:23:36.000000000 +0200 -@@ -885,7 +885,7 @@ - let _ = !print "\n### checking required tools and libraries ###\n" - - let () = check_ocamlfind_package conf "config-file";; --let () = check_ocamlfind_package conf "lablgtk2.sourceview2";; -+let () = check_ocamlfind_package conf "lablgtk2";; - let () = check_ocamlfind_package conf ~min_version: [1;1] "xmlm";; - - let _ = !print "\n###\n" ---- lablgtkextras-1.1.orig/src/Makefile 2012-04-13 16:51:37.000000000 +0200 -+++ lablgtkextras-1.1/src/Makefile 2012-05-25 16:27:58.000000000 +0200 -@@ -26,7 +26,7 @@ - - include ../master.Makefile - --PACKAGES=config-file,lablgtk2.sourceview2,xmlm -+PACKAGES=config-file,lablgtk2,xmlm - OF_FLAGS= -package $(PACKAGES) - - COMPFLAGS=-annot -g -warn-error A diff --git a/testsuite/external/lablgtkextras-1.3.patch b/testsuite/external/lablgtkextras-1.3.patch deleted file mode 100644 index e36480fd0a..0000000000 --- a/testsuite/external/lablgtkextras-1.3.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- lablgtkextras-1.3/src/Makefile.orig 2013-05-29 14:21:34.000000000 +0200 -+++ lablgtkextras-1.3/src/Makefile 2013-05-29 14:21:52.000000000 +0200 -@@ -29,7 +29,7 @@ - PACKAGES=config-file,lablgtk2.sourceview2,xmlm - OF_FLAGS= -package $(PACKAGES) - --COMPFLAGS=-annot -g -warn-error A -+COMPFLAGS=-annot -g -warn-error a - - GELIB_CMOFILES= \ - gtke_version.cmo \ diff --git a/testsuite/external/lwt-2.4.0.patch b/testsuite/external/lwt-2.4.0.patch deleted file mode 100644 index 14ce097cb5..0000000000 --- a/testsuite/external/lwt-2.4.0.patch +++ /dev/null @@ -1,24 +0,0 @@ ---- lwt-2.4.0.orig/src/unix/lwt_unix.ml 2012-07-19 13:35:56.000000000 +0200 -+++ lwt-2.4.0/src/unix/lwt_unix.ml 2013-08-13 15:46:12.000000000 +0200 -@@ -596,6 +596,9 @@ - #if ocaml_version >= (3, 13) - | O_SHARE_DELETE - #endif -+#if ocaml_version >= (4, 01) -+ | O_CLOEXEC -+#endif - - #if windows - ---- lwt-2.4.0.orig/src/unix/lwt_unix.mli 2012-07-19 13:35:56.000000000 +0200 -+++ lwt-2.4.0/src/unix/lwt_unix.mli 2013-08-13 15:46:18.000000000 +0200 -@@ -315,6 +315,9 @@ - #if ocaml_version >= (3, 13) - | O_SHARE_DELETE - #endif -+#if ocaml_version >= (4, 01) -+ | O_CLOEXEC -+#endif - - val openfile : string -> open_flag list -> file_perm -> file_descr Lwt.t - (** Wrapper for [Unix.openfile]. *) diff --git a/testsuite/external/menhir-20120123.patch b/testsuite/external/menhir-20120123.patch deleted file mode 100644 index a6a83bdf89..0000000000 --- a/testsuite/external/menhir-20120123.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- menhir-20120123/Makefile.arch.orig 2012-09-28 19:03:09.673811200 +0200 -+++ menhir-20120123/Makefile.arch 2012-09-28 19:07:38.680344000 +0200 -@@ -1,7 +1,7 @@ - # If ocaml reports that Sys.os_type is Unix, we assume Unix, otherwise - # we assume Windows. - --ifeq "$(shell rm -f ./o.ml && echo print_endline Sys.os_type > ./o.ml && ocaml ./o.ml && rm -f ./o.ml)" "Unix" -+ifneq "$(shell rm -f ./o.ml && echo print_endline Sys.os_type > ./o.ml && ocaml ./o.ml && rm -f ./o.ml)" "Win32" - MENHIREXE := menhir - OBJ := o - else diff --git a/testsuite/external/mldonkey-3.1.2.patch b/testsuite/external/mldonkey-3.1.2.patch deleted file mode 100644 index 82d3edb2fd..0000000000 --- a/testsuite/external/mldonkey-3.1.2.patch +++ /dev/null @@ -1,31 +0,0 @@ ---- mldonkey-3.1.2.orig/config/configure 2011-08-08 07:11:57.000000000 +0200 -+++ mldonkey-3.1.2/config/configure 2012-03-13 12:52:40.000000000 +0100 -@@ -4870,7 +4870,7 @@ - else - OCAMLVERSION=`$OCAMLC -v | sed -n -e 's|.*version* *\(.*\)$|\1|p' ` - case "$OCAMLVERSION" in -- "$REQUIRED_OCAML"*|3.12.*|3.11.*|3.10.1*|3.10.2*) ;; -+ "$REQUIRED_OCAML"*|4.*|3.1[23].*|3.11.*|3.10.1*|3.10.2*) ;; - *) - echo "Need build" - BUILD_OCAML=yes -@@ -5402,7 +5402,7 @@ - - # force usage of supported Ocaml versions - case "$OCAMLVERSION" in -- 3.10.1*|3.10.2*|3.1*) ;; -+ 3.10.1*|3.10.2*|3.1*|4.*) ;; - *) - if test "$REQUIRED_OCAML" != "SVN" ; then - echo "******** Version $REQUIRED_OCAML of Objective-Caml is required *********" 1>&2; ---- mldonkey-3.1.2.orig/Makefile 2012-05-16 11:56:34.000000000 +0200 -+++ mldonkey-3.1.2/Makefile 2012-05-25 19:24:15.000000000 +0200 -@@ -5447,7 +5449,7 @@ - $(OCAMLC) $(DEVFLAGS) $(INCLUDES) -c $< - - .mlcpp.ml: -- @$(CPP) -x c -P $< $(FIX_BROKEN_CPP) -o $@ -+ @$(CPP) -x c -P $< $(FIX_BROKEN_CPP) > $@ - - %.ml: %.mlp $(BITSTRING)/pa_bitstring.cmo - $(CAMLP4OF) build/bitstring.cma $(BITSTRING)/bitstring_persistent.cmo $(BITSTRING)/pa_bitstring.cmo -impl $< -o $@ diff --git a/testsuite/external/oasis-common.patch b/testsuite/external/oasis-common.patch deleted file mode 100644 index c13cd29052..0000000000 --- a/testsuite/external/oasis-common.patch +++ /dev/null @@ -1,55 +0,0 @@ ---- setup.ml 2011-03-22 17:00:48.000000000 +0100 -+++ setup.ml 2011-12-22 21:41:25.000000000 +0100 -@@ -2662,10 +2662,14 @@ - (ocamlc_config_map ()) - 0 - in -- let nm_config = -+ let chop_version_suffix s = -+ try String.sub s 0 (String.index s '+') -+ with _ -> s -+ in -+ let nm_config, value_config = - match nm with -- | "ocaml_version" -> "version" -- | _ -> nm -+ | "ocaml_version" -> "version", chop_version_suffix -+ | _ -> nm, (fun x -> x) - in - var_redefine - nm -@@ -2677,7 +2681,7 @@ - let value = - SMap.find nm_config map - in -- value -+ value_config value - with Not_found -> - failwithf2 - (f_ "Cannot find field '%s' in '%s -config' output") -@@ -3057,7 +3061,7 @@ - begin - let acc = - try -- Scanf.bscanf scbuf "%S %S@\n" -+ Scanf.bscanf scbuf "%S %S\n" - (fun e d -> - let t = - e, d ---- setup.ml.orig 2012-03-17 11:50:20.000000000 +0100 -+++ setup.ml 2012-07-31 17:45:43.000000000 +0200 -@@ -2284,7 +2284,13 @@ - let cmdline = - String.concat " " (cmd :: args) - in -- info (f_ "Running command '%s'") cmdline; -+ let printable_cmdline = -+ match List.rev args with -+ | _ :: (">" | "2>") :: rest -> -+ String.concat " " (cmd :: List.rev ("[file]" :: ">" :: rest)) -+ | _ -> cmdline -+ in -+ info (f_ "Running command '%s'") printable_cmdline; - match f_exit_code, Sys.command cmdline with - | None, 0 -> () - | None, i -> diff --git a/testsuite/external/obrowser-1.1.1.patch b/testsuite/external/obrowser-1.1.1.patch deleted file mode 100644 index f67a3b7a83..0000000000 --- a/testsuite/external/obrowser-1.1.1.patch +++ /dev/null @@ -1,1385 +0,0 @@ ---- obrowser-1.1.1/Makefile.orig 2011-07-05 16:15:30.000000000 +0200 -+++ obrowser-1.1.1/Makefile 2011-07-05 16:16:42.000000000 +0200 -@@ -16,9 +16,9 @@ - EXAMPLES = $(patsubst examples/%,%, $(wildcard examples/*)) - EXAMPLES_TARGETS = $(patsubst examples/%,%.example, $(wildcard examples/*)) - OCAMLFIND = ocamlfind --.PHONY: tuto dist plugin lwt -+.PHONY: tuto dist plugin lwt AXO - --all: .check_version rt/caml/stdlib.cma vm.js tuto $(EXAMPLES_TARGETS) examples.html AXO lwt -+all: .check_version rt/caml/stdlib.cma vm.js tuto AXO $(EXAMPLES_TARGETS) examples.html lwt - - .check_version: - @[ "$(shell ocamlc -vnum)" = "3.12.0" ] || \ ---- obrowser-1.1.1.orig/Makefile 2011-04-20 18:26:44.000000000 +0200 -+++ obrowser-1.1.1/Makefile 2012-03-12 16:55:44.000000000 +0100 -@@ -21,10 +21,11 @@ - all: .check_version rt/caml/stdlib.cma vm.js tuto $(EXAMPLES_TARGETS) examples.html AXO lwt - - .check_version: -- @[ "$(shell ocamlc -vnum)" = "3.12.0" ] || \ -- [ "$(shell ocamlc -vnum)" = "3.12.1" ] || \ -- ( echo "You need ocaml version 3.12.0 or 3.12.1"; \ -- exit 1 ) -+ @case `ocaml -vnum` in \ -+ 3.1[2-9].*);; \ -+ 4.*);; \ -+ *) echo "You need ocaml version 3.12.0 or later"; exit 1;; \ -+ esac - touch $@ - - %.example: ---- obrowser-1.1.1.orig/rt/caml/pervasives.mli 2011-04-20 18:26:44.000000000 +0200 -+++ obrowser-1.1.1/rt/caml/pervasives.mli 2012-01-12 01:07:49.000000000 +0100 -@@ -1,6 +1,6 @@ - (***********************************************************************) - (* *) --(* Objective Caml *) -+(* OCaml *) - (* *) - (* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) - (* *) -@@ -52,24 +52,24 @@ - Equality between cyclic data structures may not terminate. *) - - external ( <> ) : 'a -> 'a -> bool = "%notequal" --(** Negation of {!Pervasives.(=)}. *) -+(** Negation of {!Pervasives.( = )}. *) - - external ( < ) : 'a -> 'a -> bool = "%lessthan" --(** See {!Pervasives.(>=)}. *) -+(** See {!Pervasives.( >= )}. *) - - external ( > ) : 'a -> 'a -> bool = "%greaterthan" --(** See {!Pervasives.(>=)}. *) -+(** See {!Pervasives.( >= )}. *) - - external ( <= ) : 'a -> 'a -> bool = "%lessequal" --(** See {!Pervasives.(>=)}. *) -+(** See {!Pervasives.( >= )}. *) - - external ( >= ) : 'a -> 'a -> bool = "%greaterequal" - (** Structural ordering functions. These functions coincide with - the usual orderings over integers, characters, strings - and floating-point numbers, and extend them to a - total ordering over all types. -- The ordering is compatible with [(=)]. As in the case -- of [(=)], mutable structures are compared by contents. -+ The ordering is compatible with [( = )]. As in the case -+ of [( = )], mutable structures are compared by contents. - Comparison between functional values raises [Invalid_argument]. - Comparison between cyclic structures may not terminate. *) - -@@ -108,12 +108,12 @@ - mutable fields and objects with mutable instance variables, - [e1 == e2] is true if and only if physical modification of [e1] - also affects [e2]. -- On non-mutable types, the behavior of [(==)] is -+ On non-mutable types, the behavior of [( == )] is - implementation-dependent; however, it is guaranteed that - [e1 == e2] implies [compare e1 e2 = 0]. *) - - external ( != ) : 'a -> 'a -> bool = "%noteq" --(** Negation of {!Pervasives.(==)}. *) -+(** Negation of {!Pervasives.( == )}. *) - - - (** {6 Boolean operations} *) -@@ -229,7 +229,7 @@ - - (** {6 Floating-point arithmetic} - -- Caml's floating-point numbers follow the -+ OCaml's floating-point numbers follow the - IEEE 754 standard, using double precision (64 bits) numbers. - Floating-point operations never raise an exception on overflow, - underflow, division by zero, etc. Instead, special IEEE numbers -@@ -310,10 +310,18 @@ - Result is in radians and is between [-pi/2] and [pi/2]. *) - - external atan2 : float -> float -> float = "caml_atan2_float" "atan2" "float" --(** [atan x y] returns the arc tangent of [y /. x]. The signs of [x] -+(** [atan2 y x] returns the arc tangent of [y /. x]. The signs of [x] - and [y] are used to determine the quadrant of the result. - Result is in radians and is between [-pi] and [pi]. *) - -+external hypot : float -> float -> float -+ = "caml_hypot_float" "caml_hypot" "float" -+(** [hypot x y] returns [sqrt(x *. x + y *. y)], that is, the length -+ of the hypotenuse of a right-angled triangle with sides of length -+ [x] and [y], or, equivalently, the distance of the point [(x,y)] -+ to origin. -+ @since 3.13.0 *) -+ - external cosh : float -> float = "caml_cosh_float" "cosh" "float" - (** Hyperbolic cosine. Argument is in radians. *) - -@@ -337,6 +345,14 @@ - external abs_float : float -> float = "%absfloat" - (** [abs_float f] returns the absolute value of [f]. *) - -+external copysign : float -> float -> float -+ = "caml_copysign_float" "caml_copysign" "float" -+(** [copysign x y] returns a float whose absolute value is that of [x] -+ and whose sign is that of [y]. If [x] is [nan], returns [nan]. -+ If [y] is [nan], returns either [x] or [-. x], but it is not -+ specified which. -+ @since 3.13.0 *) -+ - external mod_float : float -> float -> float = "caml_fmod_float" "fmod" "float" - (** [mod_float a b] returns the remainder of [a] with respect to - [b]. The returned value is [a -. n *. b], where [n] -@@ -505,7 +521,7 @@ - (** The standard output for the process. *) - - val stderr : out_channel --(** The standard error ouput for the process. *) -+(** The standard error output for the process. *) - - - (** {7 Output functions on standard output} *) -@@ -642,7 +658,7 @@ - The given integer is taken modulo 2{^32}. - The only reliable way to read it back is through the - {!Pervasives.input_binary_int} function. The format is compatible across -- all machines for a given version of Objective Caml. *) -+ all machines for a given version of OCaml. *) - - val output_value : out_channel -> 'a -> unit - (** Write the representation of a structured value of any type -@@ -855,12 +871,16 @@ - (** Format strings have a general and highly polymorphic type - [('a, 'b, 'c, 'd, 'e, 'f) format6]. Type [format6] is built in. - The two simplified types, [format] and [format4] below are -- included for backward compatibility with earlier releases of Objective -- Caml. -+ included for backward compatibility with earlier releases of OCaml. - ['a] is the type of the parameters of the format, -- ['c] is the result type for the "printf"-style function, -- and ['b] is the type of the first argument given to -- [%a] and [%t] printing functions. *) -+ ['b] is the type of the first argument given to -+ [%a] and [%t] printing functions, -+ ['c] is the type of the argument transmitted to the first argument of -+ "kprintf"-style functions, -+ ['d] is the result type for the "scanf"-style functions, -+ ['e] is the type of the receiver function for the "scanf"-style functions, -+ ['f] is the result type for the "printf"-style function. -+ *) - type ('a, 'b, 'c, 'd) format4 = ('a, 'b, 'c, 'c, 'c, 'd) format6 - - type ('a, 'b, 'c) format = ('a, 'b, 'c, 'c) format4 -@@ -888,7 +908,7 @@ - (** Terminate the process, returning the given status code - to the operating system: usually 0 to indicate no errors, - and a small positive integer to indicate failure. -- All open output channels are flushed with flush_all. -+ All open output channels are flushed with [flush_all]. - An implicit [exit 0] is performed each time a program - terminates normally. An implicit [exit 2] is performed if the program - terminates early because of an uncaught exception. *) ---- obrowser-1.1.1.orig/rt/caml/pervasives.ml 2011-04-20 18:26:44.000000000 +0200 -+++ obrowser-1.1.1/rt/caml/pervasives.ml 2012-01-12 17:04:04.000000000 +0100 -@@ -91,6 +91,8 @@ - external asin : float -> float = "caml_asin_float" "asin" "float" - external atan : float -> float = "caml_atan_float" "atan" "float" - external atan2 : float -> float -> float = "caml_atan2_float" "atan2" "float" -+external hypot : float -> float -> float -+ = "caml_hypot_float" "caml_hypot" "float" - external cos : float -> float = "caml_cos_float" "cos" "float" - external cosh : float -> float = "caml_cosh_float" "cosh" "float" - external log : float -> float = "caml_log_float" "log" "float" -@@ -104,6 +106,8 @@ - external ceil : float -> float = "caml_ceil_float" "ceil" "float" - external floor : float -> float = "caml_floor_float" "floor" "float" - external abs_float : float -> float = "%absfloat" -+external copysign : float -> float -> float -+ = "caml_copysign_float" "caml_copysign" "float" - external mod_float : float -> float -> float = "caml_fmod_float" "fmod" "float" - external frexp : float -> float * int = "caml_frexp_float" - external ldexp : float -> int -> float = "caml_ldexp_float" ---- obrowser-1.1.1.orig/rt/caml/list.ml 2011-04-20 18:26:44.000000000 +0200 -+++ obrowser-1.1.1/rt/caml/list.ml 2012-01-12 17:30:31.000000000 +0100 -@@ -1,6 +1,6 @@ - (***********************************************************************) - (* *) --(* Objective Caml *) -+(* OCaml *) - (* *) - (* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) - (* *) -@@ -56,6 +56,12 @@ - [] -> [] - | a::l -> let r = f a in r :: map f l - -+let rec mapi i f = function -+ [] -> [] -+ | a::l -> let r = f i a in r :: mapi (i + 1) f l -+ -+let mapi f l = mapi 0 f l -+ - let rev_map f l = - let rec rmap_f accu = function - | [] -> accu -@@ -68,6 +74,12 @@ - [] -> () - | a::l -> f a; iter f l - -+let rec iteri i f = function -+ [] -> () -+ | a::l -> f i a; iteri (i + 1) f l -+ -+let iteri f l = iteri 0 f l -+ - let rec fold_left f accu l = - match l with - [] -> accu ---- obrowser-1.1.1.orig/rt/caml/list.mli 2011-04-20 18:26:44.000000000 +0200 -+++ obrowser-1.1.1/rt/caml/list.mli 2012-01-12 17:30:31.000000000 +0100 -@@ -1,6 +1,6 @@ - (***********************************************************************) - (* *) --(* Objective Caml *) -+(* OCaml *) - (* *) - (* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) - (* *) -@@ -75,11 +75,25 @@ - [a1; ...; an]. It is equivalent to - [begin f a1; f a2; ...; f an; () end]. *) - -+val iteri : (int -> 'a -> unit) -> 'a list -> unit -+(** Same as {!List.iter}, but the function is applied to the index of -+ the element as first argument (counting from 0), and the element -+ itself as second argument. -+ @since 3.13.0 -+*) -+ - val map : ('a -> 'b) -> 'a list -> 'b list - (** [List.map f [a1; ...; an]] applies function [f] to [a1, ..., an], - and builds the list [[f a1; ...; f an]] - with the results returned by [f]. Not tail-recursive. *) - -+val mapi : (int -> 'a -> 'b) -> 'a list -> 'b list -+(** Same as {!List.map}, but the function is applied to the index of -+ the element as first argument (counting from 0), and the element -+ itself as second argument. Not tail-recursive. -+ @since 3.13.0 -+*) -+ - val rev_map : ('a -> 'b) -> 'a list -> 'b list - (** [List.rev_map f l] gives the same result as - {!List.rev}[ (]{!List.map}[ f l)], but is tail-recursive and ---- obrowser-1.1.1-old/rt/caml/pervasives.mli 2013-06-20 13:50:19.000000000 +0200 -+++ obrowser-1.1.1/rt/caml/pervasives.mli 2013-06-20 13:50:59.000000000 +0200 -@@ -11,8 +11,6 @@ - (* *) - (***********************************************************************) - --(* $Id: pervasives.mli 10548 2010-06-09 10:26:19Z weis $ *) -- - (** The initially opened module. - - This module provides the basic operations over the built-in types -@@ -122,7 +120,7 @@ - (** The boolean negation. *) - - external ( && ) : bool -> bool -> bool = "%sequand" --(** The boolean ``and''. Evaluation is sequential, left-to-right: -+(** The boolean 'and'. Evaluation is sequential, left-to-right: - in [e1 && e2], [e1] is evaluated first, and if it returns [false], - [e2] is not evaluated at all. *) - -@@ -130,7 +128,7 @@ - (** @deprecated {!Pervasives.( && )} should be used instead. *) - - external ( || ) : bool -> bool -> bool = "%sequor" --(** The boolean ``or''. Evaluation is sequential, left-to-right: -+(** The boolean 'or'. Evaluation is sequential, left-to-right: - in [e1 || e2], [e1] is evaluated first, and if it returns [true], - [e2] is not evaluated at all. *) - -@@ -138,6 +136,20 @@ - (** @deprecated {!Pervasives.( || )} should be used instead.*) - - -+(** {6 Composition operators} *) -+ -+external ( |> ) : 'a -> ('a -> 'b) -> 'b = "%revapply" -+(** Reverse-application operator: [x |> f |> g] is exactly equivalent -+ to [g (f (x))]. -+ @since 4.01 -+*) -+ -+external ( @@ ) : ('a -> 'b) -> 'a -> 'b = "%apply" -+(** Application operator: [g @@ f @@ x] is exactly equivalent to -+ [g (f (x))]. -+ @since 4.01 -+*) -+ - (** {6 Integer arithmetic} *) - - (** Integers are 31 bits wide (or 63 bits on 64-bit processors). -@@ -234,7 +246,7 @@ - Floating-point operations never raise an exception on overflow, - underflow, division by zero, etc. Instead, special IEEE numbers - are returned as appropriate, such as [infinity] for [1.0 /. 0.0], -- [neg_infinity] for [-1.0 /. 0.0], and [nan] (``not a number'') -+ [neg_infinity] for [-1.0 /. 0.0], and [nan] ('not a number') - for [0.0 /. 0.0]. These special numbers then propagate through - floating-point computations as expected: for instance, - [1.0 /. infinity] is [0.0], and any arithmetic operation with [nan] -@@ -320,7 +332,7 @@ - of the hypotenuse of a right-angled triangle with sides of length - [x] and [y], or, equivalently, the distance of the point [(x,y)] - to origin. -- @since 3.13.0 *) -+ @since 4.00.0 *) - - external cosh : float -> float = "caml_cosh_float" "cosh" "float" - (** Hyperbolic cosine. Argument is in radians. *) -@@ -351,7 +363,7 @@ - and whose sign is that of [y]. If [x] is [nan], returns [nan]. - If [y] is [nan], returns either [x] or [-. x], but it is not - specified which. -- @since 3.13.0 *) -+ @since 4.00.0 *) - - external mod_float : float -> float -> float = "caml_fmod_float" "fmod" "float" - (** [mod_float a b] returns the remainder of [a] with respect to -@@ -395,7 +407,7 @@ - val nan : float - (** A special floating-point value denoting the result of an - undefined operation such as [0.0 /. 0.0]. Stands for -- ``not a number''. Any floating-point operation with [nan] as -+ 'not a number'. Any floating-point operation with [nan] as - argument returns [nan] as result. As for floating-point comparisons, - [=], [<], [<=], [>] and [>=] return [false] and [<>] returns [true] - if one or both of their arguments is [nan]. *) -@@ -461,7 +473,9 @@ - (** {6 String conversion functions} *) - - val string_of_bool : bool -> string --(** Return the string representation of a boolean. *) -+(** Return the string representation of a boolean. As the returned values -+ may be shared, the user should not modify them directly. -+*) - - val bool_of_string : string -> bool - (** Convert the given string to a boolean. -@@ -506,7 +520,9 @@ - (** List concatenation. *) - - --(** {6 Input/output} *) -+(** {6 Input/output} -+ Note: all input/output functions can raise [Sys_error] when the system -+ calls they invoke fail. *) - - type in_channel - (** The type of input channel. *) -@@ -864,23 +880,73 @@ - - (** {6 Operations on format strings} *) - --(** Format strings are used to read and print data using formatted input -- functions in module {!Scanf} and formatted output in modules {!Printf} and -- {!Format}. *) -+(** Format strings are character strings with special lexical conventions -+ that defines the functionality of formatted input/output functions. Format -+ strings are used to read data with formatted input functions from module -+ {!Scanf} and to print data with formatted output functions from modules -+ {!Printf} and {!Format}. -+ -+ Format strings are made of three kinds of entities: -+ - {e conversions specifications}, introduced by the special character ['%'] -+ followed by one or more characters specifying what kind of argument to -+ read or print, -+ - {e formatting indications}, introduced by the special character ['@'] -+ followed by one or more characters specifying how to read or print the -+ argument, -+ - {e plain characters} that are regular characters with usual lexical -+ conventions. Plain characters specify string literals to be read in the -+ input or printed in the output. -+ -+ There is an additional lexical rule to escape the special characters ['%'] -+ and ['@'] in format strings: if a special character follows a ['%'] -+ character, it is treated as a plain character. In other words, ["%%"] is -+ considered as a plain ['%'] and ["%@"] as a plain ['@']. -+ -+ For more information about conversion specifications and formatting -+ indications available, read the documentation of modules {!Scanf}, -+ {!Printf} and {!Format}. -+*) - - (** Format strings have a general and highly polymorphic type - [('a, 'b, 'c, 'd, 'e, 'f) format6]. Type [format6] is built in. - The two simplified types, [format] and [format4] below are -- included for backward compatibility with earlier releases of OCaml. -- ['a] is the type of the parameters of the format, -- ['b] is the type of the first argument given to -- [%a] and [%t] printing functions, -- ['c] is the type of the argument transmitted to the first argument of -- "kprintf"-style functions, -- ['d] is the result type for the "scanf"-style functions, -- ['e] is the type of the receiver function for the "scanf"-style functions, -- ['f] is the result type for the "printf"-style function. -- *) -+ included for backward compatibility with earlier releases of -+ OCaml. -+ -+ The meaning of format string type parameters is as follows: -+ -+ - ['a] is the type of the parameters of the format for formatted output -+ functions ([printf]-style functions); -+ ['a] is the type of the values read by the format for formatted input -+ functions ([scanf]-style functions). -+ -+ - ['b] is the type of input source for formatted input functions and the -+ type of output target for formatted output functions. -+ For [printf]-style functions from module [Printf], ['b] is typically -+ [out_channel]; -+ for [printf]-style functions from module [Format], ['b] is typically -+ [Format.formatter]; -+ for [scanf]-style functions from module [Scanf], ['b] is typically -+ [Scanf.Scanning.in_channel]. -+ -+ Type argument ['b] is also the type of the first argument given to -+ user's defined printing functions for [%a] and [%t] conversions, -+ and user's defined reading functions for [%r] conversion. -+ -+ - ['c] is the type of the result of the [%a] and [%t] printing -+ functions, and also the type of the argument transmitted to the -+ first argument of [kprintf]-style functions or to the -+ [kscanf]-style functions. -+ -+ - ['d] is the type of parameters for the [scanf]-style functions. -+ -+ - ['e] is the type of the receiver function for the [scanf]-style functions. -+ -+ - ['f] is the final result type of a formatted input/output function -+ invocation: for the [printf]-style functions, it is typically [unit]; -+ for the [scanf]-style functions, it is typically the result type of the -+ receiver function. -+*) - type ('a, 'b, 'c, 'd) format4 = ('a, 'b, 'c, 'c, 'c, 'd) format6 - - type ('a, 'b, 'c) format = ('a, 'b, 'c, 'c) format4 -@@ -892,14 +958,22 @@ - ('a, 'b, 'c, 'd, 'e, 'f) format6 -> - ('a, 'b, 'c, 'd, 'e, 'f) format6 = "%identity" - (** [format_of_string s] returns a format string read from the string -- literal [s]. *) -+ literal [s]. -+ Note: [format_of_string] can not convert a string argument that is not a -+ literal. If you need this functionality, use the more general -+ {!Scanf.format_from_string} function. -+*) - - val ( ^^ ) : - ('a, 'b, 'c, 'd, 'e, 'f) format6 -> - ('f, 'b, 'c, 'e, 'g, 'h) format6 -> - ('a, 'b, 'c, 'd, 'g, 'h) format6 --(** [f1 ^^ f2] catenates formats [f1] and [f2]. The result is a format -- that accepts arguments from [f1], then arguments from [f2]. *) -+(** [f1 ^^ f2] catenates format strings [f1] and [f2]. The result is a -+ format string that behaves as the concatenation of format strings [f1] and -+ [f2]: in case of formatted output, it accepts arguments from [f1], then -+ arguments from [f2]; in case of formatted input, it returns results from -+ [f1], then results from [f2]. -+*) - - - (** {6 Program termination} *) -@@ -918,13 +992,12 @@ - termination time. The functions registered with [at_exit] - will be called when the program executes {!Pervasives.exit}, - or terminates, either normally or because of an uncaught exception. -- The functions are called in ``last in, first out'' order: -+ The functions are called in 'last in, first out' order: - the function most recently added with [at_exit] is called first. *) - - (**/**) - -- --(** {6 For system use only, not for the casual user} *) -+(* The following is for system use only. Do not call directly. *) - - val valid_float_lexem : string -> string - ---- obrowser-1.1.1-old/rt/caml/pervasives.ml 2013-06-20 13:50:19.000000000 +0200 -+++ obrowser-1.1.1/rt/caml/pervasives.ml 2013-06-20 13:51:53.000000000 +0200 -@@ -1,6 +1,6 @@ - (***********************************************************************) - (* *) --(* Objective Caml *) -+(* OCaml *) - (* *) - (* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) - (* *) -@@ -11,8 +11,6 @@ - (* *) - (***********************************************************************) - --(* $Id: pervasives.ml 9412 2009-11-09 11:42:39Z weis $ *) -- - (* type 'a option = None | Some of 'a *) - - (* Exceptions *) -@@ -24,66 +22,70 @@ - - exception Exit - -+(* Composition operators *) -+ -+external ( |> ) : 'a -> ('a -> 'b) -> 'b = "%revapply" -+external ( @@ ) : ('a -> 'b) -> 'a -> 'b = "%apply" -+ - (* Comparisons *) - --external (=) : 'a -> 'a -> bool = "%equal" --external (<>) : 'a -> 'a -> bool = "%notequal" --external (<) : 'a -> 'a -> bool = "%lessthan" --external (>) : 'a -> 'a -> bool = "%greaterthan" --external (<=) : 'a -> 'a -> bool = "%lessequal" --external (>=) : 'a -> 'a -> bool = "%greaterequal" --external compare: 'a -> 'a -> int = "%compare" -+external ( = ) : 'a -> 'a -> bool = "%equal" -+external ( <> ) : 'a -> 'a -> bool = "%notequal" -+external ( < ) : 'a -> 'a -> bool = "%lessthan" -+external ( > ) : 'a -> 'a -> bool = "%greaterthan" -+external ( <= ) : 'a -> 'a -> bool = "%lessequal" -+external ( >= ) : 'a -> 'a -> bool = "%greaterequal" -+external compare : 'a -> 'a -> int = "%compare" - - let min x y = if x <= y then x else y - let max x y = if x >= y then x else y - --external (==) : 'a -> 'a -> bool = "%eq" --external (!=) : 'a -> 'a -> bool = "%noteq" -+external ( == ) : 'a -> 'a -> bool = "%eq" -+external ( != ) : 'a -> 'a -> bool = "%noteq" - - (* Boolean operations *) - - external not : bool -> bool = "%boolnot" --external (&) : bool -> bool -> bool = "%sequand" --external (&&) : bool -> bool -> bool = "%sequand" --external (or) : bool -> bool -> bool = "%sequor" --external (||) : bool -> bool -> bool = "%sequor" -+external ( & ) : bool -> bool -> bool = "%sequand" -+external ( && ) : bool -> bool -> bool = "%sequand" -+external ( or ) : bool -> bool -> bool = "%sequor" -+external ( || ) : bool -> bool -> bool = "%sequor" - - (* Integer operations *) - --external (~-) : int -> int = "%negint" --external (~+) : int -> int = "%identity" -+external ( ~- ) : int -> int = "%negint" -+external ( ~+ ) : int -> int = "%identity" - external succ : int -> int = "%succint" - external pred : int -> int = "%predint" --external (+) : int -> int -> int = "%addint" --external (-) : int -> int -> int = "%subint" --external ( * ) : int -> int -> int = "%mulint" --external (/) : int -> int -> int = "%divint" --external (mod) : int -> int -> int = "%modint" -+external ( + ) : int -> int -> int = "%addint" -+external ( - ) : int -> int -> int = "%subint" -+external ( * ) : int -> int -> int = "%mulint" -+external ( / ) : int -> int -> int = "%divint" -+external ( mod ) : int -> int -> int = "%modint" - - let abs x = if x >= 0 then x else -x - --external (land) : int -> int -> int = "%andint" --external (lor) : int -> int -> int = "%orint" --external (lxor) : int -> int -> int = "%xorint" -+external ( land ) : int -> int -> int = "%andint" -+external ( lor ) : int -> int -> int = "%orint" -+external ( lxor ) : int -> int -> int = "%xorint" - - let lnot x = x lxor (-1) - --external (lsl) : int -> int -> int = "%lslint" --external (lsr) : int -> int -> int = "%lsrint" --external (asr) : int -> int -> int = "%asrint" -+external ( lsl ) : int -> int -> int = "%lslint" -+external ( lsr ) : int -> int -> int = "%lsrint" -+external ( asr ) : int -> int -> int = "%asrint" - --let min_int = 1 lsl (if 1 lsl 32 = 1 then 31 else 63) (* obrowser mod: no tag bit*) -+let min_int = 1 lsl (if 1 lsl 31 = 0 then 30 else 62) - let max_int = min_int - 1 - -- - (* Floating-point operations *) - --external (~-.) : float -> float = "%negfloat" --external (~+.) : float -> float = "%identity" --external (+.) : float -> float -> float = "%addfloat" --external (-.) : float -> float -> float = "%subfloat" -+external ( ~-. ) : float -> float = "%negfloat" -+external ( ~+. ) : float -> float = "%identity" -+external ( +. ) : float -> float -> float = "%addfloat" -+external ( -. ) : float -> float -> float = "%subfloat" - external ( *. ) : float -> float -> float = "%mulfloat" --external (/.) : float -> float -> float = "%divfloat" -+external ( /. ) : float -> float -> float = "%divfloat" - external ( ** ) : float -> float -> float = "caml_power_float" "pow" "float" - external exp : float -> float = "caml_exp_float" "exp" "float" - external expm1 : float -> float = "caml_expm1_float" "caml_expm1" "float" -@@ -136,16 +138,16 @@ - | FP_zero - | FP_infinite - | FP_nan --external classify_float: float -> fpclass = "caml_classify_float" -+external classify_float : float -> fpclass = "caml_classify_float" - - (* String operations -- more in module String *) - - external string_length : string -> int = "%string_length" --external string_create: int -> string = "caml_create_string" -+external string_create : int -> string = "caml_create_string" - external string_blit : string -> int -> string -> int -> int -> unit - = "caml_blit_string" "noalloc" - --let (^) s1 s2 = -+let ( ^ ) s1 s2 = - let l1 = string_length s1 and l2 = string_length s2 in - let s = string_create (l1 + l2) in - string_blit s1 0 s 0 l1; -@@ -170,8 +172,8 @@ - - (* String conversion functions *) - --external format_int: string -> int -> string = "caml_format_int" --external format_float: string -> float -> string = "caml_format_float" -+external format_int : string -> int -> string = "caml_format_int" -+external format_float : string -> float -> string = "caml_format_float" - - let string_of_bool b = - if b then "true" else "false" -@@ -187,7 +189,6 @@ - - module String = struct - external get : string -> int -> char = "%string_safe_get" -- external set : string -> int -> char -> unit = "%string_safe_set" - end - - let valid_float_lexem s = -@@ -195,7 +196,7 @@ - let rec loop i = - if i >= l then s ^ "." else - match s.[i] with -- | '0' .. '9' | '-' -> loop (i+1) -+ | '0' .. '9' | '-' -> loop (i + 1) - | _ -> s - in - loop 0 -@@ -207,7 +208,7 @@ - - (* List operations -- more in module List *) - --let rec (@) l1 l2 = -+let rec ( @ ) l1 l2 = - match l1 with - [] -> l2 - | hd :: tl -> hd :: (tl @ l2) -@@ -217,12 +218,13 @@ - type in_channel - type out_channel - --let open_descriptor_out _ = failwith "not implemented in obrowser" --let open_descriptor_in _ = failwith "not implemented in obrowser" -- --let stdin = Obj.magic 0 --let stdout = Obj.magic 0 --let stderr = Obj.magic 0 -+external open_descriptor_out : int -> out_channel -+ = "caml_ml_open_descriptor_out" -+external open_descriptor_in : int -> in_channel = "caml_ml_open_descriptor_in" -+ -+let stdin = open_descriptor_in 0 -+let stdout = open_descriptor_out 1 -+let stderr = open_descriptor_out 2 - - (* General output functions *) - -@@ -231,103 +233,184 @@ - | Open_creat | Open_trunc | Open_excl - | Open_binary | Open_text | Open_nonblock - --let open_desc _ _ _ = failwith "not implemented in obrowser" --let open_out_gen mode perm name = failwith "not implemented in obrowser" --let open_out name = failwith "not implemented in obrowser" --let open_out_bin name = failwith "not implemented in obrowser" --let flush _ = failwith "not implemented in obrowser" --let out_channels_list _ = failwith "not implemented in obrowser" --let flush_all () = failwith "not implemented in obrowser" --let unsafe_output _ _ _ _ = failwith "not implemented in obrowser" --let output_char _ _ = failwith "not implemented in obrowser" --let output_string oc s = failwith "not implemented in obrowser" --let output oc s ofs len = failwith "not implemented in obrowser" --let output_byte _ _ = failwith "not implemented in obrowser" --let output_binary_int _ _ = failwith "not implemented in obrowser" --let marshal_to_channel _ _ _ = failwith "not implemented in obrowser" --let output_value _ _ = failwith "not implemented in obrowser" --let seek_out _ _ = failwith "not implemented in obrowser" --let pos_out _ = failwith "not implemented in obrowser" --let out_channel_length _ = failwith "not implemented in obrowser" --let close_out_channel _ = failwith "not implemented in obrowser" --let close_out _ = failwith "not implemented in obrowser" --let close_out_noerr _ = failwith "not implemented in obrowser" --let set_binary_mode_out _ _ = failwith "not implemented in obrowser" -+external open_desc : string -> open_flag list -> int -> int = "caml_sys_open" -+ -+let open_out_gen mode perm name = -+ open_descriptor_out(open_desc name mode perm) -+ -+let open_out name = -+ open_out_gen [Open_wronly; Open_creat; Open_trunc; Open_text] 0o666 name -+ -+let open_out_bin name = -+ open_out_gen [Open_wronly; Open_creat; Open_trunc; Open_binary] 0o666 name -+ -+external flush : out_channel -> unit = "caml_ml_flush" -+ -+external out_channels_list : unit -> out_channel list -+ = "caml_ml_out_channels_list" -+ -+let flush_all () = -+ let rec iter = function -+ [] -> () -+ | a :: l -> (try flush a with _ -> ()); iter l -+ in iter (out_channels_list ()) -+ -+external unsafe_output : out_channel -> string -> int -> int -> unit -+ = "caml_ml_output" -+ -+external output_char : out_channel -> char -> unit = "caml_ml_output_char" -+ -+let output_string oc s = -+ unsafe_output oc s 0 (string_length s) -+ -+let output oc s ofs len = -+ if ofs < 0 || len < 0 || ofs > string_length s - len -+ then invalid_arg "output" -+ else unsafe_output oc s ofs len -+ -+external output_byte : out_channel -> int -> unit = "caml_ml_output_char" -+external output_binary_int : out_channel -> int -> unit = "caml_ml_output_int" -+ -+external marshal_to_channel : out_channel -> 'a -> unit list -> unit -+ = "caml_output_value" -+let output_value chan v = marshal_to_channel chan v [] -+ -+external seek_out : out_channel -> int -> unit = "caml_ml_seek_out" -+external pos_out : out_channel -> int = "caml_ml_pos_out" -+external out_channel_length : out_channel -> int = "caml_ml_channel_size" -+external close_out_channel : out_channel -> unit = "caml_ml_close_channel" -+let close_out oc = flush oc; close_out_channel oc -+let close_out_noerr oc = -+ (try flush oc with _ -> ()); -+ (try close_out_channel oc with _ -> ()) -+external set_binary_mode_out : out_channel -> bool -> unit -+ = "caml_ml_set_binary_mode" - - (* General input functions *) - --let open_in_gen _ _ _ = failwith "not implemented in obrowser" --let open_in _ = failwith "not implemented in obrowser" --let open_in_bin _ = failwith "not implemented in obrowser" --let input_char _ = failwith "not implemented in obrowser" --let unsafe_input _ _ _ _ = failwith "not implemented in obrowser" --let input _ _ _ _ = failwith "not implemented in obrowser" --let rec unsafe_really_input _ _ _ _ = failwith "not implemented in obrowser" --let really_input _ _ _ _ = failwith "not implemented in obrowser" --let input_scan_line _ = failwith "not implemented in obrowser" --let input_line _ = failwith "not implemented in obrowser" -- --let input_byte _ = failwith "not implemented in obrowser" --let input_binary_int _ = failwith "not implemented in obrowser" --let input_value _ = failwith "not implemented in obrowser" --let seek_in _ _ = failwith "not implemented in obrowser" --let pos_in _ = failwith "not implemented in obrowser" --let in_channel_length _ = failwith "not implemented in obrowser" --let close_in _ = failwith "not implemented in obrowser" --let close_in_noerr _ = failwith "not implemented in obrowser" --let set_binary_mode_in _ _ = failwith "not implemented in obrowser" -+let open_in_gen mode perm name = -+ open_descriptor_in(open_desc name mode perm) - --(* Output functions on standard output *) -+let open_in name = -+ open_in_gen [Open_rdonly; Open_text] 0 name -+ -+let open_in_bin name = -+ open_in_gen [Open_rdonly; Open_binary] 0 name -+ -+external input_char : in_channel -> char = "caml_ml_input_char" -+ -+external unsafe_input : in_channel -> string -> int -> int -> int -+ = "caml_ml_input" -+ -+let input ic s ofs len = -+ if ofs < 0 || len < 0 || ofs > string_length s - len -+ then invalid_arg "input" -+ else unsafe_input ic s ofs len -+ -+let rec unsafe_really_input ic s ofs len = -+ if len <= 0 then () else begin -+ let r = unsafe_input ic s ofs len in -+ if r = 0 -+ then raise End_of_file -+ else unsafe_really_input ic s (ofs + r) (len - r) -+ end - --external basic_io_write : string -> unit = "caml_basic_io_write" -+let really_input ic s ofs len = -+ if ofs < 0 || len < 0 || ofs > string_length s - len -+ then invalid_arg "really_input" -+ else unsafe_really_input ic s ofs len -+ -+external input_scan_line : in_channel -> int = "caml_ml_input_scan_line" -+ -+let input_line chan = -+ let rec build_result buf pos = function -+ [] -> buf -+ | hd :: tl -> -+ let len = string_length hd in -+ string_blit hd 0 buf (pos - len) len; -+ build_result buf (pos - len) tl in -+ let rec scan accu len = -+ let n = input_scan_line chan in -+ if n = 0 then begin (* n = 0: we are at EOF *) -+ match accu with -+ [] -> raise End_of_file -+ | _ -> build_result (string_create len) len accu -+ end else if n > 0 then begin (* n > 0: newline found in buffer *) -+ let res = string_create (n - 1) in -+ ignore (unsafe_input chan res 0 (n - 1)); -+ ignore (input_char chan); (* skip the newline *) -+ match accu with -+ [] -> res -+ | _ -> let len = len + n - 1 in -+ build_result (string_create len) len (res :: accu) -+ end else begin (* n < 0: newline not found *) -+ let beg = string_create (-n) in -+ ignore(unsafe_input chan beg 0 (-n)); -+ scan (beg :: accu) (len - n) -+ end -+ in scan [] 0 -+ -+external input_byte : in_channel -> int = "caml_ml_input_char" -+external input_binary_int : in_channel -> int = "caml_ml_input_int" -+external input_value : in_channel -> 'a = "caml_input_value" -+external seek_in : in_channel -> int -> unit = "caml_ml_seek_in" -+external pos_in : in_channel -> int = "caml_ml_pos_in" -+external in_channel_length : in_channel -> int = "caml_ml_channel_size" -+external close_in : in_channel -> unit = "caml_ml_close_channel" -+let close_in_noerr ic = (try close_in ic with _ -> ());; -+external set_binary_mode_in : in_channel -> bool -> unit -+ = "caml_ml_set_binary_mode" - --let print_char c = basic_io_write (let s = string_create 1 in s.[0] <- c ; s) --let print_string s = basic_io_write s --let print_int i = basic_io_write (string_of_int i) --let print_float f = basic_io_write (string_of_float f) -+(* Output functions on standard output *) -+ -+let print_char c = output_char stdout c -+let print_string s = output_string stdout s -+let print_int i = output_string stdout (string_of_int i) -+let print_float f = output_string stdout (string_of_float f) - let print_endline s = -- print_string s; print_char '\n' --let print_newline () = print_char '\n' -+ output_string stdout s; output_char stdout '\n'; flush stdout -+let print_newline () = output_char stdout '\n'; flush stdout - - (* Output functions on standard error *) - --let prerr_char c = basic_io_write (let s = string_create 1 in s.[0] <- c ; s) --let prerr_string s = basic_io_write s --let prerr_int i = basic_io_write (string_of_int i) --let prerr_float f = basic_io_write (string_of_float f) -+let prerr_char c = output_char stderr c -+let prerr_string s = output_string stderr s -+let prerr_int i = output_string stderr (string_of_int i) -+let prerr_float f = output_string stderr (string_of_float f) - let prerr_endline s = -- prerr_string s; prerr_char '\n' --let prerr_newline () = prerr_char '\n' -+ output_string stderr s; output_char stderr '\n'; flush stderr -+let prerr_newline () = output_char stderr '\n'; flush stderr - - (* Input functions on standard input *) - --let read_line () = failwith "not implemented in obrowser" --let read_int () = failwith "not implemented in obrowser" --let read_float () = failwith "not implemented in obrowser" -+let read_line () = flush stdout; input_line stdin -+let read_int () = int_of_string(read_line()) -+let read_float () = float_of_string(read_line()) - - (* Operations on large files *) - - module LargeFile = - struct -- let seek_out _ _ = failwith "not implemented in obrowser" -- let pos_out _ = failwith "not implemented in obrowser" -- let out_channel_length _ = failwith "not implemented in obrowser" -- let seek_in _ _ = failwith "not implemented in obrowser" -- let pos_in _ = failwith "not implemented in obrowser" -- let in_channel_length _ = failwith "not implemented in obrowser" -+ external seek_out : out_channel -> int64 -> unit = "caml_ml_seek_out_64" -+ external pos_out : out_channel -> int64 = "caml_ml_pos_out_64" -+ external out_channel_length : out_channel -> int64 -+ = "caml_ml_channel_size_64" -+ external seek_in : in_channel -> int64 -> unit = "caml_ml_seek_in_64" -+ external pos_in : in_channel -> int64 = "caml_ml_pos_in_64" -+ external in_channel_length : in_channel -> int64 = "caml_ml_channel_size_64" - end - - (* References *) - --type 'a ref = { mutable contents: 'a } --external ref: 'a -> 'a ref = "%makemutable" --external (!): 'a ref -> 'a = "%field0" --external (:=): 'a ref -> 'a -> unit = "%setfield0" --external incr: int ref -> unit = "%incr" --external decr: int ref -> unit = "%decr" -+type 'a ref = { mutable contents : 'a } -+external ref : 'a -> 'a ref = "%makemutable" -+external ( ! ) : 'a ref -> 'a = "%field0" -+external ( := ) : 'a ref -> 'a -> unit = "%setfield0" -+external incr : int ref -> unit = "%incr" -+external decr : int ref -> unit = "%decr" - - (* Formats *) --type ('a, 'b, 'c, 'd) format4 = ('a, 'b, 'c, 'c, 'c, 'd) format6 -+type ('a, 'b, 'c, 'd) format4 = ('a, 'b, 'c, 'c, 'c, 'd) format6 - - type ('a, 'b, 'c) format = ('a, 'b, 'c, 'c) format4 - -@@ -345,7 +428,8 @@ - ('f, 'b, 'c, 'e, 'g, 'h) format6 -> - ('a, 'b, 'c, 'd, 'g, 'h) format6) = - fun fmt1 fmt2 -> -- string_to_format (format_to_string fmt1 ^ format_to_string fmt2);; -+ string_to_format (format_to_string fmt1 ^ "%," ^ format_to_string fmt2) -+;; - - let string_of_format fmt = - let s = format_to_string fmt in -@@ -358,7 +442,7 @@ - - external sys_exit : int -> 'a = "caml_sys_exit" - --let exit_function = ref (fun () -> ()) -+let exit_function = ref flush_all - - let at_exit f = - let g = !exit_function in ---- obrowser-1.1.1.orig/rt/caml/printexc.ml 2011-04-20 18:26:44.000000000 +0200 -+++ obrowser-1.1.1/rt/caml/printexc.ml 2013-08-13 15:54:35.000000000 +0200 -@@ -1,6 +1,6 @@ - (***********************************************************************) - (* *) --(* Objective Caml *) -+(* OCaml *) - (* *) - (* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) - (* *) -@@ -11,8 +11,6 @@ - (* *) - (***********************************************************************) - --(* $Id: printexc.ml 10272 2010-04-19 12:25:46Z frisch $ *) -- - open Printf;; - - let printers = ref [] -@@ -56,9 +54,12 @@ - sprintf locfmt file line char (char+5) "Pattern matching failed" - | Assert_failure(file, line, char) -> - sprintf locfmt file line char (char+6) "Assertion failed" -+ | Undefined_recursive_module(file, line, char) -> -+ sprintf locfmt file line char (char+6) "Undefined recursive module" - | _ -> - let x = Obj.repr x in -- let constructor = (Obj.magic(Obj.field (Obj.field x 0) 0) : string) in -+ let constructor = -+ (Obj.magic (Obj.field (Obj.field x 0) 0) : string) in - constructor ^ (fields x) in - conv !printers - -@@ -78,6 +79,11 @@ - eprintf "Uncaught exception: %s\n" (to_string x); - exit 2 - -+type raw_backtrace -+ -+external get_raw_backtrace: -+ unit -> raw_backtrace = "caml_get_exception_raw_backtrace" -+ - type loc_info = - | Known_location of bool (* is_raise *) - * string (* filename *) -@@ -86,8 +92,13 @@ - * int (* end char *) - | Unknown_location of bool (*is_raise*) - --external get_exception_backtrace: -- unit -> loc_info array option = "caml_get_exception_backtrace" -+(* to avoid warning *) -+let _ = [Known_location (false, "", 0, 0, 0); Unknown_location false] -+ -+type backtrace = loc_info array -+ -+external convert_raw_backtrace: -+ raw_backtrace -> backtrace option = "caml_convert_raw_backtrace" - - let format_loc_info pos li = - let is_raise = -@@ -108,8 +119,8 @@ - sprintf "%s unknown location" - info - --let print_backtrace outchan = -- match get_exception_backtrace() with -+let print_exception_backtrace outchan backtrace = -+ match backtrace with - | None -> - fprintf outchan - "(Program not linked with -g, cannot print stack backtrace)\n" -@@ -119,8 +130,15 @@ - fprintf outchan "%s\n" (format_loc_info i a.(i)) - done - --let get_backtrace () = -- match get_exception_backtrace() with -+let print_raw_backtrace outchan raw_backtrace = -+ print_exception_backtrace outchan (convert_raw_backtrace raw_backtrace) -+ -+(* confusingly named: prints the global current backtrace *) -+let print_backtrace outchan = -+ print_raw_backtrace outchan (get_raw_backtrace ()) -+ -+let backtrace_to_string backtrace = -+ match backtrace with - | None -> - "(Program not linked with -g, cannot print stack backtrace)\n" - | Some a -> -@@ -131,8 +149,22 @@ - done; - Buffer.contents b - -+let raw_backtrace_to_string raw_backtrace = -+ backtrace_to_string (convert_raw_backtrace raw_backtrace) -+ -+(* confusingly named: -+ returns the *string* corresponding to the global current backtrace *) -+let get_backtrace () = -+ (* we could use the caml_get_exception_backtrace primitive here, but -+ we hope to deprecate it so it's better to just compose the -+ raw stuff *) -+ backtrace_to_string (convert_raw_backtrace (get_raw_backtrace ())) -+ - external record_backtrace: bool -> unit = "caml_record_backtrace" - external backtrace_status: unit -> bool = "caml_backtrace_status" - - let register_printer fn = - printers := fn :: !printers -+ -+ -+external get_callstack: int -> raw_backtrace = "caml_get_current_callstack" ---- obrowser-1.1.1.orig/rt/caml/printexc.mli 2011-04-20 18:26:44.000000000 +0200 -+++ obrowser-1.1.1/rt/caml/printexc.mli 2013-08-13 15:54:40.000000000 +0200 -@@ -1,6 +1,6 @@ - (***********************************************************************) - (* *) --(* Objective Caml *) -+(* OCaml *) - (* *) - (* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) - (* *) -@@ -11,9 +11,7 @@ - (* *) - (***********************************************************************) - --(* $Id: printexc.mli 10457 2010-05-21 18:30:12Z doligez $ *) -- --(** Facilities for printing exceptions. *) -+(** Facilities for printing exceptions and inspecting current call stack. *) - - val to_string: exn -> string - (** [Printexc.to_string e] returns a string representation of -@@ -77,5 +75,40 @@ - in the reverse order of their registrations, until a printer returns - a [Some s] value (if no such printer exists, the runtime will use a - generic printer). -+ -+ When using this mechanism, one should be aware that an exception backtrace -+ is attached to the thread that saw it raised, rather than to the exception -+ itself. Practically, it means that the code related to [fn] should not use -+ the backtrace if it has itself raised an exception before. - @since 3.11.2 - *) -+ -+(** {6 Raw backtraces} *) -+ -+type raw_backtrace -+ -+(** The abstract type [backtrace] stores exception backtraces in -+ a low-level format, instead of directly exposing them as string as -+ the [get_backtrace()] function does. -+ -+ This allows to pay the performance overhead of representation -+ conversion and formatting only at printing time, which is useful -+ if you want to record more backtrace than you actually print. -+*) -+ -+val get_raw_backtrace: unit -> raw_backtrace -+val print_raw_backtrace: out_channel -> raw_backtrace -> unit -+val raw_backtrace_to_string: raw_backtrace -> string -+ -+ -+(** {6 Current call stack} *) -+ -+val get_callstack: int -> raw_backtrace -+ -+(** [Printexc.get_callstack n] returns a description of the top of the -+ call stack on the current program point (for the current thread), -+ with at most [n] entries. (Note: this function is not related to -+ exceptions at all, despite being part of the [Printexc] module.) -+ -+ @since 4.01.0 -+*) ---- obrowser-1.1.1/rt/caml/pervasives.mli 2013-11-27 09:51:32.000000000 +0100 -+++ /usr/local/ocaml/trunk/lib/ocaml/pervasives.mli 2013-11-26 19:03:11.000000000 +0100 -@@ -28,6 +28,11 @@ - external raise : exn -> 'a = "%raise" - (** Raise the given exception value *) - -+external raise_notrace : exn -> 'a = "%raise_notrace" -+(** A faster version [raise] which does not record the backtrace. -+ @since 4.02.0 -+*) -+ - val invalid_arg : string -> 'a - (** Raise exception [Invalid_argument] with the given string. *) - ---- obrowser-1.1.1/rt/caml/pervasives.ml 2013-11-27 14:25:40.000000000 +0100 -+++ /usr/local/ocaml/trunk/lib/ocaml/pervasives.ml 2013-11-26 19:03:11.000000000 +0100 -@@ -15,7 +15,17 @@ - - (* Exceptions *) - -+external register_named_value : string -> 'a -> unit -+ = "caml_register_named_value" -+ -+let () = -+ (* for asmrun/fail.c *) -+ register_named_value "Pervasives.array_bound_error" -+ (Invalid_argument "index out of bounds") -+ -+ - external raise : exn -> 'a = "%raise" -+external raise_notrace : exn -> 'a = "%raise_notrace" - - let failwith s = raise(Failure s) - let invalid_arg s = raise(Invalid_argument s) -@@ -454,7 +464,4 @@ - do_at_exit (); - sys_exit retcode - --external register_named_value : string -> 'a -> unit -- = "caml_register_named_value" -- - let _ = register_named_value "Pervasives.do_at_exit" do_at_exit ---- obrowser-1.1.1/rt/caml/printexc.mli 2013-11-27 14:26:19.000000000 +0100 -+++ /usr/local/ocaml/trunk/lib/ocaml/printexc.mli 2013-11-26 19:03:11.000000000 +0100 -@@ -112,3 +112,23 @@ - - @since 4.01.0 - *) -+ -+ -+(** {6 Exception slots} *) -+ -+val exn_slot_id: exn -> int -+(** [Printexc.exn_slot_id] returns an integer which uniquely identifies -+ the constructor used to create the exception value [exn] -+ (in the current runtime). -+ -+ @since 4.02.0 -+*) -+ -+val exn_slot_name: exn -> string -+(** [Printexc.exn_slot_id exn] returns the internal name of the constructor -+ used to create the exception value [exn]. -+ -+ @since 4.02.0 -+*) -+ -+ ---- obrowser-1.1.1/rt/caml/printexc.ml 2013-11-27 14:27:37.000000000 +0100 -+++ /usr/local/ocaml/trunk/lib/ocaml/printexc.ml 2013-11-26 19:03:11.000000000 +0100 -@@ -58,9 +58,12 @@ - sprintf locfmt file line char (char+6) "Undefined recursive module" - | _ -> - let x = Obj.repr x in -- let constructor = -- (Obj.magic (Obj.field (Obj.field x 0) 0) : string) in -- constructor ^ (fields x) in -+ if Obj.tag x <> 0 then -+ (Obj.magic (Obj.field x 0) : string) -+ else -+ let constructor = -+ (Obj.magic (Obj.field (Obj.field x 0) 0) : string) in -+ constructor ^ (fields x) in - conv !printers - - let print fct arg = -@@ -168,3 +171,16 @@ - - - external get_callstack: int -> raw_backtrace = "caml_get_current_callstack" -+ -+ -+let exn_slot x = -+ let x = Obj.repr x in -+ if Obj.tag x = 0 then Obj.field x 0 else x -+ -+let exn_slot_id x = -+ let slot = exn_slot x in -+ (Obj.obj (Obj.field slot 1) : int) -+ -+let exn_slot_name x = -+ let slot = exn_slot x in -+ (Obj.obj (Obj.field slot 0) : string) ---- obrowser-1.1.1/rt/caml/list.mli 2013-11-27 14:28:14.000000000 +0100 -+++ /usr/local/ocaml/trunk/lib/ocaml/list.mli 2013-11-26 19:03:11.000000000 +0100 -@@ -280,6 +278,9 @@ - (** Same as {!List.sort} or {!List.stable_sort}, whichever is faster - on typical input. *) - -+val sort_uniq : ('a -> 'a -> int) -> 'a list -> 'a list -+(** Same as {!List.sort}, but also remove duplicates. *) -+ - val merge : ('a -> 'a -> int) -> 'a list -> 'a list -> 'a list - (** Merge two lists: - Assuming that [l1] and [l2] are sorted according to the ---- obrowser-1.1.1/rt/caml/list.ml 2013-11-27 14:29:31.000000000 +0100 -+++ /usr/local/ocaml/trunk/lib/ocaml/list.ml 2013-11-26 19:03:11.000000000 +0100 -@@ -326,3 +324,106 @@ - array_to_list_in_place a - ;; - *) -+ -+ -+(** sorting + removing duplicates *) -+ -+let sort_uniq cmp l = -+ let rec rev_merge l1 l2 accu = -+ match l1, l2 with -+ | [], l2 -> rev_append l2 accu -+ | l1, [] -> rev_append l1 accu -+ | h1::t1, h2::t2 -> -+ let c = cmp h1 h2 in -+ if c = 0 then rev_merge t1 t2 (h1::accu) -+ else if c < 0 -+ then rev_merge t1 l2 (h1::accu) -+ else rev_merge l1 t2 (h2::accu) -+ in -+ let rec rev_merge_rev l1 l2 accu = -+ match l1, l2 with -+ | [], l2 -> rev_append l2 accu -+ | l1, [] -> rev_append l1 accu -+ | h1::t1, h2::t2 -> -+ let c = cmp h1 h2 in -+ if c = 0 then rev_merge_rev t1 t2 (h1::accu) -+ else if c > 0 -+ then rev_merge_rev t1 l2 (h1::accu) -+ else rev_merge_rev l1 t2 (h2::accu) -+ in -+ let rec sort n l = -+ match n, l with -+ | 2, x1 :: x2 :: _ -> -+ let c = cmp x1 x2 in -+ if c = 0 then [x1] -+ else if c < 0 then [x1; x2] else [x2; x1] -+ | 3, x1 :: x2 :: x3 :: _ -> -+ let c = cmp x1 x2 in -+ if c = 0 then begin -+ let c = cmp x2 x3 in -+ if c = 0 then [x2] -+ else if c < 0 then [x2; x3] else [x3; x2] -+ end else if c < 0 then begin -+ let c = cmp x2 x3 in -+ if c = 0 then [x1; x2] -+ else if c < 0 then [x1; x2; x3] -+ else let c = cmp x1 x3 in -+ if c = 0 then [x1; x2] -+ else if c < 0 then [x1; x3; x2] -+ else [x3; x1; x2] -+ end else begin -+ let c = cmp x1 x3 in -+ if c = 0 then [x2; x1] -+ else if c < 0 then [x2; x1; x3] -+ else let c = cmp x2 x3 in -+ if c = 0 then [x2; x1] -+ else if c < 0 then [x2; x3; x1] -+ else [x3; x2; x1] -+ end -+ | n, l -> -+ let n1 = n asr 1 in -+ let n2 = n - n1 in -+ let l2 = chop n1 l in -+ let s1 = rev_sort n1 l in -+ let s2 = rev_sort n2 l2 in -+ rev_merge_rev s1 s2 [] -+ and rev_sort n l = -+ match n, l with -+ | 2, x1 :: x2 :: _ -> -+ let c = cmp x1 x2 in -+ if c = 0 then [x1] -+ else if c > 0 then [x1; x2] else [x2; x1] -+ | 3, x1 :: x2 :: x3 :: _ -> -+ let c = cmp x1 x2 in -+ if c = 0 then begin -+ let c = cmp x2 x3 in -+ if c = 0 then [x2] -+ else if c > 0 then [x2; x3] else [x3; x2] -+ end else if c > 0 then begin -+ let c = cmp x2 x3 in -+ if c = 0 then [x1; x2] -+ else if c > 0 then [x1; x2; x3] -+ else let c = cmp x1 x3 in -+ if c = 0 then [x1; x2] -+ else if c > 0 then [x1; x3; x2] -+ else [x3; x1; x2] -+ end else begin -+ let c = cmp x1 x3 in -+ if c = 0 then [x2; x1] -+ else if c > 0 then [x2; x1; x3] -+ else let c = cmp x2 x3 in -+ if c = 0 then [x2; x1] -+ else if c > 0 then [x2; x3; x1] -+ else [x3; x2; x1] -+ end -+ | n, l -> -+ let n1 = n asr 1 in -+ let n2 = n - n1 in -+ let l2 = chop n1 l in -+ let s1 = sort n1 l in -+ let s2 = sort n2 l2 in -+ rev_merge s1 s2 [] -+ in -+ let len = length l in -+ if len < 2 then l else sort len l -+;; diff --git a/testsuite/external/ocaml-bitstring-2.0.3.patch b/testsuite/external/ocaml-bitstring-2.0.3.patch deleted file mode 100644 index b73bca1359..0000000000 --- a/testsuite/external/ocaml-bitstring-2.0.3.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- ocaml-bitstring-2.0.3/Makefile.in.orig 2013-04-04 17:42:45.000000000 +0200 -+++ ocaml-bitstring-2.0.3/Makefile.in 2013-04-04 17:43:06.000000000 +0200 -@@ -123,7 +123,7 @@ - - byteswap.h: byteswap.in.h - { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ -- cat $(srcdir)/byteswap.in.h; \ -+ cat byteswap.in.h; \ - } > $@-t - mv -f $@-t $@ - diff --git a/testsuite/external/ocaml-mysql-1.0.4.patch.disabled b/testsuite/external/ocaml-mysql-1.0.4.patch.disabled deleted file mode 100644 index 82da79dfe6..0000000000 --- a/testsuite/external/ocaml-mysql-1.0.4.patch.disabled +++ /dev/null @@ -1,15 +0,0 @@ ---- ocaml-mysql-1.0.4.orig/mysql_stubs.c 2006-02-24 00:12:36.000000000 +0100 -+++ ocaml-mysql-1.0.4/mysql_stubs.c 2012-08-09 20:51:24.000000000 +0200 -@@ -19,9 +19,9 @@ - - /* MySQL API */ - --#include <mysql/mysql.h> --#include <mysql/mysqld_error.h> --#include <mysql/errmsg.h> -+#include <mysql.h> -+#include <mysqld_error.h> -+#include <errmsg.h> - /* type 'a option = None | Some of 'a */ - - #define NONE Val_int(0) diff --git a/testsuite/external/ocamlnet-3.5.1.patch b/testsuite/external/ocamlnet-3.5.1.patch deleted file mode 100644 index 46884d2117..0000000000 --- a/testsuite/external/ocamlnet-3.5.1.patch +++ /dev/null @@ -1,52 +0,0 @@ ---- ocamlnet-3.5.1.orig/src/netsys/netsys_posix.ml 2011-10-12 14:09:05.000000000 +0200 -+++ ocamlnet-3.5.1/src/netsys/netsys_posix.ml 2012-01-12 19:33:39.000000000 +0100 -@@ -412,9 +412,11 @@ - type at_flag = AT_EACCESS | AT_SYMLINK_NOFOLLOW | AT_REMOVEDIR - - (* The stubs assume these type definitions: *) -+(* In fact, they don't: they assume OCaml's stdlib definition - type open_flag1 = Unix.open_flag = - O_RDONLY | O_WRONLY | O_RDWR | O_NONBLOCK | O_APPEND | O_CREAT | O_TRUNC - | O_EXCL | O_NOCTTY | O_DSYNC | O_SYNC | O_RSYNC -+*) - - type access_permission1 = Unix.access_permission = - R_OK | W_OK | X_OK | F_OK ---- ocamlnet-3.5.1.orig/src/netstring/Makefile.def 2012-02-29 19:02:52.000000000 +0100 -+++ ocamlnet-3.5.1/src/netstring/Makefile.def 2012-05-25 16:59:56.000000000 +0200 -@@ -13,7 +13,7 @@ - PKGNAME = netstring - - REQUIRES = $(REGEXP_PROVIDER) bigarray --INCLUDES += $(INC_NETSYS) -+INCLUDES += $(INC_NETSYS) -I +compiler-libs - - ISO_MAPPINGS = mappings/iso*.unimap - JP_MAPPINGS = mappings/jis*.*map ---- ocamlnet-3.5.1.orig/src/pop/netpop.ml 2012-02-29 19:02:53.000000000 +0100 -+++ ocamlnet-3.5.1/src/pop/netpop.ml 2013-06-20 14:06:11.000000000 +0200 -@@ -231,6 +231,7 @@ - status_response ic parse_line (Hashtbl.create 1) - with _ -> raise Protocol_error - -+(* - method stat () = - self#check_state `Transaction; - send_command oc "STAT"; -@@ -242,4 +243,5 @@ - (count, size, ext) - ) - with _ -> raise Protocol_error; -+*) - end ---- ocamlnet-3.5.1/src/netstring/netencoding.mli.orig 2013-11-27 14:41:37.000000000 +0100 -+++ ocamlnet-3.5.1/src/netstring/netencoding.mli 2013-11-27 14:41:52.000000000 +0100 -@@ -120,7 +120,7 @@ - * to ensure that all output lines have a length <= 76 bytes. - * - * Note unsafe characters: -- * As recommended by RFC 2045, the characters [!#$\@[]^`{|}~] -+ * As recommended by RFC 2045, the characters [!#$\@[]^`{}|~] - * and the double quotes - * are additionally represented as hex tokens. - * Furthermore, the letter 'F' is considered as unsafe if it diff --git a/testsuite/external/ocsigen-bundle-2.2.2.patch b/testsuite/external/ocsigen-bundle-2.2.2.patch deleted file mode 100644 index b947999a69..0000000000 --- a/testsuite/external/ocsigen-bundle-2.2.2.patch +++ /dev/null @@ -1,47 +0,0 @@ -diff -u -r ocsigen-bundle-2.2.2.orig/pkg/Makefile.lwt ocsigen-bundle-2.2.2/pkg/Makefile.lwt ---- ocsigen-bundle-2.2.2.orig/pkg/Makefile.lwt 2011-12-20 16:13:24.000000000 +0100 -+++ ocsigen-bundle-2.2.2/pkg/Makefile.lwt 2011-12-29 00:34:27.000000000 +0100 -@@ -70,7 +70,7 @@ - - ${METAS}/META.lwt: ${LWT_DIR}/src/core/META - echo "directory = \"${srcdir}/${LWT_DIR}/_build/src/core\"" > $@ -- sed -e 's%^package "\([^\"]*\)" (%package "\1" (\n directory = "../\1"%g' \ -+ sed -e 's%^package "\([^\"]*\)" (%package "\1" ( directory = "../\1"%g' \ - -e 's%../syntax%../../syntax%' \ - $< >> $@ - -diff -u -r ocsigen-bundle-2.2.2.orig/pkg/Makefile.ocsimore ocsigen-bundle-2.2.2/pkg/Makefile.ocsimore ---- ocsigen-bundle-2.2.2.orig/pkg/Makefile.ocsimore 2011-12-20 16:13:24.000000000 +0100 -+++ ocsigen-bundle-2.2.2/pkg/Makefile.ocsimore 2011-12-29 00:34:51.000000000 +0100 -@@ -37,8 +37,8 @@ - - ${METAS}/META.ocsimore: ${OCSIMORE_DIR}/src/core/META - echo "directory = \"${srcdir}/${OCSIMORE_DIR}/_build/src/core\"" > $@ -- sed -e 's%^package "\([^\"]*\(user\|wiki\|site\|forum\)\)" (%package "\1" (\n directory = "../\2"%g' \ -- -e 's%^package "site_client" (%package "site_client" (\n directory = "../site/client"%g' \ -+ sed -e 's%^package "\([^\"]*\(user\|wiki\|site\|forum\)\)" (%package "\1" ( directory = "../\2"%g' \ -+ -e 's%^package "site_client" (%package "site_client" ( directory = "../site/client"%g' \ - $< >> $@ - - -diff -u -r ocsigen-bundle-2.2.2.orig/pkg/Makefile.tyxml ocsigen-bundle-2.2.2/pkg/Makefile.tyxml ---- ocsigen-bundle-2.2.2.orig/pkg/Makefile.js_of_ocaml 2011-12-20 16:13:24.000000000 +0100 -+++ ocsigen-bundle-2.2.2/pkg/Makefile.js_of_ocaml 2011-12-29 01:47:00.000000000 +0100 -@@ -47,5 +47,5 @@ - - ${METAS}/META.js_of_ocaml: ${JS_OF_OCAML_DIR}/lib/META - echo "directory = \"${srcdir}/${JS_OF_OCAML_DIR}/lib\"" > $@ -- sed -e 's%package "syntax" (%package "syntax" (\n directory = "syntax"%g' \ -+ sed -e 's%package "syntax" (%package "syntax" ( directory = "syntax"%g' \ - $< >> $@ ---- ocsigen-bundle-2.2.2/configure.orig 2012-05-25 18:33:10.000000000 +0200 -+++ ocsigen-bundle-2.2.2/configure 2012-05-25 18:33:24.000000000 +0200 -@@ -11051,7 +11051,7 @@ - - - --build_projects="deriving-ocsigen lwt js_of_ocaml tyxml ocsigenserver eliom" -+build_projects="deriving-ocsigen js_of_ocaml tyxml ocsigenserver" - if test $enable_ocsimore = yes ; then : - build_projects+=" ocsimore" - fi diff --git a/testsuite/external/omake-0.9.8.6.patch b/testsuite/external/omake-0.9.8.6.patch deleted file mode 100644 index 9fd8a7a01d..0000000000 --- a/testsuite/external/omake-0.9.8.6.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- omake-0.9.8.6.orig/lib/build/OCaml.om 2008-03-05 02:07:25.000000000 +0100 -+++ omake-0.9.8.6/lib/build/OCaml.om 2011-05-02 22:53:23.000000000 +0200 -@@ -176,7 +176,7 @@ - # - declare OCAMLDEPFLAGS - public.OCAMLPPFLAGS = --public.OCAMLFLAGS = -warn-error A -+public.OCAMLFLAGS = -warn-error a - public.OCAMLCFLAGS = -g - public.OCAMLOPTFLAGS = - public.OCAMLCPPFLAGS = diff --git a/testsuite/external/sks-1.1.3.patch b/testsuite/external/sks-1.1.3.patch deleted file mode 100644 index d59953402a..0000000000 --- a/testsuite/external/sks-1.1.3.patch +++ /dev/null @@ -1,20 +0,0 @@ -diff -N -r -u sks-1.1.3.orig/Makefile.local sks-1.1.3/Makefile.local ---- sks-1.1.3.orig/Makefile.local 1970-01-01 01:00:00.000000000 +0100 -+++ sks-1.1.3/Makefile.local 2010-05-17 14:49:16.000000000 +0200 -@@ -0,0 +1,5 @@ -+LIBDB=-ldb -+MANDIR=${PREFIX}/share/man -+export PREFIX -+export LIBDB -+export MANDIR ---- sks-1.1.3.orig/Makefile 2012-04-11 04:03:25.000000000 +0200 -+++ sks-1.1.3/Makefile 2013-05-30 14:40:03.000000000 +0200 -@@ -47,7 +47,7 @@ - - CAMLP4=-pp $(CAMLP4O) - CAMLINCLUDE= -I lib -I bdb --COMMONCAMLFLAGS=$(CAMLINCLUDE) $(OCAMLLIB) -ccopt -Lbdb -dtypes -ccopt -pthread -ccopt -pg -warn-error A -+COMMONCAMLFLAGS=$(CAMLINCLUDE) $(OCAMLLIB) -ccopt -Lbdb -dtypes -ccopt -pthread -ccopt -pg -warn-error a - OCAMLDEP=ocamldep $(CAMLP4) - CAMLLIBS=unix.cma str.cma bdb.cma nums.cma bigarray.cma cryptokit.cma - OCAMLFLAGS=$(COMMONCAMLFLAGS) -g $(CAMLLIBS) diff --git a/testsuite/external/vsyml-2010-04-06.patch b/testsuite/external/vsyml-2010-04-06.patch deleted file mode 100644 index a688e7a56e..0000000000 --- a/testsuite/external/vsyml-2010-04-06.patch +++ /dev/null @@ -1,20 +0,0 @@ ---- vsyml-2010-04-06.orig/makefile 2010-04-06 19:28:25.000000000 +0200 -+++ vsyml-2010-04-06/makefile 2010-08-23 15:16:22.000000000 +0200 -@@ -525,13 +525,13 @@ - - # dependencies for the symbolic simulator main file on cmo cma cmx and cmxa - $(VSYML_CMO_LST): $(VSYML_MAIN) -- echo -n "VSYML_CMO=" > $@ -- for i in `grep -o -e '[a-zA-Z0-9_]*\.cmo' $<` ; do echo -n $$i " " >> $@ ; done -+ echo "VSYML_CMO=" | tr -d '\012' > $@ -+ for i in `grep -o -e '[a-zA-Z0-9_]*\.cmo' $<` ; do echo $$i " " | tr -d '\012' >> $@ ; done - echo $(patsubst $(SRC_PATH)$(PATH_SEPARATOR)%.ml,%.cmo,$<) >> $@ - - $(VSYML_CMA_LST): $(VSYML_MAIN) -- echo -n "VSYML_CMA=" > $@ -- for i in `grep -o -e '[a-zA-Z0-9_]*\.cma' $<` ; do echo -n $$i " " >> $@ ; done -+ echo "VSYML_CMA=" | tr -d '\012' > $@ -+ for i in `grep -o -e '[a-zA-Z0-9_]*\.cma' $<` ; do echo $$i " " | tr -d '\012' >> $@ ; done - - $(VSYML_BYTE_CMO_LST): $(VSYML_CMO_LST) - sed -e 's@\([a-zA-Z0-9_]*\)\.cmo@$(BYTE_PATH)$(PATH_SEPARATOR)\1.cmo@g' -e 's/VSYML_CMO/VSYML_BYTE_CMO/' $< > $@ diff --git a/testsuite/external/xml-light-2.2.patch b/testsuite/external/xml-light-2.2.patch deleted file mode 100644 index 62351908ef..0000000000 --- a/testsuite/external/xml-light-2.2.patch +++ /dev/null @@ -1,19 +0,0 @@ ---- xml-light/Makefile 2003-10-12 11:16:12.000000000 +0200 -+++ xml-light-2.2/Makefile 2010-01-23 20:57:57.000000000 +0100 -@@ -2,7 +2,7 @@ - # http://tech.motion-twin.com
- .SUFFIXES : .ml .mli .cmo .cmx .cmi .mll .mly
-
--INSTALLDIR=`ocamlc -where`
-+INSTALLDIR=`ocamlc -where`/xml-light
- CFLAGS=
- LFLAGS= -a
- LIBS=
-@@ -12,6 +12,7 @@ - opt: xml-light.cmxa test_opt.exe
-
- install: all opt
-+ mkdir -p "${INSTALLDIR}"
- cp xml-light.cmxa xml-light.a xml-light.cma xml.mli xmlParser.mli dtd.mli xml.cmi xmlParser.cmi dtd.cmi xml.cmx dtd.cmx xmlParser.cmx $(INSTALLDIR)
-
- doc:
diff --git a/testsuite/lib/Makefile b/testsuite/lib/Makefile index 3c0ad6a699..05ae538fca 100644 --- a/testsuite/lib/Makefile +++ b/testsuite/lib/Makefile @@ -10,19 +10,20 @@ # # ######################################################################### -.PHONY: compile -compile: compile-targets -.PHONY: promote -promote: defaultpromote +OCAMLRUN = $(TOPDIR)/boot/ocamlrun +OCAMLFLAGS = -nostdlib -I $(TOPDIR)/stdlib -.PHONY: clean -clean: defaultclean +.PHONY: all byte opt + +all: byte opt -include ../makefiles/Makefile.common +byte: testing.mli testing.ml + $(OCAMLRUN) $(TOPDIR)/ocamlc $(OCAMLFLAGS) -c testing.mli testing.ml -.PHONY: compile-targets -compile-targets: testing.cmi testing.cmo - @if $(BYTECODE_ONLY); then : ; else \ - $(MAKE) testing.cmx; \ - fi +opt: testing.mli testing.ml + $(OCAMLRUN) $(TOPDIR)/ocamlopt $(OCAMLFLAGS) -c testing.mli testing.ml + +.PHONY: clean +clean: + rm -f testing.cm[iox] testing.$(O) diff --git a/testsuite/makefiles/Makefile.common b/testsuite/makefiles/Makefile.common index 5fdf5a1846..29250f6a19 100644 --- a/testsuite/makefiles/Makefile.common +++ b/testsuite/makefiles/Makefile.common @@ -10,124 +10,49 @@ # # ######################################################################### -TOPDIR=$(BASEDIR)/.. -WINTOPDIR=`cygpath -m "$(TOPDIR)"` - -# TOPDIR is the root directory of the OCaml sources, in Unix syntax. -# WINTOPDIR is the same directory, in Windows syntax. - -OTOPDIR=$(TOPDIR) -CTOPDIR=$(TOPDIR) -CYGPATH=echo -DIFF=diff -q -CANKILL=true -SORT=sort -SET_LD_PATH=CAML_LD_LIBRARY_PATH="$(LD_PATH)" - -# The variables above may be overridden by .../config/Makefile -# OTOPDIR is either TOPDIR or WINTOPDIR, whichever is appropriate for -# arguments given to the OCaml compiler. -# CTOPDIR is either TOPDIR or WINTOPDIR, whichever is appropriate for -# arguments given to the C and Fortran compilers. -# CYGPATH is the command that translates unix-style file names into -# whichever syntax is appropriate for arguments of OCaml programs. -# DIFF is a "diff -q" command that ignores trailing CRs under Windows. -# CANKILL is true if a script launched by Make can kill an OCaml process, -# and false for the mingw and MSVC ports. -# SORT is the Unix "sort" command. Usually a simple command, but may be an -# absolute name if the Windows "sort" command is in the PATH. -# SET_LD_PATH is a command prefix that sets the path for dynamic libraries -# (CAML_LD_LIBRARY_PATH for Unix, PATH for Windows) using the LD_PATH shell -# variable. Note that for Windows we add Unix-syntax directory names in -# PATH, and Cygwin will translate it to Windows syntax. - -include $(TOPDIR)/config/Makefile - -OCAMLRUN=$(TOPDIR)/boot/ocamlrun$(EXE) - -OCFLAGS=-nostdlib -I $(OTOPDIR)/stdlib $(COMPFLAGS) -OCOPTFLAGS= - -ifeq ($(SUPPORTS_SHARED_LIBRARIES),false) - CUSTOM = -custom -else - CUSTOM = -endif - -OCAML=$(OCAMLRUN) $(OTOPDIR)/ocaml $(OCFLAGS) \ - -init $(OTOPDIR)/testsuite/lib/empty -OCAMLC=$(OCAMLRUN) $(OTOPDIR)/ocamlc $(CUSTOM) $(OCFLAGS) -OCAMLOPT=$(OCAMLRUN) $(OTOPDIR)/ocamlopt $(OCFLAGS) -OCAMLDOC=$(OCAMLRUN) $(OTOPDIR)/ocamldoc/ocamldoc -OCAMLLEX=$(OCAMLRUN) $(OTOPDIR)/lex/ocamllex -OCAMLMKLIB=$(OCAMLRUN) $(OTOPDIR)/tools/ocamlmklib \ - -ocamlc "$(OTOPDIR)/boot/ocamlrun$(EXE) \ - $(OTOPDIR)/ocamlc $(OCFLAGS)" \ - -ocamlopt "$(OTOPDIR)/boot/ocamlrun$(EXE) \ - $(OTOPDIR)/ocamlopt $(OCFLAGS)" -OCAMLYACC=$(TOPDIR)/yacc/ocamlyacc$(EXE) -OCAMLBUILD=$(TOPDIR)/_build/ocamlbuild/ocamlbuild.native -DUMPOBJ=$(OCAMLRUN) $(OTOPDIR)/tool/dumpobj -BYTECODE_ONLY=[ "$(ARCH)" = "none" -o "$(ASM)" = "none" ] - -#FORTRAN_COMPILER= -#FORTRAN_LIBRARY= - -UNIXLIBVAR=`case "$(OTHERLIBRARIES)" in *win32unix*) echo win32;; esac` - -defaultpromote: - @for file in *.reference; do \ - cp `basename $$file reference`result $$file; \ - done - -defaultclean: - @rm -f *.cmo *.cmi *.cmx *.cma *.cmxa *.cmxs *.$(O) *.$(SO) *.$(A) - @for dsym in *.dSYM; do \ - if [ -d $$dsym ]; then \ - rm -fr $$dsym; \ - fi \ - done - .SUFFIXES: .SUFFIXES: .mli .ml .mly .mll .cmi .cmo .cmx .cmm .cmxa .s .S .o .so .c .f .mli.cmi: - @$(OCAMLC) -c $(ADD_COMPFLAGS) $< + $(OCAMLC) -c $(ADD_COMPFLAGS) $< .ml.cmi: - @$(OCAMLC) -c $(ADD_COMPFLAGS) $< + $(OCAMLC) -c $(ADD_COMPFLAGS) $< .ml.cmo: - @if [ -f $<i ]; then $(OCAMLC) -c $(ADD_COMPFLAGS) $<i; fi - @$(OCAMLC) -c $(ADD_COMPFLAGS) $< + if [ -f $<i ]; then $(OCAMLC) -c $(ADD_COMPFLAGS) $<i; fi + $(OCAMLC) -c $(ADD_COMPFLAGS) $< .ml.cmx: - @$(OCAMLOPT) -c $(ADD_COMPFLAGS) $< + $(OCAMLOPT) -c $(ADD_COMPFLAGS) $< .cmx.so: - @$(OCAMLOPT) -o $@ -shared $(ADD_COMPFLAGS) $< + $(OCAMLOPT) -o $@ -shared $(ADD_COMPFLAGS) $< .cmxa.so: - @$(OCAMLOPT) -o $@ -shared -linkall $(ADD_COMPFLAGS) $< + $(OCAMLOPT) -o $@ -shared -linkall $(ADD_COMPFLAGS) $< %.ml %.mli: %.mly - @$(OCAMLYACC) -q $< 2> /dev/null + $(OCAMLYACC) -q $< .mll.ml: - @$(OCAMLLEX) -q $< > /dev/null + $(OCAMLLEX) -q $< .cmm.o: - @$(OCAMLRUN) ./codegen $*.cmm > $*.s - @$(ASM) -o $*.o $*.s + $(OCAMLRUN) ./codegen $*.cmm > $*.s + $(ASM) -o $*.o $*.s .S.o: - @$(ASPP) $(ASPPFLAGS) -DSYS_$(SYSTEM) -o $*.o $*.S + $(ASPP) $(ASPPFLAGS) -DSYS_$(SYSTEM) -o $*.o $*.S .s.o: - @$(ASPP) $(ASPPFLAGS) -DSYS_$(SYSTEM) -o $*.o $*.s + $(ASPP) $(ASPPFLAGS) -DSYS_$(SYSTEM) -o $*.o $*.s .c.o: - @$(CC) -c -I$(CTOPDIR)/byterun $*.c -o $*.$(O) + $(CC) -c -I$(CTOPDIR)/byterun $*.c -o $*.$(O) .f.o: - @$(FORTRAN_COMPILER) -c -I$(CTOPDIR)/byterun $*.f -o $*.$(O) + $(FORTRAN_COMPILER) -c -I$(CTOPDIR)/byterun $*.f -o $*.$(O) + +clean:: + rm -f *.cm[iox] *.$(O) diff --git a/testsuite/num-tests b/testsuite/num-tests new file mode 100644 index 0000000000..065fd3e79c --- /dev/null +++ b/testsuite/num-tests @@ -0,0 +1 @@ +137 diff --git a/testsuite/external/Patcher.sh b/testsuite/scripts/cleantest index 57597d0811..71f1c92c80 100755 --- a/testsuite/external/Patcher.sh +++ b/testsuite/scripts/cleantest @@ -1,31 +1,45 @@ -#!/bin/sh +#!/bin/bash ######################################################################### # # # OCaml # # # -# Damien Doligez, projet Gallium, INRIA Rocquencourt # +# Damien Doligez, Jane Street Capital # # # -# Copyright 2012 Institut National de Recherche en Informatique et # +# Copyright 2015 Institut National de Recherche en Informatique et # # en Automatique. All rights reserved. This file is distributed # # under the terms of the Q Public License version 1.0. # # # ######################################################################### -# usage: -# Patcher.sh <directory> [<patchfile>] +Pfile=$1 +Pdir=$(dirname $1) +base=$(basename $1 .t) +byte_exec=$base.byt +opt_exec=$base.exe -if [ -f "$1.patch" ]; then - echo "patch -d $1 -p1 < $1.patch" - patch -d $1 -p1 < "$1.patch" -fi +ml_files=$base.ml -if [ -f "$1-$VERSION.patch" ]; then - echo "patch -d $1 -p1 < $1-$VERSION.patch" - patch -d $1 -p1 < "$1-$VERSION.patch" -fi +clean_default () { + rm -rf _tmp + rm -f $byte_exec $opt_exec + for i in $ml_files $mli_files; do + rm -f ${i%.ml*}.{cmi,cmo,cmx,o} + done + for i in $mll_files; do + rm -f ${i%.mll}.ml + done + for i in $mly_files; do + rm -f ${i%.mly}.{ml,mli} + done +} -if [ -f "$2" ]; then - echo "patch -d $1 -l -p0 < $2" - patch -d $1 -l -p0 < "$2" || exit 0 -fi +clean () { + clean_default +} + +cd "$Pdir" + +. ./$base.t + +clean diff --git a/testsuite/tests/basic/Makefile b/testsuite/scripts/do_clean index 299656b246..8f7fbc6939 100644..100755 --- a/testsuite/tests/basic/Makefile +++ b/testsuite/scripts/do_clean @@ -1,15 +1,17 @@ +#!/bin/sh + ######################################################################### # # # OCaml # # # -# Xavier Clerc, SED, INRIA Rocquencourt # +# Damien Doligez, Jane Street Capital # # # -# Copyright 2010 Institut National de Recherche en Informatique et # +# Copyright 2014 Institut National de Recherche en Informatique et # # en Automatique. All rights reserved. This file is distributed # # under the terms of the Q Public License version 1.0. # # # ######################################################################### -BASEDIR=../.. -include $(BASEDIR)/makefiles/Makefile.several -include $(BASEDIR)/makefiles/Makefile.common +for d in "$@"; do + find "$d" -name '*.t' | xargs -L 1 scripts/cleantest +done diff --git a/testsuite/scripts/do_tests b/testsuite/scripts/do_tests new file mode 100755 index 0000000000..70800a4477 --- /dev/null +++ b/testsuite/scripts/do_tests @@ -0,0 +1,37 @@ +#!/bin/sh + +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2014 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +testflags= +while : ; do + case $1 in + -no-byte) testflags="$testflags -no-byte"; shift;; + -no-opt) testflags="$testflags -no-opt"; shift;; + *) break;; + esac +done + +for d in "$@"; do + find "$d" -name '*.t' \ + | LC_ALL=C sort \ + | xargs -L 1 scripts/runtest $testflags 3>&1 >>_full-log 2>&1 \ + | tee -a _log +done + +if [ "$1" = "tests" ]; then + expected=`sed -e 2q num-tests` +else + expected= +fi + +awk -f scripts/summary _log expected="$expected" diff --git a/testsuite/tests/basic-private/tlength.reference b/testsuite/scripts/empty index e69de29bb2..e69de29bb2 100644 --- a/testsuite/tests/basic-private/tlength.reference +++ b/testsuite/scripts/empty diff --git a/testsuite/scripts/runtest b/testsuite/scripts/runtest new file mode 100755 index 0000000000..61dc5cb37f --- /dev/null +++ b/testsuite/scripts/runtest @@ -0,0 +1,327 @@ +#!/bin/bash + +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2014 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +[ -z "$Tdebug" ] || set -x + +Pwith_byte=true +Pwith_opt=true +while : ; do + case $1 in + -no-byte) Pwith_byte=false; shift;; + -no-opt) Pwith_opt=false; shift;; + *) break;; + esac +done + +Pfile=$1 +Pdir=$(dirname $1) +base=$(basename $1 .t) +byte_exec=$base.byt +opt_exec=$base.exe + +Pocamlrun="$TOPDIR/boot/ocamlrun$EXE" +Pflags="-nostdlib -I $OTOPDIR/stdlib -I $OTOPDIR/testsuite/lib" +Pocamlc="$Pocamlrun $OTOPDIR/ocamlc $Pflags" +Pocamlopt="$Pocamlrun $OTOPDIR/ocamlopt $Pflags" +Pocaml="$Pocamlrun $OTOPDIR/ocaml $Pflags \ + -init $OTOPDIR/testsuite/scripts/empty" +Pocamldoc="$Pocamlrun $OTOPDIR/ocamldoc/ocamldoc" +Plex="$Pocamlrun $OTOPDIR/lex/ocamllex" +Pyacc="$TOPDIR/yacc/ocamlyacc$EXE" +Pocamlmklib="$Pocamlrun $OTOPDIR/tools/ocamlmklib \ + -ocamlc '$OTOPDIR/boot/ocamlrun$EXE $OTOPDIR/ocamlc $Pflags' \ + -ocamlopt '$OTOPDIR/boot/ocamlrun$EXE $OTOPDIR/ocamlopt $Pflags'" +if [ "$ARCH" = none -o "$ASM" = none ]; then + Pwith_opt=false +fi + +# Pcustomflag is set to "-custom" (at several places in this file) +# as soon as a custom runtime is needed. +if $SUPPORTS_SHARED_LIBRARIES; then + Pcustomflag= +else + Pcustomflag=-custom +fi + +sources="$base.ml" + +kinds="byte opt" + +compflags= +byteflags= +custom=false +optflags= +lexflags=-q +yaccflags=-q +topflags= +cflags= +fortranflags= + +exec_env= +args= +exit=0 +compexit=0 +postprocess=false +postexit=0 + +# Print the error message to stderr and exit with an error code. +error () { + echo ERROR: $* >&2 + exit 5 +} + +# Log the command given as argument(s) and execute it, saving the outputs +launch () { + echo "$*" >&2 + Ltmpexit=0 + Lstg=${Pstage:+-$Pstage} + eval "$*" </dev/null >>_tmp/$base-$kind$Lstg.refout \ + 2>>_tmp/$base-$kind$Lstg.referr \ + || Ltmpexit=$? + eval "P${Pstage}exit=$Ltmpexit" +} + +# Log the command given as argument(s) and execute it, leaving the outputs alone +log () { + echo "$*" >&2 + eval "$*" +} + +# Compile mlyacc, mllex and C files, and build a list of files for the +# OCaml compiler to compile and link. +# Two arguments: the extensions to use for library objects (cmo/cmx) and +# libs (cma/cmxa). +precompile () { + cmoext=$1 + cmaext=$2 + Pocamlfiles= + for f in $sources; do + case $f in + *.ml|*.mli) Pocamlfiles="$Pocamlfiles $f";; + *.mly) + launch $Pyacc $yaccflags $f + Pocamlfiles="$Pocamlfiles ${f%.mly}.mli ${f%.mly}.ml" + ;; + *.mll) + launch $Plex $lexflags $f + Pocamlfiles="$Pocamlfiles ${f%.mll}.ml" + ;; + *.c) + launch $NATIVECC $NATIVECCCOMPOPTS $cflags \ + -I $CTOPDIR/byterun -c $f + Pcustomflag=-custom + Pocamlfiles="$Pocamlfiles ${f%.c}.$O" + ;; + *.f) + launch $FORTRAN_COMPILER $fortranflags -c $f + Pcustomflag=-custom + Pocamlfiles="$Pocamlfiles ${f%.f}.$O" + ;; + *.cmo) Pocamlfiles="$Pocamlfiles ${f%.cmo}.$cmoext";; + *.cma) Pocamlfiles="$Pocamlfiles ${f%.cma}.$cmaext";; + *.$O) + Pcustomflag=-custom + Pocamlfiles="$Pocamlfiles $f" + ;; + *) error "unexpected source file extension: $f";; + esac + done +} + +opt_comp () { + preprocess + precompile cmx cmxa + launch $Pocamlopt $compflags $optflags $Pocamlfiles -o $opt_exec +} + +byte_comp () { + preprocess + precompile cmo cma + if $custom; then Pcustomflag=-custom; fi + launch $Pocamlc $compflags $Pcustomflag $byteflags $Pocamlfiles \ + -o $byte_exec +} + +top_comp () { + launch : no compilation step needed +} + +top_principal_comp () { + launch : no compilation step needed +} + +opt_run () { + launch $SET_LD_PATH $exec_env ./$opt_exec $args +} + +byte_run () { + case $Pcustomflag in + "") Luseruntime=$Pocamlrun;; + -custom) Luseruntime=;; + *) error "internal error (bad value for Pcustomflag)";; + esac + launch $SET_LD_PATH $exec_env $Luseruntime ./$byte_exec $args +} + +top_run () { + launch "cat $sources | TERM=dumb $Pocaml $topflags 2>&1 \ + | grep -v '^ OCaml version'" +} + +top_principal_run () { + launch "cat $sources | TERM=dumb $Pocaml $topflags -principal 2>&1 \ + | grep -v '^ OCaml version'" +} + +postprocess_sort () { + log "sort $1 >$1.post" +} + +postprocess_sort_uniq () { + log "sort $1 | uniq >$1.post" +} + +Pcompare_files () { + ref="$1" + act="$2" + if [ ! -f "$ref" ]; then ref=/dev/null; fi + log $DIFF $ref $act +} + +Pcheck () { + if $postprocess; then + post=.post + else + post= + fi + case $kind in + *_*) variant=-${kind#*_};; + *) variant=;; + esac + ( + set -e + for suff in -comp.referr -comp.refout .referr$post .refout$post; do + Pcompare_files $base$variant$suff _tmp/$base-$kind$suff + done + [ "$Pcompexit" -eq "$compexit" ] || { + error "compilation exit code $Pcompexit is different" \ + "from expected $compexit" + false + } + [ "$Pexit" -eq "$exit" ] || { + error "program exit code $Pexit is different from expected $exit" + false + } + ) +} + +Pcheck_kind () { + case $kind/$Pwith_opt/$Pwith_byte in + opt/false/*) false;; + byte/*/false) false;; + top*/*/false) false;; # top is a subset of byte + *) true;; + esac +} + +preprocess () { + : +} + +precheck () { + case "$sources " in + *'.f '*) test -n "$FORTRAN_COMPILER";; + esac +} + +opt_precheck () { + precheck +} + +byte_precheck () { + precheck +} + +top_precheck () { + precheck +} + +Pexport_variables () { + export OCAMLYACC="$Pyacc" + export OCAMLLEX="$Plex" + export OCAMLC="$Pocamlc" + export OCAMLOPT="$Pocamlopt" + export OCAMLRUN="$Pocamlrun" +} + +Pstart_test () { + printf "Testing %-4s %s ... " "$kind" "$Pfile" >&3 + printf "#################################################" + printf "\nTesting %-4s %s ...\n" "$kind" "$Pfile" +} + +Pskip_test () { + printf "skip\n" >&3 + printf "skip\n\n" + exit 0 +} + +Pfail_test () { + printf "FAIL\n" >&3 + printf "FAIL\n\n" +} + +Ppass_test () { + printf "pass\n" >&3 + printf "pass\n\n" +} + +cd "$Pdir" + +###################################################### +# read the user's definitions + +. ./$base.t + +###################################################### + +Pexport_variables +mkdir -p _tmp +for kind in $kinds; do + Pstart_test + ( + # Skip test if kind=opt and configured without native code + # or if user disabled the current kind + Pcheck_kind || Pskip_test + # Run user-defined pre-check + ${kind}_precheck || Pskip_test + rm -f _tmp/$base*.ref{out,err} + ( + Pstage=comp + ${kind}_comp + Pstage= + ${kind}_run + if $postprocess; then + Pstage=post + (cd _tmp; ${kind}_postprocess_out $base-$kind.refout) + (cd _tmp; ${kind}_postprocess_err $base-$kind.referr) + fi + Pcheck + ) + case $? in + 0) Ppass_test;; + *) Pfail_test;; + esac + ) +done diff --git a/testsuite/scripts/runtest-doc.txt b/testsuite/scripts/runtest-doc.txt new file mode 100644 index 0000000000..545c1e2e35 --- /dev/null +++ b/testsuite/scripts/runtest-doc.txt @@ -0,0 +1,90 @@ +Each *.t file describes a (fixed) number of tests, usually either one +or two (byte-code and/or native). + +The list of tests is defined in variable $kinds (by default 'byte opt') + +Each test is composed of 5 phases: +1. preliminary check + -> functions {byte,opt}_precheck (by default, they call precheck, + which just returns 0 (i.e. true). + if this funtion returns true, the test will be run, otherwise it + will be skipped. + + 2. compilation + -> functions {byte,opt}_comp. By default, they compile the files + listed in $ml_files, $mli_files, $mll_files, $mly_files. By + default, all are empty except $ml_files, which contains only + $base.ml (where $base.t is the current test file). + For compiler flags, they use the variables: + $compflags (for both compilers) + $byteflags (for byte-code compilation) + $optflags (for native-code compilation) + $lexflags [default "-q"] (for ocamllex) + $yaccflags [default "-q"] (for ocamlyacc) + $config_custom (false if shared libs are available, true otherwise) + $custom [default false]: compile in custom mode + + Before starting to compile, the default functions run the function + preprocess (by default, does nothing). + + Compilation is done in custom mode if $config_custom or $custom is + true, and in that case the byte-code executable is run without + explicitly launching the bytecode interpreter. + +3. run + -> functions {byte,opt}_run. By default, they run $base.{byt,opt}, + redirecting stdin, stdout and stderr, and recording the exit code. + For byte-code, this runs the bytecode interpreter iff $custom or + $config_custom is true. + If you override these functions, use the launch function (with the + command line as arguments) to launch the program with the correct + redirections. + This will prepend $exec_env and append $args to the command line + (default empty) so you can set some environment variables before + the program is run, and run it with some arguments. + +4. post-process + -> this is done only if $postprocess=true (by default, false). + functions {byte,opt}_postprocess_{out,err}. By default, they run + postprocess_{out,err}, which simply copy $base.out to + $base-post.out and $base.err to $base-post.err. + The postprocessing functions are run in the directory of the output + files. + +5. checking + This is done by comparing the stdout and stderr of each stage with + the ones given in the following files: + $base-comp.{out,err}: concatenated outputs of the compilation + commands. + $base.{out,err}: output of the run command, only checked if + $postprocess is false + $base-post.{out,err}: output of the post-process command, only + checked if $postprocess is true + The exit codes are also checked, against the variables: + $compexit: exit code of the last compilation command + $exit: exit code of the program under test + $postexit: exit code of the post-processing for the stderr. + +6. cleaning + The .t file may redefine the function "clean" (by default, calls + clean_default) to remove compilation and temporary file. The + "clean_default" function remove the compilation files that + correspond to the $ml_files, $mli_files, $mll_files, $mly_files + variables, the _tmp directory, and the default byte-code and + executable files. + +Examples + +If you want to compile foo.ml, run the result, and make sure the +stdout and stderr are empty and the result code is 0, just add an +empty foo.t file. + +If your program is composed of several source files, just put + ml_files="a.ml b.ml c.ml" +in your .t file. + +If your program has a lexer and parser, you write: +mll_files=lexer.mll +mly_files=parser.mly +mli_files=parser.mli lexer.mli others.mli +ml_files=parser.ml lexer.ml others.ml diff --git a/testsuite/scripts/summary b/testsuite/scripts/summary new file mode 100644 index 0000000000..aa0cfaaea5 --- /dev/null +++ b/testsuite/scripts/summary @@ -0,0 +1,64 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2014 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +function error(msg) { + printf("unexpected error (%s) at line %d:\n", msg, NR); + printf(" %s\n", $0); + got_error = 1; +} + +/^Testing .* \.\.\. pass$/ { ++npass; next; } +/^Testing .* \.\.\. skip$/ { ++nskip; next; } +/^Testing .* \.\.\. FAIL$/ { + sub(/^Testing/, ""); + sub(/ ... FAIL$/, ""); + failed[nfail++] = $0; + next; +} +{ error("invalid test result"); next; } + +END { + printf("\n"); + printf(" tests passed: %4d\n", npass); + printf(" tests skipped: %4d\n", nskip); + printf(" tests failed: %4d\n", nfail); + if (expected != ""){ + total = npass + nskip + nfail; + printf(" total..........%4d (expected %d)\n", total, expected); + } + printf("\n"); + + if (nfail > 0){ + printf("Failed tests:\n"); + for (i in failed){ + printf(" %s\n", failed[i]); + } + printf("\nSOME TESTS FAILED\n\n"); + result = 3; + } + + if (expected != "" && total != expected) { + printf("ERROR: wrong number of test results\n\n"); + result = 4; + } + + if (got_error){ + printf("ERROR: unexpected errors in test scripts\n\n"); + result = 5; + } + + if (result == 0){ + printf("ALL TESTS PASSED\n\n"); + } + + exit(result); +} diff --git a/testsuite/tests/asmcomp/.ignore b/testsuite/tests/asmcomp/.ignore index 321dc06109..6c07ff4be7 100644 --- a/testsuite/tests/asmcomp/.ignore +++ b/testsuite/tests/asmcomp/.ignore @@ -3,5 +3,3 @@ parsecmm.ml parsecmm.mli lexcmm.ml *.s -*.out -*.out.dSYM diff --git a/testsuite/tests/asmcomp/Makefile b/testsuite/tests/asmcomp/Makefile index 501d0594d3..c618e23451 100644 --- a/testsuite/tests/asmcomp/Makefile +++ b/testsuite/tests/asmcomp/Makefile @@ -12,9 +12,6 @@ BASEDIR=../.. -CC=$(NATIVECC) -CFLAGS=$(NATIVECCCOMPOPTS) -g - INCLUDES=\ -I $(OTOPDIR)/utils \ -I $(OTOPDIR)/typing \ @@ -29,69 +26,21 @@ OBJS=parsecmmaux.cmo parsecmm.cmo lexcmm.cmo ADD_COMPFLAGS=$(INCLUDES) -g -default: - @if $(BYTECODE_ONLY) || [ -z "$(ASPP)" ]; then : ; else \ - $(MAKE) all; \ - fi - -all: - $(MAKE) arch codegen - $(MAKE) tests +.PHONY: all +all: arch codegen codegen: parsecmm.ml lexcmm.ml $(OBJS:.cmo=.cmi) $(OBJS) main.cmo - @$(OCAMLC) $(LINKFLAGS) -o codegen $(OTHEROBJS) $(OBJS) main.cmo - -parsecmm.mli parsecmm.ml: parsecmm.mly - @$(OCAMLYACC) -q parsecmm.mly - -lexcmm.ml: lexcmm.mll - @$(OCAMLLEX) -q lexcmm.mll - -MLCASES=optargs staticalloc - -CASES=fib tak quicksort quicksort2 soli \ - arith checkbound tagged-fib tagged-integr tagged-quicksort tagged-tak -ARGS_fib=-DINT_INT -DFUN=fib main.c -ARGS_tak=-DUNIT_INT -DFUN=takmain main.c -ARGS_quicksort=-DSORT -DFUN=quicksort main.c -ARGS_quicksort2=-DSORT -DFUN=quicksort main.c -ARGS_soli=-DUNIT_INT -DFUN=solitaire main.c -ARGS_integr=-DINT_FLOAT -DFUN=test main.c -ARGS_arith=mainarith.c -ARGS_checkbound=-DCHECKBOUND main.c -ARGS_tagged-fib=-DINT_INT -DFUN=fib main.c -ARGS_tagged-integr=-DINT_FLOAT -DFUN=test main.c -ARGS_tagged-quicksort=-DSORT -DFUN=quicksort main.c -ARGS_tagged-tak=-DUNIT_INT -DFUN=takmain main.c - -tests: $(CASES:=.o) - @for c in $(CASES); do \ - printf " ... testing '$$c':"; \ - $(MAKE) one CC="$(CC) $(CFLAGS)" NAME=$$c; \ - done - @for c in $(MLCASES); do \ - printf " ... testing '$$c':"; \ - $(MAKE) one_ml NAME=$$c; \ - done + $(OCAMLC) $(LINKFLAGS) -o codegen $(OTHEROBJS) $(OBJS) main.cmo -one_ml: - @$(OCAMLOPT) -o $(NAME).exe $(NAME).ml && \ - ./$(NAME).exe && echo " => passed" || echo " => failed" - -one: - @$(CC) -o $(NAME).out $(ARGS_$(NAME)) $(NAME).o $(ARCH).o \ - && echo " => passed" || echo " => failed" - -clean: defaultclean - @rm -f ./codegen *.out *.o *.obj *.exe - @rm -f parsecmm.ml parsecmm.mli lexcmm.ml - @rm -f $(CASES:=.s) - -include $(BASEDIR)/makefiles/Makefile.common +include $(TOPDIR)/testsuite/makefiles/Makefile.common power.o: power-$(SYSTEM).o - @cp power-$(SYSTEM).o power.o - -promote: + cp power-$(SYSTEM).o power.o arch: $(ARCH).o + +%.o: %.s + $(ASPP) $(ASPPFLAGS) -DSYS_$(SYSTEM) -o $@ $< + +clean:: + rm -f ./codegen parsecmm.ml parsecmm.mli lexcmm.ml diff --git a/testsuite/tests/basic-io-2/Makefile b/testsuite/tests/asmcomp/Testcommon.sh index e810916c93..443364e9a7 100644 --- a/testsuite/tests/basic-io-2/Makefile +++ b/testsuite/tests/asmcomp/Testcommon.sh @@ -2,18 +2,24 @@ # # # OCaml # # # -# Xavier Clerc, SED, INRIA Rocquencourt # +# Damien Doligez, Jane Street Capital # # # -# Copyright 2010 Institut National de Recherche en Informatique et # +# Copyright 2015 Institut National de Recherche en Informatique et # # en Automatique. All rights reserved. This file is distributed # # under the terms of the Q Public License version 1.0. # # # ######################################################################### -BASEDIR=../.. -#MODULES= -MAIN_MODULE=io -EXEC_ARGS=io.ml +kinds=opt -include $(BASEDIR)/makefiles/Makefile.one -include $(BASEDIR)/makefiles/Makefile.common +cbase=$base +opt_comp () { + log $MAKE all $cbase.o + log $NATIVECC $NATIVECCCOMPOPTS -g -o $opt_exec $cflags $cbase.o $ARCH.o + launch : +} + +clean () { + clean_default + "$MAKE" clean +} diff --git a/testsuite/tests/asmcomp/amd64.S b/testsuite/tests/asmcomp/amd64.S index 16dbaec11b..5d81aa0d74 100644 --- a/testsuite/tests/asmcomp/amd64.S +++ b/testsuite/tests/asmcomp/amd64.S @@ -31,6 +31,7 @@ .globl CALL_GEN_CODE .align ALIGN CALL_GEN_CODE: + subq $8, %rsp pushq %rbx pushq %rbp pushq %r12 @@ -49,6 +50,7 @@ CALL_GEN_CODE: popq %r12 popq %rbp popq %rbx + addq $8, %rsp ret .globl CAML_C_CALL diff --git a/testsuite/tests/exotic-syntax/Makefile b/testsuite/tests/asmcomp/arith.t index 38acec51cb..4c40574b88 100644 --- a/testsuite/tests/exotic-syntax/Makefile +++ b/testsuite/tests/asmcomp/arith.t @@ -2,16 +2,15 @@ # # # OCaml # # # -# Damien Doligez, projet Gallium, INRIA Rocquencourt # +# Damien Doligez, Jane Street Capital # # # -# Copyright 2013 Institut National de Recherche en Informatique et # +# Copyright 2015 Institut National de Recherche en Informatique et # # en Automatique. All rights reserved. This file is distributed # # under the terms of the Q Public License version 1.0. # # # ######################################################################### -BASEDIR=../.. -MAIN_MODULE=exotic +. ./Testcommon.sh -include $(BASEDIR)/makefiles/Makefile.one -include $(BASEDIR)/makefiles/Makefile.common +cflags="mainarith.c" +args="1 100 3.14159 2.71828" diff --git a/testsuite/tests/asmcomp/checkbound-1.refout b/testsuite/tests/asmcomp/checkbound-1.refout new file mode 100644 index 0000000000..72943f53d1 --- /dev/null +++ b/testsuite/tests/asmcomp/checkbound-1.refout @@ -0,0 +1,2 @@ +Should not trap +OK diff --git a/testsuite/tests/asmcomp/checkbound-1.t b/testsuite/tests/asmcomp/checkbound-1.t new file mode 100644 index 0000000000..492b27fb8d --- /dev/null +++ b/testsuite/tests/asmcomp/checkbound-1.t @@ -0,0 +1,16 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh +cbase=checkbound +cflags="-DCHECKBOUND main.c" +args="500 1000" diff --git a/testsuite/tests/asmcomp/checkbound-2.referr b/testsuite/tests/asmcomp/checkbound-2.referr new file mode 100644 index 0000000000..288c938737 --- /dev/null +++ b/testsuite/tests/asmcomp/checkbound-2.referr @@ -0,0 +1 @@ +Fatal error: out-of-bound access in array or string diff --git a/testsuite/tests/asmcomp/checkbound-2.refout b/testsuite/tests/asmcomp/checkbound-2.refout new file mode 100644 index 0000000000..15fb80f927 --- /dev/null +++ b/testsuite/tests/asmcomp/checkbound-2.refout @@ -0,0 +1 @@ +Should trap diff --git a/testsuite/tests/asmcomp/checkbound-2.t b/testsuite/tests/asmcomp/checkbound-2.t new file mode 100644 index 0000000000..f8848ba681 --- /dev/null +++ b/testsuite/tests/asmcomp/checkbound-2.t @@ -0,0 +1,17 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh +cbase=checkbound +cflags="-DCHECKBOUND main.c" +args="1200 1000" +exit=2 diff --git a/testsuite/tests/asmcomp/fib.refout b/testsuite/tests/asmcomp/fib.refout new file mode 100644 index 0000000000..45b0f829eb --- /dev/null +++ b/testsuite/tests/asmcomp/fib.refout @@ -0,0 +1 @@ +987 diff --git a/testsuite/tests/basic-modules/Makefile b/testsuite/tests/asmcomp/fib.t index 4c13f27247..c1244d1e65 100644 --- a/testsuite/tests/basic-modules/Makefile +++ b/testsuite/tests/asmcomp/fib.t @@ -2,18 +2,15 @@ # # # OCaml # # # -# Xavier Clerc, SED, INRIA Rocquencourt # +# Damien Doligez, Jane Street Capital # # # -# Copyright 2010 Institut National de Recherche en Informatique et # +# Copyright 2015 Institut National de Recherche en Informatique et # # en Automatique. All rights reserved. This file is distributed # # under the terms of the Q Public License version 1.0. # # # ######################################################################### -BASEDIR=../.. +. ./Testcommon.sh -MODULES=offset pr6726 -MAIN_MODULE=main - -include $(BASEDIR)/makefiles/Makefile.one -include $(BASEDIR)/makefiles/Makefile.common +cflags="-DINT_INT -DFUN=fib main.c" +args=15 diff --git a/testsuite/tests/asmcomp/integr.refout b/testsuite/tests/asmcomp/integr.refout new file mode 100644 index 0000000000..8bbca1c98f --- /dev/null +++ b/testsuite/tests/asmcomp/integr.refout @@ -0,0 +1 @@ +0.333333 diff --git a/testsuite/tests/basic-io/Makefile b/testsuite/tests/asmcomp/integr.t index 3f9c10ed9f..3a0844c2b5 100644 --- a/testsuite/tests/basic-io/Makefile +++ b/testsuite/tests/asmcomp/integr.t @@ -2,18 +2,15 @@ # # # OCaml # # # -# Xavier Clerc, SED, INRIA Rocquencourt # +# Damien Doligez, Jane Street Capital # # # -# Copyright 2010 Institut National de Recherche en Informatique et # +# Copyright 2015 Institut National de Recherche en Informatique et # # en Automatique. All rights reserved. This file is distributed # # under the terms of the Q Public License version 1.0. # # # ######################################################################### -BASEDIR=../.. -#MODULES= -MAIN_MODULE=wc -EXEC_ARGS=wc.ml +. ./Testcommon.sh -include $(BASEDIR)/makefiles/Makefile.one -include $(BASEDIR)/makefiles/Makefile.common +cflags="-DINT_FLOAT -DFUN=test main.c" +args=1000000 diff --git a/testsuite/tests/asmcomp/optargs.t b/testsuite/tests/asmcomp/optargs.t new file mode 100644 index 0000000000..9239273778 --- /dev/null +++ b/testsuite/tests/asmcomp/optargs.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +kinds=opt diff --git a/testsuite/tests/asmcomp/quicksort.refout b/testsuite/tests/asmcomp/quicksort.refout new file mode 100644 index 0000000000..d86bac9de5 --- /dev/null +++ b/testsuite/tests/asmcomp/quicksort.refout @@ -0,0 +1 @@ +OK diff --git a/testsuite/tests/asmcomp/quicksort.t b/testsuite/tests/asmcomp/quicksort.t new file mode 100644 index 0000000000..b18cd7b215 --- /dev/null +++ b/testsuite/tests/asmcomp/quicksort.t @@ -0,0 +1,16 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh + +cflags="-DSORT -DFUN=quicksort main.c" +args=1000000 diff --git a/testsuite/tests/asmcomp/quicksort2.refout b/testsuite/tests/asmcomp/quicksort2.refout new file mode 100644 index 0000000000..d86bac9de5 --- /dev/null +++ b/testsuite/tests/asmcomp/quicksort2.refout @@ -0,0 +1 @@ +OK diff --git a/testsuite/tests/asmcomp/quicksort2.t b/testsuite/tests/asmcomp/quicksort2.t new file mode 100644 index 0000000000..b18cd7b215 --- /dev/null +++ b/testsuite/tests/asmcomp/quicksort2.t @@ -0,0 +1,16 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh + +cflags="-DSORT -DFUN=quicksort main.c" +args=1000000 diff --git a/testsuite/tests/asmcomp/soli.refout b/testsuite/tests/asmcomp/soli.refout new file mode 100644 index 0000000000..bbc770bde0 --- /dev/null +++ b/testsuite/tests/asmcomp/soli.refout @@ -0,0 +1,50 @@ +500 +1000 +1500 +2000 +2500 +3000 +3500 +4000 +4500 +5000 +5500 +6000 +6500 +7000 +7500 +8000 +8500 +9000 +9500 +10000 +10500 +11000 +11500 +12000 +12500 +13000 +13500 +14000 +14500 +15000 +15500 +16000 +16500 +17000 +17500 +18000 +18500 +19000 +19500 +20000 +......... +... ... +... ... +. . +. $ . +. . +... ... +... ... +......... +0 diff --git a/testsuite/tests/asmcomp/soli.t b/testsuite/tests/asmcomp/soli.t new file mode 100644 index 0000000000..feacef6c1e --- /dev/null +++ b/testsuite/tests/asmcomp/soli.t @@ -0,0 +1,15 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh + +cflags="-DUNIT_INT -DFUN=solitaire main.c" diff --git a/testsuite/tests/asmcomp/staticalloc.t b/testsuite/tests/asmcomp/staticalloc.t new file mode 100644 index 0000000000..9239273778 --- /dev/null +++ b/testsuite/tests/asmcomp/staticalloc.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +kinds=opt diff --git a/testsuite/tests/asmcomp/tagged-fib.refout b/testsuite/tests/asmcomp/tagged-fib.refout new file mode 100644 index 0000000000..ede5ca4172 --- /dev/null +++ b/testsuite/tests/asmcomp/tagged-fib.refout @@ -0,0 +1 @@ +1975 diff --git a/testsuite/tests/asmcomp/tagged-fib.t b/testsuite/tests/asmcomp/tagged-fib.t new file mode 100644 index 0000000000..9df1d66a06 --- /dev/null +++ b/testsuite/tests/asmcomp/tagged-fib.t @@ -0,0 +1,16 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh + +cflags="-DINT_INT -DFUN=fib main.c" +args=31 diff --git a/testsuite/tests/asmcomp/tagged-integr.refout b/testsuite/tests/asmcomp/tagged-integr.refout new file mode 100644 index 0000000000..8bbca1c98f --- /dev/null +++ b/testsuite/tests/asmcomp/tagged-integr.refout @@ -0,0 +1 @@ +0.333333 diff --git a/testsuite/tests/asmcomp/tagged-integr.t b/testsuite/tests/asmcomp/tagged-integr.t new file mode 100644 index 0000000000..3a0844c2b5 --- /dev/null +++ b/testsuite/tests/asmcomp/tagged-integr.t @@ -0,0 +1,16 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh + +cflags="-DINT_FLOAT -DFUN=test main.c" +args=1000000 diff --git a/testsuite/tests/asmcomp/tagged-quicksort.refout b/testsuite/tests/asmcomp/tagged-quicksort.refout new file mode 100644 index 0000000000..d86bac9de5 --- /dev/null +++ b/testsuite/tests/asmcomp/tagged-quicksort.refout @@ -0,0 +1 @@ +OK diff --git a/testsuite/tests/asmcomp/tagged-quicksort.t b/testsuite/tests/asmcomp/tagged-quicksort.t new file mode 100644 index 0000000000..b18cd7b215 --- /dev/null +++ b/testsuite/tests/asmcomp/tagged-quicksort.t @@ -0,0 +1,16 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh + +cflags="-DSORT -DFUN=quicksort main.c" +args=1000000 diff --git a/testsuite/tests/asmcomp/tagged-tak.refout b/testsuite/tests/asmcomp/tagged-tak.refout new file mode 100644 index 0000000000..60d3b2f4a4 --- /dev/null +++ b/testsuite/tests/asmcomp/tagged-tak.refout @@ -0,0 +1 @@ +15 diff --git a/testsuite/tests/asmcomp/tagged-tak.t b/testsuite/tests/asmcomp/tagged-tak.t new file mode 100644 index 0000000000..a46d1f399e --- /dev/null +++ b/testsuite/tests/asmcomp/tagged-tak.t @@ -0,0 +1,15 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh + +cflags="-DUNIT_INT -DFUN=takmain main.c" diff --git a/testsuite/tests/asmcomp/tak.refout b/testsuite/tests/asmcomp/tak.refout new file mode 100644 index 0000000000..7f8f011eb7 --- /dev/null +++ b/testsuite/tests/asmcomp/tak.refout @@ -0,0 +1 @@ +7 diff --git a/testsuite/tests/asmcomp/tak.t b/testsuite/tests/asmcomp/tak.t new file mode 100644 index 0000000000..a46d1f399e --- /dev/null +++ b/testsuite/tests/asmcomp/tak.t @@ -0,0 +1,15 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh + +cflags="-DUNIT_INT -DFUN=takmain main.c" diff --git a/testsuite/tests/backtrace/Makefile b/testsuite/tests/backtrace/Makefile deleted file mode 100644 index 33ca1ed8bc..0000000000 --- a/testsuite/tests/backtrace/Makefile +++ /dev/null @@ -1,92 +0,0 @@ -######################################################################### -# # -# OCaml # -# # -# Xavier Clerc, SED, INRIA Rocquencourt # -# # -# Copyright 2010 Institut National de Recherche en Informatique et # -# en Automatique. All rights reserved. This file is distributed # -# under the terms of the Q Public License version 1.0. # -# # -######################################################################### - -BASEDIR=../.. -EXECNAME=program$(EXE) - -ABCDFILES=backtrace.ml -OTHERFILES=backtrace2.ml raw_backtrace.ml \ - backtrace_deprecated.ml backtrace_slots.ml -OTHERFILESNOINLINING=backtraces_and_finalizers.ml - -default: - $(MAKE) byte - @if $(BYTECODE_ONLY); then : ; else $(MAKE) native; fi - -.PHONY: byte -byte: - @for file in $(ABCDFILES); do \ - rm -f program program.exe; \ - $(OCAMLC) -g -o $(EXECNAME) $$file; \ - for arg in a b c d ''; do \ - printf " ... testing '$$file' with ocamlc and argument '$$arg':"; \ - F="`basename $$file .ml`"; \ - (OCAMLRUNPARAM=b=1 $(OCAMLRUN) $(EXECNAME) $$arg || true) \ - >$$F.$$arg.byte.result 2>&1; \ - $(DIFF) $$F.$$arg.reference $$F.$$arg.byte.result >/dev/null \ - && echo " => passed" || echo " => failed"; \ - done; \ - done - @for file in $(OTHERFILES); do \ - rm -f program program.exe; \ - $(OCAMLC) -g -o $(EXECNAME) $$file; \ - printf " ... testing '$$file' with ocamlc:"; \ - F="`basename $$file .ml`"; \ - (OCAMLRUNPARAM=b=1 $(OCAMLRUN) $(EXECNAME) $$arg || true) \ - >$$F.byte.result 2>&1; \ - $(DIFF) $$F.reference $$F.byte.result >/dev/null \ - && echo " => passed" || echo " => failed"; \ - done - -.PHONY: native -native: - @for file in $(ABCDFILES); do \ - rm -f program program.exe; \ - $(OCAMLOPT) -g -o $(EXECNAME) $$file; \ - for arg in a b c d ''; do \ - printf " ... testing '$$file' with ocamlopt and argument '$$arg':"; \ - F="`basename $$file .ml`"; \ - (OCAMLRUNPARAM=b=1 ./$(EXECNAME) $$arg || true) \ - >$$F.$$arg.native.result 2>&1; \ - $(DIFF) $$F.$$arg.reference $$F.$$arg.native.result >/dev/null \ - && echo " => passed" || echo " => failed"; \ - done; \ - done - @for file in $(OTHERFILES); do \ - rm -f program program.exe; \ - $(OCAMLOPT) -g -o $(EXECNAME) $$file; \ - printf " ... testing '$$file' with ocamlopt:"; \ - F="`basename $$file .ml`"; \ - (OCAMLRUNPARAM=b=1 ./$(EXECNAME) $$arg || true) \ - >$$F.native.result 2>&1; \ - $(DIFF) $$F.reference $$F.native.result >/dev/null \ - && echo " => passed" || echo " => failed"; \ - done; - @for file in $(OTHERFILESNOINLINING); do \ - rm -f program program.exe; \ - $(OCAMLOPT) -inline 0 -g -o $(EXECNAME) $$file; \ - printf " ... testing '$$file' with ocamlopt:"; \ - F="`basename $$file .ml`"; \ - (OCAMLRUNPARAM=b=1 ./$(EXECNAME) $$arg || true) \ - >$$F.native.result 2>&1; \ - $(DIFF) $$F.reference $$F.native.result >/dev/null \ - && echo " => passed" || echo " => failed"; \ - done - -.PHONY: promote -promote: defaultpromote - -.PHONY: clean -clean: defaultclean - @rm -f *.result program program.exe - -include $(BASEDIR)/makefiles/Makefile.common diff --git a/testsuite/tests/backtrace/Testcommon.sh b/testsuite/tests/backtrace/Testcommon.sh new file mode 100644 index 0000000000..9631946628 --- /dev/null +++ b/testsuite/tests/backtrace/Testcommon.sh @@ -0,0 +1,14 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +compflags=-g +exec_env=OCAMLRUNPARAM=b=1 diff --git a/testsuite/tests/backtrace/backtrace.a.reference b/testsuite/tests/backtrace/backtrace-a.refout index 7898192261..7898192261 100644 --- a/testsuite/tests/backtrace/backtrace.a.reference +++ b/testsuite/tests/backtrace/backtrace-a.refout diff --git a/testsuite/tests/backtrace/backtrace-a.t b/testsuite/tests/backtrace/backtrace-a.t new file mode 100644 index 0000000000..16cd34cbf4 --- /dev/null +++ b/testsuite/tests/backtrace/backtrace-a.t @@ -0,0 +1,14 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./backtrace-common.sh +args=a diff --git a/testsuite/tests/basic-multdef/usemultdef.reference b/testsuite/tests/backtrace/backtrace-b.exit index 0cfbf08886..0cfbf08886 100644 --- a/testsuite/tests/basic-multdef/usemultdef.reference +++ b/testsuite/tests/backtrace/backtrace-b.exit diff --git a/testsuite/tests/backtrace/backtrace.b.reference b/testsuite/tests/backtrace/backtrace-b.referr index a93f65ffa5..aa988c74ec 100644 --- a/testsuite/tests/backtrace/backtrace.b.reference +++ b/testsuite/tests/backtrace/backtrace-b.referr @@ -1,4 +1,3 @@ -b Fatal error: exception Backtrace.Error("b") Raised at file "backtrace.ml", line 18, characters 21-32 Called from file "backtrace.ml", line 18, characters 42-53 diff --git a/testsuite/tests/backtrace/backtrace-b.refout b/testsuite/tests/backtrace/backtrace-b.refout new file mode 100644 index 0000000000..6178079822 --- /dev/null +++ b/testsuite/tests/backtrace/backtrace-b.refout @@ -0,0 +1 @@ +b diff --git a/testsuite/tests/backtrace/backtrace-b.t b/testsuite/tests/backtrace/backtrace-b.t new file mode 100644 index 0000000000..a6a55e560d --- /dev/null +++ b/testsuite/tests/backtrace/backtrace-b.t @@ -0,0 +1,15 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./backtrace-common.sh +args=b +exit=2 diff --git a/testsuite/tests/backtrace/backtrace-c.exit b/testsuite/tests/backtrace/backtrace-c.exit new file mode 100644 index 0000000000..0cfbf08886 --- /dev/null +++ b/testsuite/tests/backtrace/backtrace-c.exit @@ -0,0 +1 @@ +2 diff --git a/testsuite/tests/backtrace/backtrace.c.reference b/testsuite/tests/backtrace/backtrace-c.referr index 8ca6985fab..8ca6985fab 100644 --- a/testsuite/tests/backtrace/backtrace.c.reference +++ b/testsuite/tests/backtrace/backtrace-c.referr diff --git a/testsuite/tests/backtrace/backtrace-c.t b/testsuite/tests/backtrace/backtrace-c.t new file mode 100644 index 0000000000..f5efa275c1 --- /dev/null +++ b/testsuite/tests/backtrace/backtrace-c.t @@ -0,0 +1,15 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./backtrace-common.sh +args=c +exit=2 diff --git a/testsuite/tests/backtrace/backtrace-common.sh b/testsuite/tests/backtrace/backtrace-common.sh new file mode 100644 index 0000000000..1148997cfe --- /dev/null +++ b/testsuite/tests/backtrace/backtrace-common.sh @@ -0,0 +1,15 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. Testcommon.sh +sources=backtrace.ml +kinds='byte opt' diff --git a/testsuite/tests/backtrace/backtrace-d.exit b/testsuite/tests/backtrace/backtrace-d.exit new file mode 100644 index 0000000000..0cfbf08886 --- /dev/null +++ b/testsuite/tests/backtrace/backtrace-d.exit @@ -0,0 +1 @@ +2 diff --git a/testsuite/tests/backtrace/backtrace.d.reference b/testsuite/tests/backtrace/backtrace-d.referr index c4cb390a96..c4cb390a96 100644 --- a/testsuite/tests/backtrace/backtrace.d.reference +++ b/testsuite/tests/backtrace/backtrace-d.referr diff --git a/testsuite/tests/backtrace/backtrace-d.t b/testsuite/tests/backtrace/backtrace-d.t new file mode 100644 index 0000000000..8bd81cd21b --- /dev/null +++ b/testsuite/tests/backtrace/backtrace-d.t @@ -0,0 +1,15 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./backtrace-common.sh +args=d +exit=2 diff --git a/testsuite/tests/backtrace/backtrace-none.exit b/testsuite/tests/backtrace/backtrace-none.exit new file mode 100644 index 0000000000..0cfbf08886 --- /dev/null +++ b/testsuite/tests/backtrace/backtrace-none.exit @@ -0,0 +1 @@ +2 diff --git a/testsuite/tests/backtrace/backtrace..reference b/testsuite/tests/backtrace/backtrace-none.referr index fdbc70feab..fdbc70feab 100644 --- a/testsuite/tests/backtrace/backtrace..reference +++ b/testsuite/tests/backtrace/backtrace-none.referr diff --git a/testsuite/tests/backtrace/backtrace-none.t b/testsuite/tests/backtrace/backtrace-none.t new file mode 100644 index 0000000000..2e60d23434 --- /dev/null +++ b/testsuite/tests/backtrace/backtrace-none.t @@ -0,0 +1,15 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./backtrace-common.sh +args= +exit=2 diff --git a/testsuite/tests/backtrace/backtrace2.reference b/testsuite/tests/backtrace/backtrace2.refout index 185c673e05..185c673e05 100644 --- a/testsuite/tests/backtrace/backtrace2.reference +++ b/testsuite/tests/backtrace/backtrace2.refout diff --git a/testsuite/tests/backtrace/backtrace2.t b/testsuite/tests/backtrace/backtrace2.t new file mode 100644 index 0000000000..33610b956e --- /dev/null +++ b/testsuite/tests/backtrace/backtrace2.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh diff --git a/testsuite/tests/backtrace/backtrace_deprecated.reference b/testsuite/tests/backtrace/backtrace_deprecated.refout index e9fea9ffe5..e9fea9ffe5 100644 --- a/testsuite/tests/backtrace/backtrace_deprecated.reference +++ b/testsuite/tests/backtrace/backtrace_deprecated.refout diff --git a/testsuite/tests/backtrace/backtrace_deprecated.t b/testsuite/tests/backtrace/backtrace_deprecated.t new file mode 100644 index 0000000000..33610b956e --- /dev/null +++ b/testsuite/tests/backtrace/backtrace_deprecated.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh diff --git a/testsuite/tests/backtrace/backtrace_slots.reference b/testsuite/tests/backtrace/backtrace_slots.refout index 2336cd5ac3..2336cd5ac3 100644 --- a/testsuite/tests/backtrace/backtrace_slots.reference +++ b/testsuite/tests/backtrace/backtrace_slots.refout diff --git a/testsuite/tests/backtrace/backtrace_slots.t b/testsuite/tests/backtrace/backtrace_slots.t new file mode 100644 index 0000000000..33610b956e --- /dev/null +++ b/testsuite/tests/backtrace/backtrace_slots.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh diff --git a/testsuite/tests/backtrace/backtraces_and_finalizers.reference b/testsuite/tests/backtrace/backtraces_and_finalizers.refout index 9766475a41..9766475a41 100644 --- a/testsuite/tests/backtrace/backtraces_and_finalizers.reference +++ b/testsuite/tests/backtrace/backtraces_and_finalizers.refout diff --git a/testsuite/tests/backtrace/backtraces_and_finalizers.t b/testsuite/tests/backtrace/backtraces_and_finalizers.t new file mode 100644 index 0000000000..b4b5f79904 --- /dev/null +++ b/testsuite/tests/backtrace/backtraces_and_finalizers.t @@ -0,0 +1,15 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +Tcompflags=-g +Toptflags="-inline 0" +Texec_env=OCAMLRUNPARAM=b=1 diff --git a/testsuite/tests/backtrace/raw_backtrace.reference b/testsuite/tests/backtrace/raw_backtrace.refout index 96fb60e8c2..96fb60e8c2 100644 --- a/testsuite/tests/backtrace/raw_backtrace.reference +++ b/testsuite/tests/backtrace/raw_backtrace.refout diff --git a/testsuite/tests/backtrace/raw_backtrace.t b/testsuite/tests/backtrace/raw_backtrace.t new file mode 100644 index 0000000000..33610b956e --- /dev/null +++ b/testsuite/tests/backtrace/raw_backtrace.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh diff --git a/testsuite/tests/basic-float/tfloat_record.reference b/testsuite/tests/basic-float/tfloat_record.refout index d54c6b66bc..d54c6b66bc 100644 --- a/testsuite/tests/basic-float/tfloat_record.reference +++ b/testsuite/tests/basic-float/tfloat_record.refout diff --git a/testsuite/tests/basic-float/tfloat_record.t b/testsuite/tests/basic-float/tfloat_record.t new file mode 100644 index 0000000000..f22b2b7d02 --- /dev/null +++ b/testsuite/tests/basic-float/tfloat_record.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +sources='float_record.mli float_record.ml tfloat_record.ml' diff --git a/testsuite/tests/basic-io-2/io.reference b/testsuite/tests/basic-io-2/io.refout index 06740020a7..06740020a7 100644 --- a/testsuite/tests/basic-io-2/io.reference +++ b/testsuite/tests/basic-io-2/io.refout diff --git a/testsuite/tests/basic-io-2/io.t b/testsuite/tests/basic-io-2/io.t new file mode 100644 index 0000000000..53a3063461 --- /dev/null +++ b/testsuite/tests/basic-io-2/io.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +args=io.ml diff --git a/testsuite/tests/basic-io/wc.reference b/testsuite/tests/basic-io/wc.refout index adaaa750b4..adaaa750b4 100644 --- a/testsuite/tests/basic-io/wc.reference +++ b/testsuite/tests/basic-io/wc.refout diff --git a/testsuite/tests/basic-io/wc.t b/testsuite/tests/basic-io/wc.t new file mode 100644 index 0000000000..44fbb550d9 --- /dev/null +++ b/testsuite/tests/basic-io/wc.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +args=wc.ml diff --git a/testsuite/tests/basic-manyargs/manyargs.reference b/testsuite/tests/basic-manyargs/manyargs.refout index 24e9d3df3c..24e9d3df3c 100644 --- a/testsuite/tests/basic-manyargs/manyargs.reference +++ b/testsuite/tests/basic-manyargs/manyargs.refout diff --git a/testsuite/tests/basic-manyargs/manyargs.t b/testsuite/tests/basic-manyargs/manyargs.t new file mode 100644 index 0000000000..78a3e5a556 --- /dev/null +++ b/testsuite/tests/basic-manyargs/manyargs.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +sources='manyargsprim.c manyargs.ml' diff --git a/testsuite/tests/basic-modules/main.reference b/testsuite/tests/basic-modules/main.refout index d00491fd7e..d00491fd7e 100644 --- a/testsuite/tests/basic-modules/main.reference +++ b/testsuite/tests/basic-modules/main.refout diff --git a/testsuite/tests/basic-modules/main.t b/testsuite/tests/basic-modules/main.t new file mode 100644 index 0000000000..5acb82b0bb --- /dev/null +++ b/testsuite/tests/basic-modules/main.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +sources='offset.ml pr6726.ml main.ml' diff --git a/testsuite/tests/basic-more/Makefile b/testsuite/tests/basic-more/Makefile deleted file mode 100644 index f6e6659719..0000000000 --- a/testsuite/tests/basic-more/Makefile +++ /dev/null @@ -1,18 +0,0 @@ -######################################################################### -# # -# OCaml # -# # -# Xavier Clerc, SED, INRIA Rocquencourt # -# # -# Copyright 2010 Institut National de Recherche en Informatique et # -# en Automatique. All rights reserved. This file is distributed # -# under the terms of the Q Public License version 1.0. # -# # -######################################################################### - -BASEDIR=../.. -MODULES=testing - -include $(BASEDIR)/makefiles/Makefile.several -include $(BASEDIR)/makefiles/Makefile.common -OCOPTFLAGS=-inline 20 diff --git a/testsuite/tests/basic-more/Testcommon.sh b/testsuite/tests/basic-more/Testcommon.sh new file mode 100644 index 0000000000..25a8dc15d8 --- /dev/null +++ b/testsuite/tests/basic-more/Testcommon.sh @@ -0,0 +1,14 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +optflags='-inline 20' +sources="testing.cmo $base.ml" diff --git a/testsuite/tests/basic-more/bounds.reference b/testsuite/tests/basic-more/bounds.refout index 5d34a60254..5d34a60254 100644 --- a/testsuite/tests/basic-more/bounds.reference +++ b/testsuite/tests/basic-more/bounds.refout diff --git a/testsuite/tests/basic-more/bounds.t b/testsuite/tests/basic-more/bounds.t new file mode 100644 index 0000000000..33610b956e --- /dev/null +++ b/testsuite/tests/basic-more/bounds.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh diff --git a/testsuite/tests/basic-more/morematch-comp.referr b/testsuite/tests/basic-more/morematch-comp.referr new file mode 100644 index 0000000000..794be1dc9d --- /dev/null +++ b/testsuite/tests/basic-more/morematch-comp.referr @@ -0,0 +1,22 @@ +File "morematch.ml", line 1066, characters 8-65: +Warning 8: this pattern-matching is not exhaustive. +Here is an example of a value that is not matched: +A `D +File "morematch.ml", line 86, characters 2-5: +Warning 12: this sub-pattern is unused. +File "morematch.ml", line 87, characters 2-3: +Warning 12: this sub-pattern is unused. +File "morematch.ml", line 236, characters 33-47: +Warning 12: this sub-pattern is unused. +File "morematch.ml", line 405, characters 2-15: +Warning 11: this match case is unused. +File "morematch.ml", line 449, characters 43-44: +Warning 12: this sub-pattern is unused. +File "morematch.ml", line 471, characters 7-8: +Warning 12: this sub-pattern is unused. +File "morematch.ml", line 472, characters 2-7: +Warning 11: this match case is unused. +File "morematch.ml", line 1100, characters 5-51: +Warning 11: this match case is unused. +File "morematch.ml", line 1102, characters 5-51: +Warning 11: this match case is unused. diff --git a/testsuite/tests/basic-more/morematch.ml b/testsuite/tests/basic-more/morematch.ml index eaf604e825..907574dd82 100644 --- a/testsuite/tests/basic-more/morematch.ml +++ b/testsuite/tests/basic-more/morematch.ml @@ -91,13 +91,6 @@ test "quatre" g 4 4 ; test "quatre" g 7 100 ; () ;; -(* -File "morematch.ml", line 73, characters 2-5: -Warning U: this sub-pattern is unused. -File "morematch.ml", line 74, characters 2-3: -Warning U: this sub-pattern is unused. -*) - let h x = match x with (1,1) -> 1 @@ -458,10 +451,7 @@ let rec autre = function | I,_,_ -> 6 | E _,_,_ -> 7 ;; -(* -File "morematch.ml", line 437, characters 43-44: -Warning U: this sub-pattern is unused. -*) + test "autre" autre (J,J,F (D,D)) 3 ; test "autre" autre (J,J,D) 3 ; test "autre" autre (J,J,I) 9 ; @@ -481,12 +471,7 @@ let xyz = function | _,_,(X|U _) -> 8 | _,_,Y -> 5 ;; -(* -File "morematch.ml", line 459, characters 7-8: -Warning U: this sub-pattern is unused. -File "morematch.ml", line 460, characters 2-7: -Warning U: this match case is unused. -*) + test "xyz" xyz (YC,YC,X) 6 ; test "xyz" xyz (YC,YB,U X) 8 ; test "xyz" xyz (YB,YC,X) 6 ; () @@ -1076,12 +1061,6 @@ test "seb" seb ((0,Uout),Uin) 2 ; false (in Switch) *) -(* -File "morematch.ml", line 1060, characters 8-65: -Warning: this pattern-matching is not exhaustive. -Here is an example of a value that is not matched: -A `D -*) type ('a, 'b) t_j = A of 'a | B of 'b * 'a | C let f = function @@ -1122,12 +1101,6 @@ let f = function | B, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _ -> "12" | _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _ -> "13" -(* -File "morematch.ml", line 1094, characters 5-51: -Warning: this match case is unused. -File "morematch.ml", line 1096, characters 5-51: -Warning: this match case is unused. -*) let _ = test "luc" f (B, A, A, A, A, A, A, A, A, A, A, B, A, A, A, A) "10" ; test "luc" f (B, A, A, A, A, A, A, A, A, A, A, A, A, A, A, A) "12" ; diff --git a/testsuite/tests/basic-more/morematch.reference b/testsuite/tests/basic-more/morematch.refout index 197c928071..197c928071 100644 --- a/testsuite/tests/basic-more/morematch.reference +++ b/testsuite/tests/basic-more/morematch.refout diff --git a/testsuite/tests/basic-more/morematch.t b/testsuite/tests/basic-more/morematch.t new file mode 100644 index 0000000000..33610b956e --- /dev/null +++ b/testsuite/tests/basic-more/morematch.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh diff --git a/testsuite/tests/basic-more/pr2719.reference b/testsuite/tests/basic-more/pr2719.refout index 073d0916d9..073d0916d9 100644 --- a/testsuite/tests/basic-more/pr2719.reference +++ b/testsuite/tests/basic-more/pr2719.refout diff --git a/testsuite/tests/basic-more/pr2719.t b/testsuite/tests/basic-more/pr2719.t new file mode 100644 index 0000000000..33610b956e --- /dev/null +++ b/testsuite/tests/basic-more/pr2719.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh diff --git a/testsuite/tests/basic-more/pr6216.reference b/testsuite/tests/basic-more/pr6216.refout index 197c928071..197c928071 100644 --- a/testsuite/tests/basic-more/pr6216.reference +++ b/testsuite/tests/basic-more/pr6216.refout diff --git a/testsuite/tests/basic-more/pr6216.t b/testsuite/tests/basic-more/pr6216.t new file mode 100644 index 0000000000..33610b956e --- /dev/null +++ b/testsuite/tests/basic-more/pr6216.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh diff --git a/testsuite/tests/basic-more/tbuffer.reference b/testsuite/tests/basic-more/tbuffer.refout index f0f683477f..f0f683477f 100644 --- a/testsuite/tests/basic-more/tbuffer.reference +++ b/testsuite/tests/basic-more/tbuffer.refout diff --git a/testsuite/tests/basic-more/tbuffer.t b/testsuite/tests/basic-more/tbuffer.t new file mode 100644 index 0000000000..33610b956e --- /dev/null +++ b/testsuite/tests/basic-more/tbuffer.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh diff --git a/testsuite/tests/basic-more/testrandom.reference b/testsuite/tests/basic-more/testrandom.refout index 943addd1bd..943addd1bd 100644 --- a/testsuite/tests/basic-more/testrandom.reference +++ b/testsuite/tests/basic-more/testrandom.refout diff --git a/testsuite/tests/basic-more/testrandom.t b/testsuite/tests/basic-more/testrandom.t new file mode 100644 index 0000000000..33610b956e --- /dev/null +++ b/testsuite/tests/basic-more/testrandom.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh diff --git a/testsuite/tests/basic-more/tformat.reference b/testsuite/tests/basic-more/tformat.refout index 819c5ba693..819c5ba693 100644 --- a/testsuite/tests/basic-more/tformat.reference +++ b/testsuite/tests/basic-more/tformat.refout diff --git a/testsuite/tests/basic-more/tformat.t b/testsuite/tests/basic-more/tformat.t new file mode 100644 index 0000000000..ed3c8e23b1 --- /dev/null +++ b/testsuite/tests/basic-more/tformat.t @@ -0,0 +1,14 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh +compflags='-w -3' diff --git a/testsuite/tests/basic-more/tprintf.reference b/testsuite/tests/basic-more/tprintf.refout index 1fb209d42c..1fb209d42c 100644 --- a/testsuite/tests/basic-more/tprintf.reference +++ b/testsuite/tests/basic-more/tprintf.refout diff --git a/testsuite/tests/basic-more/tprintf.t b/testsuite/tests/basic-more/tprintf.t new file mode 100644 index 0000000000..33610b956e --- /dev/null +++ b/testsuite/tests/basic-more/tprintf.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh diff --git a/testsuite/tests/basic-multdef/multdef.refout b/testsuite/tests/basic-multdef/multdef.refout new file mode 100644 index 0000000000..0cfbf08886 --- /dev/null +++ b/testsuite/tests/basic-multdef/multdef.refout @@ -0,0 +1 @@ +2 diff --git a/testsuite/tests/basic-multdef/multdef.t b/testsuite/tests/basic-multdef/multdef.t new file mode 100644 index 0000000000..1f98181dd4 --- /dev/null +++ b/testsuite/tests/basic-multdef/multdef.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +sources='multdef.mli multdef.ml usemultdef.ml' diff --git a/testsuite/tests/basic/arrays.reference b/testsuite/tests/basic-private/tlength.refout index e69de29bb2..e69de29bb2 100644 --- a/testsuite/tests/basic/arrays.reference +++ b/testsuite/tests/basic-private/tlength.refout diff --git a/testsuite/tests/basic-private/tlength.t b/testsuite/tests/basic-private/tlength.t new file mode 100644 index 0000000000..3e5219ddcb --- /dev/null +++ b/testsuite/tests/basic-private/tlength.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +sources='length.mli length.ml tlength.ml' diff --git a/testsuite/tests/basic/stringmatch.reference b/testsuite/tests/basic/arrays.t index e69de29bb2..e69de29bb2 100644 --- a/testsuite/tests/basic/stringmatch.reference +++ b/testsuite/tests/basic/arrays.t diff --git a/testsuite/tests/basic/bigints.reference b/testsuite/tests/basic/bigints.refout index 512fd476b2..512fd476b2 100644 --- a/testsuite/tests/basic/bigints.reference +++ b/testsuite/tests/basic/bigints.refout diff --git a/testsuite/tests/exotic-syntax/exotic.reference b/testsuite/tests/basic/bigints.t index e69de29bb2..e69de29bb2 100644 --- a/testsuite/tests/exotic-syntax/exotic.reference +++ b/testsuite/tests/basic/bigints.t diff --git a/testsuite/tests/basic/boxedints.reference b/testsuite/tests/basic/boxedints.refout index 009390faee..009390faee 100644 --- a/testsuite/tests/basic/boxedints.reference +++ b/testsuite/tests/basic/boxedints.refout diff --git a/testsuite/tests/letrec/backreferences.reference b/testsuite/tests/basic/boxedints.t index e69de29bb2..e69de29bb2 100644 --- a/testsuite/tests/letrec/backreferences.reference +++ b/testsuite/tests/basic/boxedints.t diff --git a/testsuite/tests/basic/constprop.reference b/testsuite/tests/basic/constprop.refout index 59590530ae..59590530ae 100644 --- a/testsuite/tests/basic/constprop.reference +++ b/testsuite/tests/basic/constprop.refout diff --git a/testsuite/tests/letrec/class_1.reference b/testsuite/tests/basic/constprop.t index e69de29bb2..e69de29bb2 100644 --- a/testsuite/tests/letrec/class_1.reference +++ b/testsuite/tests/basic/constprop.t diff --git a/testsuite/tests/basic/divint.reference b/testsuite/tests/basic/divint.refout index e9a6387fa8..e9a6387fa8 100644 --- a/testsuite/tests/basic/divint.reference +++ b/testsuite/tests/basic/divint.refout diff --git a/testsuite/tests/letrec/float_block_2.reference b/testsuite/tests/basic/divint.t index e69de29bb2..e69de29bb2 100644 --- a/testsuite/tests/letrec/float_block_2.reference +++ b/testsuite/tests/basic/divint.t diff --git a/testsuite/tests/basic/equality.reference b/testsuite/tests/basic/equality.refout index 6070a6b0a0..6070a6b0a0 100644 --- a/testsuite/tests/basic/equality.reference +++ b/testsuite/tests/basic/equality.refout diff --git a/testsuite/tests/letrec/lists.reference b/testsuite/tests/basic/equality.t index e69de29bb2..e69de29bb2 100644 --- a/testsuite/tests/letrec/lists.reference +++ b/testsuite/tests/basic/equality.t diff --git a/testsuite/tests/basic/float.reference b/testsuite/tests/basic/float.refout index 3e7bab44dd..3e7bab44dd 100644 --- a/testsuite/tests/basic/float.reference +++ b/testsuite/tests/basic/float.refout diff --git a/testsuite/tests/letrec/mixing_value_closures_1.reference b/testsuite/tests/basic/float.t index e69de29bb2..e69de29bb2 100644 --- a/testsuite/tests/letrec/mixing_value_closures_1.reference +++ b/testsuite/tests/basic/float.t diff --git a/testsuite/tests/basic/includestruct.reference b/testsuite/tests/basic/includestruct.refout index a7756837ec..a7756837ec 100644 --- a/testsuite/tests/basic/includestruct.reference +++ b/testsuite/tests/basic/includestruct.refout diff --git a/testsuite/tests/letrec/mixing_value_closures_2.reference b/testsuite/tests/basic/includestruct.t index e69de29bb2..e69de29bb2 100644 --- a/testsuite/tests/letrec/mixing_value_closures_2.reference +++ b/testsuite/tests/basic/includestruct.t diff --git a/testsuite/tests/basic/maps.reference b/testsuite/tests/basic/maps.refout index c7b0c08339..c7b0c08339 100644 --- a/testsuite/tests/basic/maps.reference +++ b/testsuite/tests/basic/maps.refout diff --git a/testsuite/tests/letrec/mutual_functions.reference b/testsuite/tests/basic/maps.t index e69de29bb2..e69de29bb2 100644 --- a/testsuite/tests/letrec/mutual_functions.reference +++ b/testsuite/tests/basic/maps.t diff --git a/testsuite/tests/basic/patmatch.reference b/testsuite/tests/basic/patmatch.refout index aafc1b5c4f..aafc1b5c4f 100644 --- a/testsuite/tests/basic/patmatch.reference +++ b/testsuite/tests/basic/patmatch.refout diff --git a/testsuite/tests/basic/patmatch.t b/testsuite/tests/basic/patmatch.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/basic/patmatch.t diff --git a/testsuite/tests/basic/recvalues.reference b/testsuite/tests/basic/recvalues.refout index ac71fc1da6..ac71fc1da6 100644 --- a/testsuite/tests/basic/recvalues.reference +++ b/testsuite/tests/basic/recvalues.refout diff --git a/testsuite/tests/basic/recvalues.t b/testsuite/tests/basic/recvalues.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/basic/recvalues.t diff --git a/testsuite/tests/basic/sets.reference b/testsuite/tests/basic/sets.refout index 2d4ebc2468..2d4ebc2468 100644 --- a/testsuite/tests/basic/sets.reference +++ b/testsuite/tests/basic/sets.refout diff --git a/testsuite/tests/basic/sets.t b/testsuite/tests/basic/sets.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/basic/sets.t diff --git a/testsuite/tests/basic/stringmatch.t b/testsuite/tests/basic/stringmatch.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/basic/stringmatch.t diff --git a/testsuite/tests/basic/tailcalls.reference b/testsuite/tests/basic/tailcalls.refout index c7117bc954..c7117bc954 100644 --- a/testsuite/tests/basic/tailcalls.reference +++ b/testsuite/tests/basic/tailcalls.refout diff --git a/testsuite/tests/basic/tailcalls.t b/testsuite/tests/basic/tailcalls.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/basic/tailcalls.t diff --git a/testsuite/tests/callback/Makefile b/testsuite/tests/callback/Makefile deleted file mode 100644 index d89c532635..0000000000 --- a/testsuite/tests/callback/Makefile +++ /dev/null @@ -1,59 +0,0 @@ -######################################################################### -# # -# OCaml # -# # -# Xavier Clerc, SED, INRIA Rocquencourt # -# # -# Copyright 2010 Institut National de Recherche en Informatique et # -# en Automatique. All rights reserved. This file is distributed # -# under the terms of the Q Public License version 1.0. # -# # -######################################################################### - -BASEDIR=../.. - -CC=$(NATIVECC) -I $(CTOPDIR)/byterun -COMPFLAGS=-I $(OTOPDIR)/otherlibs/unix -LD_PATH=$(TOPDIR)/otherlibs/unix - -.PHONY: default -default: - @case " $(OTHERLIBRARIES) " in \ - *' unix '*) $(SET_LD_PATH) $(MAKE) run-byte; \ - $(SET_LD_PATH) $(MAKE) run-opt;; \ - esac - -.PHONY: common -common: - @$(CC) -c callbackprim.c - -.PHONY: run-byte -run-byte: common - @printf " ... testing 'bytecode':" - @$(OCAMLC) $(COMPFLAGS) -c tcallback.ml - @$(OCAMLC) $(COMPFLAGS) -o ./program$(EXE) -custom unix.cma \ - callbackprim.$(O) tcallback.cmo - @./program$(EXE) >bytecode.result - @$(DIFF) reference bytecode.result \ - && echo " => passed" || echo " => failed" - -.PHONY: run-opt -run-opt: common - @if $(BYTECODE_ONLY); then : ; else \ - printf " ... testing 'native':"; \ - $(OCAMLOPT) $(COMPFLAGS) -c tcallback.ml; \ - $(OCAMLOPT) $(COMPFLAGS) -o ./program$(EXE) unix.cmxa \ - callbackprim.$(O) tcallback.cmx; \ - ./program$(EXE) >native.result; \ - $(DIFF) reference native.result \ - && echo " => passed" || echo " => failed"; \ - fi - -.PHONY: promote -promote: defaultpromote - -.PHONY: clean -clean: defaultclean - @rm -f *.result ./program$(EXE) - -include $(BASEDIR)/makefiles/Makefile.common diff --git a/testsuite/tests/callback/reference b/testsuite/tests/callback/tcallback.refout index b35993aa2c..b35993aa2c 100644 --- a/testsuite/tests/callback/reference +++ b/testsuite/tests/callback/tcallback.refout diff --git a/testsuite/tests/callback/tcallback.t b/testsuite/tests/callback/tcallback.t new file mode 100644 index 0000000000..2893902938 --- /dev/null +++ b/testsuite/tests/callback/tcallback.t @@ -0,0 +1,14 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +compflags="-I $OTOPDIR/otherlibs/unix" +sources='unix.cma callbackprim.c tcallback.ml' diff --git a/testsuite/tests/embedded/Makefile b/testsuite/tests/embedded/Makefile deleted file mode 100644 index 088b021656..0000000000 --- a/testsuite/tests/embedded/Makefile +++ /dev/null @@ -1,41 +0,0 @@ -######################################################################### -# # -# OCaml # -# # -# Xavier Clerc, SED, INRIA Rocquencourt # -# # -# Copyright 2010 Institut National de Recherche en Informatique et # -# en Automatique. All rights reserved. This file is distributed # -# under the terms of the Q Public License version 1.0. # -# # -######################################################################### - -BASEDIR=../.. - -.PHONY: default -default: - $(MAKE) compile - $(MAKE) run - -.PHONY: compile -compile: - @$(OCAMLC) -ccopt -I -ccopt $(CTOPDIR)/byterun cmstub.c - @$(OCAMLC) -ccopt -I -ccopt $(CTOPDIR)/byterun cmmain.c - @$(OCAMLC) -c cmcaml.ml - @$(OCAMLC) -custom -o program cmstub.$(O) cmcaml.cmo cmmain.$(O) - -.PHONY: run -run: - @printf " ... testing 'cmmain':" - @./program >program.result - @$(DIFF) program.reference program.result >/dev/null \ - && echo " => passed" || echo " => failed" - -.PHONY: promote -promote: defaultpromote - -.PHONY: clean -clean: defaultclean - @rm -f *.result program - -include $(BASEDIR)/makefiles/Makefile.common diff --git a/testsuite/tests/embedded/program.reference b/testsuite/tests/embedded/cm.refout index 4f27810ca9..4f27810ca9 100644 --- a/testsuite/tests/embedded/program.reference +++ b/testsuite/tests/embedded/cm.refout diff --git a/testsuite/tests/embedded/cm.t b/testsuite/tests/embedded/cm.t new file mode 100644 index 0000000000..c35a8df558 --- /dev/null +++ b/testsuite/tests/embedded/cm.t @@ -0,0 +1,14 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +kinds=byte +sources='cmstub.c cmcaml.ml cmmain.c' diff --git a/testsuite/tests/exotic-syntax/exotic.t b/testsuite/tests/exotic-syntax/exotic.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/exotic-syntax/exotic.t diff --git a/testsuite/tests/formats-transition/deprecated_unsigned_printers.ml.reference b/testsuite/tests/formats-transition/deprecated_unsigned_printers.refout index 0afeaa2be1..0afeaa2be1 100644 --- a/testsuite/tests/formats-transition/deprecated_unsigned_printers.ml.reference +++ b/testsuite/tests/formats-transition/deprecated_unsigned_printers.refout diff --git a/testsuite/tests/formats-transition/deprecated_unsigned_printers.t b/testsuite/tests/formats-transition/deprecated_unsigned_printers.t new file mode 100644 index 0000000000..97b3a999dc --- /dev/null +++ b/testsuite/tests/formats-transition/deprecated_unsigned_printers.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +kinds=top diff --git a/testsuite/tests/gc-roots/Makefile b/testsuite/tests/gc-roots/Makefile deleted file mode 100644 index a10895381f..0000000000 --- a/testsuite/tests/gc-roots/Makefile +++ /dev/null @@ -1,20 +0,0 @@ -######################################################################### -# # -# OCaml # -# # -# Xavier Clerc, SED, INRIA Rocquencourt # -# # -# Copyright 2010 Institut National de Recherche en Informatique et # -# en Automatique. All rights reserved. This file is distributed # -# under the terms of the Q Public License version 1.0. # -# # -######################################################################### - -BASEDIR=../.. -#MODULES= -MAIN_MODULE=globroots -C_FILES=globrootsprim -ADD_COMPFLAGS=-w a - -include $(BASEDIR)/makefiles/Makefile.one -include $(BASEDIR)/makefiles/Makefile.common diff --git a/testsuite/tests/gc-roots/globroots.reference b/testsuite/tests/gc-roots/globroots.refout index aae90b2230..aae90b2230 100644 --- a/testsuite/tests/gc-roots/globroots.reference +++ b/testsuite/tests/gc-roots/globroots.refout diff --git a/testsuite/tests/gc-roots/globroots.t b/testsuite/tests/gc-roots/globroots.t new file mode 100644 index 0000000000..89e0d9cdb9 --- /dev/null +++ b/testsuite/tests/gc-roots/globroots.t @@ -0,0 +1,14 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +sources='globrootsprim.c globroots.ml' +compflags='-w a' diff --git a/testsuite/tests/letrec/backreferences.refout b/testsuite/tests/letrec/backreferences.refout new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/letrec/backreferences.refout diff --git a/testsuite/tests/letrec/backreferences.t b/testsuite/tests/letrec/backreferences.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/letrec/backreferences.t diff --git a/testsuite/tests/letrec/class_1.refout b/testsuite/tests/letrec/class_1.refout new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/letrec/class_1.refout diff --git a/testsuite/tests/letrec/class_1.t b/testsuite/tests/letrec/class_1.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/letrec/class_1.t diff --git a/testsuite/tests/letrec/class_2.reference b/testsuite/tests/letrec/class_2.refout index ab713757f4..ab713757f4 100644 --- a/testsuite/tests/letrec/class_2.reference +++ b/testsuite/tests/letrec/class_2.refout diff --git a/testsuite/tests/letrec/class_2.t b/testsuite/tests/letrec/class_2.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/letrec/class_2.t diff --git a/testsuite/tests/letrec/evaluation_order_1.reference b/testsuite/tests/letrec/evaluation_order_1.refout index f471662b7d..f471662b7d 100644 --- a/testsuite/tests/letrec/evaluation_order_1.reference +++ b/testsuite/tests/letrec/evaluation_order_1.refout diff --git a/testsuite/tests/letrec/evaluation_order_1.t b/testsuite/tests/letrec/evaluation_order_1.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/letrec/evaluation_order_1.t diff --git a/testsuite/tests/letrec/evaluation_order_2.reference b/testsuite/tests/letrec/evaluation_order_2.refout index 04ec35a6dc..04ec35a6dc 100644 --- a/testsuite/tests/letrec/evaluation_order_2.reference +++ b/testsuite/tests/letrec/evaluation_order_2.refout diff --git a/testsuite/tests/letrec/evaluation_order_2.t b/testsuite/tests/letrec/evaluation_order_2.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/letrec/evaluation_order_2.t diff --git a/testsuite/tests/letrec/evaluation_order_3.reference b/testsuite/tests/letrec/evaluation_order_3.refout index 5b8c549eca..5b8c549eca 100644 --- a/testsuite/tests/letrec/evaluation_order_3.reference +++ b/testsuite/tests/letrec/evaluation_order_3.refout diff --git a/testsuite/tests/letrec/evaluation_order_3.t b/testsuite/tests/letrec/evaluation_order_3.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/letrec/evaluation_order_3.t diff --git a/testsuite/tests/letrec/float_block_1.reference b/testsuite/tests/letrec/float_block_1.refout index b77b4eb1d9..b77b4eb1d9 100644 --- a/testsuite/tests/letrec/float_block_1.reference +++ b/testsuite/tests/letrec/float_block_1.refout diff --git a/testsuite/tests/letrec/float_block_1.t b/testsuite/tests/letrec/float_block_1.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/letrec/float_block_1.t diff --git a/testsuite/tests/letrec/float_block_2.t b/testsuite/tests/letrec/float_block_2.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/letrec/float_block_2.t diff --git a/testsuite/tests/letrec/lists.t b/testsuite/tests/letrec/lists.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/letrec/lists.t diff --git a/testsuite/tests/letrec/mixing_value_closures_1.t b/testsuite/tests/letrec/mixing_value_closures_1.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/letrec/mixing_value_closures_1.t diff --git a/testsuite/tests/letrec/mixing_value_closures_2.t b/testsuite/tests/letrec/mixing_value_closures_2.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/letrec/mixing_value_closures_2.t diff --git a/testsuite/tests/letrec/mutual_functions.t b/testsuite/tests/letrec/mutual_functions.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/letrec/mutual_functions.t diff --git a/testsuite/tests/letrec/record_with.reference b/testsuite/tests/letrec/record_with.refout index d81cc0710e..d81cc0710e 100644 --- a/testsuite/tests/letrec/record_with.reference +++ b/testsuite/tests/letrec/record_with.refout diff --git a/testsuite/tests/letrec/record_with.t b/testsuite/tests/letrec/record_with.t new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/testsuite/tests/letrec/record_with.t diff --git a/testsuite/tests/lib-bigarray-2/Makefile b/testsuite/tests/lib-bigarray-2/Makefile deleted file mode 100644 index 373ff94493..0000000000 --- a/testsuite/tests/lib-bigarray-2/Makefile +++ /dev/null @@ -1,19 +0,0 @@ -######################################################################### -# # -# OCaml # -# # -# Xavier Clerc, SED, INRIA Rocquencourt # -# # -# Copyright 2010 Institut National de Recherche en Informatique et # -# en Automatique. All rights reserved. This file is distributed # -# under the terms of the Q Public License version 1.0. # -# # -######################################################################### - -BASEDIR=../.. -LIBRARIES=unix bigarray -C_FILES=bigarrfstub -F_FILES=bigarrf - -include $(BASEDIR)/makefiles/Makefile.several -include $(BASEDIR)/makefiles/Makefile.common diff --git a/testsuite/tests/lib-bigarray-2/bigarrfml.reference b/testsuite/tests/lib-bigarray-2/bigarrf.refout index 8368d5aba0..8368d5aba0 100644 --- a/testsuite/tests/lib-bigarray-2/bigarrfml.reference +++ b/testsuite/tests/lib-bigarray-2/bigarrf.refout diff --git a/testsuite/tests/basic-manyargs/Makefile b/testsuite/tests/lib-bigarray-2/bigarrf.t index 3cf4a15e80..4feaf9218e 100644 --- a/testsuite/tests/basic-manyargs/Makefile +++ b/testsuite/tests/lib-bigarray-2/bigarrf.t @@ -2,18 +2,15 @@ # # # OCaml # # # -# Xavier Clerc, SED, INRIA Rocquencourt # +# Damien Doligez, Jane Street Capital # # # -# Copyright 2010 Institut National de Recherche en Informatique et # +# Copyright 2015 Institut National de Recherche en Informatique et # # en Automatique. All rights reserved. This file is distributed # # under the terms of the Q Public License version 1.0. # # # ######################################################################### -BASEDIR=../.. -#MODULES= -MAIN_MODULE=manyargs -C_FILES=manyargsprim - -include $(BASEDIR)/makefiles/Makefile.one -include $(BASEDIR)/makefiles/Makefile.common +sources='unix.cma bigarray.cma bigarrf.f bigarrfstub.c bigarrfml.ml' +cflags="-I $CTOPDIR/otherlibs/bigarray" +compflags="-I $OTOPDIR/otherlibs/bigarray -I $OTOPDIR/otherlibs/$UNIXLIB \ + $FORTRAN_LIBRARY" diff --git a/testsuite/tests/lib-bigarray-2/bigarrfml.ml b/testsuite/tests/lib-bigarray-2/bigarrfml.ml index 906826fae6..d73f1555f0 100644 --- a/testsuite/tests/lib-bigarray-2/bigarrfml.ml +++ b/testsuite/tests/lib-bigarray-2/bigarrfml.ml @@ -39,7 +39,7 @@ let test test_number answer correct_answer = (* External C and Fortran functions *) external c_filltab : - unit -> (float, float64_elt, c_layout) Array2.t = "c_filltaab" + unit -> (float, float64_elt, c_layout) Array2.t = "c_filltab" external c_printtab : (float, float64_elt, c_layout) Array2.t -> unit = "c_printtab" external fortran_filltab : diff --git a/testsuite/tests/basic-float/Makefile b/testsuite/tests/lib-bigarray/Testcommon.sh index 8214dfa227..ee51f63a42 100644 --- a/testsuite/tests/basic-float/Makefile +++ b/testsuite/tests/lib-bigarray/Testcommon.sh @@ -2,17 +2,14 @@ # # # OCaml # # # -# Xavier Clerc, SED, INRIA Rocquencourt # +# Damien Doligez, Jane Street Capital # # # -# Copyright 2010 Institut National de Recherche en Informatique et # +# Copyright 2015 Institut National de Recherche en Informatique et # # en Automatique. All rights reserved. This file is distributed # # under the terms of the Q Public License version 1.0. # # # ######################################################################### -BASEDIR=../.. -MODULES=float_record -MAIN_MODULE=tfloat_record - -include $(BASEDIR)/makefiles/Makefile.one -include $(BASEDIR)/makefiles/Makefile.common +sources="unix.cma bigarray.cma $base.ml" +compflags="-I $OTOPDIR/otherlibs/$UNIXLIB -I $OTOPDIR/otherlibs/bigarray" +LD_PATH=$TOPDIR/otherlibs/$UNIXLIB:$TOPDIR/otherlibs/bigarray diff --git a/testsuite/tests/lib-bigarray/bigarrays.reference b/testsuite/tests/lib-bigarray/bigarrays.refout index bdc7beae23..bdc7beae23 100644 --- a/testsuite/tests/lib-bigarray/bigarrays.reference +++ b/testsuite/tests/lib-bigarray/bigarrays.refout diff --git a/testsuite/tests/lib-bigarray/bigarrays.t b/testsuite/tests/lib-bigarray/bigarrays.t new file mode 100644 index 0000000000..33610b956e --- /dev/null +++ b/testsuite/tests/lib-bigarray/bigarrays.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh diff --git a/testsuite/tests/lib-bigarray/fftba.reference b/testsuite/tests/lib-bigarray/fftba.refout index 71017f70fc..71017f70fc 100644 --- a/testsuite/tests/lib-bigarray/fftba.reference +++ b/testsuite/tests/lib-bigarray/fftba.refout diff --git a/testsuite/tests/lib-bigarray/fftba.t b/testsuite/tests/lib-bigarray/fftba.t new file mode 100644 index 0000000000..33610b956e --- /dev/null +++ b/testsuite/tests/lib-bigarray/fftba.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh diff --git a/testsuite/tests/lib-bigarray/pr5115.ml b/testsuite/tests/lib-bigarray/pr5115.ml index 27afaf56e7..2a621b085b 100644 --- a/testsuite/tests/lib-bigarray/pr5115.ml +++ b/testsuite/tests/lib-bigarray/pr5115.ml @@ -20,5 +20,5 @@ let f y0 = let _ = let y = Array1.of_array float64 fortran_layout [| 1. |] in - (f y).{1}; + ignore (f y).{1}; (f y).{1} <- 3.14 diff --git a/testsuite/tests/lib-bigarray/pr5115.reference b/testsuite/tests/lib-bigarray/pr5115.refout index 63f719ac56..63f719ac56 100644 --- a/testsuite/tests/lib-bigarray/pr5115.reference +++ b/testsuite/tests/lib-bigarray/pr5115.refout diff --git a/testsuite/tests/lib-bigarray/pr5115.t b/testsuite/tests/lib-bigarray/pr5115.t new file mode 100644 index 0000000000..33610b956e --- /dev/null +++ b/testsuite/tests/lib-bigarray/pr5115.t @@ -0,0 +1,13 @@ +######################################################################### +# # +# OCaml # +# # +# Damien Doligez, Jane Street Capital # +# # +# Copyright 2015 Institut National de Recherche en Informatique et # +# en Automatique. All rights reserved. This file is distributed # +# under the terms of the Q Public License version 1.0. # +# # +######################################################################### + +. ./Testcommon.sh diff --git a/testsuite/tests/lib-digest/Makefile b/testsuite/tests/lib-digest/Makefile deleted file mode 100644 index adda276594..0000000000 --- a/testsuite/tests/lib-digest/Makefile +++ /dev/null @@ -1,19 +0,0 @@ -######################################################################### -# # -# OCaml # -# # -# Xavier Clerc, SED, INRIA Rocquencourt # -# # -# Copyright 2010 Institut National de Recherche en Informatique et # -# en Automatique. All rights reserved. This file is distributed # -# under the terms of the Q Public License version 1.0. # -# # -######################################################################### - -BASEDIR=../.. -#MODULES= -MAIN_MODULE=md5 -ADD_COMPFLAGS=-w a - -include $(BASEDIR)/makefiles/Makefile.one -include $(BASEDIR)/makefiles/Makefile.common diff --git a/testsuite/tests/lib-digest/md5.reference b/testsuite/tests/lib-digest/md5.refout index 956ac65448..956ac65448 100644 --- a/testsuite/tests/lib-digest/md5.reference +++ b/testsuite/tests/lib-digest/md5.refout diff --git a/tools/check-typo b/tools/check-typo index bd48dc7a3e..b5037143aa 100755 --- a/tools/check-typo +++ b/tools/check-typo @@ -38,6 +38,8 @@ # - Any file whose name matches one of the following patterns is # automatically exempt from all rules # *.reference +# *.out +# *.err # */reference # */.depend* # - Any file whose name begins with "Makefile" is automatically exempt @@ -53,6 +55,7 @@ # - Any file whose name matches the following pattern is automatically # exempt from the "long-line" rule (but not from "very-long-line"). # */ocamldoc/* +# - An empty file is exempt from the missing-header rule. # ASCII characters are bytes from 0 to 127. Any other byte is # flagged as a non-ASCII character. @@ -139,7 +142,7 @@ IGNORE_DIRS=" Makefile*|*/Makefile*) rules="tab,$rules";; */.ignore) add_hd;; *.mlpack|*.mllib|*.mltop|*.odocl|*.itarget|*.clib) add_hd;; - *.reference|*/reference|*/.depend*) continue;; + *.reference|*.out|*.err|*/reference|*/.depend*) continue;; esac case "$f" in ocamldoc/*|*/ocamldoc/*) rules="long-line,$rules";; @@ -169,7 +172,7 @@ IGNORE_DIRS=" err("non-ascii", "non-ASCII character(s)"); } - match($0, /[^\t\200-\377 -~]/) { + match($0, /[^\t\200-\377 -}~]/) { err("non-printing", "non-printing ASCII character(s)"); } @@ -223,7 +226,7 @@ IGNORE_DIRS=" NR = 1; RSTART = 1; RLENGTH = 0; - if (!(header_ocaml && header_copyright)){ + if (!empty_file && !(header_ocaml && header_copyright)){ err("missing-header", "missing copyright header"); } split(svnrules, r, "[, ]"); diff --git a/tools/setignore b/tools/setignore index 43d37a97dd..77be7cba4a 100755 --- a/tools/setignore +++ b/tools/setignore @@ -26,15 +26,14 @@ *.cmti *.annot -*.result *.byte *.native -program +*.byt *.exe *.exe.manifest +*.exe.dSYM +_tmp -.depend -.depend.nt .DS_Store EOF |