Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] building native gcc for target
@ 2012-08-08  1:18 Kevin Broch
  2012-08-08  2:19 ` Steve Calfee
  0 siblings, 1 reply; 15+ messages in thread
From: Kevin Broch @ 2012-08-08  1:18 UTC (permalink / raw)
  To: buildroot

I'm am looking to build a complete (gcc too) development environment on the
target (arm) but currently don't see that this is possible.
I have tried all 3 toolchain types (buildroot, cross-ng, external (linaro),
but regardless I don't find gcc in output/target/usr/bin/gcc
I am wondering if I am missing something?

If not I am looking for any pointer on how I might do this (having never
created a buildroot package).
Ideally I would like to create a package that compiles Linaro GCC:
https://wiki.linaro.org/WorkingGroups/ToolChain/Using/GCCNative
I am imagining leveraging what is used to generate other tools like gdb,
binutils, and trying to incorporate the various machine options (VFP,
softfloat, etc)
in the configure options.

Any pointers would be appreciated.

Best, /<evin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20120807/634fb4bd/attachment.html>

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Buildroot] building native gcc for target
  2012-08-08  1:18 [Buildroot] building native gcc for target Kevin Broch
@ 2012-08-08  2:19 ` Steve Calfee
  2012-08-08  2:27   ` Scott Moore
  2012-08-08 20:49   ` Kevin Broch
  0 siblings, 2 replies; 15+ messages in thread
From: Steve Calfee @ 2012-08-08  2:19 UTC (permalink / raw)
  To: buildroot

On Tue, Aug 7, 2012 at 6:18 PM, Kevin Broch <kevbroch@gmail.com> wrote:
> I'm am looking to build a complete (gcc too) development environment on the
> target (arm) but currently don't see that this is possible.
> I have tried all 3 toolchain types (buildroot, cross-ng, external (linaro),
> but regardless I don't find gcc in output/target/usr/bin/gcc
> I am wondering if I am missing something?
>
> If not I am looking for any pointer on how I might do this (having never
> created a buildroot package).
> Ideally I would like to create a package that compiles Linaro GCC:
> https://wiki.linaro.org/WorkingGroups/ToolChain/Using/GCCNative
> I am imagining leveraging what is used to generate other tools like gdb,
> binutils, and trying to incorporate the various machine options (VFP,
> softfloat, etc)
> in the configure options.
>
> Any pointers would be appreciated.
>
> Best, /<evin

I guess you haven't seen how to do it because it is kind of bizarre.
You want to cross compile a native mode compiler. Why?

Most people building embedded systems don't want to compile on those
systems. I don't know how you even bootstrap a gcc build in a system
without a c compiler.

Regards, Steve

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Buildroot] building native gcc for target
  2012-08-08  2:19 ` Steve Calfee
@ 2012-08-08  2:27   ` Scott Moore
  2012-08-08  5:57     ` Baruch Siach
                       ` (2 more replies)
  2012-08-08 20:49   ` Kevin Broch
  1 sibling, 3 replies; 15+ messages in thread
From: Scott Moore @ 2012-08-08  2:27 UTC (permalink / raw)
  To: buildroot

On 8/7/12 7:19 PM, Steve Calfee wrote:
> On Tue, Aug 7, 2012 at 6:18 PM, Kevin Broch <kevbroch@gmail.com> wrote:
>> I'm am looking to build a complete (gcc too) development environment on the
>> target (arm) but currently don't see that this is possible.
>> I have tried all 3 toolchain types (buildroot, cross-ng, external (linaro),
>> but regardless I don't find gcc in output/target/usr/bin/gcc
>> I am wondering if I am missing something?
>>
>> If not I am looking for any pointer on how I might do this (having never
>> created a buildroot package).
>> Ideally I would like to create a package that compiles Linaro GCC:
>> https://wiki.linaro.org/WorkingGroups/ToolChain/Using/GCCNative
>> I am imagining leveraging what is used to generate other tools like gdb,
>> binutils, and trying to incorporate the various machine options (VFP,
>> softfloat, etc)
>> in the configure options.
>>
>> Any pointers would be appreciated.
>>
>> Best, /<evin
> I guess you haven't seen how to do it because it is kind of bizarre.
> You want to cross compile a native mode compiler. Why?
>
> Most people building embedded systems don't want to compile on those
> systems. I don't know how you even bootstrap a gcc build in a system
> without a c compiler.
>
> Regards, Steve
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
According to http://www.uclibc.org/toolchains.html (which unfortunately 
seems quite out of date), this is a recommended way of creating a 
development system for using uClibc.
I'm actually trying to do something similar to easily build applications 
in a "clean" environment with only uClibc headers, etc, and also having 
trouble. Has anyone done this recently? (See my message earlier today 
about a configuration for x86_64)

Kevin, you may need to select GCC in the "package selection for target 
-> development tools" options in menuconfig (which requires setting 
development files on target to true in build options). I've gotten that 
far but the resulting native compiler hasn't worked reliably.

Cheers,
Scott

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Buildroot] building native gcc for target
  2012-08-08  2:27   ` Scott Moore
