All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] Why is libbsd limited to ARM, x86 and x86_64?
@ 2016-02-02 15:30 Carlos Santos
  2016-02-02 21:09 ` Arnout Vandecappelle
  0 siblings, 1 reply; 7+ messages in thread
From: Carlos Santos @ 2016-02-02 15:30 UTC (permalink / raw)
  To: buildroot

Hello,

I'm working on a project for PowerPC in which libbsd would be useful. However the package is restricted to ARM, x86 and x86_64 architectures, since Config.in contains this:

  # libbsd requires a.out.h, which is only available for those
  # architectures: arm, x86 (and alpha, currently not supported in Buildroot;
  # also m68k which is currently not enabled, so can't be tested.)
  default y if BR2_arm || BR2_i386 || BR2_x86_64

However, my PowerPC toolchain, generated by crosstool-NG, provides the required a.out.h file. It is based on GCC 4.8.2, GLIBC 2.19 and Kernel 3.10.47.

Where does the information about the missing a.out.h on PowerPC comes from?

Carlos Santos (Casantos) - DATACOM, P&D
Rua Am?rica, 1000 - Eldorado do Sul, RS, Brasil - 92990-000
casantos at datacom.ind.br          +55 51 3933.3000 ext. 3627
http://www.datacom.ind.br

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

* [Buildroot] Why is libbsd limited to ARM, x86 and x86_64?
  2016-02-02 15:30 [Buildroot] Why is libbsd limited to ARM, x86 and x86_64? Carlos Santos
@ 2016-02-02 21:09 ` Arnout Vandecappelle
  2016-02-03 15:39   ` Carlos Santos
  0 siblings, 1 reply; 7+ messages in thread
From: Arnout Vandecappelle @ 2016-02-02 21:09 UTC (permalink / raw)
  To: buildroot

On 02-02-16 16:30, Carlos Santos wrote:
> Hello,
> 
> I'm working on a project for PowerPC in which libbsd would be useful. However the package is restricted to ARM, x86 and x86_64 architectures, since Config.in contains this:
> 
>   # libbsd requires a.out.h, which is only available for those
>   # architectures: arm, x86 (and alpha, currently not supported in Buildroot;
>   # also m68k which is currently not enabled, so can't be tested.)
>   default y if BR2_arm || BR2_i386 || BR2_x86_64
> 
> However, my PowerPC toolchain, generated by crosstool-NG, provides the required a.out.h file. It is based on GCC 4.8.2, GLIBC 2.19 and Kernel 3.10.47.
> 
> Where does the information about the missing a.out.h on PowerPC comes from?

 I had to do some archeology for this one :-)

 This exclusion was from the time that we only supported glibc for external
toolchains and it didn't get too much attention. So we missed the fact that
glibc doesn't include linux/a.out.h so you won't get this[1] error. And it also
seems that libbsd doesn't really require a.out support in the architecture (PPC
doesn't support a.out), it just needs the a.out.h file to be present (in uClibc,
a.out.h includes linux/a.out.h; in glibc, it doesn't). So for glibc, it works on
any architecture.

 Sometime later, the bump to 0.6.0 made libbsd require a glibc toolchain [2].
But of course, nobody noticed that this meant that the architecture dependencies
are no longer needed.

 So it would be great if you could prepare a patch that removes the arch
dependency and test if libbsd builds on all the arches that have glibc: aarch64,
mips, sh, microblaze, sparc, nios2.

 Regards,
 Arnout
 [1]
http://autobuild.buildroot.org/results/019/019091312ec547520370ffad967b53e23f54a14b/
[2]
http://autobuild.buildroot.net/results/e94/e949d8fabeeecc74bd1c324c516e0b4938c99dbc/




-- 
Arnout Vandecappelle                          arnout at mind be
Senior Embedded Software Architect            +32-16-286500
Essensium/Mind                                http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium           BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF

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

* [Buildroot] Why is libbsd limited to ARM, x86 and x86_64?
  2016-02-02 21:09 ` Arnout Vandecappelle
@ 2016-02-03 15:39   ` Carlos Santos
  2016-02-03 18:50     ` Carlos Santos
  0 siblings, 1 reply; 7+ messages in thread
From: Carlos Santos @ 2016-02-03 15:39 UTC (permalink / raw)
  To: buildroot

> From: "Arnout Vandecappelle" <arnout@mind.be>
> To: "Carlos Santos" <casantos@datacom.ind.br>, "buildroot" <buildroot@buildroot.org>
> Sent: Tuesday, February 2, 2016 7:09:28 PM
> Subject: Re: [Buildroot] Why is libbsd limited to ARM, x86 and x86_64?

> On 02-02-16 16:30, Carlos Santos wrote:
>> Hello,
>> 
>> I'm working on a project for PowerPC in which libbsd would be useful. However
>> the package is restricted to ARM, x86 and x86_64 architectures, since Config.in
>> contains this:
>> 
>>   # libbsd requires a.out.h, which is only available for those
>>   # architectures: arm, x86 (and alpha, currently not supported in Buildroot;
>>   # also m68k which is currently not enabled, so can't be tested.)
>>   default y if BR2_arm || BR2_i386 || BR2_x86_64
>> 
>> However, my PowerPC toolchain, generated by crosstool-NG, provides the required
>> a.out.h file. It is based on GCC 4.8.2, GLIBC 2.19 and Kernel 3.10.47.
>> 
>> Where does the information about the missing a.out.h on PowerPC comes from?
> 
> I had to do some archeology for this one :-)
> 
> This exclusion was from the time that we only supported glibc for external
> toolchains and it didn't get too much attention. So we missed the fact that
> glibc doesn't include linux/a.out.h so you won't get this[1] error. And it also
> seems that libbsd doesn't really require a.out support in the architecture (PPC
> doesn't support a.out), it just needs the a.out.h file to be present (in uClibc,
> a.out.h includes linux/a.out.h; in glibc, it doesn't). So for glibc, it works on
> any architecture.
> 
> Sometime later, the bump to 0.6.0 made libbsd require a glibc toolchain [2].
> But of course, nobody noticed that this meant that the architecture dependencies
> are no longer needed.
> 
> So it would be great if you could prepare a patch that removes the arch
> dependency and test if libbsd builds on all the arches that have glibc: aarch64,
> mips, sh, microblaze, sparc, nios2.
> 
> Regards,
> Arnout
> [1]
> http://autobuild.buildroot.org/results/019/019091312ec547520370ffad967b53e23f54a14b/
> [2]
> http://autobuild.buildroot.net/results/e94/e949d8fabeeecc74bd1c324c516e0b4938c99dbc/

OK, I will submit a patch.

Carlos Santos (Casantos)
DATACOM, P&D

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

* [Buildroot] Why is libbsd limited to ARM, x86 and x86_64?
  2016-02-03 15:39   ` Carlos Santos
@ 2016-02-03 18:50     ` Carlos Santos
  2016-02-04  0:00       ` Arnout Vandecappelle
  0 siblings, 1 reply; 7+ messages in thread
From: Carlos Santos @ 2016-02-03 18:50 UTC (permalink / raw)
  To: buildroot

Two questions, first:

1. Is it enough to build for quemu boards?

2. I'm absolutely ignorant about nios2. What defconfig should I use to build for it? 

Carlos Santos (Casantos)
DATACOM, P&D

----- Original Message -----
> From: "Carlos Santos" <casantos@datacom.ind.br>
> To: "Arnout Vandecappelle" <arnout@mind.be>
> Cc: "buildroot" <buildroot@buildroot.org>, "guilherme machado" <guilherme.machado@datacom.ind.br>
> Sent: Wednesday, February 3, 2016 1:39:51 PM
> Subject: Re: [Buildroot] Why is libbsd limited to ARM, x86 and x86_64?

>> From: "Arnout Vandecappelle" <arnout@mind.be>
>> To: "Carlos Santos" <casantos@datacom.ind.br>, "buildroot"
>> <buildroot@buildroot.org>
>> Sent: Tuesday, February 2, 2016 7:09:28 PM
>> Subject: Re: [Buildroot] Why is libbsd limited to ARM, x86 and x86_64?
> 
>> On 02-02-16 16:30, Carlos Santos wrote:
>>> Hello,
>>> 
>>> I'm working on a project for PowerPC in which libbsd would be useful. However
>>> the package is restricted to ARM, x86 and x86_64 architectures, since Config.in
>>> contains this:
>>> 
>>>   # libbsd requires a.out.h, which is only available for those
>>>   # architectures: arm, x86 (and alpha, currently not supported in Buildroot;
>>>   # also m68k which is currently not enabled, so can't be tested.)
>>>   default y if BR2_arm || BR2_i386 || BR2_x86_64
>>> 
>>> However, my PowerPC toolchain, generated by crosstool-NG, provides the required
>>> a.out.h file. It is based on GCC 4.8.2, GLIBC 2.19 and Kernel 3.10.47.
>>> 
>>> Where does the information about the missing a.out.h on PowerPC comes from?
>> 
>> I had to do some archeology for this one :-)
>> 
>> This exclusion was from the time that we only supported glibc for external
>> toolchains and it didn't get too much attention. So we missed the fact that
>> glibc doesn't include linux/a.out.h so you won't get this[1] error. And it also
>> seems that libbsd doesn't really require a.out support in the architecture (PPC
>> doesn't support a.out), it just needs the a.out.h file to be present (in uClibc,
>> a.out.h includes linux/a.out.h; in glibc, it doesn't). So for glibc, it works on
>> any architecture.
>> 
>> Sometime later, the bump to 0.6.0 made libbsd require a glibc toolchain [2].
>> But of course, nobody noticed that this meant that the architecture dependencies
>> are no longer needed.
>> 
>> So it would be great if you could prepare a patch that removes the arch
>> dependency and test if libbsd builds on all the arches that have glibc: aarch64,
>> mips, sh, microblaze, sparc, nios2.
>> 
>> Regards,
>> Arnout
>> [1]
>> http://autobuild.buildroot.org/results/019/019091312ec547520370ffad967b53e23f54a14b/
>> [2]
>> http://autobuild.buildroot.net/results/e94/e949d8fabeeecc74bd1c324c516e0b4938c99dbc/
> 
> OK, I will submit a patch.
> 
> Carlos Santos (Casantos)
> DATACOM, P&D

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

* [Buildroot] Why is libbsd limited to ARM, x86 and x86_64?
  2016-02-03 18:50     ` Carlos Santos
@ 2016-02-04  0:00       ` Arnout Vandecappelle
  2016-02-04  5:21         ` Baruch Siach
  0 siblings, 1 reply; 7+ messages in thread
From: Arnout Vandecappelle @ 2016-02-04  0:00 UTC (permalink / raw)
  To: buildroot

