]> Zhao Yanbai Git Server - minix.git/commitdiff
Dinks for the (source/binary) package scripts
authorBen Gras <ben@minix3.org>
Wed, 15 Mar 2006 17:02:46 +0000 (17:02 +0000)
committerBen Gras <ben@minix3.org>
Wed, 15 Mar 2006 17:02:46 +0000 (17:02 +0000)
commands/scripts/packme.sh
etc/mtree/minix.tree
tools/release.sh

index ba6fe0404374db5a2f46e4b5d2d43a020a02924e..908bb9f59a272426e96a288f043eb3b888088b69 100644 (file)
@@ -6,6 +6,8 @@ RC=/usr/etc/rc.package
 CDDIR=PACKAGES
 MP=/mnt
 CDPACK=${MP}/install/packages
+CDSRC=${MP}/install/package-sources
+SRC=/usr/bigports
 
 if [ -f "$RC" ]
 then   . "$RC"
@@ -27,6 +29,16 @@ then pack=${cddrive}p2
                        if [ "$y" = y -o "$y" = Y ]
                        then    echo "Extracting $CDPACK/$package .."
                                cat $package | packit -
+                               srcname="`echo $package | sed 's/.tar.bz/-src.tar.bz'`"
+                               srcarc="$CDSRC/$srcname"
+                               if [ -f "$srcarc" ]
+                               then    echo -n "Install its source (y/N) ? "
+                                       read y
+                                       if [ "$y" = y -o "$y" = Y ]
+                                       then    echo "Installing $srcarc into $SRC."
+                                               ( cd /usr/bigports && smallbunzip2 "$srcarc" | tar xf - )
+                                       fi
+                               fi
                        fi
                done
        else    echo "CD mount failed - skipping CD packages."
index f387ac553775dafd72bde1f8369550203a5c8d10..4ffad41216716336082ed5e1287f35f3348cda11 100644 (file)
@@ -69,6 +69,7 @@
 775  root    uucp      /usr/spool/locks
 700  daemon  daemon    /usr/spool/lpd
 755  root    operator  /usr/spool/mail
+755  bin     operator  /usr/bigports
 755  bin     operator  /usr/src
 1777 root    operator  /usr/tmp
 755  root    operator  /var
index 9a6c1553472eb11c5a2f50d7503e4921cd3034a0..d20751c02c88a04d7285eac4d27ecbfeba955b1e 100755 (executable)
@@ -1,6 +1,7 @@
 #!/bin/sh
 
 PACKAGEDIR=/usr/bigports/Packages
+PACKAGESOURCEDIR=/usr/bigports/Sources
 secs=`expr 32 '*' 64`
 
 make_hdimage()
@@ -73,6 +74,7 @@ usr=/dev/c0d7p0s2
 COPYITEMS="usr/bin bin usr/lib"
 RELEASEDIR=/usr/r
 RELEASEPACKAGE=${RELEASEDIR}/usr/install/packages
+RELEASEPACKAGESOURCES=${RELEASEDIR}/usr/install/package-sources
 IMAGE=cdfdimage
 ROOTIMAGE=rootimage
 CDFILES=/usr/tmp/cdreleasefiles
@@ -122,7 +124,7 @@ fi
 IMGBZ=${IMG}.bz2
 echo "Making $IMGBZ"
 
-USRMB=128
+USRMB=150
 
 USRBLOCKS="`expr $USRMB \* 1024 \* 1024 / $BS`"
 USRSECTS="`expr $USRMB \* 1024 \* 2`"
@@ -232,21 +234,25 @@ mount $TMPDISK $RELEASEDIR/usr || exit
 mkdir -p $RELEASEDIR/tmp
 mkdir -p $RELEASEDIR/usr/tmp
 mkdir -p $RELEASEPACKAGE
+mkdir -p $RELEASEPACKAGESOURCES
 
 echo " * Transfering $COPYITEMS to $RELEASEDIR"
 ( cd / && tar cf - $COPYITEMS ) | ( cd $RELEASEDIR && tar xf - ) || exit 1
 
-if [ -d $PACKAGEDIR ]
-then   echo " * Transfering $PACKAGEDIR to $RELEASEPACKAGE"
-       cp $PACKAGEDIR/* $RELEASEPACKAGE/
+if [ -d $PACKAGEDIR -a -d $PACKAGESOURCEDIR ]
+then   echo " * Indexing packages"
        ( cd $PACKAGEDIR
-               for p in *.tar.bz
-               do      descr="../`echo $p | sed 's/.tar.bz//'`/.descr"
-                       if [ -f "$descr" ]
-                       then    printf "%-27s   %s\n" "$p" "`cat $descr`"
-                       fi
-               done >List
+         for p in *.tar.bz
+         do    descr="../`echo $p | sed 's/.tar.bz//'`/.descr"
+               if [ -f "$descr" ]
+               then    printf "%-32s   %s\n" "$p" "`cat $descr`"
+               fi
+         done >List
        )
+       echo " * Transfering $PACKAGEDIR to $RELEASEPACKAGE"
+       cp $PACKAGEDIR/* $RELEASEPACKAGE/
+       echo " * Transfering $PACKAGESOURCEDIR to $RELEASEPACKAGESOURCES"
+       cp $PACKAGESOURCEDIR/* $RELEASEPACKAGESOURCES/
 fi
 
 # Make sure compilers and libraries are bin-owned