@ 2012-08-08  5:57     ` Baruch Siach
  2012-08-08 20:24       ` Kevin Broch
  2012-08-08 13:58     ` Grant Edwards
  2012-08-08 20:16     ` Kevin Broch
  2 siblings, 1 reply; 15+ messages in thread
From: Baruch Siach @ 2012-08-08  5:57 UTC (permalink / raw)
  To: buildroot

Hi Scott, Kevin,

On Tue, Aug 07, 2012 at 07:27:33PM -0700, Scott Moore wrote:
> On 8/7/12 7:19 PM, Steve Calfee wrote:
> >On Tue, Aug 7, 2012 at 6:18 PM, Kevin Broch <kevbroch@gmail.com> wrote:
> >>I'm am looking to build a complete (gcc too) development environment on the
> >>target (arm) but currently don't see that this is possible.
> >>I have tried all 3 toolchain types (buildroot, cross-ng, external (linaro),
> >>but regardless I don't find gcc in output/target/usr/bin/gcc
> >>I am wondering if I am missing something?
> >>
> >>If not I am looking for any pointer on how I might do this (having never
> >>created a buildroot package).
> >>Ideally I would like to create a package that compiles Linaro GCC:
> >>https://wiki.linaro.org/WorkingGroups/ToolChain/Using/GCCNative
> >>I am imagining leveraging what is used to generate other tools like gdb,
> >>binutils, and trying to incorporate the various machine options (VFP,
> >>softfloat, etc)
> >>in the configure options.
> >>
> >>Any pointers would be appreciated.
> >I guess you haven't seen how to do it because it is kind of bizarre.
> >You want to cross compile a native mode compiler. Why?
> >
> >Most people building embedded systems don't want to compile on those
> >systems. I don't know how you even bootstrap a gcc build in a system
> >without a c compiler.
> According to http://www.uclibc.org/toolchains.html (which
> unfortunately seems quite out of date), this is a recommended way of
> creating a development system for using uClibc.
> I'm actually trying to do something similar to easily build
> applications in a "clean" environment with only uClibc headers, etc,
> and also having trouble. Has anyone done this recently? (See my
> message earlier today about a configuration for x86_64)
> 
> Kevin, you may need to select GCC in the "package selection for
> target -> development tools" options in menuconfig (which requires
> setting development files on target to true in build options). I've
> gotten that far but the resulting native compiler hasn't worked
> reliably.

You may try Aboriginal Linux (http://landley.net/aboriginal/) which includes 
pre-built native compilers for various targets, along with their build 
scripts.

baruch

-- 
     http://baruch.siach.name/blog/                  ~. .~   Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
   - baruch at tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Buildroot] building native gcc for target
  2012-08-08  2:27   ` Scott Moore
  2012-08-08  5:57     ` Baruch Siach
@ 2012-08-08 13:58     ` Grant Edwards
  2012-08-08 20:16     ` Kevin Broch
  2 siblings, 0 replies; 15+ messages in thread
From: Grant Edwards @ 2012-08-08 13:58 UTC (permalink / raw)
  To: buildroot

