Changeset bc40917


Ignore:
Timestamp:
08/21/2006 09:57:52 PM (18 years ago)
Author:
Manuel Canales Esparcia <manuel@…>
Branches:
experimental
Children:
0208570
Parents:
cac94f6
Message:

Making use off installed version from packages database.
Not full tested yet.

Files:
4 edited

Legend:

Unmodified
Added
Removed
  • BLFS/gen-makefile.sh

    rcac94f6 rbc40917  
    55set -e
    66
    7 # Uncomment this when reasy to be used
    8 #source ../configuration
    9 
    107# TEMPORARY VARIABLES.. development use only
    118declare MKFILE=Makefile
    129declare PREV_PACKAGE=""
    1310declare BUILD_SCRIPTS=scripts
    14 # Remove this when we can use configuration
    15 declare TRACKING_DIR=/var/lib/jhalfs/BLFS
     11declare TRACKING_DIR=tracking-dir
    1612
    1713HEADER="# This file is automatically generated by jhalfs
  • BLFS/gen_config.sh

    rcac94f6 rbc40917  
    77export inFile=packages          # file for reading and writing to.
    88
    9 declare TRACKING_DIR=tracking-dir
    10 
    119declare PKG_NAME
    1210declare PKG_XML_FILE
    1311declare PKG_DIR
    1412declare PKG_VER
     13declare INST_VER
    1514declare SAVE_IFS=${IFS}
    1615declare -a DIR_TREE
     
    4342  PKG_DIR=$(dirname $2)
    4443  PKG_VER=$3
     44  INST_VER=$4
    4545    # These are the META packages.
    4646  if [ $PKG_DIR = "." ]; then
    4747    SET_COMMENT=y
    4848      # Do not include previously installed packages....
    49     if [ -e $TRACKING_DIR/${PKG_NAME}-${PKG_VER} ]; then continue; fi
     49    if [ -n "${PKG_VER}" ] && [ "x${PKG_VER}" = "x${INST_VER}" ]; then
     50      continue
     51    fi
    5052
    5153    META_PKG=$(echo ${PKG_NAME} | tr [a-z] [A-Z])
    5254    echo -e "config CONFIG_$META_PKG" >> $outFile
    53     echo -e "\tbool \"$META_PKG $PKG_VER\"" >> $outFile
     55    echo -e "\tbool \"$META_PKG $PKG_VER $INST_VER\"" >> $outFile
    5456    echo -e "\tdefault n" >> $outFile
    5557
     
    6062         read || break 1
    6163         PKG_NAME=${REPLY}
    62          PKG_VER=$(grep "^$PKG_NAME[[:space:]]" $inFile | cut -f3)
     64         PKG_VER=$(grep "^${PKG_NAME}[[:space:]]" $inFile | cut -f3)
     65         INST_VER=$(grep "^${PKG_NAME}[[:space:]]" $inFile | cut -f4)
     66         if [ -n "${PKG_VER}" ] && [ "x${PKG_VER}" = "x${INST_VER}" ]; then
     67           continue
     68         fi
    6369(
    6470cat << EOF
    6571        config  DEP_${META_PKG}_${PKG_NAME}
    66                 bool    "$PKG_NAME ${PKG_VER}"
     72                bool    "$PKG_NAME ${PKG_VER} ${INST_VER}"
    6773                default y
    6874
     
    8490    # IF this package name-version exists in the tracking dir
    8591    # do not add this package to the list of installable pkgs.
    86   if [ -e $TRACKING_DIR/${PKG_NAME}-${PKG_VER} ]; then continue; fi
     92  if [ -n "${PKG_VER}" ] && [ "x${PKG_VER}" = "x${INST_VER}" ]; then
     93    continue
     94  fi
    8795
    8896  IFS="/"
     
    123131cat << EOF
    124132        config CONFIG_$PKG_NAME
    125                 bool "$PKG_NAME ${PKG_VER}"
     133                bool "$PKG_NAME ${PKG_VER} ${INST_VER}"
    126134                default n
    127135EOF
     
    236244                Select if sudo will be used (you want build as a normal user)
    237245                        otherwise sudo is not needed (you want build as root)
    238 
    239 config  TRACKING_DIR
    240         string
    241         default $TRACKING_DIR
    242 
    243246EOF
    244247) >> $outFile
  • BLFS/libs/func_dependencies

    rcac94f6 rbc40917  
    137137                       $GHOSTSCRIPT
    138138                       $MAILSERVER
    139                        $TRACKING_DIR
    140139                file:  depure.txt
    141140                       $TARGET-index.xml.tmp
     
    155154  local saveIFS=$IFS
    156155  local DEP_LV=$DEP_LEVEL
    157   local line line2 DEP pkg_ver
    158   # Remove this when we can use configuration file
    159   local TRACKING_DIR=/var/lib/jhalfs/BLFS
     156  local line line2 DEP pkg_ver inst_ver
    160157
    161158  #------------------
     
    183180    # If DEP has been previouly installed, skip it
    184181    pkg_ver=$(grep "^${DEP}[[:space:]]" ../packages | cut -f3)
    185     [ -e $TRACKING_DIR/${DEP}-$pkg_ver ] && continue
     182    inst_ver=$(grep "^${DEP}[[:space:]]" ../packages | cut -f4)
     183    [ -n "${pkg_ver}" ] && [ "x${pkg_ver}" = "x${inst_ver}" ] && continue
     184
    186185    # Special packages (a lot of hacks)
    187186    case $DEP in
  • blfs

    rcac94f6 rbc40917  
    127127# Set some harcoded envars to their proper values
    128128sed -i 's,blfs-xml,'$BLFS_XML',' update_book.sh libs/book.xsl
    129 sed -i 's,tracking-dir,'$TRACKING_DIR',' update_book.sh gen_config.sh
     129sed -i 's,tracking-dir,'$TRACKING_DIR',' update_book.sh gen-makefile.sh
    130130
    131 # Fetch book sources and create packages and GNOME/KDE dependencies files
     131# Fetch book sources and create packages and meta-packages dependencies files
    132132if [[ -d $BLFS_XML ]] ; then
    133133  ./update_book.sh
Note: See TracChangeset for help on using the changeset viewer.