Question

I am using Ubuntu 12.04 64bit and I am getting the following error while compiling a Qt project which needs a 32bit .so file.

error: skipping incompatible /opt/lib/libEposCmd.so when searching for -lEposCmd

I want to compile this project with -m32 option but I don't know where should I insert this option.

Was it helpful?

Solution

Problem Solved through below instruction:

  • installing g++-multilib, libstdc++.i386, libgcc.i386, glibc-devel.i386, gcc-c++-32bit
  • edite make file and adjust below config:

    cc = add -m32
    CFLAGS = add -m32
    INCPATH = linux-g++-32
    LFLAGS = -m32 -w1, -o1
    LIBS = i386-linux-gnu
    
  • make softlink of

    /usr/lib/i386-GNU-linux/libQtCore.so.4.1
                        libQtGui.....
                        libQtXmlPattern..
                        libQtXml.....
    

    to lib .... .so.o then to lib .... .so make clean and compile

OTHER TIPS

Use string command to see the values inside the .so file . And check the values

for eg string /opt/lib/libEposCmd.so

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