On 2012-08-08, Scott Moore <scott.moore@sri.com> wrote:
> On 8/7/12 7:19 PM, Steve Calfee wrote:
>
>> I guess you haven't seen how to do it because it is kind of bizarre.
>> You want to cross compile a native mode compiler. Why?
>
> According to http://www.uclibc.org/toolchains.html (which
> unfortunately seems quite out of date), this is a recommended way of
> creating a development system for using uClibc.
>
> I'm actually trying to do something similar to easily build
> applications in a "clean" environment with only uClibc headers, etc,

I don't see why a cross compiler built using Crosstool-NG doesn't
satisfy that requirement.

-- 
Grant Edwards               grant.b.edwards        Yow! Spreading peanut
                                  at               butter reminds me of
                              gmail.com            opera!!  I wonder why?

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Buildroot] building native gcc for target
  2012-08-08  2:27   ` Scott Moore
  2012-08-08  5:57     ` Baruch Siach
  2012-08-08 13:58     ` Grant Edwards
@ 2012-08-08 20:16     ` Kevin Broch
  2012-08-11 18:16       ` Thomas Petazzoni
  2 siblings, 1 reply; 15+ messages in thread
From: Kevin Broch @ 2012-08-08 20:16 UTC (permalink / raw)
  To: buildroot

Hi Scott,

Thanks for the suggestion.  I unfortunately do not see this "select GCC"
option that you suggest.
I am using git://git.buildroot.net/buildroot @HEAD

- I have selected "Buildroot toolchain" from the Toolchain menu.
- Under "Package selection for the target" -> "Development Tools", I see a
comment
"gcc needs development files in target filesystem"
but no way to select GCC.
As far as I can see the only selecting of GCC goes to which version for the
cross compiled version.

Best, /<evin


On Tue, Aug 7, 2012 at 7:27 PM, Scott Moore <scott.moore@sri.com> wrote:

> On 8/7/12 7:19 PM, Steve Calfee wrote:
>
>> On Tue, Aug 7, 2012 at 6:18 PM, Kevin Broch <kevbroch@gmail.com> wrote:
>>
>>> I'm am looking to build a complete (gcc too) development environment on
>>> the
>>> target (arm) but currently don't see that this is possible.
>>> I have tried all 3 toolchain types (buildroot, cross-ng, external
>>> (linaro),
>>> but regardless I don't find gcc in output/target/usr/bin/gcc
>>> I am wondering if I am missing something?
>>>
>>> If not I am looking for any pointer on how I might do this (having never
>>> created a buildroot package).
>>> Ideally I would like to create a package that compiles Linaro GCC:
>>> https://wiki.linaro.org/**WorkingGroups/ToolChain/Using/**GCCNative<https://wiki.linaro.org/WorkingGroups/ToolChain/Using/GCCNative>
>>> I am imagining leveraging what is used to generate other tools like gdb,
>>> binutils, and trying to incorporate the various machine options (VFP,
>>> softfloat, etc)
>>> in the configure options.
>>>
>>> Any pointers would be appreciated.
>>>
>>> Best, /<evin
>>>
>> I guess you haven't seen how to do it because it is kind of bizarre.
>> You want to cross compile a native mode compiler. Why?
>>
>> Most people building embedded systems don't want to compile on those
>> systems. I don't know how you even bootstrap a gcc build in a system
>> without a c compiler.
>>
>> Regards, Steve
>> ______________________________**_________________
>> buildroot mailing list
>> buildroot at busybox.net
>> http://lists.busybox.net/**mailman/listinfo/buildroot<http://lists.busybox.net/mailman/listinfo/buildroot>
>>
> According to http://www.uclibc.org/**toolchains.html<http://www.uclibc.org/toolchains.html>(which unfortunately seems quite out of date), this is a recommended way of
> creating a development system for using uClibc.
> I'm actually trying to do something similar to easily build applications
> in a "clean" environment with only uClibc headers, etc, and also having
> trouble. Has anyone done this recently? (See my message earlier today about
> a configuration for x86_64)
>
> Kevin, you may need to select GCC in the "package selection for target ->
> development tools" options in menuconfig (which requires setting
> development files on target to true in build options). I've gotten that far
> but the resulting native compiler hasn't worked reliably.
>
> Cheers,
> Scott
> ______________________________**_________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/**mailman/listinfo/buildroot<http://lists.busybox.net/mailman/listinfo/buildroot>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20120808/9c016d9f/attachment-0001.html>

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Buildroot] building native gcc for target
  2012-08-08  5:57     ` Baruch Siach
