A question about the share files!

In many embedded project there are a lot of share files needed by the program.
I have got one question puzzled: does defferent platform has different version of share files of their own?
For example, I have got the Berkeley DB source code. Compiling it under X86 platform and some .so files were generated. Then if i want to cross-compile my project to a MIPS platform. Do I need to regenerate new .so files for MIPS platform ,or just use a tanslater program to translater the X86 .so files to MIPS instructions.

Also I have the same question about the executable files. ‘ls’ is a executable files in X86 platform. If i want my image have this function,only simply add it in the makefile.If my target is a MIPS platform, then which version of ‘ls’ is included in the image: the x86 version or a special MIPS version.

                                                  Thanks,^-^ :smiley:

Yes, you need to generate the shared objects (*.so) and the executables for each architecture you are using them on.