Ignore:
Timestamp:
Feb 16, 2009, 12:47:36 PM (14 years ago)
Author:
Jim Gifford <clfs@…>
Branches:
clfs-1.2, clfs-2.1, clfs-3.0.0-systemd, clfs-3.0.0-sysvinit, master, systemd, sysvinit
Children:
099bfc2
Parents:
61a83e8
Message:

Figure out what the last patch # is and grab the next #

File:
1 edited

Legend:

Unmodified
Added
Removed
  • scripts/patch/gcc-patch.sh

    r61a83e8 rc7ef534  
    2020  wget ftp://gcc.gnu.org/pub/gcc/releases/gcc-${VERSION}/gcc-${VERSION}.tar.bz2
    2121fi
     22
     23# Set Patch Number
     24#
     25cd /usr/src
     26wget http://svn.cross-lfs.org/svn/repos/cross-lfs/trunk/patches/ --no-remove-listing
     27PATCH_NUM=$(cat index.html | grep gcc | grep "${VERSION}" | grep branch_update | cut -f2 -d'"' | cut -f1 -d'"'| cut -f4 -d- | cut -f1 -d. | tail -n 1)
     28PATCH_NUM=$(expr ${PATCH_NUM} + 1)
     29rm -f index.html
    2230
    2331# Cleanup Directory
     
    5765#
    5866cd /usr/src
    59 echo "Submitted By: Jim Gifford (jim at cross-lfs dot org)" > gcc-${VERSION}-branch_update-x.patch
    60 echo "Date: `date +%m-%d-%Y`" >> gcc-${VERSION}-branch_update-x.patch
    61 echo "Initial Package Version: ${VERSION}" >> gcc-${VERSION}-branch_update-x.patch
    62 echo "Origin: Upstream" >> gcc-${VERSION}-branch_update-x.patch
    63 echo "Upstream Status: Applied" >> gcc-${VERSION}-branch_update-x.patch
    64 echo "Description: This is a branch update for gcc-${VERSION}, and should be" >> gcc-${VERSION}-branch_update-x.patch
    65 echo "             rechecked periodically." >> gcc-${VERSION}-branch_update-x.patch
    66 echo "" >> gcc-${VERSION}-branch_update-x.patch
    67 diff -Naur gcc-${VERSION}.orig gcc-${VERSION} >> gcc-${VERSION}-branch_update-x.patch
    68 echo "Created /usr/src/gcc-${VERSION}-branch_update-x.patch."
     67echo "Submitted By: Jim Gifford (jim at cross-lfs dot org)" > gcc-${VERSION}-branch_update-${PATCH_NUM}.patch
     68echo "Date: `date +%m-%d-%Y`" >> gcc-${VERSION}-branch_update-${PATCH_NUM}.patch
     69echo "Initial Package Version: ${VERSION}" >> gcc-${VERSION}-branch_update-${PATCH_NUM}.patch
     70echo "Origin: Upstream" >> gcc-${VERSION}-branch_update-${PATCH_NUM}.patch
     71echo "Upstream Status: Applied" >> gcc-${VERSION}-branch_update-${PATCH_NUM}.patch
     72echo "Description: This is a branch update for gcc-${VERSION}, and should be" >> gcc-${VERSION}-branch_update-${PATCH_NUM}.patch
     73echo "             rechecked periodically." >> gcc-${VERSION}-branch_update-${PATCH_NUM}.patch
     74echo "" >> gcc-${VERSION}-branch_update-${PATCH_NUM}.patch
     75diff -Naur gcc-${VERSION}.orig gcc-${VERSION} >> gcc-${VERSION}-branch_update-${PATCH_NUM}.patch
     76echo "Created /usr/src/gcc-${VERSION}-branch_update-${PATCH_NUM}.patch."
Note: See TracChangeset for help on using the changeset viewer.