1 |
Nikos Chantziaras <realnc@×××××.de> posted ghnsoh$ubf$1@×××××××××.org, |
2 |
excerpted below, on Wed, 10 Dec 2008 09:57:08 +0200: |
3 |
|
4 |
> Branko Badrljica wrote: |
5 |
>> gcc -O2 -m32 -march=barcelona -pipe -L/usr/lib64 -lgdgeda -o tt tt.c |
6 |
>> (libgdgeda has just .so ) |
7 |
> |
8 |
> -m32 generates 32-bit code. /usr/lib64 is only for 64-bit binaries. |
9 |
> Don't use -m32. |
10 |
|
11 |
That's absolutely correct as far as it goes, but may miss the point. |
12 |
|
13 |
Presumably, the OP is trying to compile 32-bit code, thus the -m32. Does |
14 |
that nVidia stuff even support 64-bit? If he's trying to do 64-bit |
15 |
compiles, then you are right, kill that -m32. If he's trying to do 32- |
16 |
bit compiles, he must link to 32-bit libs, not the 64-bit libs he's |
17 |
trying to link to at present. |
18 |
|
19 |
Keep in mind that Gentoo's 32-bit side of multilib is rather limited. In |
20 |
general, it's designed to work with pre-built binaries, not for compiling |
21 |
32-bit, altho trivial 32-bit programs only using glibc and (for C++) |
22 |
libstdc++ (part of gcc) should be compilable. |
23 |
|
24 |
If you're going to be doing a lot of 32-bit compilation, the suggested |
25 |
solution is to use a 32-bit chroot in which you start from a standard 32- |
26 |
bit stage tarball and build most of an entire 32-bit Gentoo installation |
27 |
(sans kernel and services that are provided by the 64-bit side). It |
28 |
works and is in some ways much more in keeping with the normal Gentoo |
29 |
build-from-sources spirit, but it's a LOT more work than just running a |
30 |
standard multilib system so you can run the occasional 32-bit-only |
31 |
binary. |
32 |
|
33 |
Here's the Gentoo/amd64 32-bit chroot HOWTO: |
34 |
http://www.gentoo.org/proj/en/base/amd64/howtos/chroot.xml |
35 |
|
36 |
-- |
37 |
Duncan - List replies preferred. No HTML msgs. |
38 |
"Every nonfree program has a lord, a master -- |
39 |
and if you use the program, he is your master." Richard Stallman |