@ 2012-08-08 20:24       ` Kevin Broch
  2012-08-09  3:32         ` Baruch Siach
  0 siblings, 1 reply; 15+ messages in thread
From: Kevin Broch @ 2012-08-08 20:24 UTC (permalink / raw)
  To: buildroot

Thank Baruch I will have to check it out.  Have you used this yourself and
if so what platform?

Best, /<evin


On Tue, Aug 7, 2012 at 10:57 PM, Baruch Siach <baruch@tkos.co.il> wrote:

> Hi Scott, Kevin,
>
> On Tue, Aug 07, 2012 at 07:27:33PM -0700, Scott Moore wrote:
> > On 8/7/12 7:19 PM, Steve Calfee wrote:
> > >On Tue, Aug 7, 2012 at 6:18 PM, Kevin Broch <kevbroch@gmail.com> wrote:
> > >>I'm am looking to build a complete (gcc too) development environment
> on the
> > >>target (arm) but currently don't see that this is possible.
> > >>I have tried all 3 toolchain types (buildroot, cross-ng, external
> (linaro),
> > >>but regardless I don't find gcc in output/target/usr/bin/gcc
> > >>I am wondering if I am missing something?
> > >>
> > >>If not I am looking for any pointer on how I might do this (having
> never
> > >>created a buildroot package).
> > >>Ideally I would like to create a package that compiles Linaro GCC:
> > >>https://wiki.linaro.org/WorkingGroups/ToolChain/Using/GCCNative
> > >>I am imagining leveraging what is used to generate other tools like
> gdb,
> > >>binutils, and trying to incorporate the various machine options (VFP,
> > >>softfloat, etc)
> > >>in the configure options.
> > >>
> > >>Any pointers would be appreciated.
> > >I guess you haven't seen how to do it because it is kind of bizarre.
> > >You want to cross compile a native mode compiler. Why?
> > >
> > >Most people building embedded systems don't want to compile on those
> > >systems. I don't know how you even bootstrap a gcc build in a system
> > >without a c compiler.
> > According to http://www.uclibc.org/toolchains.html (which
> > unfortunately seems quite out of date), this is a recommended way of
> > creating a development system for using uClibc.
> > I'm actually trying to do something similar to easily build
> > applications in a "clean" environment with only uClibc headers, etc,
> > and also having trouble. Has anyone done this recently? (See my
> > message earlier today about a configuration for x86_64)
> >
> > Kevin, you may need to select GCC in the "package selection for
> > target -> development tools" options in menuconfig (which requires
> > setting development files on target to true in build options). I've
> > gotten that far but the resulting native compiler hasn't worked
> > reliably.
>
> You may try Aboriginal Linux (http://landley.net/aboriginal/) which
> includes
> pre-built native compilers for various targets, along with their build
> scripts.
>
> baruch
>
> --
>      http://baruch.siach.name/blog/                  ~. .~   Tk Open
> Systems
> =}------------------------------------------------ooO--U--Ooo------------{=
>    - baruch at tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20120808/ffab85b6/attachment.html>

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Buildroot] building native gcc for target
  2012-08-08  2:19 ` Steve Calfee
  2012-08-08  2:27   ` Scott Moore
@ 2012-08-08 20:49   ` Kevin Broch
  2012-08-08 21:55     ` Alex Bradbury
  1 sibling, 1 reply; 15+ messages in thread
From: Kevin Broch @ 2012-08-08 20:49 UTC (permalink / raw)
  To: buildroot

Steve, Grant,

I appreciate your skepticism as validation this is something uncommon.
 That being said I still want to do it.
To be clear my end goal is to have native gcc compiler on the target.  As I
see it there are 2 ways to accomplish that:
1) cross compile it
2) go through step to build a native compiler here:
http://gcc.gnu.org/install/build.html

