As I learned the hard way, it is essentially impossible to get
a satisfying behavior in presence of a mix of updates, concatenations
and counts. The best thing to do is thus to not change anything
(a good way to preserve compatibility), and only fix the
Stream.of_string function to assume nothing of the count passed to the
[from] function.
I also modified the mli documentation of [Stream.from] to warn other
users of this potential pitfall.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13915 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
(modified patch from Adrien Nader!)
Add also new comments for the new INSTALL flags.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13864 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
(patch by Adrien Nader!)
Compared to the previous version of this patch, this fixes too issues.
First, it updates the makefiles for mingw and msvc to set $host and
$target. I'm not completely sure why that was required since these
variables should have evaluated to empty strings which were only tested
for equality later on. Still, it's needed and it avoids an asymetry
between the regular ./configure-based builds and the ones using pre-made
Makefiles.
Second, it update the ocamlbuild config to also store $host and $target.
I had been building the cross-compilers with OCAMLBUILD_NOBOOT (which is
rather new) and updating that config wasn't needed. However it is
required for the "regular" builds.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13862 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
The OpenBSD Jenkins slave started failing because of the use of
gnu-style conditionals.
There's unfortunately no way that I know of to get a conditional syntax
that works both with gmake and mk.
Fortunately, the conditional wasn't needed at all since the value was
already computed in the configure step.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13861 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
* -short-paths is activated via the "short_paths" tag
* -principal is activated via the "principal" tag
* -strict_sequence now has a "strict_sequence" tag to alias the
"strict-sequence" tag that was already there, to follow the
convention of command-line options having dashes replaced by
underscores. It's easy to mess this up since incorrect tags
are silently ignored by ocamlbuild.
Add test cases that check if principal and strict-sequence have
been passed, and tweak the test suite slightly to make it easier
to match on failing_msg output.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13859 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
(Patch by Adrien Nader!)
I tried to use "hasgot" to test it but proved too difficult since you
must #include <winsock2.h> to make link succeed (windows magic) which
then makes gcc complain about the prototype being wrong.
Since windows already needs a special case in order to add -lws2_32 and
since we know for sure it will be available, skip the hasgot test and
check $target directly.
configure: add a special case to test for BSD sockets for mingw.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13855 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
(patch by Adrien Nader!)
While at it also re-add two spaces that were eaten.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13851 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
(patch by Adrien Nader!)
The test tried to do something like:
case "$foo,$bar" in
*,*) echo 1 ;;
*) echo "compiler not working" ;;
esac
However the second case cannot match because of the first one.
Instead, check the return code of the command.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13844 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
(Patch by Adrien Nader!)
This makes messages to the user more consistent.
Behaviours:
inf(): writes its arguments to stderr
wrn(): writes "[WARNING]" to stderr and then its arguments to stderr
err(): writes "[ERROR!]" to stderr, then its arguments to stderr, and
calls "exit 2"
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13841 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02