[Please don't top-post]

On 03-02-16 19:50, Carlos Santos wrote:
> Two questions, first:
> 
> 1. Is it enough to build for quemu boards?

 Sure. I don't think runtime testing is really needed, except maybe for powerpc.

> 
> 2. I'm absolutely ignorant about nios2. What defconfig should I use to build for it? 

 Hm, looks like we don't have a nios2 defconfig... But you can do a very quick
build-test by setting arch to nios2 and selecting the Sourcery toolchain.

 Regards,
 Arnout

> 
> Carlos Santos (Casantos)
> DATACOM, P&D

-- 
Arnout Vandecappelle      arnout dot vandecappelle at essensium dot com
Senior Embedded Software Architect . . . . . . +32-478-010353 (mobile)
Essensium, Mind division . . . . . . . . . . . . . . http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium . . . . . BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF

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

* [Buildroot] Why is libbsd limited to ARM, x86 and x86_64?
  2016-02-04  0:00       ` Arnout Vandecappelle
@ 2016-02-04  5:21         ` Baruch Siach
  2016-02-04 12:22           ` Carlos Santos
  0 siblings, 1 reply; 7+ messages in thread
From: Baruch Siach @ 2016-02-04  5:21 UTC (permalink / raw)
  To: buildroot

Hi Carlos, Arnout,

On Thu, Feb 04, 2016 at 01:00:14AM +0100, Arnout Vandecappelle wrote:
> On 03-02-16 19:50, Carlos Santos wrote:
> > 2. I'm absolutely ignorant about nios2. What defconfig should I use to 
> > build for it? 
> 
>  Hm, looks like we don't have a nios2 defconfig... But you can do a very quick
> build-test by setting arch to nios2 and selecting the Sourcery toolchain.

You can also use the config at 
http://autobuild.buildroot.net/toolchains/configs/br-nios2-glibc.config.

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] 7+ messages in thread

* [Buildroot] Why is libbsd limited to ARM, x86 and x86_64?
  2016-02-04  5:21         ` Baruch Siach
@ 2016-02-04 12:22           ` Carlos Santos
  0 siblings, 0 replies; 7+ messages in thread
From: Carlos Santos @ 2016-02-04 12:22 UTC (permalink / raw)
  To: buildroot

> From: "Baruch Siach" <baruch@tkos.co.il>
> To: "Arnout Vandecappelle" <arnout@mind.be>
> Cc: "Carlos Santos" <casantos@datacom.ind.br>, "guilherme machado" <guilherme.machado@datacom.ind.br>, "buildroot"
> <buildroot@buildroot.org>
> Sent: Thursday, February 4, 2016 3:21:32 AM
> Subject: Re: [Buildroot] Why is libbsd limited to ARM, x86 and x86_64?

> Hi Carlos, Arnout,
> 
> On Thu, Feb 04, 2016 at 01:00:14AM +0100, Arnout Vandecappelle wrote:
>> On 03-02-16 19:50, Carlos Santos wrote:
>> > 2. I'm absolutely ignorant about nios2. What defconfig should I use to
>> > build for it?
>> 
>>  Hm, looks like we don't have a nios2 defconfig... But you can do a very quick
>> build-test by setting arch to nios2 and selecting the Sourcery toolchain.
> 
> You can also use the config at
> http://autobuild.buildroot.net/toolchains/configs/br-nios2-glibc.config.

OK, I was able to build libbsd and its dependent packages (libedit and netcat-openbsd) using br-nios2-glibc.config, as well as the following defconfigs: (some of them modified to use glibc instead of uClibc):

- qemu_aarch64_virt
- qemu_mips64_malta
- qemu_mips64el_malta
- qemu_mips_malta
- qemu_mipsel_malta
- qemu_sh4_r2d
- qemu_sparc64_sun4u
- qemu_sparc_ss10

The compilation for microblaze failed using br-microblazeel-full.config, taken from the autobuilder (build log saved at http://ur1.ca/ohak2). It also failed, for similar reasons using the existing defconfig's:

- qemu_microblazebe_mmu
- qemu_microblazeel_mmu
'
The compilation also failed using qemu_sh4eb_r2d_defconfig but I don't think it is a valid test, since I forced BR2_TOOLCHAIN_BUILDROOT_GLIBC to "y".

So I think I should disable libbsd for the microblaze architecture, at least for the moment.

Carlos Santos (Casantos)
DATACOM, P&D

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

end of thread, other threads:[~2016-02-04 12:22 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-02-02 15:30 [Buildroot] Why is libbsd limited to ARM, x86 and x86_64? Carlos Santos
2016-02-02 21:09 ` Arnout Vandecappelle
2016-02-03 15:39   ` Carlos Santos
2016-02-03 18:50     ` Carlos Santos
2016-02-04  0:00       ` Arnout Vandecappelle
2016-02-04  5:21         ` Baruch Siach
2016-02-04 12:22           ` Carlos Santos

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.