#1 seems easier to me (and give the resource constraints of my system #2
might not be possible)

As for why(some just examples):
- use buildroot to create a native development platform for
http://www.raspberrypi.org/
- isolated system that has feedback loop from sensor data which requires
periodic recompilation of C source
- stress test hardware using gcc as a workload

Best, /<evin





On Tue, Aug 7, 2012 at 7:19 PM, Steve Calfee <stevecalfee@gmail.com> wrote:

> On Tue, Aug 7, 2012 at 6:18 PM, Kevin Broch <kevbroch@gmail.com> wrote:
> > I'm am looking to build a complete (gcc too) development environment on
> the
> > target (arm) but currently don't see that this is possible.
> > I have tried all 3 toolchain types (buildroot, cross-ng, external
> (linaro),
> > but regardless I don't find gcc in output/target/usr/bin/gcc
> > I am wondering if I am missing something?
> >
> > If not I am looking for any pointer on how I might do this (having never
> > created a buildroot package).
> > Ideally I would like to create a package that compiles Linaro GCC:
> > https://wiki.linaro.org/WorkingGroups/ToolChain/Using/GCCNative
> > I am imagining leveraging what is used to generate other tools like gdb,
> > binutils, and trying to incorporate the various machine options (VFP,
> > softfloat, etc)
> > in the configure options.
> >
> > Any pointers would be appreciated.
> >
> > Best, /<evin
>
> I guess you haven't seen how to do it because it is kind of bizarre.
> You want to cross compile a native mode compiler. Why?
>
> Most people building embedded systems don't want to compile on those
> systems. I don't know how you even bootstrap a gcc build in a system
> without a c compiler.
>
> Regards, Steve
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20120808/83cabfba/attachment.html>

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Buildroot] building native gcc for target
  2012-08-08 20:49   ` Kevin Broch
@ 2012-08-08 21:55     ` Alex Bradbury
  0 siblings, 0 replies; 15+ messages in thread
From: Alex Bradbury @ 2012-08-08 21:55 UTC (permalink / raw)
  To: buildroot

On 8 August 2012 21:49, Kevin Broch <kevbroch@gmail.com> wrote:
> As for why(some just examples):
> - use buildroot to create a native development platform for
> http://www.raspberrypi.org/
> - isolated system that has feedback loop from sensor data which requires
> periodic recompilation of C source
> - stress test hardware using gcc as a workload

Plus it would be a little cool to use buildroot to compile a rootfs
with enough host dependencies to run buildroot on the target.

