diff --git a/BLFS/gen-makefile.sh b/BLFS/gen-makefile.sh index 9f0685e..fd233eb 100755 --- a/BLFS/gen-makefile.sh +++ b/BLFS/gen-makefile.sh @@ -10,7 +10,7 @@ declare PREV_PACKAGE="" declare BUILD_SCRIPTS=scripts declare TRACKING_DIR=tracking-dir -HEADER="# This file is automatically generated by jhalfs +HEADER="# This file is automatically generated by gen-makefile.sh # YOU MAY NEED TO EDIT THIS FILE MANUALLY # # Generated on `date \"+%F %X %Z\"`" @@ -247,6 +247,16 @@ EOF } +if [[ -e Config.in ]] ; then + echo -e "${BOLD}This script must be run from inside the target package directory.${WHITE}" + exit 1 +fi + +if [[ ! -d scripts ]] ; then + echo -e "\n\tNo ./scripts/ directory has been found.\n" + exit 1 +fi + generate_Makefile cp ../progress_bar.sh .