public inbox for crossgcc@sourceware.org
 help / color / mirror / Atom feed
From: Bryan Hundven <bryanhundven@gmail.com>
To: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Cc: Jimm Chen <chjfth@gmail.com>,
	crossgcc maillist <crossgcc@sourceware.org>,
		"Yann E. MORIN" <yann.morin.1998@free.fr>,
	Ray Donnelly <mingw.android@gmail.com>
Subject: Re: How to generate a cross gcc toolchain that accepts both -m32 and -m64 compiler option?
Date: Sun, 23 Nov 2014 03:25:00 -0000	[thread overview]
Message-ID: <CAJ+oik3_Mo4Abpnd=dAf-SSRdv6DM+KfjURO+h_m3CL=wqWY2A@mail.gmail.com> (raw)
In-Reply-To: <20141122214555.60914134@free-electrons.com>

Jimm, Thomas,

On Sat, Nov 22, 2014 at 12:45 PM, Thomas Petazzoni
<thomas.petazzoni@free-electrons.com> wrote:
> Dear Jimm Chen,
>
> On Thu, 20 Nov 2014 00:47:37 +0800, Jimm Chen wrote:
>> Using crosstool-ng 1.20, I've managed to build a gcc 4.8.3 cross
>> compiler on openSUSE 12.3(32-bit) that is targeted at x86_64(x64)
>> linux. The CT-NG tool is a life saver. However, I have a question. the
>> generated compiler x86_64-pc-linux-gnu-gcc can only produce x64
>> executables. When I try to do
>>
>>   x86_64-pc-linux-gnu-gcc -m32 hello.c
>>
>> I got error message like:
>>
>> /home/chj/x-tools/.../sysroot/usr/include/gnu/stubs.h:7:27: fatal
>> error: gnu/stubs-32.h: No such file or directory
>>  # include <gnu/stubs-32.h>
>>                            ^
>> compilation terminated.
>>
>> You know, on an openSUSE Linux 64-bit distribution, we can use -m64 to
>> produce 64-bit image and -m32 to produce 32-bit image. Can someone
>> tell me how to achieve that functionality with CT-NG generated
>> toolchain?
>
> You need to look at something called "multilib support". I don't
> remember if Crosstool-NG has added multilib support. Last time I
> looked, it didn't had multilib support, but maybe it has changed since
> then.

Correct. Crosstool-NG currently does not have multilib support.
Last commit to Yann's repository was back in September:
http://crosstool-ng.org/git/crosstool-ng/log/

There are a lot of patches waiting to be applied:
https://patchwork.ozlabs.org/project/crosstool-ng/list/

Ray Donnelly and I started to work on multilib support, but I stopped
sending patches when Yann stopped applying them. Some of the patches
in the patchwork list no longer apply correctly and need to be resent.

I hope Crosstool-NG keeps going.

-Bryan

--
For unsubscribe information see http://sourceware.org/lists.html#faq

      reply	other threads:[~2014-11-23  3:25 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-19 16:47 Jimm Chen
2014-11-22 20:46 ` Thomas Petazzoni
2014-11-23  3:25   ` Bryan Hundven [this message]

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='CAJ+oik3_Mo4Abpnd=dAf-SSRdv6DM+KfjURO+h_m3CL=wqWY2A@mail.gmail.com' \
    --to=bryanhundven@gmail.com \
    --cc=chjfth@gmail.com \
    --cc=crossgcc@sourceware.org \
    --cc=mingw.android@gmail.com \
    --cc=thomas.petazzoni@free-electrons.com \
    --cc=yann.morin.1998@free.fr \
    /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 read-only IMAP folder(s) and NNTP newsgroup(s).