Commit Graph

1236 Commits (master)

Author SHA1 Message Date
David Allsopp 5efcc1b474 AppVeyor: test dependency generation on msvc64 2020-05-01 09:53:01 +01:00
David Allsopp ac2a9dd188 Cease committing C dependendency information
When building for the first time, the only requirement is that generated
header files have been built (jumptbl.h, version.h and opnames.h).
Detailed dependency information is only required when headers have been
edited.

COMPUTE_DEPS in Makefile.config controls whether C dependency
information should be generated on a per-file basis. This variable is
controlled by a new --disable-dependency-generation in configure which
is enabled for Git checkouts and disabled for tarballs (i.e. releases).

The Microsoft C compiler (cl) cannot generate dependencies in a
consistent way which we can consume, so for a Git checkout configure
searches for an additional C compiler in order to compute dependencies.
This is obviously not required for a user-build.

As a result, the MSVC port can now safely run make alldepend, since only
OCaml dependency information is committed to the repo after this change.

CI does not need to waste time testing the dependency information,
because it only tests a single build. A single Travis job has been added
which tests the build system code to generate the dependency information
(and provides a single `make -j` run in CI, although Inria's CI also
tests parallel building continuously).
2020-04-17 14:11:22 +01:00
David Allsopp 3a40b2fd94 Introduce Makefile.build_config.in
This moves the configure-generated parts of Makefile.common to a
separate (generated) Makefile, allowing Makefile.common to be a normal
Makefile.

