[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: CC vs. CFLAGS
From: |
Bruno Haible |
Subject: |
Re: CC vs. CFLAGS |
Date: |
Wed, 19 Apr 2017 13:23:29 +0200 |
User-agent: |
KMail/5.1.3 (Linux/4.4.0-72-generic; KDE/5.18.0; x86_64; ; ) |
Mojca Miklavec writes:
> I'm still slightly confused about something else in that case. In the
> past I always used
>
> CC=gcc
> CFLAGS="-arch ppc"
>
> when compiling for another architecture.
The GNU standards [1][2] don't give an answer to this, but the Autoconf manual
[3] does.
I routinely use
* CC="gcc -m32", CC="gcc -m64" on bi-arch platforms,
* CC="gcc -mabi=n32", CC="gcc -mabi=64" on Linux/mips and IRIX,
* CC="gcc -m31" on Linux/s390x,
* CC="cc +DD64" on HP-UX/hppa,
* CC="arm-linux-gnueabihf-gcc-4.8" on Linux/arm64.
This is the normal way to set CC.
Bruno
[1] https://www.gnu.org/prep/standards/html_node/Configuration.html
[2] https://www.gnu.org/prep/standards/html_node/Command-Variables.html
[3]
https://www.gnu.org/software/autoconf/manual/autoconf-2.69/html_node/Preset-Output-Variables.html
Re: Patch for config.guess for "cross-compiling" x86_64 -> powerpc on Mac OS X <= 10.6, Bruno Haible, 2017/04/19