Use the ability to pass flags to the C compiler at configure time
to simplify this CI script.
Looking at the diff, it may seem that some flags like -fwrapv,
-fno-strict-aliasing, -Wall and -Werror got lost by this commit.
It is actually not the case. In its previous version, this script was
overriding the flags as defined by the compiler's build system, so it
had to provide a rather exhaustive list of flags. Now one only needs to
add the flags specific to the build one wishes to do. The flags mentionned above*
are provided by the compiler's build system so they do not need to be mentionned
here any longer.
With this commit, it becomes possible to provide C compiler and preprocessor
flags to use in addition to those defined by the build system.
As required by the GNU coding standards, the flags can be provided
either at configure or at make invocation.
The provided CFLAGS and CPPFLAGS will also be taken into account
when C code is compiled by ocamlc/ocamlopt.
This commit removes the explicit reference to CFLAGS in the
configuration for the xlc compiler, since it is not necessary any longer.
The AFL code generator alters the generated output and the
expect tests fail. This test is already restricted to 64-bit
only architectures for similar reasons (the output locations
change).
Also updates the expected outputs to account for the extra line
in the test case now.
Fixes#9822
The C global variable caml_fl_merge and the C function
caml_spacetime_my_profinfo (bytecode version) were declared and
defined with different types. This is undefined behavior and
can cause link-time errors with link-time optimization (LTO).
Closes: #9825
On iOS / macOS ARM64, libunwind seems unable to unwind anything, not
just OCaml function calls, but even C function calls. Maybe this is
related to the observation that the C compiler doesn't produce DWARF
unwinding info by default.
The DWARF unwinding info produced by ocamlopt seems correct, given that
lldb prints correct stack backtraces for this "unwind" example.
* Fix#9759: Typing without -principal is broken in 4.11 and trunk
* compile stdlib in -principal mode
* never modify generic part of ty_expected_explained
* use generic_instance where possible
* add comment for -no-principal in stdlib__oo.cmi
To preserve behaviour, explicit polls are added:
- in caml_raise, to raise the right exception when as system
call is interrupted by a signal.
- in sigprocmask, to ensure that signals are handled as soon
as they are unmasked.