Question

I've downloaded MinGW from this link x64-4.8.1-posix-sjlj-rev1 but when I try to build for x86 target I've lots of linkage errors... seems that only x64 lib are installed...

I've need to build for x86 and x64 platforms on windows... Have I to download both x64 and x86 or are some simpler ways?

Edit I'm using eclipse keplero as IDE I've tryed to build myself a simple hello world program with g++ -m32 -std=c++11 test.cpp -o test32.exe and g++ -m64 -std=c++11 test.cpp -o test64.exe. And all is ok... So the problem was with eclipse... After a little a discovered that I need to use MYSY ( set in PATH ) and set -m32 also in the c++ linkage options...

Now all is fine.

I've also tryed to use NetBeans C++ as IDE... seems a gread IDE!!!

Was it helpful?

Solution

It is not multilib enabled. That's why you are not able to compile 32-bit(x86) program. You can get multilib enabled toolchain from following link:

For 64-bit machine: 64-Bit

For 32-bit machine: 32-Bit

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top