* [gentoo-amd64] Best plan for cross compiling for i686
@ 2006-08-05 21:08 Richard Fish
2006-08-05 21:48 ` Thierry de Coulon
` (3 more replies)
0 siblings, 4 replies; 9+ messages in thread
From: Richard Fish @ 2006-08-05 21:08 UTC (permalink / raw
To: gentoo-amd64
I have an AMD64 desktop/server system (amd64 arch) that I would like
to use for cross-compiling packages for my i686 laptop. The problem
isn't that my laptop is slow, just that I use it for real work, and
pretend work, so I would like to reduce the amount of time and risk
involved in keeping it up to date.
So far I have tried two methods:
1. crossdev. This method works for compiling some packages with:
ROOT=/mnt/path PORTAGE_CONFIGROOT=/mnt/path emerge <pkg>
But it doesn't work for deep world updates (emerge -DNuv world), as
portage ends up using the make.conf from the host, not target. I also
have some problems with portage using the hosts package database.
Even when building specific packages, there seem to be many packages
that fail to link, or run things like freetype-config or kde-config to
determine paths for libraries and include files and the like, and that
doesn't work right when cross-compiling.
2. chroot. I created a chroot environment by copying the actual / and
/var filesystems from my laptop, so I could use the actual 32-bit
toolchain and package database for my laptop. This works better, as I
can at least start deep world updates, and I don't have the link or
*-config issues with the crossdev method. The big problem here is
packages that use uname or /bin/arch commands to determine the
architecture. Since the kerrnel the chroot is running on is still for
the amd64 arch, these packages get the idea that they can compile
64-bit code, which of course fails miserably with a 32-bit compiler.
My current options for making this really are to either setup a
virtual machine with something like vmware-server, so that I actually
boot the i686 kernel. I would probably try to use an nfs-root for
this. Or I can convert my box to an x86 profile, which should also
fix my problems with chroot environment. But of course I would lose
any ability to play around with the 64-bit stuff, and the ability to
file bugs against the packages that (wrongly) look at uname/arch
output.
So does anybody have an AMD64-to-i686 cross-compiling environment that
they are happy with?
-Richard
--
gentoo-amd64@gentoo.org mailing list
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [gentoo-amd64] Best plan for cross compiling for i686
2006-08-05 21:08 [gentoo-amd64] Best plan for cross compiling for i686 Richard Fish
@ 2006-08-05 21:48 ` Thierry de Coulon
2006-08-05 22:27 ` Richard Fish
2006-08-05 23:33 ` Peter Hoff
` (2 subsequent siblings)
3 siblings, 1 reply; 9+ messages in thread
From: Thierry de Coulon @ 2006-08-05 21:48 UTC (permalink / raw
To: gentoo-amd64
On Saturday 05 August 2006 23.08, Richard Fish wrote:
> this. Or I can convert my box to an x86 profile, which should also
> fix my problems with chroot environment. But of course I would lose
> any ability to play around with the 64-bit stuff, and the ability to
> file bugs against the packages that (wrongly) look at uname/arch
> output.
I don't know much about these things but what about installing a second system
(x86) on your desktop just to do this job?
Thierry
--
gentoo-amd64@gentoo.org mailing list
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [gentoo-amd64] Best plan for cross compiling for i686
2006-08-05 21:48 ` Thierry de Coulon
@ 2006-08-05 22:27 ` Richard Fish
0 siblings, 0 replies; 9+ messages in thread
From: Richard Fish @ 2006-08-05 22:27 UTC (permalink / raw
To: gentoo-amd64
On 8/5/06, Thierry de Coulon <tcoulon@decoulon.ch> wrote:
> On Saturday 05 August 2006 23.08, Richard Fish wrote:
> > this. Or I can convert my box to an x86 profile, which should also
> > fix my problems with chroot environment. But of course I would lose
> > any ability to play around with the 64-bit stuff, and the ability to
> > file bugs against the packages that (wrongly) look at uname/arch
> > output.
>
> I don't know much about these things but what about installing a second system
> (x86) on your desktop just to do this job?
You mean dual-boot it? I guess that would be possible, although it
isn't just my desktop, but also my home network server for dhcp, ntp,
file sharing, etc. So to make it capable of running all of those
things as either x86 or amd64 would just about double the
administration I'd have to do with that box. I think it would
probably end up as just pure x86 before long...
But thanks anyway!
-Richard
--
gentoo-amd64@gentoo.org mailing list
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [gentoo-amd64] Best plan for cross compiling for i686
2006-08-05 21:08 [gentoo-amd64] Best plan for cross compiling for i686 Richard Fish
2006-08-05 21:48 ` Thierry de Coulon
@ 2006-08-05 23:33 ` Peter Hoff
2006-08-06 18:05 ` Paul de Vrieze
2006-08-05 23:47 ` [gentoo-amd64] " Duncan
2006-08-06 0:01 ` [gentoo-amd64] " Brian Litzinger
3 siblings, 1 reply; 9+ messages in thread
From: Peter Hoff @ 2006-08-05 23:33 UTC (permalink / raw
To: gentoo-amd64
[-- Attachment #1: Type: text/plain, Size: 2614 bytes --]
----- Original Message ----
From: Richard Fish <bigfish@asmallpond.org>
To: gentoo-amd64@lists.gentoo.org
Sent: Saturday, August 5, 2006 2:08:25 PM
Subject: [gentoo-amd64] Best plan for cross compiling for i686
I have an AMD64 desktop/server system (amd64 arch) that I would like
to use for cross-compiling packages for my i686 laptop. The problem
isn't that my laptop is slow, just that I use it for real work, and
pretend work, so I would like to reduce the amount of time and risk
involved in keeping it up to date.
So far I have tried two methods:
1. crossdev. This method works for compiling some packages with:
ROOT=/mnt/path PORTAGE_CONFIGROOT=/mnt/path emerge <pkg>
But it doesn't work for deep world updates (emerge -DNuv world), as
portage ends up using the make.conf from the host, not target. I also
have some problems with portage using the hosts package database.
Even when building specific packages, there seem to be many packages
that fail to link, or run things like freetype-config or kde-config to
determine paths for libraries and include files and the like, and that
doesn't work right when cross-compiling.
2. chroot. I created a chroot environment by copying the actual / and
/var filesystems from my laptop, so I could use the actual 32-bit
toolchain and package database for my laptop. This works better, as I
can at least start deep world updates, and I don't have the link or
*-config issues with the crossdev method. The big problem here is
packages that use uname or /bin/arch commands to determine the
architecture. Since the kerrnel the chroot is running on is still for
the amd64 arch, these packages get the idea that they can compile
64-bit code, which of course fails miserably with a 32-bit compiler.
My current options for making this really are to either setup a
virtual machine with something like vmware-server, so that I actually
boot the i686 kernel. I would probably try to use an nfs-root for
this. Or I can convert my box to an x86 profile, which should also
fix my problems with chroot environment. But of course I would lose
any ability to play around with the 64-bit stuff, and the ability to
file bugs against the packages that (wrongly) look at uname/arch
output.
So does anybody have an AMD64-to-i686 cross-compiling environment that
they are happy with?
-Richard
--
gentoo-amd64@gentoo.org mailing list
Have you thought about using Xen to create a virtual copy of your laptop on your server? I have no idea if it would actually work, or to what extent it's possible to virtualize the 'hardware', but it might be worth looking into.
[-- Attachment #2: Type: text/html, Size: 3266 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* [gentoo-amd64] Re: Best plan for cross compiling for i686
2006-08-05 21:08 [gentoo-amd64] Best plan for cross compiling for i686 Richard Fish
2006-08-05 21:48 ` Thierry de Coulon
2006-08-05 23:33 ` Peter Hoff
@ 2006-08-05 23:47 ` Duncan
2006-08-06 0:33 ` Richard Fish
2006-08-06 0:01 ` [gentoo-amd64] " Brian Litzinger
3 siblings, 1 reply; 9+ messages in thread
From: Duncan @ 2006-08-05 23:47 UTC (permalink / raw
To: gentoo-amd64
"Richard Fish" <bigfish@asmallpond.org> posted
7573e9640608051408i5d4db55bi526fb4ba03771a20@mail.gmail.com, excerpted
below, on Sat, 05 Aug 2006 14:08:25 -0700:
> 2. chroot. I created a chroot environment by copying the actual / and
> /var filesystems from my laptop, so I could use the actual 32-bit
> toolchain and package database for my laptop. This works better, as I
> can at least start deep world updates, and I don't have the link or
> *-config issues with the crossdev method. The big problem here is
> packages that use uname or /bin/arch commands to determine the
> architecture. Since the kerrnel the chroot is running on is still for
> the amd64 arch, these packages get the idea that they can compile
> 64-bit code, which of course fails miserably with a 32-bit compiler.
With a bit of a disclaimer that I've no personal experience with this,
only have read the list and documentation, so I'll be of little help with
details...
Have you read the amd64 chroot guide? If not, read it, as that's
basically what you want to do. You got the idea right; you can jump-start
with what's on the laptop copied over if desired, but AFAICT, you missed
one little bit -- the command to change your uname to x86 so those
packages don't mess up.
Depending on how you set it up, you can run the 32-bit environment on the
amd64 for stuff like 32-bit-binary-only plugins and the like, too. It's
also possible, but not manditory, to set it up as a full dual-boot so you
can boot either x86 or amd64.
I'm about to head to work so won't bother looking up the chroot guide link
ATM, but it's linked from the gentoo/amd64 project site, AFAIK. If you
have trouble finding it, post again and I'm sure someone will give you a
more direct link.
--
Duncan - List replies preferred. No HTML msgs.
"Every nonfree program has a lord, a master --
and if you use the program, he is your master." Richard Stallman
--
gentoo-amd64@gentoo.org mailing list
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [gentoo-amd64] Best plan for cross compiling for i686
2006-08-05 21:08 [gentoo-amd64] Best plan for cross compiling for i686 Richard Fish
` (2 preceding siblings ...)
2006-08-05 23:47 ` [gentoo-amd64] " Duncan
@ 2006-08-06 0:01 ` Brian Litzinger
2006-08-06 0:39 ` Richard Fish
3 siblings, 1 reply; 9+ messages in thread
From: Brian Litzinger @ 2006-08-06 0:01 UTC (permalink / raw
To: gentoo-amd64
On Sat, Aug 05, 2006 at 02:08:25PM -0700, Richard Fish wrote:
> I have an AMD64 desktop/server system (amd64 arch) that I would like
> to use for cross-compiling packages for my i686 laptop. The problem
> isn't that my laptop is slow, just that I use it for real work, and
> pretend work, so I would like to reduce the amount of time and risk
> involved in keeping it up to date.
I have to admit I have such an environment. Native AMD 64bit machines
(Dual Opteron and Athlon X2) with cross devs to i686 for Pentium M
machines, and C3 for a VIA epia boards.
I do not recall having any issues except:
1. OpenSSL required some hack
2. Had to make sure to compile kernels with 'make ARCH=...'
It may be I have simply not run into any other packages with
uname dependencies.
Oh wait, there was the ivtv driver. I think they fixed the problem
when I complained.
What packages are giving you trouble?
--
brian
--
gentoo-amd64@gentoo.org mailing list
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [gentoo-amd64] Re: Best plan for cross compiling for i686
2006-08-05 23:47 ` [gentoo-amd64] " Duncan
@ 2006-08-06 0:33 ` Richard Fish
0 siblings, 0 replies; 9+ messages in thread
From: Richard Fish @ 2006-08-06 0:33 UTC (permalink / raw
To: gentoo-amd64
On 8/5/06, Duncan <1i5t5.duncan@cox.net> wrote:
> Have you read the amd64 chroot guide? If not, read it, as that's
Um, er....no.
> one little bit -- the command to change your uname to x86 so those
> packages don't mess up.
Yep, I missed the linux32/setarch trick.
I have a pretty major KDE update compiling now, after which I will
probably do the linux32 thing and start an emerge -ev world in the
chroot to see what breaks.
Thanks Duncan for pointing out that I should have RTFM!!
-Richard
--
gentoo-amd64@gentoo.org mailing list
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [gentoo-amd64] Best plan for cross compiling for i686
2006-08-06 0:01 ` [gentoo-amd64] " Brian Litzinger
@ 2006-08-06 0:39 ` Richard Fish
0 siblings, 0 replies; 9+ messages in thread
From: Richard Fish @ 2006-08-06 0:39 UTC (permalink / raw
To: gentoo-amd64
On 8/5/06, Brian Litzinger <brian@worldcontrol.com> wrote:
> What packages are giving you trouble?
Well klibc needs the same ARCH trick as the kernel, but the ARCH
variable was getting filtered by the ebuild. There was another
package (firefox? thunderbird? seamonkey?) that failed trying to
enable some 64-bit code. Those were just the ones I found with normal
updates, not trying to do an emerge -ev world or anything.
I missed the setarch/linux32 trick, and I think that will fix these problems.
Thanks,
-Richard
--
gentoo-amd64@gentoo.org mailing list
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [gentoo-amd64] Best plan for cross compiling for i686
2006-08-05 23:33 ` Peter Hoff
@ 2006-08-06 18:05 ` Paul de Vrieze
0 siblings, 0 replies; 9+ messages in thread
From: Paul de Vrieze @ 2006-08-06 18:05 UTC (permalink / raw
To: gentoo-amd64
[-- Attachment #1: Type: text/plain, Size: 824 bytes --]
On Sunday 06 August 2006 01:33, Peter Hoff wrote:
> -Richard
> --
> gentoo-amd64@gentoo.org mailing list
>
>
> Have you thought about using Xen to create a virtual copy of your laptop on
> your server? I have no idea if it would actually work, or to what extent
> it's possible to virtualize the 'hardware', but it might be worth looking
> into.
Peter,
would you next time reply above the "-- " line and quote properly (put "> " in
front of each line). The "-- " line marks the signature of the sender. People
are used to not look below it. As such I first thought you just hit the reply
button but didn't send a message. The Xen part looks to be the signature of
Richard, not your message.
Paul
--
Paul de Vrieze
Gentoo Developer
Mail: pauldv@gentoo.org
Homepage: http://www.devrieze.net
[-- Attachment #2: Type: application/pgp-signature, Size: 200 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2006-08-06 18:07 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-08-05 21:08 [gentoo-amd64] Best plan for cross compiling for i686 Richard Fish
2006-08-05 21:48 ` Thierry de Coulon
2006-08-05 22:27 ` Richard Fish
2006-08-05 23:33 ` Peter Hoff
2006-08-06 18:05 ` Paul de Vrieze
2006-08-05 23:47 ` [gentoo-amd64] " Duncan
2006-08-06 0:33 ` Richard Fish
2006-08-06 0:01 ` [gentoo-amd64] " Brian Litzinger
2006-08-06 0:39 ` Richard Fish
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox