Ignore:
Timestamp:
Sep 18, 2002, 2:36:56 PM (22 years ago)
Author:
ahuck
Message:

minor enhancements to buildall.pl,
buildlist contains the src.rpms as well (without version number),
unpack_srpm.sh accepts *.srpm as parameter and unpack in directories
omitting the version number

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/technical/common/build/unpack_srpm.sh

    r610 r612  
    1 #!/bin/bash
    2 # unpack_srpm.sh
    3 # entpackt das übergebene srpm in ein eigenen Unterverzeichnis
    4 # mit dem Namen des srpm
    5 # $Id: unpack_srpm.sh,v 1.1 2002/09/17 09:50:26 pstorz Exp $
     1#!/bin/bash
     2# packt die srpms in eigene Unterverzeichnisse aus
     3# wobei die Versionsnummern nicht berücksichtigt werden
     4# $Id: unpack_srpm.sh,v 1.2 2002/09/18 12:36:56 ahuck Exp $
     5# $Id: unpack_srpm.sh,v 1.2 2002/09/18 12:36:56 ahuck Exp $
     6# the buildall.sh script should be used after extracting the
     7# package - without dependence on version numbers in this directory
    68
    7 echo $#;
    8 if [ $# -ne 1 ]
    9         then
    10         echo "bitte srpm als parameter uerbergeben";
    11         exit 1;
    12 
     9if [ $# -le 1 ]
     10        then
     11        echo "Bitte alle srpm als Parameter übergeben, z.B. *.src.rpm";
     12        exit 1;
    1313fi
    1414
    15 RPM=`echo $1 | sed 's/.src.rpm//'`;
    16 echo $RPM;
    17 mkdir $RPM;cd $RPM; \
    18         rpm2cpio ../$RPM.src.rpm |cpio -i; \
    19         echo "unpacking package $RPM"; \
    20 #        cd .. ;
     15for i in $*; do shortname=`echo $i | sed 's/-[0-9]*\..*.src.rpm//'`; \
     16        echo "Unpacking $i into directory $shortname "; \
     17        mkdir $shortname; \
     18        cd $shortname; \
     19        rpm2cpio ../$i |cpio -i; \
     20        cd ..; \
     21    done
     22
Note: See TracChangeset for help on using the changeset viewer.