Added switch to skipp packages dowload.
This commit is contained in:
parent
44f88e31e9
commit
07f47df141
1 changed files with 38 additions and 26 deletions
16
jhalfs
16
jhalfs
|
@ -22,7 +22,8 @@ Options:
|
||||||
DIR/jhalfs
|
DIR/jhalfs
|
||||||
-D, --download-client=CLIENT use CLIENT as the program for retrieving
|
-D, --download-client=CLIENT use CLIENT as the program for retrieving
|
||||||
packages
|
packages
|
||||||
-T, --no-testsuites don't run the package's testsuites.
|
-T, --no-testsuites don't run the package's testsuites
|
||||||
|
-P, --have-packages don't download the packages
|
||||||
"
|
"
|
||||||
|
|
||||||
help="\
|
help="\
|
||||||
|
@ -84,6 +85,12 @@ while test $# -gt 0 ; do
|
||||||
shift
|
shift
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
--have-packages | -P )
|
||||||
|
shift
|
||||||
|
HPKG=1
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
|
||||||
* )
|
* )
|
||||||
echo "$usage"
|
echo "$usage"
|
||||||
exit 1
|
exit 1
|
||||||
|
@ -221,6 +228,9 @@ download() {
|
||||||
|
|
||||||
get_sources() {
|
get_sources() {
|
||||||
|
|
||||||
|
# Test if the packages must be downloaded
|
||||||
|
if [ -z $HPKG ] ; then
|
||||||
|
|
||||||
# This variable is necessary to make sure the `cat $JHALFSDIR/packages`
|
# This variable is necessary to make sure the `cat $JHALFSDIR/packages`
|
||||||
# separates each iteration by lines. It is necessary to have the second
|
# separates each iteration by lines. It is necessary to have the second
|
||||||
# ' on the next line.
|
# ' on the next line.
|
||||||
|
@ -252,6 +262,7 @@ get_sources() {
|
||||||
download $PKG $PATCH
|
download $PKG $PATCH
|
||||||
done
|
done
|
||||||
done
|
done
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
build_Makefile() {
|
build_Makefile() {
|
||||||
|
@ -288,7 +299,8 @@ build_Makefile() {
|
||||||
FILE="$name-$vrs.tar.bz2"
|
FILE="$name-$vrs.tar.bz2"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Insert instructions for unpacking the package and changing directories
|
# Insert instructions for unpacking the package and to set
|
||||||
|
# the PKGDIR variable.
|
||||||
echo -e "\t\$(call unpack-lfs,$FILE) && \\" >> $MKFILE.tmp
|
echo -e "\t\$(call unpack-lfs,$FILE) && \\" >> $MKFILE.tmp
|
||||||
echo -e "\tROOT=\`head -n1 /tmp/unpacked | sed 's@/.*@@'\` && \\" >> $MKFILE.tmp
|
echo -e "\tROOT=\`head -n1 /tmp/unpacked | sed 's@/.*@@'\` && \\" >> $MKFILE.tmp
|
||||||
echo -e "\tchown -R lfs \$(LFS)\$(SRC)/\$\$ROOT && \\" >> $MKFILE.tmp
|
echo -e "\tchown -R lfs \$(LFS)\$(SRC)/\$\$ROOT && \\" >> $MKFILE.tmp
|
||||||
|
|
Reference in a new issue