version 1.2.4.9, 2012/10/09 11:29:24
|
version 1.9.2.7, 2017/06/19 21:24:49
|
Line 32 fi
|
Line 32 fi
|
|
|
clean_romfs() |
clean_romfs() |
{ |
{ |
echo "+++ Clean ELWIX RomFS firmware ..." | echo "+++ Clean ELWIX RomFS firmware ... $ROMFS" |
chflags -Rf noschg $ROMFS |
chflags -Rf noschg $ROMFS |
rm -rf $ROMFS |
rm -rf $ROMFS |
|
|
Line 42 clean_romfs()
|
Line 42 clean_romfs()
|
|
|
build_romfs() |
build_romfs() |
{ |
{ |
echo "+++ Build ELWIX RomFS directory ..." | echo "+++ Build ELWIX RomFS directory ... $ROMFS_USR" |
mkdir -p $ROMFS_USR |
mkdir -p $ROMFS_USR |
|
|
cd $ROMFS_USR |
cd $ROMFS_USR |
Line 54 build_romfs()
|
Line 54 build_romfs()
|
install -d libdata; |
install -d libdata; |
install -d libexec; |
install -d libexec; |
install -d share; |
install -d share; |
|
install -d share/keys; |
install -d share/misc; |
install -d share/misc; |
install -d share/skel; |
install -d share/skel; |
install -d share/zoneinfo; |
install -d share/zoneinfo; |
|
|
|
ln -s /elwix/local local; |
ln -s /elwix/pkg pkg; |
ln -s /elwix/pkg pkg; |
|
|
|
# special patch to ensuring properly working of passwd!!! |
|
ln -s /sbin/pwd_mkdb sbin; |
|
|
chown -hR root:wheel . |
chown -hR root:wheel . |
cd - |
cd - |
} |
} |
Line 75 install_romfs()
|
Line 80 install_romfs()
|
SKEL="${SHARE}/skel" |
SKEL="${SHARE}/skel" |
MISC="${SHARE}/misc" |
MISC="${SHARE}/misc" |
|
|
echo "+++ Install ELWIX RomFS software ..." | echo "+++ Install ELWIX RomFS software ... $ROMFS_USR" |
if [ -r ${BSDSRC}/release/picobsd/mfs_tree/etc/termcap ]; then |
if [ -r ${BSDSRC}/release/picobsd/mfs_tree/etc/termcap ]; then |
install -v -m 644 ${BSDSRC}/release/picobsd/mfs_tree/etc/termcap $MISC; |
install -v -m 644 ${BSDSRC}/release/picobsd/mfs_tree/etc/termcap $MISC; |
install -v -m 644 ${BSDSRC}/release/picobsd/mfs_tree/etc/services $MISC; |
install -v -m 644 ${BSDSRC}/release/picobsd/mfs_tree/etc/services $MISC; |
Line 90 install_romfs()
|
Line 95 install_romfs()
|
install -v ${CFGDIR}/root.skel/profile $SKEL/dot.profile; |
install -v ${CFGDIR}/root.skel/profile $SKEL/dot.profile; |
install -v ${CFGDIR}/root.skel/vimrc $SKEL/dot.vimrc; |
install -v ${CFGDIR}/root.skel/vimrc $SKEL/dot.vimrc; |
|
|
find ${WORLD}/lib -type f -name \*.so.\* -exec install {} $LIBS \; | find ${WORLD}/lib -type f -name \*.so.\* ! -name \*.debug -exec install {} $LIBS \; |
find ${WORLD}/lib -type f -name libalias_\*.so -exec install {} $LIBS \; |
find ${WORLD}/lib -type f -name libalias_\*.so -exec install {} $LIBS \; |
find ${WORLD}/lib/geom -type f -name \*.so -exec install {} $LIBS/geom \; |
find ${WORLD}/lib/geom -type f -name \*.so -exec install {} $LIBS/geom \; |
find ${WORLD}/usr/lib -type f -name \*.so.\* -exec install {} $LIBS \; | find ${WORLD}/usr/lib -type f -name \*.so.\* ! -name \*.debug -exec install {} $LIBS \; |
| find ${WORLD}/usr/lib/engines -type f -name \*.so -exec install {} $LIBS/engines \; |
|
|
InstallList ${ELWIX_ROMFS} ${WORLD} ${ROMFS} |
InstallList ${ELWIX_ROMFS} ${WORLD} ${ROMFS} |
|
|
Line 102 install_romfs()
|
Line 108 install_romfs()
|
InstallDir ${WORLD}/usr/local/lib $LIBS |
InstallDir ${WORLD}/usr/local/lib $LIBS |
InstallDir ${WORLD}/usr/local/libdata $LIBDATA |
InstallDir ${WORLD}/usr/local/libdata $LIBDATA |
|
|
install -d ${PKGDIR}/bin |
|
# InstallDir ${PKGDIR}/bin $BIN |
|
install -d ${PKGDIR}/sbin |
|
InstallDir ${PKGDIR}/sbin $SBIN |
|
|
|
InstallFiles \*.so\* ${PKG}/lib $LIBS |
|
InstallFiles \* ${PKG}/libexec $LIBEXEC |
|
InstallFiles \* ${PKG}/libdata $LIBDATA |
|
InstallFiles \* ${PKG}/bin $BIN |
|
InstallFiles \* ${PKG}/sbin $SBIN |
|
|
|
chown -R root:wheel $SBIN $BIN $LIBDATA $LIBEXEC $LIBS |
chown -R root:wheel $SBIN $BIN $LIBDATA $LIBEXEC $LIBS |
|
echo "+++ Completed ELWIX RomFS software ... $ROMFS_USR" |
} |
} |
|
|
build_image() |
build_image() |
{ |
{ |
echo "+++ Build ELWIX Firmware image ..." | echo "+++ Build ELWIX Firmware system image ... $ROMFS_USR --> ${REL}/${ROMFS_IMG}" |
|
|
cd ${ROMFS_USR} |
cd ${ROMFS_USR} |
pax -w -z -v -f${REL}/${ROMFS_IMG} . |
pax -w -z -v -f${REL}/${ROMFS_IMG} . |
|
cd - |
|
|
# Stop using uzip fs |
# Stop using uzip fs |
# makefs -ominfree=0,bsize=8192,fsize=1024,optimization=space -s${ROMFS_SIZE} \ |
# makefs -ominfree=0,bsize=8192,fsize=1024,optimization=space -s${ROMFS_SIZE} \ |
Line 133 build_image()
|
Line 130 build_image()
|
|
|
# mkuzip -s 8192 -o ${REL}/${ROMFS_IMG}.uzip ${REL}/${ROMFS_IMG}; |
# mkuzip -s 8192 -o ${REL}/${ROMFS_IMG}.uzip ${REL}/${ROMFS_IMG}; |
# mv ${REL}/${ROMFS_IMG}.uzip ${REL}/${ROMFS_IMG} |
# mv ${REL}/${ROMFS_IMG}.uzip ${REL}/${ROMFS_IMG} |
|
|
|
echo "+++ Completed ELWIX Firmware system image ... $ROMFS_USR --> ${REL}/${ROMFS_IMG}" |
} |
} |
|
|
### main() |
### main() |
clean_romfs | clean_romfs || exit 1 |
| build_romfs || exit 1 |
|
|
build_romfs | install_romfs || exit 1 |
install_romfs | build_image || exit 1 |
| |
build_image | |
|
|
echo "+++ Complete build ELWIX RomFS" |
echo "+++ Complete build ELWIX RomFS" |