Alex

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Buildroot] building native gcc for target
  2012-08-08 20:24       ` Kevin Broch
@ 2012-08-09  3:32         ` Baruch Siach
  2012-08-10  2:28           ` Kevin Broch
  0 siblings, 1 reply; 15+ messages in thread
From: Baruch Siach @ 2012-08-09  3:32 UTC (permalink / raw)
  To: buildroot

Hi Kevin,

On Wed, Aug 08, 2012 at 01:24:14PM -0700, Kevin Broch wrote:
> Thank Baruch I will have to check it out.  Have you used this yourself and
> if so what platform?

Yes. I used it on ARMv5 platform (i.MX25) to build the initramfs environment 
(just Busybox and a few small utilities) statically linked.

Another option that comes to mind is to install Debian on your target. Debian 
includes a natively built toolchain, and you can easily test the result in a 
chroot. If you don't have enough storage for Debian (at least 500MB, more is 
preferred) on-board you can use NFS mounted root filesystem, mounted from a 
PC. I used this trick on several platforms (ARM, MIPS, PowerPC) during 
bring-up phase as it's a short path to a wealth of pre-built (and natively 
compiled) software packages.

baruch

> On Tue, Aug 7, 2012 at 10:57 PM, Baruch Siach <baruch@tkos.co.il> wrote:
> > Hi Scott, Kevin,
> >
> > On Tue, Aug 07, 2012 at 07:27:33PM -0700, Scott Moore wrote:
> > > On 8/7/12 7:19 PM, Steve Calfee wrote:
> > > >On Tue, Aug 7, 2012 at 6:18 PM, Kevin Broch <kevbroch@gmail.com> wrote:
> > > >>I'm am looking to build a complete (gcc too) development environment
> > on the
> > > >>target (arm) but currently don't see that this is possible.
> > > >>I have tried all 3 toolchain types (buildroot, cross-ng, external
> > (linaro),
> > > >>but regardless I don't find gcc in output/target/usr/bin/gcc
> > > >>I am wondering if I am missing something?
> > > >>
> > > >>If not I am looking for any pointer on how I might do this (having
> > never
> > > >>created a buildroot package).
> > > >>Ideally I would like to create a package that compiles Linaro GCC:
> > > >>https://wiki.linaro.org/WorkingGroups/ToolChain/Using/GCCNative
> > > >>I am imagining leveraging what is used to generate other tools like
> > gdb,
> > > >>binutils, and trying to incorporate the various machine options (VFP,
> > > >>softfloat, etc)
> > > >>in the configure options.
> > > >>
> > > >>Any pointers would be appreciated.
> > > >I guess you haven't seen how to do it because it is kind of bizarre.
> > > >You want to cross compile a native mode compiler. Why?
> > > >
> > > >Most people building embedded systems don't want to compile on those
> > > >systems. I don't know how you even bootstrap a gcc build in a system
> > > >without a c compiler.
> > > According to http://www.uclibc.org/toolchains.html (which
> > > unfortunately seems quite out of date), this is a recommended way of
> > > creating a development system for using uClibc.
> > > I'm actually trying to do something similar to easily build
> > > applications in a "clean" environment with only uClibc headers, etc,
> > > and also having trouble. Has anyone done this recently? (See my
> > > message earlier today about a configuration for x86_64)
> > >
> > > Kevin, you may need to select GCC in the "package selection for
> > > target -> development tools" options in menuconfig (which requires
> > > setting development files on target to true in build options). I've
> > > gotten that far but the resulting native compiler hasn't worked
> > > reliably.
> >
> > You may try Aboriginal Linux (http://landley.net/aboriginal/) which
> > includes
> > pre-built native compilers for various targets, along with their build
> > scripts.
> >
> > baruch

-- 
     http://baruch.siach.name/blog/                  ~. .~   Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
   - baruch at tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Buildroot] building native gcc for target
  2012-08-09  3:32         ` Baruch Siach
