Source : nss-3.12.5-with-nspr-4.8.2
Path : /home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2
1.Build for X86 first
make build_coreconf
cd ../../nsprpub
./configure --with-dist-prefix='/home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/../../dist/Linux2.6_x86_glibc_PTH_DBG.OBJ' --with-dist-includedir='/home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/../../dist/Linux2.6_x86_glibc_PTH_DBG.OBJ/include' --cache-file=/dev/null
make
cd ../security/nss/
make build_dbm
make
2.Build for ARM
Build arm
Modify ../coreconf/arch.mk
Set
OS_TEST := arm
Modify ../coreconf/Linux.mk
CC = arm-none-linux-gnueabi-gcc
CCC = arm-none-linux-gnueabi-g++
RANLIB = arm-none-linux-gnueabi-ranlib
cd ../../nsprpub
CC=arm-none-linux-gnueabi-gcc AR=arm-none-linux-gnueabi-ar RANLIB=arm-none-linux-gnueabi-ranlib ./configure --target=arm-linux --with-dist-prefix='/home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/../../dist/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ' --with-dist-includedir='/home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/../../dist/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ/include' --cache-file=/dev/null
make
cd ../security/nss/
make build_dbm
make
Then there's error
make[3]: Leaving directory `/home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/mangle'
cd Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ ; sh /home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/./sign.sh /home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/../../../../dist/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ \
/home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ Linux \
/home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/../../../../dist/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ/lib /home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/../../../../dist/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ/lib/libsoftokn3.so
/home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ/shlibsign -v -i /home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/../../../../dist/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ/lib/libsoftokn3.so
/home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ/shlibsign: 1: Syntax error: word unexpected (expecting ")")
make[2]: *** [../../../../dist/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ/lib/libsoftokn3.chk] Error 2
make[2]: Leaving directory `/home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign'
make[1]: *** [libs] Error 2
make[1]: Leaving directory `/home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd'
make: *** [libs] Error 2
很明顯是無法執行shlibsign,把X86 build的binary拿來取代就行
cd cmd/shlibsign/
cp Linux2.6_x86_glibc_PTH_DBG.OBJ/shlibsign Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ/
cd ../..
繼續
make
make[3]: Leaving directory `/home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/mangle'
cd Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ ; sh /home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/./sign.sh /home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/../../../../dist/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ \
/home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ Linux \
/home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/../../../../dist/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ/lib /home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/../../../../dist/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ/lib/libsoftokn3.so
/home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ/shlibsign -v -i /home/gigijoe/OMAP3530/MSN/nss-3.12.5-with-nspr-4.8.2/mozilla/security/nss/cmd/shlibsign/../../../../dist/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ/lib/libsoftokn3.so
shlibsign: shlibsign.c:772: main: Assertion `lib != ((void *)0)' failed.
Aborted
應該也是相同的問題,換成X86 build的library
cd ../../dist/Linux2.6_arm_arm-none-linux-gnueabi-gcc_glibc_PTH_DBG.OBJ/lib
cp -a ../../Linux2.6_x86_glibc_PTH_DBG.OBJ/lib/libsoftokn* .
cd ../../../security/nss/
make
完成囉
沒有留言:
張貼留言