Contact us for instructions on building from 64-bit powerpredhat to 32-bit powerpredhat

Asked 2 years ago, Updated 2 years ago, 170 views

I want to install 32-bit odbc with 64-bit odbc binary, but it keeps building with 64-bit.

./configure --prefix=$HOME/unixODBC --sysconfdir=$HOME/unixODBC/etc --build=ppc32-pc-linux-gnu --host=ppc64-pc-linux-gnu

Checking build system type... Invalid configuration ppc32-pc-linux-gnu': machineppc32-pc' not recognized It says that it does not recognize ppc32 as follows, and when you insert only ppc, it builds to 64 bits.

If you know how to build from 64-bit powerpredhat to 32-bit with the configure file, please answer.

for reference http://stackoverflow.com/questions/1272357/how-to-compile-a-32-bit-binary-on-a-64-bit-linux-machine-with-gcc-cmake

http://stackoverflow.com/questions/13756674/how-to-build-static-32bit-binary-on-64bit-machine-os-with-configure-script

powerpc crosscompile build

2022-09-22 22:06

1 Answers

For gcc -mXX ( -m32, -m64, ... ) Options are options that you adjust.

When configuring, try to include -m32 in CFLAGS or CXXFLAGS options.

For C source

CFLAGS="-m32 <Other C compilation options>"./configure....

For C++ sources

CXXLAGS="-m32 <Other C++ Compilation Options>"./configure....

If C and C++ are mixed

CFLAGS="-m32 <Other Ccompile Options>" CXXLAGS="-m32 <Other C++ Compile Options>"./configure....

And if the purpose is to run the compilation results on that machine, I think it's certain to build it static. Most configurations provide build options such as --enable-static, --disable-static, --enable-shared, --disable-shared.

CFLAGS="-m32 <Other Options>"./configure --enable-static ...

Or

CFLAGS="-m32 <Other Options>" ./configure --enable-static --disable-static ...

And the libraries that you need for compilation are compiled in 32 bits.

Try it as above.


2022-09-22 22:06

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.