@ 2012-08-10  2:28           ` Kevin Broch
  0 siblings, 0 replies; 15+ messages in thread
From: Kevin Broch @ 2012-08-10  2:28 UTC (permalink / raw)
  To: buildroot

Thanks for suggestions. I am going down the debian arm route to get armv7l

Best, /<evin

On Wed, Aug 8, 2012 at 8:32 PM, Baruch Siach <baruch@tkos.co.il> wrote:

> Hi Kevin,
>
> On Wed, Aug 08, 2012 at 01:24:14PM -0700, Kevin Broch wrote:
> > Thank Baruch I will have to check it out.  Have you used this yourself
> and
> > if so what platform?
>
> Yes. I used it on ARMv5 platform (i.MX25) to build the initramfs
> environment
> (just Busybox and a few small utilities) statically linked.
>
> Another option that comes to mind is to install Debian on your target.
> Debian
> includes a natively built toolchain, and you can easily test the result in
> a
> chroot. If you don't have enough storage for Debian (at least 500MB, more
> is
> preferred) on-board you can use NFS mounted root filesystem, mounted from a
> PC. I used this trick on several platforms (ARM, MIPS, PowerPC) during
> bring-up phase as it's a short path to a wealth of pre-built (and natively
> compiled) software packages.
>
> baruch
>
> > On Tue, Aug 7, 2012 at 10:57 PM, Baruch Siach <baruch@tkos.co.il> wrote:
> > > Hi Scott, Kevin,
> > >
> > > On Tue, Aug 07, 2012 at 07:27:33PM -0700, Scott Moore wrote:
> > > > On 8/7/12 7:19 PM, Steve Calfee wrote:
> > > > >On Tue, Aug 7, 2012 at 6:18 PM, Kevin Broch <kevbroch@gmail.com>
> wrote:
> > > > >>I'm am looking to build a complete (gcc too) development
> environment
> > > on the
> > > > >>target (arm) but currently don't see that this is possible.
> > > > >>I have tried all 3 toolchain types (buildroot, cross-ng, external
> > > (linaro),
> > > > >>but regardless I don't find gcc in output/target/usr/bin/gcc
> > > > >>I am wondering if I am missing something?
> > > > >>
> > > > >>If not I am looking for any pointer on how I might do this (having
> > > never
> > > > >>created a buildroot package).
> > > > >>Ideally I would like to create a package that compiles Linaro GCC:
> > > > >>https://wiki.linaro.org/WorkingGroups/ToolChain/Using/GCCNative
> > > > >>I am imagining leveraging what is used to generate other tools like
> > > gdb,
> > > > >>binutils, and trying to incorporate the various machine options
> (VFP,
> > > > >>softfloat, etc)
> > > > >>in the configure options.
> > > > >>
> > > > >>Any pointers would be appreciated.
> > > > >I guess you haven't seen how to do it because it is kind of bizarre.
> > > > >You want to cross compile a native mode compiler. Why?
> > > > >
> > > > >Most people building embedded systems don't want to compile on those
> > > > >systems. I don't know how you even bootstrap a gcc build in a system
> > > > >without a c compiler.
> > > > According to http://www.uclibc.org/toolchains.html (which
> > > > unfortunately seems quite out of date), this is a recommended way of
> > > > creating a development system for using uClibc.
> > > > I'm actually trying to do something similar to easily build
> > > > applications in a "clean" environment with only uClibc headers, etc,
> > > > and also having trouble. Has anyone done this recently? (See my
> > > > message earlier today about a configuration for x86_64)
> > > >
> > > > Kevin, you may need to select GCC in the "package selection for
> > > > target -> development tools" options in menuconfig (which requires
> > > > setting development files on target to true in build options). I've
> > > > gotten that far but the resulting native compiler hasn't worked
> > > > reliably.
> > >
> > > You may try Aboriginal Linux (http://landley.net/aboriginal/) which
> > > includes
> > > pre-built native compilers for various targets, along with their build
> > > scripts.
> > >
> > > baruch
>
> --
>      http://baruch.siach.name/blog/                  ~. .~   Tk Open
> Systems
> =}------------------------------------------------ooO--U--Ooo------------{=
>    - baruch at tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20120809/5f84200c/attachment.html>

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Buildroot] building native gcc for target
  2012-08-08 20:16     ` Kevin Broch
@ 2012-08-11 18:16       ` Thomas Petazzoni
  2012-08-14  0:38         ` Kevin Broch
  0 siblings, 1 reply; 15+ messages in thread
From: Thomas Petazzoni @ 2012-08-11 18:16 UTC (permalink / raw)
  To: buildroot

Le Wed, 8 Aug 2012 13:16:26 -0700,
Kevin Broch <kevbroch@gmail.com> a ?crit :

> Thanks for the suggestion.  I unfortunately do not see this "select GCC"
> option that you suggest.
> I am using git://git.buildroot.net/buildroot @HEAD
> 
> - I have selected "Buildroot toolchain" from the Toolchain menu.
> - Under "Package selection for the target" -> "Development Tools", I see a
> comment
> "gcc needs development files in target filesystem"
> but no way to select GCC.
> As far as I can see the only selecting of GCC goes to which version for the
> cross compiled version.

Build options -> development files in target filesystem
Packages -> Development tools -> gcc

Note that this is only available if you use "Buildroot toolchain" as
the toolchain type. We don't support generating gcc for the target with
the external toolchain and Crosstool-NG toolchain backends.

Best regards,

Thomas
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Buildroot] building native gcc for target
  2012-08-11 18:16       ` Thomas Petazzoni
@ 2012-08-14  0:38         ` Kevin Broch
  0 siblings, 0 replies; 15+ messages in thread
From: Kevin Broch @ 2012-08-14  0:38 UTC (permalink / raw)
  To: buildroot

Thanks Thomas.  Everything is working now.

Best, /<evin


On Sat, Aug 11, 2012 at 11:16 AM, Thomas Petazzoni <
thomas.petazzoni@free-electrons.com> wrote:

> Le Wed, 8 Aug 2012 13:16:26 -0700,
> Kevin Broch <kevbroch@gmail.com> a ?crit :
>
> > Thanks for the suggestion.  I unfortunately do not see this "select GCC"
> > option that you suggest.
> > I am using git://git.buildroot.net/buildroot @HEAD
> >
> > - I have selected "Buildroot toolchain" from the Toolchain menu.
> > - Under "Package selection for the target" -> "Development Tools", I see
> a
> > comment
> > "gcc needs development files in target filesystem"
> > but no way to select GCC.
> > As far as I can see the only selecting of GCC goes to which version for
> the
> > cross compiled version.
>
> Build options -> development files in target filesystem
> Packages -> Development tools -> gcc
>
> Note that this is only available if you use "Buildroot toolchain" as
> the toolchain type. We don't support generating gcc for the target with
> the external toolchain and Crosstool-NG toolchain backends.
>
> Best regards,
>
> Thomas
> --
> Thomas Petazzoni, Free Electrons
> Kernel, drivers, real-time and embedded Linux
> development, consulting, training and support.
> http://free-electrons.com
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20120813/efd6280b/attachment-0001.html>

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Buildroot] building native gcc for target
@ 2014-12-29 13:27 Boris Lenin
  2014-12-29 13:34 ` Thomas Petazzoni
  0 siblings, 1 reply; 15+ messages in thread
From: Boris Lenin @ 2014-12-29 13:27 UTC (permalink / raw)
  To: buildroot

Hi,

I want to have a gcc binary in my target, so I can compile ELFs inside it.
This is for compiling using uClibc as suggested here:
http://www.uclibc.org/toolchains.html

But after I make, I have no gcc in output/target/usr/bin/gcc
I also don't have an option to include gcc in menuconfig->Target
packages->Development Tools

How can I have a working gcc that's using uClibc inside my new rootfs?

Thank you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20141229/a86a08cf/attachment.html>

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Buildroot] building native gcc for target
  2014-12-29 13:27 Boris Lenin
@ 2014-12-29 13:34 ` Thomas Petazzoni
  0 siblings, 0 replies; 15+ messages in thread
From: Thomas Petazzoni @ 2014-12-29 13:34 UTC (permalink / raw)
  To: buildroot

Dear Boris Lenin,

On Mon, 29 Dec 2014 15:27:40 +0200, Boris Lenin wrote:

> I want to have a gcc binary in my target, so I can compile ELFs inside it.
> This is for compiling using uClibc as suggested here:
> http://www.uclibc.org/toolchains.html
> 
> But after I make, I have no gcc in output/target/usr/bin/gcc
> I also don't have an option to include gcc in menuconfig->Target
> packages->Development Tools
> 
> How can I have a working gcc that's using uClibc inside my new rootfs?

This is no longer supported in Buildroot. See
http://buildroot.org/downloads/manual/manual.html#faq-no-compiler-on-target
for more details about this topic.

You should either cross-compile your applications/libraries, or use a
full-featured Linux distribution on your system.

Best regards,

Thomas Petazzoni
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2014-12-29 13:34 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-08-08  1:18 [Buildroot] building native gcc for target Kevin Broch
2012-08-08  2:19 ` Steve Calfee
2012-08-08  2:27   ` Scott Moore
2012-08-08  5:57     ` Baruch Siach
2012-08-08 20:24       ` Kevin Broch
2012-08-09  3:32         ` Baruch Siach
2012-08-10  2:28           ` Kevin Broch
2012-08-08 13:58     ` Grant Edwards
2012-08-08 20:16     ` Kevin Broch
2012-08-11 18:16       ` Thomas Petazzoni
2012-08-14  0:38         ` Kevin Broch
2012-08-08 20:49   ` Kevin Broch
2012-08-08 21:55     ` Alex Bradbury
  -- strict thread matches above, loose matches on Subject: below --
2014-12-29 13:27 Boris Lenin
2014-12-29 13:34 ` Thomas Petazzoni

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox