X-Git-Url: https://hackdaworld.org/gitweb/?a=blobdiff_plain;f=misc%2Fhdw-tools%2Fhdw-get;h=0ee4ba78cf521dc3dec5c4d552d55487b616ee82;hb=6836aca6fe863145c4e0da63bfd8689c97d0c161;hp=fa08cb16e38c340b92f5e79f7c3783193ad014a3;hpb=e6cbadee3fa9e3e04c70d6d652a64d7025936695;p=hdw-linux%2Fhdw-linux.git diff --git a/misc/hdw-tools/hdw-get b/misc/hdw-tools/hdw-get index fa08cb1..0ee4ba7 100644 --- a/misc/hdw-tools/hdw-get +++ b/misc/hdw-tools/hdw-get @@ -11,12 +11,14 @@ usage() { echo "usage:" echo "$0 [install/remove] [root] [package]" echo "$0 [dist-install] [root] [dist file]" + echo "$0 [update]" echo echo "options:" echo "-v tell me whats going on" echo "-a auto resolve deps, do not prompt user" echo "-no-dep do not care for dependencies (used by hdw-get itself)" echo "-s simulation only, do not install/remove packages" + echo "-b base package, not listed in hdw-get.db" echo } @@ -26,6 +28,7 @@ d_install="" ; install="" verbose="" ; no_dep="" auto_resolve_deps="" simulate="" +base="" FL_DIR="var/adm/flists" DEPS_DIR="var/adm/deps/run" @@ -46,6 +49,7 @@ while [ "$1" ] ; do -a) auto_resolve_deps="1" ; shift 1 ;; -no-dep) no_dep="1" ; shift 1 ;; -s) simulate="1" ; shift 1 ;; + -b) base="1" ; no_dep="1" ; shift 1;; *) usage ; exit 1 ;; esac done @@ -175,14 +179,16 @@ elif [ "$install" = "1" ] ; then fi # package in database? - if [ "`grep "^$pkg\ -" $DBF`" = "" ] ; then - echo "sorry, package $package not found ..." - echo "(use 'hdw-get update' to update database)" - exit 1 + if [ -z $base ] ; then + if [ "`grep "^$pkg\ -" $DBF`" = "" ] ; then + echo "sorry, package $package not found ..." + echo "(use 'hdw-get update' to update database)" + exit 1 + fi fi # check for runtime deps - if [ -z $no_deps ] ; then + if [ -z $no_dep ] ; then deps="`grep "^$pkg\ -" $DBF | sed 's/.* -//'`" udeps="" tudeps="" @@ -271,7 +277,9 @@ elif [ "$d_install" = "1" ] ; then # install all distribution related packages for package in `cat $dist_file`; do # execute myelf - $0 install $inst_root $package + auto="" + [ "$auto_resolve_deps" = "1" ] && auto="-a" + $0 $auto -b install $inst_root $package done fi fi