Changeset 1db9dca
- Timestamp:
- 11/24/2005 07:19:16 PM (19 years ago)
- Branches:
- 0.2
- Children:
- 61784cd
- Parents:
- b6ca323
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
jhalfs
rb6ca323 r1db9dca 27 27 jhalfs produces will be in the directory 28 28 DIR/jhalfs. Default is \"/mnt/lfs\". 29 30 --rebuild clean the build directory before to perfom 31 any other task. The directory is cleaned 32 only if it was populated by a previous 33 jhalfs run. 29 34 30 35 -P, --get-packages download the packages and patches. This … … 113 118 ################################### 114 119 120 121 #----------------------------# 122 clean_builddir() { 123 #----------------------------# 124 # Test if the clean must be done. 125 if [ "$CLEAN" = "1" ] ; then 126 # Test to make sure we're running the clean as root 127 if [ "$UID" != "0" ] ; then 128 echo "You must be logged in as root to clean the build directory." 129 exit 1 130 fi 131 # Test to make sure that the build directory was populated by jhalfs 132 if [ ! -d $JHALFSDIR ] || [ ! -d $BUILDDIR/sources ] ; then 133 echo "Look like $BUILDDIR was not populated by a previous jhalfs run." 134 exit 1 135 else 136 # Clean the build directory 137 echo -ne "Cleaning $BUILDDIR...\n" 138 rm -rf $BUILDDIR/{bin,boot,dev,etc,home,lib,media,mnt,opt,proc,root,sbin,srv,sys,tmp,tools,usr,var} 139 echo -ne "Cleaning $JHALFSDIR...\n" 140 rm -rf $JHALFSDIR/{0*,1*,envars,sources-dir,commands,logs,Makefile,dump-lfs-scripts.xsl,functions,packages,patches} 141 echo -ne "Cleaning remainig extracted sources in $BUILDDIR/sources...\n" 142 rm -rf `find $BUILDDIR/sources/* -maxdepth 0 -type d` 143 echo -ne "done\n" 144 fi 145 fi 146 } 115 147 116 148 #----------------------------# … … 963 995 ;; 964 996 997 --rebuild ) CLEAN=1 ;; 998 965 999 --download-client | -D ) 966 1000 test $# = 1 && eval "$exit_missing_arg" … … 1051 1085 done 1052 1086 1087 # Prevents setting "-d /" by mistake. 1088 1089 if [ $BUILDDIR = / ] ; then 1090 echo -ne "\nThe root directory can't be used to build LFS.\n\n" 1091 exit 1 1092 fi 1093 1053 1094 # If $BUILDDIR have subdirectories like tools/ or bin/, stop the run 1054 # and notify the user about that. This also prevents setting "-d /" 1055 # by mistake. 1056 1057 if [ -d $BUILDDIR/tools -o -d $BUILDDIR/bin ] ; then 1095 # and notify the user about that. 1096 1097 if [ -d $BUILDDIR/tools -o -d $BUILDDIR/bin ] && [ -z $CLEAN ] ; then 1058 1098 eval "$no_empty_builddir" 1059 1099 fi 1100 1101 # If requested, clean the build directory 1102 clean_builddir 1060 1103 1061 1104 # Find the download client to use, if not already specified.
Note:
See TracChangeset
for help on using the changeset viewer.