Commit Graph

337 Commits (6ee0712423af746a4b9e9f6789ff16a970a89486)

Author SHA1 Message Date
Gabriel Scherer 514f15fc96 Translate french pythic comment
(user 'octachron')

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16478 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-10-09 20:41:44 +00:00
Gabriel Scherer 5882fdea22 General translation of french comments
(user 'octachron')

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16474 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-10-09 20:41:38 +00:00
Gabriel Scherer 9a533a50cd make alldepend
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16352 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-08-15 15:57:59 +00:00
Gabriel Scherer cb3bb152ab add option handling for colors in compiler, OCAMLPARAM and ocamlbuild
(Simon Cruanes and Gabriel Scherer)

Use one of
  -color auto
  -color always
  -color never

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16348 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-08-15 15:57:51 +00:00
Gabriel Scherer 365cd572d7 ocamlbuild: add examples to the documentation of rule definitions
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16344 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-08-15 10:26:32 +00:00
Gabriel Scherer 36d53043b2 ocamlbuild: + Log.is_logging to skip allocation in hot path
(user 'ygrek')

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16305 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-08-02 13:05:50 +00:00
Gabriel Scherer c2704c259b ocamlbuild: Log: do not wrap format unless it will be used
(user 'ygrek')

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16304 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-08-02 13:05:48 +00:00
Gabriel Scherer 7569a5f7a0 ocamlbuild: specialize Hashtbl for Resource.Cache
(user 'ygrek')

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16303 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-08-02 13:05:47 +00:00
Xavier Leroy 688d5a5915 Changed OCamlbuild's license to LGPL with static linking exception.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16294 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-07-28 13:18:34 +00:00
Gabriel Scherer d939804269 GPR#208: add "asm" ocamlbuild tag to enable -S
(Patch by ygrek)

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16252 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-07-25 20:44:05 +00:00
Damien Doligez 4b83d53fbc update .depend and bootstrap compilers after 4.02 merge
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16218 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-07-17 18:34:07 +00:00
Damien Doligez 860c670848 merge branch 4.02 from 4.02.1 (rev 15540) to a few fixes after 4.02.2 (rev 16205)
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16214 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-07-17 14:31:05 +00:00
Leo White 5c55e4cc08 Attach documentation comments to Parsetree
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16189 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-06-28 13:11:50 +00:00
Gabriel Scherer 65bb607cd7 PR#6733: ocamlbuild .{byte,native}.so targets and runtime_variant(X) flag
(Peter Zotov)

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16105 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-05-10 05:51:25 +00:00
Gabriel Scherer 3c32a0c711 GPR#179: fix -jN race condition in ocamlbuild's Makefile
(Frédéric Bour)

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16061 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-05-01 17:17:36 +00:00
Gabriel Scherer df05508cfc PR#6793: ocamlbuild passes nonsensical "-ocamlc ..." commands to menhir
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15993 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-04-11 17:40:27 +00:00
Gabriel Scherer a0ddc6ff30 PR#6774: new menhir-specific flags "only_tokens" and "external_tokens(Foo)"
(François Pottier)

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15991 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-04-11 17:40:23 +00:00
Gabriel Scherer 0db2316653 PR#6794: pass package-specific include flags when building C files
(Jérémie Dimino, request by Peter Zotov)

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15883 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-03-08 09:03:24 +00:00
Gabriel Scherer 7ca29ef3f7 PR#5887: move the byterun/*.h headers to byterun/caml/*.h to avoid header name clashes
(Jérôme Vouillon and Adrien Nader and Peter Zotov)


git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15757 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-12-27 14:41:49 +00:00
Gabriel Scherer 1d8e590c54 PR#6475: accept -o in ocamlc when compiling C files
(Vincent Laporte, Peter Zotov)

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15734 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-12-21 12:18:07 +00:00
Gabriel Scherer f15f4f3ed8 PR6695: Make sure the compiler only uses ASCII string functions.
This should cover all places involving filenames in the compiler.
There are a few more paths still using Latin-1 in other ways,
e.g. in ocamldoc.

From: Peter Zotov <whitequark@whitequark.org>

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15727 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-12-21 11:46:14 +00:00
Gabriel Scherer 35f02a6db0 PR#6625: pass -linkpkg to files built with -output-obj.
(Peter Zotov)

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15719 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-12-21 10:39:22 +00:00
Gabriel Scherer f517bd2947 ocamlbuild: use sets rather than list for cycle-checking
I'm worried the previous algorithmically-naive implementation may
behave badly on larger-scale projects. We still keep a list around to
return results in the exact same order as previously.

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15694 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-12-20 22:21:55 +00:00
Gabriel Scherer 4ace563b9f ocamlbuild: refine circular dependency errors
When reporting a circular dependency, refine the printed filenames to
those that are really part of the cycle -- instead of those that
happened to be traversed during the DFS that found a cycle. This gives
much more readable error messages.

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15693 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-12-20 22:21:54 +00:00
Gabriel Scherer d7bac4efb2 PR#6720: pass -g to C compilers when tag 'debug' is set
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15680 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-12-17 10:36:06 +00:00
Gabriel Scherer 8be30254e2 ocamlbuild: explicit 'linkpkg' and 'dontlink(foo)' flags
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15670 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-12-14 20:58:10 +00:00
Gabriel Scherer 73590cc155 PR6712: Ignore (-traverse) common VCS directories in ocamlbuild.
From: Peter Zotov <whitequark@whitequark.org>

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15668 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-12-13 22:36:03 +00:00
Gabriel Scherer ae48bbb17b PR#6640: add 'precious' as a builtin-useful tag
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15606 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-11-23 09:54:43 +00:00
Gabriel Scherer b14de1e93a ocamlbuild: add an explicit "infer" tag for menhir (Patch by Hugo Heuzard)
This allows to prevent the --infer option from being passed to Menhir
by using the negative tag -infer.

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15598 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-11-18 09:35:41 +00:00
Gabriel Scherer a699625e78 fix for ocamlbuild on cygwin cannot find ocamlfind
ocamlbuild should append .exe extension to filename when looking for
executables and Sys.cygiwn is set (not only Sys.win32).

From: algoriddle <szilvasy@gmail.com>

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15577 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-11-16 17:37:25 +00:00
Damien Doligez 031cffd155 merge branch 4.02 from release 4.02.0 to release 4.02.1
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15558 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-10-15 13:34:58 +00:00
Gabriel Scherer f3ebb28d90 tell ocamlbuild about ocamldep's support of -open
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15469 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-10-03 20:31:36 +00:00
Damien Doligez a18bc7950b merge changes of version/4.02 from r15121 to r15155
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15168 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-08-29 17:14:00 +00:00
Damien Doligez cbfe627f92 merge changes from branch 4.02 from branching (rev 14852) to 4.02.0+rc1 (rev 15121)
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15125 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-08-22 13:45:02 +00:00
Gabriel Scherer 0ca6694dc5 ocamlbuild: add no_alias_deps tag (patch by Daniel Bünzli)
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15055 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-08-06 15:01:25 +00:00
Gabriel Scherer 438a6fe77e PR#6495: also add unsafe_string tag to ocamlbuild
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15054 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-08-06 15:01:23 +00:00
Gabriel Scherer c2c68e3788 PR#6495: add a safe_string tag to ocamlbuild (patch by Anil Madhavapeddy)
It kicks in for interface inference and compiler invocations.
safe_string does also alter the output of inferred types if
short_paths is used (since "bytes" is shorter than "string"),
but this requires a change to the ocamldoc driver and isn't
addressed in this PR.

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15053 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-08-06 15:01:21 +00:00
Gabriel Scherer 483d773c44 PR#6502: spurious warning on "use_menhir" tag
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15044 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-08-06 11:15:45 +00:00
Gabriel Scherer e331dacf29 PR#6482: ocamlbuild fails when _tags file in unhygienic directory
ocamlbuild lazily traverses directory to build a vision of the
filesystem tree in which the build happens. During that traversals, it
parses any configuration file `_tags` it encouters. PR#6482 was caused
by the fact that the configuration-parsing code used the relative path
of the _tags file, which was correct at the time of traversal, but
stale at the time the lazy thunk was in fact forced (a Sys.chdir had
occured in between).

The first fix is to detect when relative paths become stale, and use
the correct absolute path in that situation.

The reason why this lazy thunk was only forced after a Sys.chdir is
that, at hygiene time, only the subtrees that are selected for hygiene
checking are forced. It is an unexpected behavior that non-hygienic
subtrees could remain unforced for so long (in particular, the
semantics of parsing a configuration file only much later in the build
process is more than unclear); this commit also removes this behavior
by always forcing the whole traversed subtree just before hygiene.

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15000 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-07-14 14:44:53 +00:00
Xavier Leroy 3946f47972 Reflecting commit 14958 on version/4.02:
Missing dependencies on the pack, causing parallel make to fail.


git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14959 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-06-05 08:33:24 +00:00
Gabriel Scherer 3fa347743e PR#5547: ocamlbuild reverts to using -no-ocamlfind by default
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14952 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-06-04 20:01:16 +00:00
Gabriel Scherer 34fb0d4345 PR#5371: a partial patch by Edwin Török to fix the FreeBSD failure
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14891 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-05-18 16:08:38 +00:00
Gabriel Scherer 5ca901cfa6 ocamlbuild: only show backtrace in verbose mode
Building foo.cmo in an empty directory (so with in particular no
foo.ml) currently returns the following output:

> Solver failed:
>   Ocamlbuild cannot find or build foo.ml.  A file with such a name
>   would usually be a source file.  I suspect you have given a wrong
>   target name to Ocamlbuild.
> Backtrace:
>   - Failed to build the target foo.cmo
>       - Building foo.cmo:
>           - Failed to build all of these:
>               - Building foo.ml:
>                   - Failed to build all of these:
>                       - Building foo.mly
>                       - Building foo.mll
>               - Building foo.mli:
>                   - Building foo.mly
>               - Building foo.mlpack
>               - Building foo.mli:
>                   - Building foo.mly
> Compilation unsuccessful after building 0 targets (0 cached) in 00:00:00.

While the "Solver failed" part is nice and reasonably easy to
understand, users report that the "Backtrace" part is confusing
(it talks about files they don't know about) -- and it can be so large
that the explanation above is completely hidden.

This patch disables backtrace-printing by default; it is now only
shown when some "-verbose N" (N starting at 1) argument is passed.

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14732 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-05-03 21:21:58 +00:00
Gabriel Scherer db32d6a7ed Ocamlbuild: make log printing code tail-recursive
Patch by Frédéric Bour

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14716 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-05-01 09:28:35 +00:00
Damien Doligez 5b8df637d2 merge branch "safe-string"
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14705 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-04-29 11:56:17 +00:00
Damien Doligez 7303ac34ca fix some of the whitespace problems in the source
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14582 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-04-12 10:17:02 +00:00
Gabriel Scherer 3d98a382f3 refine ocamlbuild/.depend for `make -jN` to work again
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14576 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-04-12 06:56:49 +00:00
Jacques Garrigue f309a7a05c Fix ocamlbuild installation directory
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14564 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-04-09 03:12:53 +00:00
Gabriel Scherer de4f4cf8b3 PR#6358: obey DESTDIR in install targets
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14536 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-04-07 07:06:17 +00:00
Alain Frisch 0c4c54c990 Get rid of ocamlcomp.sh. The next step is to share all those common declarations for calling the compilers from various places.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14521 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-04-02 16:20:38 +00:00