All of lore.kernel.org
 help / color / mirror / Atom feed
* Newbie questions on cross-building packages for PPC
@ 2019-02-23 21:14 Philip Prindeville
  2019-02-24 13:33 ` Alexander Kanavin
  0 siblings, 1 reply; 2+ messages in thread
From: Philip Prindeville @ 2019-02-23 21:14 UTC (permalink / raw)
  To: yocto

Hi.

I’ve worked on a lot of embedded projects involving cross-building (like AstLinux and OpenWrt), but I’m new to Yocto so please bear with the noob questions.

I’d like to build packages (mostly RPM’s, plus a Linux kernel or three) on an x86_64 (AMD64) Linux (CentOS 7.6) platform, but for e500v2 and 85xxDP PPC targets.

What do I need to do to set up a toolchain and environment to be able to do that?

Ideally, I’d also like to set up an RPM target so I could use “rpmbuild --target e500v2-unknown-linux” (or whatever) and it would use the correct compiler, linker, archiver, sysheaders, etc.

Advice on both of these, or just pointers to instructions on how to set it all up, would be great.

For instance, do I need one compiler only that can handle multiple processor variants via the --march= flag, or is this not the right way to go?  And similarly, since the linker can rewrite code (shortening branch offsets, peep-hole optimization, unreachable code removal, etc.) do I need different linker versions for the 2 PPC variants?

Thanks,

-Philip



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

* Re: Newbie questions on cross-building packages for PPC
  2019-02-23 21:14 Newbie questions on cross-building packages for PPC Philip Prindeville
@ 2019-02-24 13:33 ` Alexander Kanavin
  0 siblings, 0 replies; 2+ messages in thread
From: Alexander Kanavin @ 2019-02-24 13:33 UTC (permalink / raw)
  To: Philip Prindeville; +Cc: Yocto discussion list

On Sat, 23 Feb 2019 at 22:18, Philip Prindeville
<philipp_subx@redfish-solutions.com> wrote:
> I’ve worked on a lot of embedded projects involving cross-building (like AstLinux and OpenWrt), but I’m new to Yocto so please bear with the noob questions.
>
> I’d like to build packages (mostly RPM’s, plus a Linux kernel or three) on an x86_64 (AMD64) Linux (CentOS 7.6) platform, but for e500v2 and 85xxDP PPC targets.
>
> What do I need to do to set up a toolchain and environment to be able to do that?

First, you need to figure out which BSP layer provides support for
your targets. What boards are you targeting?

> Ideally, I’d also like to set up an RPM target so I could use “rpmbuild --target e500v2-unknown-linux” (or whatever) and it would use the correct compiler, linker, archiver, sysheaders, etc.
>
> Advice on both of these, or just pointers to instructions on how to set it all up, would be great.

I'd suggest you start with the yocto quickstart guide, so you'll know
the basic procedures.
https://www.yoctoproject.org/docs/latest/brief-yoctoprojectqs/brief-yoctoprojectqs.html

> For instance, do I need one compiler only that can handle multiple processor variants via the --march= flag, or is this not the right way to go?  And similarly, since the linker can rewrite code (shortening branch offsets, peep-hole optimization, unreachable code removal, etc.) do I need different linker versions for the 2 PPC variants?

This is what BSP layers do, they define a target machine (which
includes compiler and linker settings), and give it a name. Then you
place that name in your configuration file, and the target build
process will sort itself out.

Alex


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

end of thread, other threads:[~2019-02-24 13:33 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-23 21:14 Newbie questions on cross-building packages for PPC Philip Prindeville
2019-02-24 13:33 ` Alexander Kanavin

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.