OCaml's build system Makefile's now include Makefile.build_config (which
itself includes Makefile.config) but Makefile.config is still installed
as before. This allows configure to generate variables which are
specific to the build process and are not intended to be exported to the
installation.
2020-04-17 13:53:49 +01:00
Enguerrand Decorne b7f0494df5 Rewrite the instrumented runtime to store traces in the CTF format.
The instrumentation code in the instrumented runtime was replaced
with new APIs to gather runtime statistics and output them in a new format
(Common Trace Format).
This commit also exposes new functions in the Gc module to pause or resume
instrumentation during a program execution (Gc.eventlog_pause and
Gc.eventlog_resume).
2020-04-30 10:32:01 +02:00
David Allsopp abd6712f6a
Merge pull request #9491 from dra27/bionic-travis
Switch Travis testing from Xenial to Bionic
2020-04-23 21:17:13 +01:00
Damien Doligez 2d3c211e00 release checklist: fix small problems in branching instructions 2020-04-23 21:28:41 +02:00
David Allsopp c6048eb406 Switch Travis testing from Xenial to Bionic 2020-04-23 15:58:36 +01:00
Damien Doligez e92d13c986 last commit before branching 4.11 2020-04-22 17:28:08 +02:00
David Allsopp 8a36b7ab30 Test distclean in CI
Ensure that distclean works in an unconfigured tree. At the end of the
build, ensure that no tracked files have been altered or untracked files
created and ensure that distclean removes all ignored files.
2020-04-20 11:07:28 +01:00
Nicolás Ojeda Bär 15b08d2fdf
Use Filename.quote_command (#9476) 2020-04-20 14:38:10 +02:00
David Allsopp 014105bf1c Use configure-caches on AppVeyor 2020-04-17 10:16:03 +01:00
David Allsopp db1d8488e6 Run AppVeyor with -j for branches 2020-04-17 09:35:16 +01:00
David Allsopp 644696e041 Display AppVeyor environment 2020-04-17 09:28:05 +01:00
David Allsopp 540df2ee65 Introduce $MAKE to AppVeyor script 2020-04-17 08:58:44 +01:00
David Allsopp 67c011b883
Revert "AppVeyor speed-ups" 2020-04-20 09:55:54 +01:00
David Allsopp eaa2a01eeb Use configure-caches on AppVeyor 2020-04-17 10:16:03 +01:00
David Allsopp 094447b8fe Run AppVeyor with -j for branches 2020-04-17 09:35:16 +01:00
David Allsopp 1850f55c58 Display AppVeyor environment 2020-04-17 09:28:05 +01:00
David Allsopp afe92bb4f3 Introduce $MAKE to AppVeyor script 2020-04-17 08:58:44 +01:00
David Allsopp f568f858f4 Update release-checklist 2019-10-15 12:04:04 +01:00
David Allsopp 13786d7d12 Ensure make distclean works on an unconfigured tree 2019-10-15 11:46:36 +01:00
David Allsopp 91913bc505 autogen -> make configure 2018-12-04 10:29:02 +00:00
David Allsopp d4a566573f Allow make to be invoked before configure
This should be improved to give better warnings for when Makefile.config
and Makefile.common are required.
2018-12-04 10:28:36 +00:00
Nicolás Ojeda Bär 57d329e07b
Deprecate -annot (#2141)
* Move driver code from Cmt2annot to Read_cmt
* Move cmt2annot.ml into typing/
* make depend
* Use standard error handling
* Move specific logic to read_cmt
* Do not pass full cmt record as argument
* Better locations
* Emit .annot files produced from cmt data
* Remove direct calls to Stypes
* Deprecate -annot
* Changes
* make depend
* Adapt doc
* make -C tools depend
2020-03-13 12:59:34 +01:00
David Allsopp fd6c0e3a03 Don't built ocamltest on release builds
--enable-ocamltest is paranoidly included in the CI scripts, although
the trees are never pushed with a release VERSION at the tip.
2020-02-13 16:53:07 +00:00
Stephen Dolan d6a3a8c58e
Merge pull request #9277 from dbuenzli/objinfo-c-metadata
Objinfo c metadata
2020-02-04 15:53:37 +00:00
Daniel Bünzli 47b9410b33 objinfo: print cm[x]a extra C object, options and dlls in the cli order.
Follow up to #4949. Closes #9276.
2020-01-31 15:12:47 +01:00
Florian Angeletti 5302b09764
ci: check the prefixing policy for runtime symbols (#9260)
* ci: check runtime symbol policy on travis and Appveyor
* tune check-symbol-names:
** ignore all local symbol
** ignore Caml_ prefix
** ignore x86: pic-related symbols
** windows: ignore debugging, unicode and wmain symbols
2020-01-29 15:30:15 +01:00
Sébastien Hinderer a831ba1adc objinfo_hellper fix
This commit modifies objinfo_helper so that the caml_plugin_header
symbol is also looked up in the static symbol table, if it is
not found in the dynamic one.

This is useful e.g. on Windows where the symbol can not be found
without this commit.

It is also necessary to look for the _-prefixed version of the symbol.
2019-12-17 10:10:14 +01:00
Sébastien Hinderer 6953721e5d objinfo_helper: introduce an error function 2019-12-17 10:08:55 +01:00
Gabriel Scherer e3ae18a4e5 (verbosely) document the release-time manual curation process 2019-12-07 17:07:02 +01:00
Fourchaux 1f9474c63c Fixing typos (#9162) 2019-12-04 19:38:02 +00:00
Gabriel Scherer f572295def
Merge pull request #463 from gasche/robust-ocamlobjinfo
objinfo: tell when the object file comes from a different OCaml version
2019-12-03 10:36:13 +01:00
Gabriel Scherer 443a9de638 [minor] objinfo: use Fun.protect instead of Misc.try_finally 2019-12-03 00:08:30 +01:00
Gabriel Scherer 314154ad69 objinfo: tell when the object file comes from a different OCaml version
When passed an object file that comes from a different OCaml version,
objinfo will currently just detect that the magic number is not what
it expects, and claim it is not a valid file. This is irritating.

The error message output by objinfo now looks like this:

    File /home/gasche/.opam/4.08.0/lib/astring/astring.cmi
    Wrong magic number:
    this tool only supports object files produced by compiler version
    	4.11.0+dev0-2019-10-18
    This seems to be a compiled interface file (cmi) for an older version of OCaml.
2019-12-03 00:08:30 +01:00
Sébastien Hinderer 69316099b0 Fix BFD support on OpenBSD 2019-11-28 16:20:03 +01:00
Florian Angeletti b768c0be59 Highlighting in the manual
* Replace caml-sl with the standard listings package
and ulem package
* update caml_tex to output nicer latex code
* simplify escaping in caml_tex
2019-11-28 11:45:08 +01:00
Gabriel Scherer 05f15cf215
Merge pull request #8820 from Drup/stringquot
Quoted extensions
2019-11-25 21:26:53 +01:00
Drup 9c8b63f4ce Annotated Asttypes.constant's string with content location. 2019-11-13 16:08:40 +01:00
Gabriel Scherer 4f37f9ee2b README: new badges for 4.10 and 4.09
(no change entry needed)
2019-11-09 11:08:51 +01:00
Gabriel Scherer 312253ce82 split patterns into "value patterns" and "computation patterns"
Value patterns match on a value (the result of computation), while
computation patterns handle the effects (hint hint) of
a computation. The only forms of computation patterns in OCaml today
are value patterns and exception patterns (exception p).

The sub-pattern `p` of the `lazy p` construction should be
a computation pattern, rather than a value pattern. This pull-request
does not make this change.

Most of the changes in this PR are boilerplate -- it really is a lot
of work now to add a new syntactic category to the typed-tree
syntax. This boilerplate is fairly automatic and should be easy to
review.

There is a subtle part to the patch, though: the implementation of the
pattern type-checking. It now has to reconstruct the value/computation
distinction (absent from the parse-tree), and return values from two
different types. Instead of splitting the type-checker in several
functions (which risked code duplications), I choose to use a GADT to
have the same [type_pat] function return two different types depending
on the caller. This is the least invasive way to adapt this part of
the codebase, whose inherent complexity is so large (unfortunately)
that adding a GADT to the mix barely makes a difference.
2019-10-31 13:29:16 +01:00
Florian Angeletti 7a9e887eda release-checklist: github branch protection 2019-10-23 16:59:59 +02:00
Florian Angeletti ea55b8b590 release-checklist: more info for branching 2019-10-22 18:15:59 +02:00
Florian Angeletti 5c53a18390 release-checklist: inria ci 2019-10-21 16:37:20 +02:00
Xavier Leroy 7b3a147cee extra-checks: update to clang 9
Also, disable man page generation on the sanitized runs to save a bit of time.
2019-10-20 19:30:03 +02:00
Jacques-Henri Jourdan 5a53560e7d Fix address sanitizer check on INRIA CI (#9053)
Since the new stack overflow detection system (#8670), ASAN was confused.
We fix the issue by telling ASAN to not use a sigaltstack, and by disabling
ASAN on functions used by the stack overflow handler.
2019-10-19 11:39:30 +02:00
Thomas Refis 8e928caea7
a better representation for modules with no name (#8908) 2019-10-09 14:15:37 +01:00
David Allsopp 4f09104d88 Allow by-host worktree-sharable configure caches
The Git configuration value ocaml.configure-cache can be used to specify
a directory to keep autoconf cache files in, relative to the worktree
root (so `git config ocaml.configure-cache .` enables the feature, and
`git config --global ocaml.configure-cache ..` enables it for all
worktrees, assuming they're at the same level).

autoconf's --cache-file option speeds up future runs of configure by
caching the results of previous tests. The cache is invalidated if any
environment variables differ (e.g. LDFLAGS) or if the build-host-target
triplet differs. This is a nuisance on Windows, where configure is both
very slow and it's also common to build with multiple different --host
values.

This PR allows a tree to be quickly reconfigured from one Windows port
to another.
2019-10-05 14:50:57 +01:00
David Allsopp 345fd4c3f9 Allow Git config options to be passed to configure
The Git configuration value ocaml.configure is now passed to the
configure script's arguments before $@ if (and only if) OCaml is being
configured from a Git clone.

This allows, for example:

- Developer-specific preferences (e.g. `--disable-ocamldoc` or
  `--disable-debug-runtime`)
- Automatic use of autoconf cach files (-C option)

It is implemented by inserting a test at the top of `configure`, which
is bypassed if `.git` doesn't exist.
2019-10-05 14:50:35 +01:00
David Allsopp fb6f58ea69
Merge pull request #8951 from shindere/make-default-target
Let make's default target build the compiler
2019-10-04 14:23:27 +01:00
Guillaume Munch-Maccagnoni b304042b29 Fix missing Caml_state (#8940)
* Fix free identifiers in spacetime

* Fix free identifiers in tools/gdb-macros

* [minor] Fix Caml_state fields in comments, and other comment updates

* Changes
2019-10-03 16:27:32 +02:00
Gabriel Scherer 5fc29e52a4
Merge pull request #8992 from Octachron/shared_args
Share argument implementations
2019-10-01 12:08:54 +02:00
Jacques Garrigue 1e895dbaee
Allow compiling ocamldoc with -principal (#8955)
Also solves issue #6922
2019-09-30 21:14:06 +02:00
Sébastien Hinderer 987b0814d7 Let make's default target build the compiler
This commit makes it possible to build the OCaml compiler according to
its configuration by simply runnning make. There is no need to specify
neither world nor world.opt explicitly, although the two targets
remain available.

This commit also introduces (and starts making use of) the
NATIVE_COMPILER build variable whosse value is true when the native
compiler is enabled and false otherwise.
2019-09-30 16:01:29 +02:00
Florian Angeletti a509157eb9 share argument implementation across executable
This commit defines five default argument modules in
Main_args.default. Those modules provide a default implementation
for the argument of ocaml, ocamlnat, ocamlc, ocamlopt, ocamldoc,
ocamlcp, ocamloptp, and expect_test.

Grouping together those implementations allow to share as much as
possible similar implementation across executables. It should make
easier to keep synchronized the various implementation, or reuse
those implementation in alternative drivers.
2019-09-30 15:56:40 +02:00
David Allsopp 705739fa54 Fix failure to install tools links
In --disable-installing-bytecode-programs mode, the .opt version of the
tools is installed, but the symlink for the tool itself is not created.
2019-09-29 13:57:15 +01:00
David Allsopp 55755d82de check-parser-uptodate-or-warn.sh: Improve message if mstat fails 2019-09-26 08:26:08 +02:00
David Allsopp 7b078dedd8 check-parser-uptodate-or-warn.sh: improve shell script 2019-09-26 08:26:02 +02:00
Gabriel Scherer 87e3630d55 Changes entry
fixes #8965
2019-09-26 08:25:17 +02:00
Gabriel Scherer c8c6762d54 check-parser-uptodate-or-warn.sh: do nothing on non-development versions 2019-09-25 15:01:07 +02:00
Gabriel Scherer 3f77dade9f make check-parser-uptodate-or-warn.sh more robust to script failures 2019-09-25 15:01:07 +02:00
Gabriel Scherer 9383912c21 check-parser-uptodate-or-warn.sh: support busybox's stat (#8965) 2019-09-25 15:01:07 +02:00
Gabriel Scherer 776fcc3919 make depend 2019-09-25 11:45:33 +02:00
Nicolás Ojeda Bär 3aff5141fd Add a new -output-complete-exe option (#8872)
This option allows to build self-contained bytecode executable and is aimed to replace `-custom`. The main difference between the two is that executables produced by `-output-compete-exe` can be stripped.
2019-09-25 08:07:31 +01:00
Gabriel Scherer d70d6df648
Merge pull request #8967 from gasche/cmt2annot-proper-iterator
tools/cmt2annot: use proper Tast_iter instead of Tast_mapper
2019-09-24 16:41:26 +02:00
Sébastien Hinderer a74def9144 Inria CI: request BFD support on MacOS X 2019-09-23 14:49:03 +02:00
Sébastien Hinderer e3b33a5750 Build system: introduce the BFD_LDFLAGS variable
This variable is not really used yet but will be used soon.
2019-09-23 14:45:54 +02:00
Sébastien Hinderer 762fe0abaa Build system: rename the LIBBFD_INCLUDE variable to BFD_CPPFLAGS 2019-09-23 14:45:54 +02:00
Sébastien Hinderer d718cd9db3 Build system: rename the LIBBFD_LINK variable to BFD_LDFLAGS 2019-09-23 14:45:54 +02:00
Gabriel Scherer 36c461d8b9 tools/cmt2annot: use proper Tast_iter instead of Tast_mapper 2019-09-23 11:21:50 +02:00
Florian Angeletti c56ed411f8 Merge pull request #8827 from gasche/revert-numeric-operators-hint
Revert #2307 ( Hint on type error on numeric operators )

(cherry picked from commit 1fadc49604a791a7e9fa41c90fedad9304267f19)
2019-09-19 15:00:24 +02:00
Sébastien Hinderer 5ec649f0cb
Build system: share rules to compile C files (#8930)
This commit deduplicates some of the Makefile rules used to compile C files.

Rather than having one such rule per Makefile for each directory
containing C files, the relevant rules are moved to Makefile.common.in.
2019-09-11 09:16:15 +02:00
Valentin Gatien-Baron f40011556c in -dtimings output, show time spent in C linker clearly 2019-08-26 07:58:28 +02:00
Sébastien Hinderer 8c1107d910 tools/ci/inria/extra-checks: use git clean rather than make distclean 2019-08-06 14:47:07 +02:00
Damien Doligez 50727df482 release-checklist: be more explicit about how to update the year in the manual 2019-08-01 11:36:33 +02:00
David Allsopp d689f33e04
Merge pull request #8845 from dra27/old-school
Test make world on Inria CI
2019-07-31 11:58:36 +01:00
David Allsopp 37c524b447 Move the quicker tests to the top of the script 2019-07-31 10:30:59 +01:00
Florian Angeletti 204dd09e8c Update release checklist 2019-07-30 17:50:07 +02:00
David Allsopp fdda9d2e3b Test make world on Inria CI 2019-07-30 11:09:57 +01:00
David Allsopp 91c3ca831c Test all ocamldoc generators in the CI
Build all the formats of the standard library documentation.
2019-07-27 23:11:59 +01:00
Gabriel Scherer 5cba149ebf minor release-checklist update 2019-07-24 14:49:44 +02:00
David Allsopp 32df16fd7f Test non-shared platform and minimal build 2019-07-18 20:27:39 +01:00
Florian Angeletti 9102f6a2f7 manual: test case-insensitive collisions 2019-07-05 09:34:02 +02:00
Gabriel Scherer df631380ba actually remove tools/addlabels.ml, leftover from #8663 2019-06-19 16:46:01 +02:00
zapashcanon 6375461686 Improve shell scripts (#1690) 2019-06-19 16:15:02 +02:00
Gabriel Scherer 010d94cae2
Merge pull request #2309 from TheLortex/runtime-variant-path
Add -noruntime option
2019-06-19 16:12:28 +02:00
Damien Doligez 0712982758 Fix the instructions for uploading the manual to the Web server.
Closes: #8740
2019-06-19 15:57:59 +02:00
Jacques-Henri Jourdan 1ea07c881b Fix Thread sanitizer after GPR#8691.
GPR#8691 refactored the signal/async callback system, and introduced
new data races to `caml_something_to_do` and friends. These data races
morally already existed and are "benign", in the sense that they can
only cause more checks for async callbacks.

The corresponding functions are now marked with a special attribute
for whitelisting them. We do no longer use -fsanitize-blacklist, which
seemed to fail preventing warnings (???).
2019-06-18 13:32:46 +02:00
Damien Doligez 922cbee090 more fixes for release-checklist 2019-06-14 14:51:24 +02:00
Lucas Pluvinage e61263c0ac Introduce the -without-runtime option. 2019-05-06 14:35:57 +02:00
Xavier Leroy 69e0f1c314 Use "make --warn-undefined-variables" for CI at Inria 2019-05-02 19:43:17 +02:00
David Allsopp 6e9d153c5d Update release-checklist 2019-04-30 14:10:15 +01:00
David Allsopp 6f63c55f18 Fix error message displayed on Travis push 2019-04-30 08:57:56 +01:00
David Allsopp 3bb1886b65 Check all necessary paths for configure 2019-04-30 08:52:27 +01:00
Sébastien Hinderer b8823973d1 Improve the main script of Inria's CI
This contains the following improvements:

- Stop calling make distclean at the beginning of the script
- Make the call to git distclean quiet
- Add the --warn-undefined-variables explicitly to those calls to
  make for whihc this is relevant
2019-05-17 13:58:17 +02:00
Sébastien Hinderer 3e52e4e6a8 Remove the scrapelabels and addlabels tools 2019-05-07 11:49:44 +02:00
Sébastien Hinderer 6f2d142df2 Remove the ocaml299to3 tool 2019-05-07 11:49:44 +02:00
Sébastien Hinderer a201ade7f3 Build system: make ocamllex silent by default (#8664)
This commit makes e.g. make -s world.opt completely
silent when everything works, in order to increase the visibility of
any unexpected message occurring during the build.
This will be useful for instance during CI, in particular it should
make it easier to catch undefined build variables.

The implementation is straightforward. The OCAMLLEX_FLAGS variable is
defined in Makefile.common.in and then used consistently by all
lexing recipes.

In addition, in tools/Makefile, the two rules producing the lexers
from cvt_emit.mll and make_opcodes.mll have been replaced by a
pattern-rule and the useless .SUFFIXES target has been removed.
2019-05-07 11:32:05 +02:00
Damien Doligez f67b6eba6c release-checklist: remove section on updating Mantis 2019-04-18 15:22:37 +02:00
Gabriel Scherer 3b5cda4d27 Merge pull request #8604 from gretay-js/pr2207
Add opam files to allow pinning

(cherry picked from commit e89287f056b3641af214f8d71717c6fa81de531b)
(version changed 4.08 => 4.09)
2019-04-12 14:28:47 +02:00
David Allsopp 7156b9cd15 Verify that configure.ac generates configure 2019-04-02 16:35:36 +01:00
Mark Shinwell 72ea849d2a
Move some middle-end files around (#2281)
* Various file moves in the middle end: this is the first stage of improving separation between the middle end and backend.
* Creation of file_formats/ directory (with associated file moves) to hold the definitions of compilation artifact formats.
* Creation of lambda/ directory (with associated file moves) to hold Lambda language definition files, transformation passes and construction passes from Typedtree.
* Disable (hopefully temporarily) dynlink, debugger and ocamldoc for the dune build.
2019-04-01 17:18:47 +01:00
David Allsopp ed2ec2537f Ensure that files marked executable are #! scripts 2019-03-27 10:32:40 +00:00
David Allsopp 3f91e8750b Skip files in .gitignore in check-typo 2019-03-27 10:32:40 +00:00
David Allsopp db215dda8f Quote directories in pre-commit hook
Belt-and-braces, since we don't use spaces.
2019-03-27 10:32:40 +00:00
David Allsopp ff26bf7a72 Ensure awk supports interval expressions
Travis already added the required option for old versions of GNU awk,
but this was still a problem on current Ubuntu systems if gawk is not
installed - mawk (the default) does not support them.
2019-03-27 10:17:41 +00:00
Anton Kochkov 4405395e9f Fix the bug reporting URL in release-checklist 2019-03-25 21:23:11 +08:00
Damien Doligez 46f901bb94 Small fixes to release-checklist 2019-03-22 15:13:41 +01:00
Stephen Dolan f495bfb7cb
Merge pull request #8514 from stedolan/boot-ocamlc-opt
Use boot/ocamlc.opt for building, if available.
2019-03-22 12:22:14 +00:00
Stephen Dolan 46c427f519 Use boot/ocamlc.opt for building, if available. 2019-03-20 10:31:46 +00:00
Mark Shinwell dbede46c2e
Improve the packing mechanism used to build Dynlink (#2268) 2019-03-19 10:26:35 +00:00
Jérémie Dimino c413136fa3 Delete otherlib/{graph,win32graph} (#2318)
The Graphics library is now distributed as a separate package.
The sources are at https://github.com/ocaml/graphics .

Signed-off-by: Jeremie Dimino <jeremie@dimino.org>
2019-03-18 15:05:57 +01:00
Xavier Leroy c5efbb42a4
MPR#3249: ocamlmklib does not support .cmxa files as arguments (#8512)
That's because ocamlopt -a doesn't support .cmxa files as arguments.
It is better to reject those files in ocamlmklib than later.
The manual never said that ocamlmklib accepts .cmxa files.

Closes: #3249
2019-03-18 09:11:36 +01:00
Mark Shinwell 2cc1ea26b9 Remove gprof support (#2314)
This commit removes support for gprof-based profiling (the -p option to ocamlopt).  It follows a discussion on the core developers' list, which indicated that removing gprof support was a reasonable thing to do. The rationale is that there are better easy-to-use profilers out there now, such as perf for Linux and Instruments on macOS; and the gprof support has always been patchy across targets. We save a whole build of the runtime and simplify some other parts of the codebase by removing it.
2019-03-16 19:56:53 +01:00
Nicolás Ojeda Bär bd69c678c2 Add CSV file with Mantis=>GitHub renumbering information 2019-03-15 00:01:48 +01:00
Mark Shinwell 0bd539ae24 GPR#2082: New option -no-insn-sched 2019-03-13 15:03:49 +00:00
David Allsopp 6e84987715 Restore -vmthreads flag as an error (#2312)
This GPR restores -vmthread with an adapted version of the deprecation message as an error message and also keeps the use_vmthreads part of ppx contexts.

* Partially revert #2289
* Convert -vmthread to an error
* Neuter use_vmthreads in ppx context
* Remove Clflags.use_vmthreads
2019-03-13 10:46:30 +01:00
Sébastien Hinderer 2ac104cd3c Update Inria's bootstrap CI job
This commit adapts Inria's bootstrap CI job to take into account the
removal of the threads library. More precisely, it updates the patch
that removes the sinh primitive from the runtime to not patch
otherlibs/threads/stdlib.ml any longer since this file has been removed
from the repository.
2019-03-12 03:33:26 +01:00
Sébastien Hinderer 32dc5b8290 Fix typo in CI script 2019-03-12 03:28:20 +01:00
Jérémie Dimino 705054b346 Delete the vmthreads library (#2289)
* Delete the deprecated vmthreads library

It was deprecated in 4.08.

* Remove the byte/native argument of init_path

It is no longer necessary.

* Error out when passing --{enable,disable}-vmthreads to ./configure

Signed-off-by: Jeremie Dimino <jeremie@dimino.org>
2019-03-11 19:38:16 +01:00
Jules Aguillon a241675676 Fix tools/caml-tex printing of sub message locations
List printer fields explicitly to avoid the same problem from happening again
2019-03-11 13:27:48 +01:00
David Allsopp 1befa5bb3e Ensure failed build terminates AppVeyor run
The mingw32 build log is post-processed for AppVeyor, but this was done
without setting -o pipefail.
2019-03-05 17:49:28 +00:00
Xavier Leroy 15cb5caf8a Use "git clean" to start CI from a clean state
Otherwise leftover files from a previous CI build can cause problems.
2019-03-02 19:31:28 +01:00
Xavier Leroy 176cb2dad1 Allow race condition in caml_leave_blocking_section
Since commit 08ed1e8 (GPR#2211) caml_leave_blocking_section writes
to caml_signals_are_pending, a variable that has known race conditions.
2019-03-02 18:29:37 +01:00
Damien Doligez 66117d2cc4 small fixes to release-checklist 2019-03-01 12:00:27 +01:00
Sébastien Hinderer 652cc148a9 Disable rebase on Cygwin 64 in Inria's CI
We do not perform the rebase which is not necessary when building
shared libraries.
2019-03-01 09:26:33 +01:00
Fourchaux 1946594bd7 Fixing typos in various files (#2246)
Note: Typos found with https://github.com/codespell-project/codespell

Here is the (semi-manual) command used to get (and correct) the typos:

$ codespell -i 3 -w --skip=".png,.gif,./ocaml/boot,./ocaml/.git,./ocaml/manual/styles,./ocaml/manual/manual/htmlman" -L minimise,instal,contructor,"o'caml",cristal,pres,clos,cmo,uint,iff,te,objext,nto,nd,mut,upto,larg,exten,leage,mthod,delte,tim,atleast,langage,hten,iwth,mke,contant,succint,methids,eles,valu,clas,modul,que,classe,missings,froms,defaut,correspondance,differents,configury,reachs,cas,approche,normale,dur,millon,amin,oje,transfert
2019-02-13 14:04:56 +01:00
Sébastien Hinderer 3a2ae8c462 Revert "temporary patch to work around a problem with BSD/ocamltest/fork"
This reverts commit 309bad6197.

The problem that made this commit necessary has since bben fixed, in
commit 6015d60fc6.
2019-02-11 16:38:58 +01:00
Damien Doligez 2b2670e72a small fixes to release checklist 2019-02-08 16:21:55 +01:00
Damien Doligez 309bad6197 temporary patch to work around a problem with BSD/ocamltest/fork 2019-02-05 16:07:11 +01:00
Florian Angeletti f15ee3be5d
Merge pull request #1941 from sliquister/ocamlcp-dedup3
reduce boilerplate in compiler command line parsing
2019-02-04 17:03:27 +01:00
Jeremie Dimino 7e0862a212 Refactor load path management and initial environment
- Add a Load_path module which caches files lookup

- Instead of falling back to the external environment, allow to
  declare in the environment that a module comes from the external
  world. This allows persistent structures to shadows non-persistent
  ones
2019-01-30 16:36:38 +00:00
Valentin Gatien-Baron 427e5a5c59 simplify the ocamlc{,opt}p code forwarding options to ocaml{c,opt} 2019-01-22 20:38:15 -05:00
David Allsopp 832db132d9 Make unix, vmthreads and str optional libraries
--disable-unix-lib, --disable-vmthreads and --disable-str-lib added to
prevent building these three libraries.

ocamldoc, the debugger and caml-tex are automatically disabled if their
prerequisites are not built. Using --enable-debugger and
--enable-ocamldoc will result in errors if these tools cannot be built.
2019-01-08 17:27:42 +01:00
Sébastien Hinderer 8550f71441 Build system: use $(ROOTDIR) rather than hardcoded paths to access ocamlc 2019-01-03 17:02:25 +01:00
Sébastien Hinderer d258bb78ac Build system: use ocamlc -depend rather than ocamldep 2019-01-03 16:43:23 +01:00
Florian Angeletti ebdad4fb74
Merge pull request #2210 from Octachron/camltex_ellipsis_test
test suite: caml-tex, test and tweaks for ellipses
2018-12-21 18:51:05 +01:00
Sébastien Hinderer cc3f70b705 Use autoconf to generate the compiler's configuration script 2018-12-21 16:02:47 +01:00
Florian Angeletti 4694786b75 caml-tex: test and tweak for ellipses 2018-12-21 12:41:40 +01:00
Sébastien Hinderer 0723ac158e Inria CI: add -no-shared-libs to script
This option was specified in the Cygwin64 slave's configuration, but this
makes it impossible to use different values on differnet branches,
which is needed when switching to autoconf.
2018-12-21 11:01:14 +01:00
David Allsopp 2b41b3f0a5 Update the pre-commit-githook for typo.prune 2018-12-20 11:46:34 +01:00
David Allsopp a18647c582 Update comments in tools/check-typo
ocaml-typo=prune => typo.prune
2018-12-20 11:46:34 +01:00
David Allsopp 1b5278a829 Update travis-ci.sh to cope with typo.prune 2018-12-20 11:46:34 +01:00
Gabriel Scherer 295f71cb96 make alldepend (with new one-dep-per-file printing) 2018-12-12 09:38:49 +01:00
Gabriel Scherer 46ef054330 Makefiles: restructure CAMLDEP usage to easily add flags
This change should be a refactoring no-op.

Before, a DEPFLAGS variable existed in some makefiles to contain
include directories to be passed to ocamldep invocations, but no
support for easily adding command-line flags to ocamldep was available
(invocations would systematically use -slash, which was duplicated
across callsites).

With this PR, a new DEPINCLUDES variable contains the include
directories, and DEPFLAGS is repurposed to contain other command-line
flags for the tool -- currently "slash".
2018-12-12 09:30:55 +01:00
Gabriel Scherer b98d3e738f add a variant of check-typo to compare against a git reference
./tools/check-typo-since trunk
./tools/check-typo-since HEAD~10

In most cases, this should be much faster than running check-typo on
the whole directory.
2018-12-09 13:31:26 +00:00
Gabriel Scherer bd29de9efe check-typo: make --check-prune faster
this comment special-cases the prune-detection logic to use the `git
check-attr` layer directly, instead of using the convenience function
`get_attrs ..` which parses its output.

On my machine, calling --check-prune on the testsuite files goes from
17s to 12s when this patch is applied.
2018-12-09 13:31:26 +00:00
Gabriel Scherer bf72878ee3 .gitattributes: prune directories recursively
Before this change, check-typo would run on manual/Makefile for
example, while this file lives within a pruned directory so it
ought to be ignored by the tool.

Note: the check-typo code seems to assume that the only pruned things
are directory, it prints "pruned directory ..." when something is
pruned. I haven't changed this part of the logic; but note that normal
./check-typo invocation will only check pruning for directories.
2018-12-09 13:31:26 +00:00
David Allsopp 89ad24e5cc Update Inria CI scripts to recognise cygwin64
OCAML_ARCH is now cygwin on the Cygwin32 worker and cygwin64 on the
Cygwin64 worker. The rebase "trick" is now only used on the Cygwin64
worker, where it is required.
2018-11-28 19:45:15 +00:00
Leo White 403003cad5 Add support for "let" operators 2018-11-27 13:30:55 +00:00