slitaz-modular diff initramfs/usr/bin/slitaz-modular @ rev 171
initramfs: Update local-mirror script and lighttpd config files. Support new /lib/libtaz.sh script.
author | Christopher Rogers <slaxemulator@gmail.com> |
---|---|
date | Tue Apr 24 18:55:39 2012 +0000 (2012-04-24) |
parents | c1efda801fa2 |
children | 06775c59c666 |
line diff
1.1 --- a/initramfs/usr/bin/slitaz-modular Fri Apr 15 21:04:12 2011 +0000 1.2 +++ b/initramfs/usr/bin/slitaz-modular Tue Apr 24 18:55:39 2012 +0000 1.3 @@ -8,11 +8,12 @@ 1.4 CDNAME="slitaz" 1.5 QUIET="y" 1.6 FORCE="y" 1.7 -export LABEL="slitaz_${1}_$(date +%Y%m)" 1.8 +export LABEL="slitaz_$1_$(date +%F)" 1.9 +VOLUME_ID="$LABEL" 1.10 PUBLISHER="Slitaz-$1" 1.11 APPLICATION="Slitaz-$1" 1.12 EXT="xz" 1.13 -COMPRESSION="xz -Xbcj x86" 1.14 +COMPRESSION="-comp xz -Xbcj x86" 1.15 WORKING="$PROFILE/working" 1.16 INITRAMFS="$WORKING/initramfs" 1.17 UNION="$WORKING/union" 1.18 @@ -42,8 +43,9 @@ 1.19 SOURCES_REPOSITORY="$LOCAL_REPOSITORY/src" 1.20 HG_LIST="flavors flavors-stable slitaz-base-files slitaz-boot-scripts \ 1.21 slitaz-configs slitaz-dev-tools slitaz-doc slitaz-doc-wiki-data slitaz-forge \ 1.22 - slitaz-modular slitaz-pizza slitaz-tools tazlito tazpanel tazpkg tazusb tazweb \ 1.23 - tazwok website wok wok-stable wok-tiny wok-undigest" 1.24 + slitaz-modular slitaz-pizza slitaz-tools slitaz-vz ssfs tazlito tazpanel \ 1.25 + tazpkg tazusb tazweb tazwok tiny-slitaz website wok wok-stable \ 1.26 + wok-tiny wok-undigest" 1.27 1.28 error () { echo -e "\033[1;31;40m!!! \033[1;37;40m$@\033[1;0m"; } 1.29 warn () { echo -e "\033[1;33;40m*** \033[1;37;40m$@\033[1;0m"; } 1.30 @@ -82,7 +84,7 @@ 1.31 1.32 look_for_dep() 1.33 { 1.34 - grep -m1 ^$1$'\t' $INCOMING_REPOSITORY/wok-depends.txt | \ 1.35 + grep -m1 ^$1$'\t' $INCOMING_REPOSITORY/depends.txt | \ 1.36 cut -f 2 | sed 's|^[ \t]*||g' | sed 's| |\n|g' | sed '/^$/d' 1.37 } 1.38 1.39 @@ -117,7 +119,7 @@ 1.40 1.41 info "Making bootable image" 1.42 cat "$BASEDIR/initramfs/initramfs.list" | grep -v "^#" | while read pkgname; do 1.43 - if [ ! -f ${INITRAMFS}/var/lib/tazpkg/installed/${pkgname}/files.list ]; then 1.44 + if [ ! -f ${INITRAMFS}${INSTALLED}/${pkgname}/files.list ]; then 1.45 tazpkg get-install $pkgname --root=$INITRAMFS | tee -a $LOG/initramfs.log 1.46 if [ ! $(grep -l "^${pkgname}$" $ISODIR/packages-order.txt) ]; then 1.47 echo "$pkgname" >> $ISODIR/packages-order.txt 1.48 @@ -197,7 +199,7 @@ 1.49 done 1.50 [ -d $CUR_DIR ] || mkdir $CUR_DIR 1.51 md5sum $PKGNAME.tazpkg > $PKGNAME/fs/$INSTALLED/$PACKAGE/pkgmd5 1.52 - create_module $PKGNAME/fs $CUR_DIR/$PKGNAME.$EXT /var/lib/tazpkg/installed 1.53 + create_module $PKGNAME/fs $CUR_DIR/$PKGNAME.$EXT $INSTALLED 1.54 fi 1.55 } 1.56 1.57 @@ -224,7 +226,7 @@ 1.58 # fi 1.59 #fi 1.60 [ -f "$2" ] && rm -f "$2" # overwrite, never append to existing file 1.61 - mksquashfs "$1" "$2" -b 256K -comp $COMPRESSION >/dev/null 1.62 + mksquashfs "$1" "$2" -b 256K $COMPRESSION >/dev/null 1.63 if [ $? -ne 0 ]; then return 1; fi 1.64 chmod a-wx "$2" # remove execute and write attrib 1.65 chmod a+r "$2" # add read for everyone 1.66 @@ -314,7 +316,7 @@ 1.67 fi 1.68 1.69 [ -d $INCOMING_REPOSITORY ] || mkdir -p $INCOMING_REPOSITORY 1.70 - tazwok gen-wok-db --WOK=$SLITAZ_DIR/repos/wok 1.71 + cooker gen-wok-db $SLITAZ_DIR/repos/wok-tank 1.72 1.73 local i 1.74 for flavors in $FLAVORS_LIST; do 1.75 @@ -328,56 +330,114 @@ 1.76 backup_pkg() { 1.77 if [ "${BACKUP_PACKAGES}" = "yes" ]; then 1.78 [ -d $PKGISO_DIR ] && rm -r $PKGISO_DIR 1.79 + [ -f $LOG/backup_pkg.log ] && rm -rf $LOG/backup_pkg.log 1.80 mkdir -p $PKGISO_DIR 1.81 - WOK=${HG_DIR}/wok/home/slitaz/repos/wok 1.82 info "Making cooking list based installed packages in union" 1.83 # this is to filter out packages build by get- 1.84 # packages that don't exist in repo or wok 1.85 - cat $ISODIR/packages-order.txt | while read pkg; do 1.86 + cat $ISODIR/packages-installed.list | while read pkg; do 1.87 if [ ! -f $WOK/$pkg/receipt ]; then 1.88 - sed -i "s|^${pkg}$||g" $ISODIR/packages-order.txt 1.89 + sed -i "s|$pkg||g" $ISODIR/packages-installed.list 1.90 fi 1.91 done 1.92 - tazwok gen-cooklist $ISODIR/packages-order.txt > $ISODIR/cookorder.list 1.93 - [ -f $INCOMING_REPOSITORY/wok-wanted.txt ] || tazwok gen-wok-db 1.94 + local pkg wanted rwanted pkg_VERSION incoming_pkg_VERSION cache_pkg_VERSION 1.95 + cook gen-cooklist $ISODIR/packages-installed.list > $ISODIR/cookorder.list 1.96 + [ -f $PKGS/fullco.txt ] || cook gen-wok-db $WOKHG 1.97 + cookorder=$ISODIR/cookorder.list 1.98 + [ "$BACKUP_ALL" = "yes" ] && cookorder=$PKGS/fullco.txt 1.99 + [ "$BACKUP_ALL" = "yes" ] && cp -a $cookorder $PKGISO_DIR/fullco.txt 1.100 + CACHE_REPOSITORY="$CACHE_DIR/$(cat /etc/slitaz-release)/packages" 1.101 + [ -f $PROFILE/list/backupall.banned ] && cp -a $PROFILE/list/backupall.banned $ISODIR/blocked 1.102 1.103 - CACHE_REPOSITORY="$CACHE_DIR/$(cat /etc/slitaz-release)/packages" 1.104 - 1.105 - cat $ISODIR/cookorder.list | grep -v "^#" | while read pkg; do 1.106 - rwanted=$(grep $'\t'$pkg$ $INCOMING_REPOSITORY/wok-wanted.txt | cut -f 1) 1.107 + cat $cookorder | grep -v "^#" | while read pkg; do 1.108 + [ -f "$WOK/$pkg/receipt" ] || continue 1.109 + unset rwanted pkg_VERSION incoming_pkg_VERSION cache_pkg_VERSION 1.110 + rwanted=$(grep $'\t'$pkg$ $PKGS/wanted.txt | cut -f 1) 1.111 pkg_VERSION="$(grep -m1 -A1 ^$pkg$ $PACKAGES_REPOSITORY/packages.txt | \ 1.112 tail -1 | sed 's/ *//')" 1.113 incoming_pkg_VERSION="$(grep -m1 -A1 ^$pkg$ $INCOMING_REPOSITORY/packages.txt | \ 1.114 tail -1 | sed 's/ *//')" 1.115 + cache_pkg_VERSION="$(grep -m1 -A1 ^$pkg$ $LOCALSTATE/packages.txt | \ 1.116 + tail -1 | sed 's/ *//')" 1.117 for wanted in $rwanted; do 1.118 + if [ -f $PROFILE/list/backupall.banned ]; then 1.119 + if [ "$BACKUP_ALL" = "yes" ]; then 1.120 + [ $(grep -l "^$wanted$" $PROFILE/list/backupall.banned) ] && continue 1.121 + fi 1.122 + fi 1.123 + 1.124 if [ -f $INCOMING_REPOSITORY/$wanted-$incoming_pkg_VERSION.tazpkg ]; then 1.125 + info "Backing up $INCOMING_REPOSITORY/$wanted-$incoming_pkg_VERSION.tazpkg" | tee -a $LOG/backup_pkg.log 1.126 ln -sf $INCOMING_REPOSITORY/$wanted-$incoming_pkg_VERSION.tazpkg $PKGISO_DIR/$wanted-$incoming_pkg_VERSION.tazpkg 1.127 elif [ -f $PACKAGES_REPOSITORY/$wanted-$pkg_VERSION.tazpkg ]; then 1.128 + info "Backing up $PACKAGES_REPOSITORY/$wanted-$pkg_VERSION.tazpkg" | tee -a $LOG/backup_pkg.log 1.129 ln -sf $PACKAGES_REPOSITORY/$wanted-$pkg_VERSION.tazpkg $PKGISO_DIR/$wanted-$pkg_VERSION.tazpkg 1.130 - elif [ -f $CACHE_REPOSITORY/$Wanted-$pkg_VERSION.tazpkg ]; then 1.131 - ln -sf $CACHE_REPOSITORY/$wanted-$pkg_VERSION.tazpkg $PKGISO_DIR/$wanted-$pkg_VERSION.tazpkg 1.132 + elif [ -f $CACHE_REPOSITORY/$Wanted-$cache_pkg_VERSION.tazpkg ]; then 1.133 + info "Backing up $CACHE_REPOSITORY/$wanted-$cache_pkg_VERSION.tazpkg" | tee -a $LOG/backup_pkg.log 1.134 + ln -sf $CACHE_REPOSITORY/$wanted-$cache_pkg_VERSION.tazpkg $PKGISO_DIR/$wanted-$cache_pkg_VERSION.tazpkg 1.135 fi 1.136 done 1.137 - 1.138 - for i in $(ls $WOK/$pkg/receipt); do 1.139 - unset SOURCE TARBALL WANTED PACKAGE VERSION pkg_VERSION COOK_OPT 1.140 - source $i 1.141 - pkg_VERSION="$(grep -m1 -A1 ^$PACKAGE$ $PACKAGES_REPOSITORY/packages.txt | \ 1.142 - tail -1 | sed 's/ *//')" 1.143 - incoming_pkg_VERSION="$(grep -m1 -A1 ^$pkg$ $INCOMING_REPOSITORY/packages.txt | \ 1.144 - tail -1 | sed 's/ *//')" 1.145 - [ "$WGET_URL" ] || continue 1.146 - if [ -f $INCOMING_REPOSITORY/$PACKAGE-$incoming_pkg_VERSION.tazpkg ]; then 1.147 - ln -sf $INCOMING_REPOSITORY/$PACKAGE-$incoming_pkg_VERSION.tazpkg $PKGISO_DIR/$PACKAGE-$incoming_pkg_VERSION.tazpkg 1.148 - elif [ -f $PACKAGES_REPOSITORY/$PACKAGE-$pkg_VERSION.tazpkg ]; then 1.149 - ln -sf $PACKAGES_REPOSITORY/$PACKAGE-$pkg_VERSION.tazpkg $PKGISO_DIR/$PACKAGE-$pkg_VERSION.tazpkg 1.150 - elif [ -f $CACHE_REPOSITORY/$PACKAGE-$pkg_VERSION.tazpkg ]; then 1.151 - ln -sf $CACHE_REPOSITORY/$PACKAGE-$pkg_VERSION.tazpkg $PKGISO_DIR/$PACKAGE-$pkg_VERSION.tazpkg 1.152 + 1.153 + if [ -f $PROFILE/list/backupall.banned ]; then 1.154 + if [ "$BACKUP_ALL" = "yes" ]; then 1.155 + [ $(grep -l "^$pkg$" $PROFILE/list/backupall.banned) ] && continue 1.156 fi 1.157 - done 1.158 + fi 1.159 + 1.160 + if [ -f $INCOMING_REPOSITORY/$pkg-$incoming_pkg_VERSION.tazpkg ]; then 1.161 + info "Backing up $INCOMING_REPOSITORY/$pkg-$incoming_pkg_VERSION.tazpkg" | tee -a $LOG/backup_pkg.log 1.162 + ln -sf $INCOMING_REPOSITORY/$pkg-$incoming_pkg_VERSION.tazpkg $PKGISO_DIR/$pkg-$incoming_pkg_VERSION.tazpkg 1.163 + elif [ -f $PACKAGES_REPOSITORY/$pkg-$pkg_VERSION.tazpkg ]; then 1.164 + info "Backing up $PACKAGES_REPOSITORY/$pkg-$pkg_VERSION.tazpkg" | tee -a $LOG/backup_pkg.log 1.165 + ln -sf $PACKAGES_REPOSITORY/$pkg-$pkg_VERSION.tazpkg $PKGISO_DIR/$pkg-$pkg_VERSION.tazpkg 1.166 + elif [ -f $CACHE_REPOSITORY/$pkg-$cache_pkg_VERSION.tazpkg ]; then 1.167 + info "Backing up $CACHE_REPOSITORY/$pkg-$cache_pkg_VERSION.tazpkg" | tee -a $LOG/backup_pkg.log 1.168 + ln -sf $CACHE_REPOSITORY/$pkg-$cache_pkg_VERSION.tazpkg $PKGISO_DIR/$pkg-$cache_pkg_VERSION.tazpkg 1.169 + fi 1.170 done 1.171 1.172 - [ -d $PKGISO_DIR ] && tazwok gen-list $PKGISO_DIR 1.173 + if [ "$SRC_PKG" = "yes" ]; then 1.174 + cat $cookorder | grep -v "^#" | while read pkg; do 1.175 + [ -f "$WOK/$pkg/receipt" ] || continue 1.176 + [ $(grep ^$pkg$ $PROFILE/list/srcpkg.banned) ] && continue 1.177 + for i in $(grep -l "^SOURCE=\"$pkg\"" $WOK/*/receipt); do 1.178 + unset SOURCE TARBALL WANTED PACKAGE VERSION COOK_OPT WGET_URL 1.179 + unset pkg_VERSION incoming_pkg_VERSION cache_pkg_VERSION src_pkg src_ver 1.180 + #source $i 1.181 + src_pkg=$(grep ^PACKAGE= $WOK/$pkg/receipt | cut -d "=" -f 2 | sed -e 's/"//g') 1.182 + src_ver=$(grep ^VERSION= $WOK/$pkg/receipt | cut -d "=" -f 2 | sed -e 's/"//g') 1.183 + [ "$VERSION" = "$src_ver" ] || continue 1.184 + pkg_VERSION="$(grep -m1 -A1 ^$src_pkg$ $PACKAGES_REPOSITORY/packages.txt | \ 1.185 + tail -1 | sed 's/ *//')" 1.186 + incoming_pkg_VERSION="$(grep -m1 -A1 ^$src_pkg$ $INCOMING_REPOSITORY/packages.txt | \ 1.187 + tail -1 | sed 's/ *//')" 1.188 + cache_pkg_VERSION="$(grep -m1 -A1 ^$src_pkg$ $LOCALSTATE/packages.txt | \ 1.189 + tail -1 | sed 's/ *//')" 1.190 + rwanted=$(grep $'\t'$src_pkg$ $PKGS/wanted.txt | cut -f 1) 1.191 + 1.192 + for wanted in $rwanted; do 1.193 + if [ -f $INCOMING_REPOSITORY/$wanted-$incoming_pkg_VERSION.tazpkg ]; then 1.194 + ln -sf $INCOMING_REPOSITORY/$wanted-$incoming_pkg_VERSION.tazpkg $PKGISO_DIR/$wanted-$incoming_pkg_VERSION.tazpkg 1.195 + elif [ -f $PACKAGES_REPOSITORY/$wanted-$pkg_VERSION.tazpkg ]; then 1.196 + ln -sf $PACKAGES_REPOSITORY/$wanted-$pkg_VERSION.tazpkg $PKGISO_DIR/$wanted-$pkg_VERSION.tazpkg 1.197 + elif [ -f $CACHE_REPOSITORY/$Wanted-$pkg_VERSION.tazpkg ]; then 1.198 + ln -sf $CACHE_REPOSITORY/$wanted-$pkg_VERSION.tazpkg $PKGISO_DIR/$wanted-$pkg_VERSION.tazpkg 1.199 + fi 1.200 + done 1.201 + 1.202 + if [ -f $INCOMING_REPOSITORY/$PACKAGE-$incoming_pkg_VERSION.tazpkg ]; then 1.203 + ln -sf $INCOMING_REPOSITORY/$PACKAGE-$incoming_pkg_VERSION.tazpkg $PKGISO_DIR/$PACKAGE-$incoming_pkg_VERSION.tazpkg 1.204 + elif [ -f $PACKAGES_REPOSITORY/$PACKAGE-$pkg_VERSION.tazpkg ]; then 1.205 + ln -sf $PACKAGES_REPOSITORY/$PACKAGE-$pkg_VERSION.tazpkg $PKGISO_DIR/$PACKAGE-$pkg_VERSION.tazpkg 1.206 + elif [ -f $CACHE_REPOSITORY/$PACKAGE-$cache_pkg_VERSION.tazpkg ]; then 1.207 + ln -sf $CACHE_REPOSITORY/$PACKAGE-$cache_pkg_VERSION.tazpkg $PKGISO_DIR/$PACKAGE-$cache_pkg_VERSION.tazpkg 1.208 + fi 1.209 + done 1.210 + done 1.211 + fi 1.212 + 1.213 + [ -f $LOG/packages-gen-list.log ] && rm -f $LOG/packages-gen-list.log 1.214 + [ -d $PKGISO_DIR ] && cook pkgdb $PKGISO_DIR | tee -a $LOG/packages-gen-list.log 1.215 fi 1.216 1.217 } 1.218 @@ -385,46 +445,68 @@ 1.219 backup_src() { 1.220 1.221 if [ "${BACKUP_PACKAGES}" = "yes" -a "${BACKUP_SOURCES}" = "yes" ]; then 1.222 - [ -d $SOURCES_REPOSITORY ] || mkdir -p $SOURCES_REPOSITORY 1.223 - [ -d $SRCISO_DIR ] && rm -r $SRCISO_DIR 1.224 - mkdir -p $SRCISO_DIR 1.225 - WOK=${HG_DIR}/wok/home/slitaz/repos/wok 1.226 - cat $ISODIR/cookorder.list | grep -v "^#"| while read pkg; do 1.227 - #rwanted=$(grep $'\t'$pkg$ $INCOMING_REPOSITORY/wok-wanted.txt | cut -f 1) 1.228 - for i in $(ls $WOK/$pkg/receipt); do 1.229 - unset SOURCE TARBALL WANTED PACKAGE VERSION COOK_OPT 1.230 - source $i 1.231 - { [ ! "$TARBALL" ] || [ ! "$WGET_URL" ] ; } && continue 1.232 - if [ ! -f "$SOURCES_REPOSITORY/$TARBALL" ] && \ 1.233 - [ ! -f "$SOURCES_REPOSITORY/${SOURCE:-$PACKAGE}-$VERSION.tar.lzma" ]; then 1.234 - tazwok get-src $PACKAGE --nounpack 1.235 - if [ -f "$SOURCES_REPOSITORY/$TARBALL" ]; then 1.236 - ln -sf $SOURCES_REPOSITORY/$TARBALL $SRCISO_DIR/$TARBALL 1.237 - elif [ -f "$SOURCES_REPOSITORY/${SOURCE:-$PACKAGE}-$VERSION.tar.lzma" ]; then 1.238 - ln -sf $SOURCES_REPOSITORY/${SOURCE:-$PACKAGE}-$VERSION.tar.lzma $SRCISO_DIR/${SOURCE:-$PACKAGE}-$VERSION.tar.lzma 1.239 - fi 1.240 - else 1.241 - [ -f "$SOURCES_REPOSITORY/$TARBALL" ] && ln -sf $SOURCES_REPOSITORY/$TARBALL $SRCISO_DIR/$TARBALL 1.242 - [ -f "$SOURCES_REPOSITORY/${SOURCE:-$PACKAGE}-$VERSION.tar.lzma" ] && ln -sf $SOURCES_REPOSITORY/${SOURCE:-$PACKAGE}-$VERSION.tar.lzma $SRCISO_DIR/${SOURCE:-$PACKAGE}-$VERSION.tar.lzma 1.243 + [ -d $SOURCES_REPOSITORY ] || mkdir -p $SOURCES_REPOSITORY 1.244 + [ -d $SRCISO_DIR ] && rm -r $SRCISO_DIR 1.245 + mkdir -p $SRCISO_DIR 1.246 + local pkg cookorder pkg_VERSION 1.247 + cookorder=$ISODIR/cookorder.list 1.248 + [ "$BACKUP_ALL" = "yes" ] && cookorder=$PKGS/fullco.txt 1.249 + [ -f $LOG/cook-getsrc.log ] && rm -rf $LOG/cook-getsrc.log 1.250 + [ -f $LOG/backup_src.log ] && rm -rf $LOG/backup_src.log 1.251 + cat $cookorder | grep -v "^#" | while read pkg; do 1.252 + if [ -f $PROFILE/list/backupall.banned ]; then 1.253 + if [ "$BACKUP_ALL" = "yes" ]; then 1.254 + [ $(grep -l "^$pkg$" $PROFILE/list/backupall.banned) ] && continue 1.255 + fi 1.256 + fi 1.257 + unset PATCH SOURCE TARBALL WANTED PACKAGE VERSION COOK_OPT WGET_URL KBASEVER 1.258 + unset pkg_VERSION 1.259 + [ -f $WOK/$pkg/receipt ] || continue 1.260 + source $WOK/$pkg/receipt 1.261 + [ "$WGET_URL" ] || continue 1.262 + [ "$TARBALL" ] || continue 1.263 + pkg_VERSION="$(grep -m1 -A1 ^$pkg$ $PKGISO_DIR/packages.txt | \ 1.264 + tail -1 | sed 's/ *//')" 1.265 + [ -f "$PKGISO_DIR/$PACKAGE-$pkg_VERSION.tazpkg" ] || continue 1.266 + #{ [ ! "$TARBALL" ] || [ ! "$WGET_URL" ] ; } && continue 1.267 + LZMA_TARBALL="${SOURCE:-$PACKAGE}-${KBASEVER:-$VERSION}.tar.lzma" 1.268 + if [ "$PATCH" ]; then 1.269 + if [ -f "$SOURCES_REPOSITORY/$(basename $PATCH)" ]; then 1.270 + info "Backing up $SOURCES_REPOSITORY/$(basename $PATCH)" | tee -a $LOG/backup_src.log 1.271 + ln -sf $SOURCES_REPOSITORY/$(basename $PATCH) $SRCISO_DIR/$(basename $PATCH) 1.272 + else 1.273 + cook $PACKAGE --getsrc | tee -a $LOG/cook-getsrc.log 1.274 + if [ -f "$SOURCES_REPOSITORY/$(basename $PATCH)" ]; then 1.275 + info "Backing up $SOURCES_REPOSITORY/$(basename $PATCH)" | tee -a $LOG/backup_src.log 1.276 + ln -sf $SOURCES_REPOSITORY/$(basename $PATCH) $SRCISO_DIR/$(basename $PATCH) 1.277 fi 1.278 - done 1.279 - done 1.280 - cd $SRCISO_DIR 1.281 - info "Make md5sum file for sources" 1.282 - find * -not -type d | grep -v md5sum | xargs md5sum > md5sum 1.283 - cd $WORKING 1.284 + fi 1.285 + fi 1.286 + if [ -f "$SOURCES_REPOSITORY/$LZMA_TARBALL" ]; then 1.287 + info "Backing up $SOURCES_REPOSITORY/$LZMA_TARBALL" | tee -a $LOG/backup_src.log 1.288 + ln -sf $SOURCES_REPOSITORY/$LZMA_TARBALL $SRCISO_DIR/$LZMA_TARBALL 1.289 + elif [ -f "$SOURCES_REPOSITORY/$TARBALL" ]; then 1.290 + info "Backing up $SOURCES_REPOSITORY/$TARBALL" | tee -a $LOG/backup_src.log 1.291 + ln -sf $SOURCES_REPOSITORY/$TARBALL $SRCISO_DIR/$TARBALL 1.292 + else 1.293 + cook $PACKAGE --getsrc | tee -a $LOG/cook-getsrc.log 1.294 + if [ -f "$SOURCES_REPOSITORY/$TARBALL" ]; then 1.295 + info "Backing up $SOURCES_REPOSITORY/$TARBALL" | tee -a $LOG/backup_src.log 1.296 + ln -sf $SOURCES_REPOSITORY/$TARBALL $SRCISO_DIR/$TARBALL 1.297 + elif [ -f "$SOURCES_REPOSITORY/$LZMA_TARBALL" ]; then 1.298 + info "Backing up $SOURCES_REPOSITORY/$LZMA_TARBALL" | tee -a $LOG/backup_src.log 1.299 + ln -sf $SOURCES_REPOSITORY/$LZMA_TARBALL $SRCISO_DIR/$LZMA_TARBALL 1.300 + fi 1.301 + fi 1.302 + done 1.303 + cd $SRCISO_DIR 1.304 + info "Make md5sum file for sources" 1.305 + find * -not -type d | grep -v md5sum | xargs md5sum > md5sum 1.306 + cd $WORKING 1.307 fi 1.308 1.309 } 1.310 1.311 -backup_all() 1.312 -{ 1.313 - if [ "${BACKUP_ALL}" = "yes" ]; then 1.314 - [ -d $SRCISO_DIR ] || ln -sf $SOURCES_REPOSITORY $SRCISO_DIR 1.315 - [ -d $PKGISO_DIR ] || ln -sf $PACKAGES_REPOSITORY $PKGISO_DIR 1.316 - fi 1.317 -} 1.318 - 1.319 imgcommon () { 1.320 1.321 build_modules 1.322 @@ -438,16 +520,20 @@ 1.323 fi 1.324 fi 1.325 1.326 - [ -d $SRCISO_DIR ] && rm -r $SRCISO_DIR 1.327 - [ -d $PKGISO_DIR ] && rm -r $PKGISO_DIR 1.328 - 1.329 - if [ -d ${HG_DIR}/wok ]; then 1.330 - backup_pkg 1.331 - backup_src 1.332 + if [ "$DONT_UPDATE_MIRROR" = "no" ]; then 1.333 + [ -d $SRCISO_DIR ] && rm -r $SRCISO_DIR 1.334 + [ -d $PKGISO_DIR ] && rm -r $PKGISO_DIR 1.335 + if [ -d ${HG_DIR}/wok-tank/repos/wok-tank/.hg ]; then 1.336 + WOK=${HG_DIR}/wok-tank/repos/wok-tank 1.337 + backup_pkg 1.338 + backup_src 1.339 + elif [ -d ${HG_DIR}/wok/repos/wok/.hg ]; then 1.340 + WOK=${HG_DIR}/wok/repos/wok 1.341 + backup_pkg 1.342 + backup_src 1.343 + fi 1.344 fi 1.345 1.346 - backup_all 1.347 - 1.348 info "====> Making bootable image" 1.349 1.350 # Sanity checks 1.351 @@ -496,11 +582,11 @@ 1.352 fi 1.353 1.354 info "Creating ISO image..." 1.355 - genisoimage -R -l -f -o $IMGNAME -b boot/isolinux/isolinux.bin \ 1.356 + genisoimage -R -l -f -V $VOLUME_ID -o $IMGNAME -b boot/isolinux/isolinux.bin \ 1.357 -c boot/isolinux/boot.cat -no-emul-boot -boot-load-size 4 \ 1.358 -uid 0 -gid 0 \ 1.359 -udf -allow-limited-size -iso-level 3 \ 1.360 - -V "SliTaz" -input-charset utf-8 -boot-info-table $ISODIR 1.361 + -P $PUBLISHER -input-charset utf-8 -boot-info-table $ISODIR 1.362 if [ -x /usr/bin/isohybrid ]; then 1.363 info "Creating hybrid ISO..." 1.364 isohybrid "${IMGNAME}"