From: Adrien Nader <adrien@notk.org>
To: Christopher Zimmermann <christopher@gmerlin.de>
Cc: caml users <caml-list@inria.fr>
Subject: Re: [Caml-list] use cc instead of gcc as default C compiler?
Date: Wed, 25 Oct 2017 08:52:01 +0200 [thread overview]
Message-ID: <20171025065201.GA24593@notk.org> (raw)
In-Reply-To: <152B8F33-A053-42AA-AF57-160FF3C897D0@gmerlin.de>
Hi,
On Wed, Oct 25, 2017, Christopher Zimmermann wrote:
> >> My Problem is that custom OCaml builds, especially the ones done
> >through opam will use gcc and therefore fail to build projects with not
> >so modest requirements. At the moment I'm just wondering at which level
> >in the toolchain this neuds fixing. OCaml configure, opam-repository or
> >opam source?
> >
> >Could you elaborate on that « therefore fail to build projects with not
> >so modest requirements » ?
>
> In my case it is core_kernel v0.9 which fails on OpenBSD gcc 4.2.1 because it uses -mpopcnt, while it compiles just fine with OpenBSD cc clang 4.0.0.
I believe there are several things to change. I outline my thoughts
below; I've sorted them by due date:
1- (overdue): Openbsd should stop shipping GCC 4.2: it's ten years old
and unmaintained. *TEN* years. It shouldn't be a surprise it starts
causing issues. The very reason 'gcc' has been used by ocaml instead of
'cc' was to avoid bad compilers on old systems and now openbsd is
re-creating similar issues, only with a different twist.
2- (easy, compatible): OCaml's configure script should probably fallback
to clang if GCC isn't found. That way, with openbsd not shipping GCC 4.2
anymore, clang would be automatically selected. I assumue ports ship a
modern GCC and installing this one would still result in a working
setup. Unsurprisingly, this is the step where you're invited to
contribute: it should really be a small change. My only concern is that
I seem to recall past discussions related to detecting clang but not
their outcome.
3- (longer term): I know that there has been some work on a replacement
of the configure script with something autoconf-based (and before anyone
complains, this doesn't include automake nor libtool). I don't know the
current status of this work however.
--
Adrien
next prev parent reply other threads:[~2017-10-25 6:52 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-10-19 15:05 Christopher Zimmermann
2017-10-22 9:20 ` SP
2017-10-23 7:46 ` Sébastien Hinderer
2017-10-23 7:57 ` Gabriel Scherer
2017-10-23 19:34 ` SP
2017-10-23 19:41 ` Christopher Zimmermann
2017-10-23 19:49 ` Adrien Nader
2017-10-24 5:15 ` [Caml-list] Are there any OCaml bindings to liblinear (a library for large linear classification)? Francois BERENGER
2017-10-24 7:55 ` Milo Davis
2017-10-25 2:31 ` Francois BERENGER
2017-10-25 7:06 ` [Caml-list] libsvm OCaml bindings and segfaults Francois BERENGER
2017-10-25 9:08 ` Philippe Veber
[not found] ` <152B8F33-A053-42AA-AF57-160FF3C897D0@gmerlin.de>
2017-10-25 6:52 ` Adrien Nader [this message]
2017-10-25 7:05 ` [Caml-list] use cc instead of gcc as default C compiler? Gabriel Scherer
2017-10-25 7:14 ` Sébastien Hinderer
2017-10-25 7:20 ` Adrien Nader
2017-10-25 7:10 ` Sébastien Hinderer
2017-10-25 8:04 ` Christopher Zimmermann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20171025065201.GA24593@notk.org \
--to=adrien@notk.org \
--cc=caml-list@inria.fr \
--cc=christopher@gmerlin.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).