develooper Front page | perl.perl5.porters | Postings from June 2019

[perl #134189] configure: ubuntu without gcc

Thread Previous | Thread Next
Tony Cook via RT
June 13, 2019 04:10
[perl #134189] configure: ubuntu without gcc
Message ID:
On Tue, 11 Jun 2019 08:41:37 -0700, hv wrote:
> On Mon, 10 Jun 2019 14:06:38 -0700, ilmari wrote:
> > As far as I can tell there's no
> > Configure variable for this, but Configure has a comment that
> > ccname=gcc for clang
> Sadly that doesn't appear to be the case here: after removing gcc{,-7}
> again to test, $ccname is empty when I try that here. The concept
> works though: using instead
>  +elif [ X"$cc" = Xclang ] ; then
>  +    gcc=$cc
> does give me a successful build.
> I'm sure there are better ways to do this: we should at least allow
> for both 'clang' and '/usr/bin/clang'. I'd also be tempted to test
> this before '-x /usr/bin/gcc', on the assumption that if the invoker
> asked for clang we should try to use it.

clang might not be called clang.

For example, I installed clang and no gcc on a clean Ubuntu and /usr/bin/cc was an alias for clang, so a default Configure used "cc".

The attached tries to detect if $cc is clang or if clang is available in PATH (and works-for-me).


via perlbug:  queue: perl5 status: open

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About