Below there is an explanation of configure parameters for:
./configure --cc-prefix=~/OpenWrt-SDK-Linux-i686-1/staging_dir_mipsel/bin/mipsel-linux-uclibc- --little-endian \
--cc-options="-fno-builtin -nostdinc++ -nodefaultlibs -Os" --ld-options="-luClibc++ -lm" --disable-adns
1. --cc-prefix
--cc-prefix=~/OpenWrt-SDK-Linux-i686-1/staging_dir_mipsel/bin/mipsel-linux-uclibc-
This option tells configure script use different compiler than the default, in this case instead of using
g++, compiler from build environment will be used.
Each call to a compiler will be prefixed with
~/OpenWrt-SDK-Linux-i686-1/staging_dir_mipsel/bin/mipsel-linux-uclibc-, so in our case
~/OpenWrt-SDK-Linux-i686-1/staging_dir_mipsel/bin/mipsel-linux-uclibc-g++ will be called. Which of course exists in the system:
grusin@it:~$ ls -al ~/OpenWrt-SDK-Linux-i686-1/staging_dir_mipsel/bin/mipsel-linux-uclibc-g++
-rwxr-xr-x 1 grusin grusin 281819 2007-01-30 17:43 /home/grusin/OpenWrt-SDK-Linux-i686-1/staging_dir_mipsel/bin/mipsel-linux-uclibc-g++
and points to a compiler from the build environment.
NOTE: Each build environment will probably require different cc_prefix.
2. --little-endian, --big-endian
--little-endian
This options tells configure script to configure cryptographic support for machine with little endian processor.
NOTE: You should check what kind of endian does CPU in your router have, in case of having router with big endian CPU pass --big-endian instead of --little-endian.
3. --cc-options
--cc-options="-fno-builtin -nostdinc++ -nodefaultlibs -Os"
This line forces passing "-fno-builtin -nostdinc++ -nodefaultlibs -Os" compile options to the compiler.
NOTE: You should check what compiler options are needed for building software for your router's linux distribution. In case of openwrt, those should work :)
4. --ld-options
--ld-options="-luClibc++ -lm"
This line forces linker to link with micro c++ library and math library.
NOTE: You should check what linker options are needed.
5. --disable-adns
--disable-adns
This options forces configure script to disable asynchronous dns support. If you do not pass this option bot will be built with adns support and it will require libpthread to be instilled on your router. It is advised to disable this option, because adns support consumes a lot of memory.