dermesser / libsocket

The ultimate socket library for C and C++, supporting TCP, UDP and Unix sockets (DGRAM and STREAM) on Linux, FreeBSD, Solaris. See also my uvco library for a refreshed version!
https://borgac.net/~lbo/doc/libsocket/
Other
797 stars 195 forks source link

Cross-compiling discussion #67

Open minhdc opened 4 years ago

minhdc commented 4 years ago

I'm trying to cross compile this lib to run on multiple architecture like MIPS and ARM. If you guys have any decent suggestions, please discuss here.

ancloud-teach commented 4 years ago

I'm trying to cross compile this lib to run on multiple architecture like MIPS and ARM. If you guys have any decent suggestions, please discuss here.

It is my suggestion.


SET(CMAKE_C_COMPILER mipsel-openwrt-linux-gcc)
SET(CMAKE_CXX_COMPILER mipsel-openwrt-linux-g++)
SET(CMAKE_INSTALL_PREFIX "/home/sl/Engineer/tool/libsocket/out/Widora")

rm CMakeCache.txt CMakeFiles/ -rf

make && make install
dermesser commented 4 years ago

@ancloud-teach does this work well for you? If so, would you mind documenting it somewhere? Either as comments in the CMakeLists.txt or on a doxygen page, for example.