diff options
author | Patrick J Volkerding <volkerdi@slackware.com> | 2016-06-30 20:26:57 +0000 |
---|---|---|
committer | Eric Hameleers <alien@slackware.com> | 2018-05-31 23:31:18 +0200 |
commit | d31c50870d0bee042ce660e445c9294a59a3a65b (patch) | |
tree | 6bfc0de3c95267b401b620c2c67859557dc60f97 /source/a/pkgtools/scripts/pkgtool | |
parent | 76fc4757ac91ac7947a01fb7b53dddf9a78a01d1 (diff) | |
download | current-d31c50870d0bee042ce660e445c9294a59a3a65b.tar.gz current-d31c50870d0bee042ce660e445c9294a59a3a65b.tar.xz |
Slackware 14.2slackware-14.2
Thu Jun 30 20:26:57 UTC 2016
Slackware 14.2 x86_64 stable is released!
The long development cycle (the Linux community has lately been living in
"interesting times", as they say) is finally behind us, and we're proud to
announce the release of Slackware 14.2. The new release brings many updates
and modern tools, has switched from udev to eudev (no systemd), and adds
well over a hundred new packages to the system. Thanks to the team, the
upstream developers, the dedicated Slackware community, and everyone else
who pitched in to help make this release a reality.
The ISOs are off to be replicated, a 6 CD-ROM 32-bit set and a dual-sided
32-bit/64-bit x86/x86_64 DVD. Please consider supporting the Slackware
project by picking up a copy from store.slackware.com. We're taking
pre-orders now, and offer a discount if you sign up for a subscription.
Have fun! :-)
Diffstat (limited to 'source/a/pkgtools/scripts/pkgtool')
-rw-r--r-- | source/a/pkgtools/scripts/pkgtool | 33 |
1 files changed, 20 insertions, 13 deletions
diff --git a/source/a/pkgtools/scripts/pkgtool b/source/a/pkgtools/scripts/pkgtool index dd9d6816f..fd77f2980 100644 --- a/source/a/pkgtools/scripts/pkgtool +++ b/source/a/pkgtools/scripts/pkgtool @@ -1,10 +1,9 @@ #!/bin/sh # -# Copyright 1993, 1994, 1995, 1996, 1997, -# 1998, 1999 Patrick Volkerding, Moorhead, MN USA +# Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999 Patrick Volkerding, Moorhead, MN USA # Copyright 2001, 2004 Slackware Linux, Inc., Concord, CA USA # All rights reserved. -# Copyright 2007, 2009, 2010, 2011, 2013 Patrick Volkerding, Sebeka, MN, USA +# Copyright 2007, 2009, 2010, 2011, 2013, 2015 Patrick Volkerding, Sebeka, MN, USA # # Redistribution and use of this script, with or without modification, is # permitted provided that the following conditions are met: @@ -44,6 +43,15 @@ # Wed Jan 26 23:06:22 GMT 2005 # * Fix for non-standard package descriptions by Jim Hawkins +# Avoid problems if any files in /var/log/packages and /var/log/scripts +# might contain any broken UTF-8 sequences. This was once known to cause +# dialog to crash. +unset LANG LC_CTYPE LC_NUMERIC LC_TIME LC_COLLATE LC_MONETARY \ + LC_MESSAGES LC_PAPER LC_NAME LC_ADDRESS LC_TELEPHONE LC_MEASUREMENT \ + LC_IDENTIFICATION LC_ALL +LANG=C +export LANG + # Return a package name that has been stripped of the dirname portion # and any of the valid extensions (only): pkgbase() { @@ -72,10 +80,9 @@ SOURCE_DIR=/var/log/mount ASK="tagfiles" if [ -L /bin/chmod -a -L /bin/chown ]; then # probably on the bootdisk using busybox TARGET_DIR=/mnt + rootdevice="$(mount | grep ' on /mnt ' | tail -n 1 | cut -f 1 -d ' ' 2> /dev/null)" TMP=/mnt/var/log/setup/tmp - if mount | grep "on /mnt" 1> /dev/null 2>&1 ; then # good - true - else # bad + if ! mount | grep ' on /mnt ' 1> /dev/null 2> /dev/null ; then echo echo echo "You can't run pkgtool from the rootdisk until you've mounted your Linux" @@ -95,6 +102,7 @@ if [ -L /bin/chmod -a -L /bin/chown ]; then # probably on the bootdisk using bus fi else TARGET_DIR=/ + rootdevice="$(mount | grep ' on / ' | tail -n 1 | cut -f 1 -d ' ')" TMP=/var/log/setup/tmp fi if [ ! -d $TMP ]; then @@ -212,7 +220,7 @@ else # there were no arguments, so we'll get the needed information from the CMD_START="true" rm -f $TMP/SeT* while [ 0 ]; do - dialog --title "Slackware Package Tool (pkgtool version 14.1)" \ + dialog --title "Slackware Package Tool (pkgtool version 14.2)" \ --menu "\nWelcome to the Slackware package tool.\n\ \nWhich option would you like?\n" 17 75 7 \ "Current" "Install packages from the current directory" \ @@ -250,8 +258,7 @@ are done selecting to run the scripts." 17 70 9 \' > $TMP/setupscr # Run each script: for script in $(cat $TMP/return) ; do scrpath=$ADM_DIR/setup/setup.$(echo $script | tr -d \") - rootdevice="$(mount | head -n 1 | cut -f 1 -d ' ')" - ( COLOR=on ; cd $TARGET_DIR ; . $scrpath / $rootdevice ) + ( COLOR=on ; cd $TARGET_DIR ; . $scrpath $TARGET_DIR $rootdevice ) done fi rm -f $TMP/return $TMP/setupscr @@ -470,7 +477,7 @@ retry, or quit?" 10 60 2 \ umount_the_source() { if [ ! "$SOURCE_MOUNTED" = "always" ]; then - umount $SOURCE_DEVICE 1> /dev/null 2>&1 + umount $SOURCE_DEVICE 1> /dev/null 2> /dev/null fi; } @@ -570,7 +577,7 @@ install_disk() { CATALOG_FILE=$(basename $PACKAGE_DIR/disk*); fi if [ -r $PACKAGE_DIR/$CATALOG_FILE -a ! -d $PACKAGE_DIR/$CATALOG_FILE ]; then - if grep CONTENTS: $PACKAGE_DIR/$CATALOG_FILE 1> /dev/null 2>&1 ; then + if grep CONTENTS: $PACKAGE_DIR/$CATALOG_FILE 1> /dev/null 2> /dev/null ; then # First we check for missing packages... for PKGTEST in $(grep "^CONTENTS:" $PACKAGE_DIR/$CATALOG_FILE | cut -f2- -d : 2> /dev/null) ; do # This is not a perfect test. (say emacs is missing but emacs-nox is not) @@ -601,7 +608,7 @@ EOF for PACKAGE_FILENAME in $PACKAGE_DIR/*.t?z; do BASE=$(pkgbase $PACKAGE_FILENAME) BASE="$(package_name $BASE)" - if echo $ALLOWED | grep $BASE 1> /dev/null 2>&1 ; then + if echo $ALLOWED | grep $BASE 1> /dev/null 2> /dev/null ; then true else cat << EOF > $TMP/tmpmsg @@ -687,7 +694,7 @@ if [ "$DISK_SETS" = "disk" ]; then else touch $TMP/tagfile chmod 600 $TMP/tagfile - if echo $DISK_SETS | grep "#a#" 1> /dev/null 2>&1; then + if echo $DISK_SETS | grep "#a#" 1> /dev/null 2> /dev/null ; then A_IS_NEEDED="true" else A_IS_NEEDED="false" |