Re: Newbie new to the list

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 23 February 2011 05:29, [p e r c e p t i c o n]
<percepticon@xxxxxxxxx> wrote:
> hi again,
>
> ok, last week i mysteriously got it to compile my shared lib.  this week
> however, the errors returned even though i'm doing the exact same thing.
> here's the message:

Obviously you're not doing exactly the same thing, or you'd get the
same results.

> g++   -fPIC -DUNIX -D_REENTRANT -I. -I./../include  AuthModule.cpp -c -o
> sampleAuth/AuthModule.o

No -m32 here, so the output file is 64-bit

> g++ -shared -m32 -lstdc++ -o ./sampleAuth/AuthModule.so
> ./sampleAuth/AuthModule.o

-m32 here, requesting 32-bit output

> /usr/bin/ld: warning: i386:x86-64 architecture of input file
> `./sampleAuth/AuthModule.o' is incompatible with i386 output

It's telling you that AuthModule.o cannot be linked into a 32-bit
file, because it's 64-bit.

> i set LD_LIBRARY_PATH in my env vars to point to the 32bit libs...
> i also set LDFLAGS to -L/path/to/32bitlibs
> it's also tellimg me that it std::basic_string is not defined even though as
> you can see above i'm linking the std lib...

Have you used #include <string> ?



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux