Changeset 3b63c8c for CLFS


Ignore:
Timestamp:
07/26/2006 06:42:01 PM (18 years ago)
Author:
Manuel Canales Esparcia <manuel@…>
Branches:
experimental
Children:
613d46b
Parents:
1504208
Message:

Updated experimental branch to current trunk code.

Location:
CLFS
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • CLFS/clfs.xsl

    r1504208 r3b63c8c  
    231231        <xsl:value-of select="$page"/>
    232232      </xsl:when>
     233      <xsl:when test="ancestor::sect1[@id='ch-boot-kernel'] or
     234                      ancestor::sect1[@id='ch-bootable-kernel']">
     235        <xsl:value-of select="$keymap"/>
     236      </xsl:when>
    233237      <xsl:otherwise>
    234238        <xsl:text>**EDITME</xsl:text>
  • CLFS/config

    r1504208 r3b63c8c  
    2323# >>>> 64-64 BUILD <<<<
    2424# ARCH=x86_64-64  ; TARGET="x86_64-unknown-linux-gnu"
    25 # ARCH=mips64-64  ; TARGET="mipsel-unknown-linux-gnu"
    26 # ARCH=mips64-64  ; TARGET="mips-unknown-linux-gnu"
     25# ARCH=mips64-64  ; TARGET="mips64el-unknown-linux-gnu"
     26# ARCH=mips64-64  ; TARGET="mips64-unknown-linux-gnu"
    2727# ARCH=sparc64-64 ; TARGET="sparc64-unknown-linux-gnu"
    2828# ARCH=alpha      ; TARGET="alpha-unknown-linux-gnu"
     
    3030# >>>> MULTILIB 32/64 <<<<
    3131# ARCH=x86_64  ; TARGET="x86_64-unknown-linux-gnu"    ; TARGET32="i686-pc-linux-gnu"
    32 # ARCH=mips64  ; TARGET="mipsel-unknown-linux-gnu"    ; TARGET32="mipsel-unknown-linux-gnu"
    33 # ARCH=mips64  ; TARGET="mips-unknown-linux-gnu"      ; TARGET32="mips-unknown-linux-gnu"
    34 # ARCH=sparc64 ; TARGET="sparc64-unknown-linux-gnu"   ; TARGET32="sparcv9-unknown-linux-gnu"
     32# ARCH=mips64  ; TARGET="mips64el-unknown-linux-gnu"  ; TARGET32="mipsel-unknown-linux-gnu"
     33# ARCH=mips64  ; TARGET="mips64-unknown-linux-gnu"    ; TARGET32="mips-unknown-linux-gnu"
     34# ARCH=sparc64 ; TARGET="sparc64-unknown-linux-gnu"   ; TARGET32="sparc-unknown-linux-gnu"
    3535# ARCH=ppc64   ; TARGET="powerpc64-unknown-linux-gnu" ; TARGET32="powerpc-unknown-linux-gnu"
    3636
     
    6969#--- Book version
    7070LFSVRS=development
     71TREE=trunk/BOOK
    7172
    7273#--- Name of the makefile
  • CLFS/master.sh

    r1504208 r3b63c8c  
    1111host_prep_Makefiles() {      # Initialization of the system
    1212#----------------------------#
    13   local   LFS_HOST
     13  local   CLFS_HOST
    1414
    1515  echo "${tab_}${GREEN}Processing... ${L_arrow}host prep files${R_arrow}"
    1616
    1717  # defined here, only for ease of reading
    18   LFS_HOST="`echo ${MACHTYPE} | sed -e 's/unknown/cross/g' -e 's/-pc-/-cross-/g'`"
     18  CLFS_HOST="$(echo $MACHTYPE | sed "s/$(echo $MACHTYPE | cut -d- -f2)/cross/")"
    1919(
    2020cat << EOF
     
    4242025-addinguser:  024-creatingcrossdir
    4343        @\$(call echo_message, Building)
    44         @if [ ! -d /home/lfs ]; then \\
    45                 groupadd lfs; \\
    46                 useradd -s /bin/bash -g lfs -m -k /dev/null lfs; \\
     44        @if [ ! -d /home/clfs ]; then \\
     45                groupadd clfs; \\
     46                useradd -s /bin/bash -g clfs -m -k /dev/null clfs; \\
    4747        else \\
    48                 touch user-lfs-exist; \\
     48                touch user-clfs-exist; \\
    4949        fi;
    50         @chown lfs \$(MOUNT_PT) && \\
    51         chown lfs \$(MOUNT_PT)/tools && \\
    52         chown lfs \$(MOUNT_PT)/cross-tools && \\
    53         chown lfs \$(MOUNT_PT)/sources && \\
     50        @chown clfs \$(MOUNT_PT) && \\
     51        chown clfs \$(MOUNT_PT)/tools && \\
     52        chown clfs \$(MOUNT_PT)/cross-tools && \\
     53        chown clfs \$(MOUNT_PT)/sources && \\
    5454        touch \$@ && \\
    5555        echo " "\$(BOLD)Target \$(BLUE)\$@ \$(BOLD)OK && \\
     
    5858026-settingenvironment:  025-addinguser
    5959        @\$(call echo_message, Building)
    60         @if [ -f /home/lfs/.bashrc -a ! -f /home/lfs/.bashrc.XXX ]; then \\
    61                 mv /home/lfs/.bashrc /home/lfs/.bashrc.XXX; \\
     60        @if [ -f /home/clfs/.bashrc -a ! -f /home/clfs/.bashrc.XXX ]; then \\
     61                mv /home/clfs/.bashrc /home/clfs/.bashrc.XXX; \\
    6262        fi;
    63         @if [ -f /home/lfs/.bash_profile  -a ! -f /home/lfs/.bash_profile.XXX ]; then \\
    64                 mv /home/lfs/.bash_profile /home/lfs/.bash_profile.XXX; \\
     63        @if [ -f /home/clfs/.bash_profile  -a ! -f /home/clfs/.bash_profile.XXX ]; then \\
     64                mv /home/clfs/.bash_profile /home/clfs/.bash_profile.XXX; \\
    6565        fi;
    66         @echo "set +h" > /home/lfs/.bashrc && \\
    67         echo "umask 022" >> /home/lfs/.bashrc && \\
    68         echo "LFS=\$(MOUNT_PT)" >> /home/lfs/.bashrc && \\
    69         echo "LC_ALL=POSIX" >> /home/lfs/.bashrc && \\
    70         echo "PATH=/cross-tools/bin:/bin:/usr/bin" >> /home/lfs/.bashrc && \\
    71         echo "export LFS LC_ALL PATH" >> /home/lfs/.bashrc && \\
    72         echo "" >> /home/lfs/.bashrc && \\
    73         echo "unset CFLAGS" >> /home/lfs/.bashrc && \\
    74         echo "unset CXXFLAGS" >> /home/lfs/.bashrc && \\
    75         echo "" >> /home/lfs/.bashrc && \\
    76         echo "export LFS_HOST=\"${LFS_HOST}\"" >> /home/lfs/.bashrc && \\
    77         echo "export LFS_TARGET=\"${TARGET}\"" >> /home/lfs/.bashrc && \\
    78         echo "export LFS_TARGET32=\"${TARGET32}\"" >> /home/lfs/.bashrc && \\
    79         echo "source $JHALFSDIR/envars" >> /home/lfs/.bashrc
    80         @chown lfs:lfs /home/lfs/.bashrc && \\
     66        @echo "set +h" > /home/clfs/.bashrc && \\
     67        echo "umask 022" >> /home/clfs/.bashrc && \\
     68        echo "CLFS=\$(MOUNT_PT)" >> /home/clfs/.bashrc && \\
     69        echo "LC_ALL=POSIX" >> /home/clfs/.bashrc && \\
     70        echo "PATH=/cross-tools/bin:/bin:/usr/bin" >> /home/clfs/.bashrc && \\
     71        echo "export CLFS LC_ALL PATH" >> /home/clfs/.bashrc && \\
     72        echo "" >> /home/clfs/.bashrc && \\
     73        echo "unset CFLAGS" >> /home/clfs/.bashrc && \\
     74        echo "unset CXXFLAGS" >> /home/clfs/.bashrc && \\
     75        echo "" >> /home/clfs/.bashrc && \\
     76        echo "export CLFS_HOST=\"${CLFS_HOST}\"" >> /home/clfs/.bashrc && \\
     77        echo "export CLFS_TARGET=\"${TARGET}\"" >> /home/clfs/.bashrc && \\
     78        echo "export CLFS_TARGET32=\"${TARGET32}\"" >> /home/clfs/.bashrc && \\
     79        echo "source $JHALFSDIR/envars" >> /home/clfs/.bashrc
     80        @chown clfs:clfs /home/clfs/.bashrc && \\
    8181        touch envars && \\
    8282        touch \$@ && \\
     
    118118                                  -e 's@-static@@' \
    119119                                  -e 's@-final@@' \
    120                                   -e 's@-headers@@' \
    121                                   -e 's@-64@@' \
     120                                  -e 's@-64@@' \
    122121                                  -e 's@-n32@@'`
    123     # Adjust 'name' and patch a few scripts on the fly..
    124     case $name in
    125       linux-libc) name=linux-libc-headers ;;
    126     esac
    127     #
    128     # Find the version of the command files, if it corresponds with the building of a specific package
    129     vrs=`grep "^$name-version" $JHALFSDIR/packages | sed -e 's/.* //' -e 's/"//g'`
    130 
     122    pkg_tarball=$(get_package_tarball_name $name)
    131123
    132124    #--------------------------------------------------------------------#
     
    138130    wrt_target "${this_script}" "$PREV"
    139131    #
    140     # If $vrs isn't empty, we've got a package...
    141     #
    142     [[ "$vrs" != "" ]] && wrt_unpack "$name-$vrs.tar.*"
    143     #
    144     wrt_run_as_su "${this_script}" "${file}"
    145     #
    146     [[ "$vrs" != "" ]] && wrt_remove_build_dirs "${name}"
     132    # If $pkg_tarball isn't empty, we've got a package...
     133    #
     134    [[ "$pkg_tarball" != "" ]] && wrt_unpack_clfs "$pkg_tarball"
     135    #
     136    wrt_run_as_clfs_su "${this_script}" "${file}"
     137    #
     138    [[ "$pkg_tarball" != "" ]] && wrt_remove_build_dirs "${name}"
    147139    #
    148140    # Include a touch of the target name so make can check if it's already been made.
     
    169161    this_script=`basename $file`
    170162    #
     163    #  Deal with any odd scripts..
     164    case $this_script in
     165      *choose) # The choose script will fail if you cannot enter the new environment
     166               # If the 'boot' build method was chosen don't run the script
     167         [[ $METHOD = "boot" ]] && continue; ;;
     168      *) ;;
     169    esac
     170
     171    #
    171172    # First append each name of the script files to a list (this will become
    172173    # the names of the targets in the Makefile
     
    177178    name=`echo $this_script | sed -e 's@[0-9]\{3\}-@@'`
    178179    #
    179     # Find the version of the command files, if it corresponds with the building of a specific package
    180     vrs=`grep "^$name-version" $JHALFSDIR/packages | sed -e 's/.* //' -e 's/"//g'`
    181 
     180    pkg_tarball=$(get_package_tarball_name $name)
    182181
    183182    #--------------------------------------------------------------------#
     
    189188    wrt_target "${this_script}" "$PREV"
    190189    #
    191     # If $vrs isn't empty, we've got a package...
     190    # If $pkg_tarball isn't empty, we've got a package...
    192191    # Insert instructions for unpacking the package and to set the PKGDIR variable.
    193192    #
    194     [[ "$vrs" != "" ]] && wrt_unpack "$name-$vrs.tar.*"
    195     [[ "$vrs" != "" ]] && [[ "$OPTIMIZE" = "2" ]] &&  wrt_optimize "$name" && wrt_makeflags "$name"
    196     #
    197     wrt_run_as_su "${this_script}" "${file}"
    198     #
    199     [[ "$vrs" != "" ]] && wrt_remove_build_dirs "${name}"
     193    [[ "$pkg_tarball" != "" ]] && wrt_unpack_clfs "$pkg_tarball"
     194    [[ "$pkg_tarball" != "" ]] && [[ "$OPTIMIZE" = "2" ]] &&  wrt_optimize "$name" && wrt_makeflags "$name"
     195    #
     196    wrt_run_as_clfs_su "${this_script}" "${file}"
     197    #
     198    [[ "$pkg_tarball" != "" ]] && wrt_remove_build_dirs "${name}"
    200199    #
    201200    # Include a touch of the target name so make can check if it's already been made.
     
    250249      *)              name=`echo $this_script | sed -e 's@[0-9]\{3\}-@@' -e 's@-build@@' ` ;;
    251250    esac
    252 
    253     vrs=`grep "^$name-version" $JHALFSDIR/packages | sed -e 's/.* //' -e 's/"//g'`
     251      # Identify the unique version naming scheme for the clfs bootscripts..(bad boys)
     252    pkg_tarball=$(get_package_tarball_name $name)
    254253
    255254    #--------------------------------------------------------------------#
     
    261260    wrt_target "${this_script}" "$PREV"
    262261    #
    263     # If $vrs isn't empty, we've got a package...
     262    # If $pkg_tarball isn't empty, we've got a package...
    264263    # Insert instructions for unpacking the package and changing directories
    265264    #
    266     [[ "$vrs" != "" ]] && wrt_unpack "$name-$vrs.tar.*"
    267     [[ "$vrs" != "" ]] && [[ "$OPTIMIZE" = "2" ]] &&  wrt_optimize "$name" && wrt_makeflags "$name"
     265    [[ "$pkg_tarball" != "" ]] && wrt_unpack_clfs "$pkg_tarball"
     266    [[ "$pkg_tarball" != "" ]] && [[ "$OPTIMIZE" = "2" ]] &&  wrt_optimize "$name" && wrt_makeflags "$name"
    268267    #
    269268    # Select a script execution method
    270269    case $this_script in
    271       *changingowner*)  wrt_run_as_root "${this_script}" "${file}"    ;;
    272       *devices*)        wrt_run_as_root "${this_script}" "${file}"    ;;
     270      *changingowner*)  wrt_run_as_clfs_root "${this_script}" "${file}"    ;;
     271      *devices*)        wrt_run_as_clfs_root "${this_script}" "${file}"    ;;
    273272      *fstab*)   if [[ -n "$FSTAB" ]]; then
    274273                   wrt_copy_fstab "${this_script}"
    275274                 else
    276                    wrt_run_as_su  "${this_script}" "${file}"
     275                   wrt_run_as_clfs_su  "${this_script}" "${file}"
    277276                 fi
    278277         ;;
    279       *)         wrt_run_as_su  "${this_script}" "${file}"       ;;
     278      *)         wrt_run_as_clfs_su  "${this_script}" "${file}"       ;;
    280279    esac
    281280    #
    282281    # Housekeeping...remove any build directory(ies) except if the package build fails.
    283     [[ "$vrs" != "" ]] && wrt_remove_build_dirs "${name}"
     282    [[ "$pkg_tarball" != "" ]] && wrt_remove_build_dirs "${name}"
    284283    #
    285284    # Include a touch of the target name so make can check if it's already been made.
     
    318317    # Grab the name of the target, strip id number, XXX-script
    319318    name=`echo $this_script | sed -e 's@[0-9]\{3\}-@@'`
    320     vrs=`grep "^$name-version" $JHALFSDIR/packages | sed -e 's/.* //' -e 's/"//g'`
     319
     320    pkg_tarball=$(get_package_tarball_name $name)
    321321
    322322    #--------------------------------------------------------------------#
     
    328328    wrt_target "${this_script}" "$PREV"
    329329    #
    330     # If $vrs isn't empty, we've got a package...
     330    # If $pkg_tarball isn't empty, we've got a package...
    331331    # Insert instructions for unpacking the package and changing directories
    332332    #
    333     if [ "$vrs" != "" ] ; then
     333    if [ "$pkg_tarball" != "" ] ; then
    334334      case $this_script in
    335         *util-linux)    wrt_unpack  "$name-$vrs.tar.*"  ;;
    336         *)              wrt_unpack2 "$name-$vrs.tar.*"  ;;
     335        *util-linux)    wrt_unpack_clfs  "$pkg_tarball"  ;;
     336        *)              wrt_unpack2 "$pkg_tarball"  ;;
    337337      esac
    338338      [[ "$OPTIMIZE" = "2" ]] &&  wrt_optimize "$name" && wrt_makeflags "$name"
     
    341341    # Select a script execution method
    342342    case $this_script in
    343       *kernfs)        wrt_run_as_root    "${this_script}" "${file}"  ;;
    344       *util-linux)    wrt_run_as_su     "${this_script}" "${file}"  ;;
    345       *)              wrt_run_as_chroot1 "${this_script}" "${file}"  ;;
     343      *kernfs)        wrt_run_as_clfs_root "${this_script}" "${file}"  ;;
     344      *util-linux)    wrt_run_as_clfs_su   "${this_script}" "${file}"  ;;
     345      *)              wrt_run_as_chroot1   "${this_script}" "${file}"  ;;
    346346    esac
    347347    #
    348348    # Housekeeping...remove the build directory(ies), except if the package build fails.
    349     [[ "$vrs" != "" ]] && wrt_remove_build_dirs "${name}"
     349    [[ "$pkg_tarball" != "" ]] && wrt_remove_build_dirs "${name}"
    350350    #
    351351    # Include a touch of the target name so make can check if it's already been made.
     
    383383                                  -e 's@n32@@'`
    384384
    385     vrs=`grep "^$name-version" $JHALFSDIR/packages | sed -e 's/.* //' -e 's/"//g'`
     385    pkg_tarball=$(get_package_tarball_name $name)
    386386
    387387    #--------------------------------------------------------------------#
     
    393393    wrt_target "${this_script}" "$PREV"
    394394    #
    395     case $name in
    396       tcl)    wrt_unpack2 "$name$vrs-src.tar.*" ;;
    397       *)      wrt_unpack2 "$name-$vrs.tar.*"    ;;
    398     esac
     395    wrt_unpack2 "$pkg_tarball"
    399396    [[ "$OPTIMIZE" = "2" ]] &&  wrt_optimize "$name" && wrt_makeflags "$name"
    400397    #
     
    438435                                  -e 's@n32@@'`
    439436
    440     vrs=`grep "^$name-version" $JHALFSDIR/packages | sed -e 's/.* //' -e 's/"//g'`
     437    pkg_tarball=$(get_package_tarball_name $name)
    441438
    442439    #--------------------------------------------------------------------#
     
    446443    # Drop in the name of the target on a new line, and the previous target
    447444    # as a dependency. Also call the echo_message function.
    448     wrt_target "${this_script}" "$PREV"
    449     #
    450     case $name in
    451       tcl)    wrt_unpack3 "$name$vrs-src.tar.*" ;;
    452       *)      wrt_unpack3 "$name-$vrs.tar.*"    ;;
    453     esac
     445    wrt_target_boot "${this_script}" "$PREV"
     446    #
     447    wrt_unpack3 "$pkg_tarball"
    454448    [[ "$OPTIMIZE" = "2" ]] &&  wrt_optimize "$name" && wrt_makeflags "$name"
    455449    #
     
    520514    # a specific package. We need this here to can skip scripts not needed for
    521515    # iterations rebuilds
    522     vrs=`grep "^$name-version" $JHALFSDIR/packages | sed -e 's/.* //' -e 's/"//g'`
    523 
    524     if [[ "$vrs" = "" ]] && [[ -n "$N" ]] ; then
     516    pkg_tarball=$(get_package_tarball_name $name)
     517
     518    if [[ "$pkg_tarball" = "" ]] && [[ -n "$N" ]] ; then
    525519      case "${this_script}" in
    526520        *stripping*) ;;
     
    545539    wrt_target "${this_script}${N}" "$PREV"
    546540
    547     # If $vrs isn't empty, we've got a package...
    548     if [ "$vrs" != "" ] ; then
    549       FILE="$name-$vrs.tar.*"
    550       wrt_unpack2 "$FILE"
     541    # If $pkg_tarball isn't empty, we've got a package...
     542    if [ "$pkg_tarball" != "" ] ; then
     543      wrt_unpack2 "$pkg_tarball"
    551544      # If the testsuites must be run, initialize the log file
    552545      case $name in
     
    564557    wrt_run_as_chroot1 "${this_script}" "${file}"
    565558    #
    566     [[ "$vrs" != "" ]] && wrt_remove_build_dirs "${name}"
     559    [[ "$pkg_tarball" != "" ]] && wrt_remove_build_dirs "${name}"
    567560    #
    568561    # Include a touch of the target name so make can check if it's already been made.
     
    631624    # a specific package. We need this here to can skip scripts not needed for
    632625    # iterations rebuilds
    633     vrs=`grep "^$name-version" $JHALFSDIR/packages | sed -e 's/.* //' -e 's/"//g'`
    634 
    635     if [[ "$vrs" = "" ]] && [[ -n "$N" ]] ; then
     626
     627    pkg_tarball=$(get_package_tarball_name $name)
     628
     629    if [[ "$pkg_tarball" = "" ]] && [[ -n "$N" ]] ; then
    636630      case "${this_script}" in
    637631        *stripping*) ;;
     
    654648    # Drop in the name of the target on a new line, and the previous target
    655649    # as a dependency. Also call the echo_message function.
    656     wrt_target "${this_script}${N}" "$PREV"
    657 
    658     # If $vrs isn't empty, we've got a package...
    659     if [ "$vrs" != "" ] ; then
    660       FILE="$name-$vrs.tar.*"
     650    wrt_target_boot "${this_script}${N}" "$PREV"
     651
     652    # If $pkg_tarball isn't empty, we've got a package...
     653    if [ "$pkg_tarball" != "" ] ; then
     654      FILE="$pkg_tarball"
    661655      wrt_unpack3 "$FILE"
    662656      # If the testsuites must be run, initialize the log file
     
    675669    wrt_run_as_root2 "${this_script}" "${file}"
    676670    #
    677     [[ "$vrs" != "" ]] && wrt_remove_build_dirs2 "${name}"
     671    [[ "$pkg_tarball" != "" ]] && wrt_remove_build_dirs2 "${name}"
    678672    #
    679673    # Include a touch of the target name so make can check if it's already been made.
     
    721715      *udev-rules)   name=udev-cross-lfs ;;
    722716    esac
    723     vrs=`grep "^$name-version" $JHALFSDIR/packages | sed -e 's/.* //' -e 's/"//g'`
     717
     718    pkg_tarball=$(get_package_tarball_name $name)
    724719
    725720    #--------------------------------------------------------------------#
     
    731726    wrt_target "${this_script}" "$PREV"
    732727    #
    733     # If $vrs isn't empty, we've got a package...
    734     #
    735     [[ "$vrs" != "" ]] && wrt_unpack2 "$name-$vrs.tar.*"
     728    # If $pkg_tarball isn't empty, we've got a package...
     729    #
     730    [[ "$pkg_tarball" != "" ]] && wrt_unpack2 "$pkg_tarball"
    736731    #
    737732    wrt_run_as_chroot1 "${this_script}" "${file}"
    738733    #
    739     [[ "$vrs" != "" ]] && wrt_remove_build_dirs "${name}"
     734    [[ "$pkg_tarball" != "" ]] && wrt_remove_build_dirs "${name}"
    740735    #
    741736    # Include a touch of the target name so make can check if it's already been made.
     
    782777       ;;
    783778    esac
    784     vrs=`grep "^$name-version" $JHALFSDIR/packages | sed -e 's/.* //' -e 's/"//g'`
     779
     780    pkg_tarball=$(get_package_tarball_name $name)
    785781
    786782    #--------------------------------------------------------------------#
     
    790786    # Drop in the name of the target on a new line, and the previous target
    791787    # as a dependency. Also call the echo_message function.
    792     wrt_target "${this_script}" "$PREV"
    793     #
    794     # If $vrs isn't empty, we've got a package...
    795     #
    796     [[ "$vrs" != "" ]] && wrt_unpack3 "$name-$vrs.tar.*"
     788    wrt_target_boot "${this_script}" "$PREV"
     789    #
     790    # If $pkg_tarball isn't empty, we've got a package...
     791    #
     792    [[ "$pkg_tarball" != "" ]] && wrt_unpack3 "$pkg_tarball"
    797793    #
    798794    wrt_run_as_root2 "${this_script}" "${file}"
    799795    #
    800     [[ "$vrs" != "" ]] && wrt_remove_build_dirs2 "${name}"
     796    [[ "$pkg_tarball" != "" ]] && wrt_remove_build_dirs2 "${name}"
    801797    #
    802798    # Include a touch of the target name so make can check if it's already been made.
     
    845841       ;;
    846842    esac
    847     vrs=`grep "^$name-version" $JHALFSDIR/packages | sed -e 's/.* //' -e 's/"//g'`
     843
     844    pkg_tarball=$(get_package_tarball_name $name)
    848845
    849846    #--------------------------------------------------------------------#
     
    855852    wrt_target "${this_script}" "$PREV"
    856853    #
    857     # If $vrs isn't empty, we've got a package...
     854    # If $pkg_tarball isn't empty, we've got a package...
    858855    # Insert instructions for unpacking the package and changing directories
    859856    #
    860     [[ "$vrs" != "" ]] && wrt_unpack2 "$name-$vrs.tar.*"
     857    [[ "$pkg_tarball" != "" ]] && wrt_unpack2 "$pkg_tarball"
    861858    #
    862859    # Select a script execution method
     
    872869    #
    873870    # Housekeeping...remove any build directory(ies) except if the package build fails.
    874     [[ "$vrs" != "" ]] && wrt_remove_build_dirs "${name}"
     871    [[ "$pkg_tarball" != "" ]] && wrt_remove_build_dirs "${name}"
    875872    #
    876873    # Include a touch of the target name so make can check if it's already been made.
     
    918915    # Grab the name of the target, strip id number and misc words.
    919916    case $this_script in
    920       *kernel) name=linux
    921          ;;
     917      *kernel) name=linux  ;;
    922918      *)       name=`echo $this_script | sed -e 's@[0-9]\{3\}-@@' -e 's@-build@@' ` ;;
    923919    esac
    924920
    925     vrs=`grep "^$name-version" $JHALFSDIR/packages | sed -e 's/.* //' -e 's/"//g'`
     921    pkg_tarball=$(get_package_tarball_name $name)
    926922
    927923    #--------------------------------------------------------------------#
     
    931927    # Drop in the name of the target on a new line, and the previous target
    932928    # as a dependency. Also call the echo_message function.
    933     wrt_target "${this_script}" "$PREV"
    934     #
    935     # If $vrs isn't empty, we've got a package...
     929    wrt_target_boot "${this_script}" "$PREV"
     930    #
     931    # If $pkg_tarball isn't empty, we've got a package...
    936932    # Insert instructions for unpacking the package and changing directories
    937933    #
    938     [[ "$vrs" != "" ]] && wrt_unpack3 "$name-$vrs.tar.*"
     934    [[ "$pkg_tarball" != "" ]] && wrt_unpack3 "$pkg_tarball"
    939935    #
    940936    # Select a script execution method
     
    952948    #
    953949    # Housekeeping...remove any build directory(ies) except if the package build fails.
    954     [[ "$vrs" != "" ]] && wrt_remove_build_dirs2 "${name}"
     950    [[ "$pkg_tarball" != "" ]] && wrt_remove_build_dirs2 "${name}"
    955951    #
    956952    # Include a touch of the target name so make can check if it's already been made.
     
    10321028                                                                -e 's|exit||g' \
    10331029                                                                -e 's|$| -c|' \
    1034                                                                 -e 's|"$$LFS"|$(MOUNT_PT)|'\
     1030                                                                -e 's|"$$CLFS"|$(MOUNT_PT)|'\
    10351031                                                                -e 's|set -e||'`
    10361032    echo -e "CHROOT1= $chroot\n" >> $MKFILE
     
    10641060clean:  clean-chapter4 clean-chapter3 clean-chapter2
    10651061
     1062restart:
     1063        @echo "This feature does not exist for the CLFS makefile. (yet)"
     1064
    10661065clean-chapter2:
    1067         -if [ ! -f user-lfs-exist ]; then \\
    1068                 userdel lfs; \\
    1069                 rm -rf /home/lfs; \\
     1066        -if [ ! -f user-clfs-exist ]; then \\
     1067                userdel clfs; \\
     1068                rm -rf /home/clfs; \\
    10701069        fi;
    10711070        rm -rf \$(MOUNT_PT)/tools
     
    10731072        rm -rf \$(MOUNT_PT)/cross-tools
    10741073        rm -f /cross-tools
    1075         rm -f envars user-lfs-exist
     1074        rm -f envars user-clfs-exist
    10761075        rm -f 02* logs/02*.log
    10771076
    10781077clean-chapter3:
    10791078        rm -rf \$(MOUNT_PT)/tools/*
    1080         rm -f $cross_tools restore-lfs-env sources-dir
     1079        rm -f $cross_tools restore-clfs-env sources-dir
    10811080        cd logs && rm -f $cross_tools && cd ..
    10821081
     
    10921091
    10931092
    1094 restore-lfs-env:
     1093restore-clfs-env:
    10951094        @\$(call echo_message, Building)
    1096         @if [ -f /home/lfs/.bashrc.XXX ]; then \\
    1097                 mv -f /home/lfs/.bashrc.XXX /home/lfs/.bashrc; \\
     1095        @if [ -f /home/clfs/.bashrc.XXX ]; then \\
     1096                mv -f /home/clfs/.bashrc.XXX /home/clfs/.bashrc; \\
    10981097        fi;
    1099         @if [ -f /home/lfs/.bash_profile.XXX ]; then \\
    1100                 mv /home/lfs/.bash_profile.XXX /home/lfs/.bash_profile; \\
     1098        @if [ -f /home/clfs/.bash_profile.XXX ]; then \\
     1099                mv /home/clfs/.bash_profile.XXX /home/clfs/.bash_profile; \\
    11011100        fi;
    1102         @chown lfs:lfs /home/lfs/.bash* && \\
     1101        @chown clfs:clfs /home/clfs/.bash* && \\
    11031102        touch \$@ && \\
    11041103        echo " "\$(BOLD)Target \$(BLUE)\$@ \$(BOLD)OK && \\
     
    11111110        @-umount \$(MOUNT_PT)/sys
    11121111        @-umount \$(MOUNT_PT)/proc
    1113         @-if [ ! -f user-lfs-exist ]; then \\
    1114                 userdel lfs; \\
    1115                 rm -rf /home/lfs; \\
     1112        @-if [ ! -f user-clfs-exist ]; then \\
     1113                userdel clfs; \\
     1114                rm -rf /home/clfs; \\
    11161115        fi;
    11171116
     
    11431142clean:  clean-makesys clean-makeboot clean-jhalfs
    11441143
     1144restart:
     1145        @echo "This feature does not exist for the CLFS makefile. (yet)"
     1146
    11451147clean-jhalfs:
    1146         -if [ ! -f user-lfs-exist ]; then \\
    1147                 userdel lfs; \\
    1148                 rm -rf /home/lfs; \\
     1148        -if [ ! -f user-clfs-exist ]; then \\
     1149                userdel clfs; \\
     1150                rm -rf /home/clfs; \\
    11491151        fi;
    11501152        rm -rf \$(MOUNT_PT)/tools
     
    11521154        rm -rf \$(MOUNT_PT)/cross-tools
    11531155        rm -f /cross-tools
    1154         rm -f envars user-lfs-exist
     1156        rm -f envars user-clfs-exist
    11551157        rm -f 02* logs/02*.log
    11561158
     
    11581160        rm -rf /tools/*
    11591161        rm -f $cross_tools && rm -f $temptools && rm -f $chroottools && rm -f $boottools
    1160         rm -f restore-lfs-env sources-dir
     1162        rm -f restore-clfs-env sources-dir
    11611163        cd logs && rm -f $cross_tools && rm -f $temptools && rm -f $chroottools && rm -f $boottools && cd ..
    11621164
     
    11741176
    11751177
    1176 restore-lfs-env:
     1178restore-clfs-env:
    11771179        @\$(call echo_message, Building)
    1178         @if [ -f /home/lfs/.bashrc.XXX ]; then \\
    1179                 mv -fv /home/lfs/.bashrc.XXX /home/lfs/.bashrc; \\
     1180        @if [ -f /home/clfs/.bashrc.XXX ]; then \\
     1181                mv -fv /home/clfs/.bashrc.XXX /home/clfs/.bashrc; \\
    11801182        fi;
    1181         @if [ -f /home/lfs/.bash_profile.XXX ]; then \\
    1182                 mv -v /home/lfs/.bash_profile.XXX /home/lfs/.bash_profile; \\
     1183        @if [ -f /home/clfs/.bash_profile.XXX ]; then \\
     1184                mv -v /home/clfs/.bash_profile.XXX /home/clfs/.bash_profile; \\
    11831185        fi;
    1184         @chown lfs:lfs /home/lfs/.bash* && \\
     1186        @chown clfs:clfs /home/clfs/.bash* && \\
    11851187        touch \$@ && \\
    11861188        echo " "\$(BOLD)Target \$(BLUE)\$@ \$(BOLD)OK && \\
Note: See TracChangeset for help on using the changeset viewer.