Changeset 0271c0c


Ignore:
Timestamp:
03/21/2006 01:25:20 PM (19 years ago)
Author:
George Boudreau <georgeb@…>
Branches:
experimental
Children:
a9490ab
Parents:
b0976d2
Message:

Standardized handling of the optional param CONFIG

Files:
4 edited

Legend:

Unmodified
Added
Removed
  • CLFS/master.sh

    rb0976d2 r0271c0c  
    217217      *whatnext*) continue     ;;
    218218      *settingenvironment*) sed 's@PS1=@set +h\nPS1=@' -i $file  ;;
    219       *kernel)   # if there is no kernel config file do not build the kernel
     219      *kernel)    # if there is no kernel config file do not build the kernel
    220220                [[ -z $CONFIG ]] && continue
    221                 sed "s|make mrproper|make mrproper\ncp $CONFIG .config|" -i $file
    222                 # You cannot run menuconfig from within the makefile
     221                  # Copy the config file to /sources with a standardized name
     222                cp -v $CONFIG $BUILDDIR/sources/kernel-config
     223                sed "s|make mrproper|make mrproper\ncp /sources/kernel-config .config|" -i $file
     224                  # You cannot run menuconfig from within the makefile
    223225                sed 's|menuconfig|oldconfig|'     -i $file
    224                 #If defined include the keymap in the kernel
     226                  #If defined include the keymap in the kernel
    225227                if [[ -n "$KEYMAP" ]]; then
    226228                  sed "s|^loadkeys -m.*>|loadkeys -m $KEYMAP >|" -i $file
     
    857859      *grub*)     continue ;;
    858860      *kernel)
    859                # if there is no kernel config file do not build the kernel
     861                 # if there is no kernel config file do not build the kernel
    860862               [[ -z $CONFIG ]] && continue
    861                sed "s|make mrproper|make mrproper\ncp $CONFIG .config|" -i $file
    862                # You cannot run menuconfig from within the makefile
     863                 # Copy the config file to /sources with a standardized name
     864               cp -v $CONFIG $BUILDDIR/sources/kernel-config
     865               sed "s|make mrproper|make mrproper\ncp /sources/kernel-config .config|" -i $file
     866                 # You cannot run menuconfig from within the makefile
    863867               sed 's|menuconfig|oldconfig|'     -i $file
    864                # If defined include the keymap in the kernel
     868                 # If defined include the keymap in the kernel
    865869               if [[ -n "$KEYMAP" ]]; then
    866870                 sed "s|^loadkeys -m.*>|loadkeys -m $KEYMAP >|" -i $file
     
    938942      *grub*)     continue  ;;
    939943      *kernel)
    940                # if there is no kernel config file do not build the kernel
     944                 # if there is no kernel config file do not build the kernel
    941945               [[ -z $CONFIG ]] && continue
    942                cfg_file="/sources/`basename $CONFIG`"
    943                sed "s|make mrproper|make mrproper\ncp $cfg_file .config|" -i $file
    944                # You cannot run menuconfig from within the makefile
     946                 # Copy the named config file to /sources with a standardized name
     947               cp -v $CONFIG $BUILDDIR/sources/kernel-config
     948               sed "s|make mrproper|make mrproper\ncp ../kernel-config .config|" -i $file
     949                 # You cannot run menuconfig from within the makefile
    945950               sed 's|menuconfig|oldconfig|'     -i $file
    946                # If defined include the keymap in the kernel
     951                 # If defined include the keymap in the kernel
    947952               if [[ -n "$KEYMAP" ]]; then
    948953                 sed "s|^loadkeys -m.*>|loadkeys -m $KEYMAP >|" -i $file
  • HLFS/master.sh

    rb0976d2 r0271c0c  
    456456    fi
    457457
    458     if [[ `_IS_ $this_script kernel` ]] ; then
    459       # not much really, script does everything..
    460       echo -e "\t@cp -f $CONFIG \$(MOUNT_PT)/sources/kernel-config" >> $MKFILE.tmp
    461     fi
    462 
    463458    # Check if we have a real /etc/fstab file
    464459    if [[ `_IS_ $this_script fstab` ]] && [[ -n "$FSTAB" ]] ; then
  • LFS/master.sh

    rb0976d2 r0271c0c  
    223223    # should enter the chroot environment to create the root
    224224    # password, edit several files and setup Grub.
    225     if [[ `_IS_ ${this_script} grub` ]] || [[ `_IS_ ${this_script} reboot` ]] ; then
    226        continue
    227     fi
    228 
     225    #
    229226    # If no .config file is supplied, the kernel build is skipped
    230     if [ -z $CONFIG ] && [[ `_IS_ ${this_script} kernel` ]] ; then
    231       continue
    232     fi
     227    #
     228    case ${this_script} in
     229      *grub)    continue ;;
     230      *reboot)  continue ;;
     231      *kernel)  [[ -z ${CONFIG} ]] && continue
     232                cp ${CONFIG} $BUILDDIR/sources/kernel-config  ;;
     233    esac
    233234
    234235    # First append each name of the script files to a list (this will become
  • common/common-functions

    rb0976d2 r0271c0c  
    723723                                               -e 's@">@"@' \
    724724                                               -e '/generic/d' >> packages
     725      echo " ...OK"
    725726      ;;
    726727  esac
Note: See TracChangeset for help on using the changeset viewer.