Changeset 9676bac


Ignore:
Timestamp:
Jan 20, 2009, 4:01:19 PM (16 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:
550b73d
Parents:
d8b9d99
Message:

Added Perl Patch and cleaned up

Location:
scripts/patch
Files:
1 added
7 edited

Legend:

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

    rd8b9d99 r9676bac  
    99#
    1010if [ "${VERSION}" = "" ]; then
    11         echo "$0 - Bash_Version"
    12         echo "This will Create a Patch for Bash Bash_Version"
     11  echo "$0 - Bash_Version"
     12  echo "This will Create a Patch for Bash Bash_Version"
     13  exit 255
    1314fi
    1415
     
    2728#
    2829if ! [ -e bash-${VERSION}.tar.gz ]; then
    29         wget ftp://ftp.cwru.edu/pub/bash/bash-${VERSION}.tar.gz
     30  wget ftp://ftp.cwru.edu/pub/bash/bash-${VERSION}.tar.gz
    3031fi
    3132
     
    4445COUNT=1
    4546while [ ${COUNT} -le ${FILES} ]; do
    46         cd /tmp/bash-${VERSION}           
    47         DLCOUNT="${COUNT}"
    48         SKIPME=no
    49         if [ "${COUNT}" -lt "100" ]; then
    50                 DLCOUNT="0${COUNT}"
    51         fi
    52         if [ "${COUNT}" -lt "10" ]; then
    53                 DLCOUNT="00${COUNT}"
    54         fi
    55         for skip in ${SKIPPATCH} ; do
    56                 if [ "${DLCOUNT}" = "$skip" ]; then
    57                         echo "Patch bash${VERSION2}-${DLCOUNT} skipped"
    58                         SKIPPED="${SKIPPED} ${DLCOUNT}"
    59                         SKIPME=yes
    60                 fi
    61         done
    62         if [ "${SKIPME}" != "yes" ]; then
    63                 if ! [ -e ${VERSION}.${DLCOUNT} ]; then
    64                         wget --quiet ${PATCHURL}/bash${VERSION2}-${DLCOUNT}
    65                 fi
    66                 cd ${CURRENTDIR}
    67                 patch --dry-run -s -f -Np0 -i /tmp/bash-${VERSION}/bash${VERSION2}-${DLCOUNT}
    68                 if [ "$?" = "0" ]; then
    69                         echo "Patch bash${VERSION2}-${DLCOUNT} applied"
    70                         patch -s -Np0 -i /tmp/bash-${VERSION}/bash${VERSION2}-${DLCOUNT}
    71                 else
    72                         echo "Patch bash${VERSION2}-${DLCOUNT} not applied"
    73                         rm -f /tmp/bash-${VERSION}/bash${VERSION2}-${DLCOUNT}
    74                         SKIPPED="${SKIPPED} ${DLCOUNT}"
    75                 fi
    76         fi
    77         COUNT=`expr ${COUNT} + 1`
     47  cd /tmp/bash-${VERSION}           
     48  DLCOUNT="${COUNT}"
     49  SKIPME=no
     50  if [ "${COUNT}" -lt "100" ]; then
     51    DLCOUNT="0${COUNT}"
     52  fi
     53  if [ "${COUNT}" -lt "10" ]; then
     54    DLCOUNT="00${COUNT}"
     55  fi
     56  for skip in ${SKIPPATCH} ; do
     57    if [ "${DLCOUNT}" = "$skip" ]; then
     58      echo "Patch bash${VERSION2}-${DLCOUNT} skipped"
     59      SKIPPED="${SKIPPED} ${DLCOUNT}"
     60      SKIPME=yes
     61    fi
     62  done
     63  if [ "${SKIPME}" != "yes" ]; then
     64    if ! [ -e ${VERSION}.${DLCOUNT} ]; then
     65      wget --quiet ${PATCHURL}/bash${VERSION2}-${DLCOUNT}
     66    fi
     67    cd ${CURRENTDIR}
     68    patch --dry-run -s -f -Np0 -i /tmp/bash-${VERSION}/bash${VERSION2}-${DLCOUNT}
     69    if [ "$?" = "0" ]; then
     70      echo "Patch bash${VERSION2}-${DLCOUNT} applied"
     71      patch -s -Np0 -i /tmp/bash-${VERSION}/bash${VERSION2}-${DLCOUNT}
     72    else
     73     echo "Patch bash${VERSION2}-${DLCOUNT} not applied"
     74     rm -f /tmp/bash-${VERSION}/bash${VERSION2}-${DLCOUNT}
     75     SKIPPED="${SKIPPED} ${DLCOUNT}"
     76    fi
     77  fi
     78  COUNT=`expr ${COUNT} + 1`
    7879done
    7980
     
    8283
    8384for dir in $(find * -type d); do
    84         cd /usr/src/bash-${VERSION}/${dir}
    85         for file in $(find . -name '*~'); do
    86                 rm -f ${file}
    87         done
    88         for file in $(find . -name '*.orig'); do
    89                 rm -f ${file}
    90         done
     85  cd /usr/src/bash-${VERSION}/${dir}
     86  for file in $(find . -name '*~'); do
     87    rm -f ${file}
     88  done
     89  for file in $(find . -name '*.orig'); do
     90    rm -f ${file}
     91  done
    9192done
    9293cd /usr/src/bash-${VERSION}
     
    103104echo "Description: Contains all upstream patches up to ${VERSION}-${FILES}" >> bash-${VERSION}-branch_update-x.patch
    104105if [ -n "${SKIPPED}" ]; then
    105         echo "             The following patches were skipped" >> bash-${VERSION}-branch_update-x.patch
    106         echo "            ${SKIPPED}" >> bash-${VERSION}-branch_update-x.patch
     106  echo "             The following patches were skipped" >> bash-${VERSION}-branch_update-x.patch
     107  echo "            ${SKIPPED}" >> bash-${VERSION}-branch_update-x.patch
    107108fi
    108109echo "" >> bash-${VERSION}-branch_update-x.patch
    109110diff -Naur bash-${VERSION}.orig bash-${VERSION} >> bash-${VERSION}-branch_update-x.patch
    110111echo "Created /usr/src/bash-${VERSION}-branch_update-x.patch."
    111 
  • scripts/patch/binutils-patch.sh

    rd8b9d99 r9676bac  
    99#
    1010if [ "${VERSION}" = "" ]; then
    11         echo "$0 - Binutils_Version"
    12         echo "This will Create a Patch for Binutils Binutils_Version"
     11  echo "$0 - Binutils_Version"
     12  echo "This will Create a Patch for Binutils Binutils_Version"
     13  exit 255
    1314fi
    1415
     
    1718cd /usr/src
    1819if ! [ -e binutils-${VERSION}.tar.bz2  ]; then
    19         wget ftp://ftp.gnu.org/gnu/binutils/binutils-${VERSION}.tar.bz2
     20  wget ftp://ftp.gnu.org/gnu/binutils/binutils-${VERSION}.tar.bz2
    2021fi
    2122
     
    3839DIRS="binutils-${VERSION} binutils-${VERSION}.orig"
    3940for DIRECTORY in ${DIRS}; do
    40 cd /usr/src/${DIRECTORY}
    41         FILE_LIST=".cvsignore *.gmo"
    42         for files in ${FILE_LIST}; do
    43                 REMOVE=$(find * -name ${files})
    44                 for file in $REMOVE; do
    45                         rm -f ${file}
    46                 done
    47         done
     41  cd /usr/src/${DIRECTORY}
     42  FILE_LIST=".cvsignore *.gmo"
     43  for files in ${FILE_LIST}; do
     44    REMOVE=$(find * -name ${files})
     45    for file in $REMOVE; do
     46      rm -f ${file}
     47    done
     48  done
    4849
    49         REMOVE=".cvsignore MAINTAINERS COPYING.LIBGLOSS COPYING.NEWLIB README-maintainer-mode depcomp
    50                 ChangeLog compile ltgcc.m4 lt~obsolete.m4 etc/ChangeLog etc/add-log.el etc/add-log.vi"
    51         for file in $REMOVE; do
    52                 rm -f ${file}
    53         done
    54         cd ..
     50  REMOVE=".cvsignore MAINTAINERS COPYING.LIBGLOSS COPYING.NEWLIB README-maintainer-mode depcomp
     51    ChangeLog compile ltgcc.m4 lt~obsolete.m4 etc/ChangeLog etc/add-log.el etc/add-log.vi"
     52  for file in $REMOVE; do
     53    rm -f ${file}
     54    done
     55    cd ..
    5556done
    5657
     
    5859#
    5960for dir in $(find * -type d); do
    60         cd /usr/src/binutils-${VERSION}
    61         for file in $(find . -name '*~'); do
    62                 rm -f ${file}
    63         done
    64         for file in $(find . -name '*.orig'); do
    65                 rm -f ${file}
    66         done
     61  cd /usr/src/binutils-${VERSION}
     62  for file in $(find . -name '*~'); do
     63    rm -f ${file}
     64  done
     65  for file in $(find . -name '*.orig'); do
     66    rm -f ${file}
     67  done
    6768done
    6869cd /usr/src/binutils-${VERSION}
     
    8990diff -Naur binutils-${VERSION}.orig binutils-${VERSION} >> binutils-${VERSION}-branch_update-x.patch
    9091echo "Created /usr/src/binutils-${VERSION}-branch_update-x.patch."
    91 
  • scripts/patch/gcc-patch.sh

    rd8b9d99 r9676bac  
    99#
    1010if [ "${VERSION}" = "" ]; then
    11         echo "$0 - GCC_Version"
    12         echo "This will Create a Patch for GCC GCC_Version"
     11  echo "$0 - GCC_Version"
     12  echo "This will Create a Patch for GCC GCC_Version"
     13  exit 255
    1314fi
    1415
     
    1718cd /usr/src
    1819if ! [ -e gcc-${VERSION}.tar.bz2  ]; then
    19         wget ftp://ftp.gnu.org/gnu/gcc/gcc-${VERSION}/gcc-${VERSION}.tar.bz2
     20  wget ftp://ftp.gnu.org/gnu/gcc/gcc-${VERSION}/gcc-${VERSION}.tar.bz2
    2021fi
    2122
     
    3839DIRS="gcc-${VERSION} gcc-${VERSION}.orig"
    3940for DIRECTORY in ${DIRS}; do
    40         cd ${DIRECTORY}
    41         REMOVE="ABOUT-NLS COPYING COPYING.LIB ChangeLog ChangeLog.tree-ssa MAINTAINERS Makefile.def
    42                 Makefile.in Makefile.tpl README README.SCO boehm-gc/ChangeLog BUGS FAQ LAST_UPDATED
    43                 MD5SUMS NEWS bugs.html faq.html gcc/BASE-VER gcc/DATESTAMP gcc/DEV-PHASE gcc/c-parse.c
    44                 gcc/gengtype-lex.c gcc/c-parse.y gcc/gengtype-yacc.c gcc/gengtype-yacc.h gcc/f/BUGS gcc/f/NEWS
    45                 gcc/java/parse-scan.c gcc/java/parse.c gcc/objc/objc-parse.c gcc/objc/objc-parse.y"
    46         for file in ${REMOVE}; do
    47                 rm -f $file
    48         done
    49         rm -rf INSTALL
    50         rm -f fastjar/*.{1,info} gcc/doc/*.{1,info,7} gcc/fortran/*.{1,info,7}
    51         rm -f gcc/po/*.{gmo,po}  libcpp/po/*.{gmo,po} libgomp/*.{1,info,7}
    52         cd ..
     41  cd ${DIRECTORY}
     42  REMOVE="ABOUT-NLS COPYING COPYING.LIB ChangeLog ChangeLog.tree-ssa MAINTAINERS Makefile.def
     43    Makefile.in Makefile.tpl README README.SCO boehm-gc/ChangeLog BUGS FAQ LAST_UPDATED
     44    MD5SUMS NEWS bugs.html faq.html gcc/BASE-VER gcc/DATESTAMP gcc/DEV-PHASE gcc/c-parse.c
     45    gcc/gengtype-lex.c gcc/c-parse.y gcc/gengtype-yacc.c gcc/gengtype-yacc.h gcc/f/BUGS gcc/f/NEWS
     46    gcc/java/parse-scan.c gcc/java/parse.c gcc/objc/objc-parse.c gcc/objc/objc-parse.y"
     47  for file in ${REMOVE}; do
     48    rm -f $file
     49  done
     50  rm -rf INSTALL
     51  rm -f fastjar/*.{1,info} gcc/doc/*.{1,info,7} gcc/fortran/*.{1,info,7}
     52  rm -f gcc/po/*.{gmo,po}  libcpp/po/*.{gmo,po} libgomp/*.{1,info,7}
     53  cd ..
    5354done
    5455
     
    6667diff -Naur gcc-${VERSION}.orig gcc-${VERSION} >> gcc-${VERSION}-branch_update-x.patch
    6768echo "Created /usr/src/gcc-${VERSION}-branch_update-x.patch."
    68 
    69 
  • scripts/patch/gcc-specs-patch.sh

    rd8b9d99 r9676bac  
    99#
    1010if [ "${VERSION}" = "" ]; then
    11         echo "$0 - GCC_Version"
    12         echo "This will Create a Patch for GCC Specs GCC_Version"
     11  echo "$0 - GCC_Version"
     12  echo "This will Create a Patch for GCC Specs GCC_Version"
     13  exit 255
    1314fi
    1415
     
    1718cd /usr/src
    1819if ! [ -e gcc-${VERSION}.tar.bz2  ]; then
    19         wget ftp://ftp.gnu.org/gnu/gcc/gcc-${VERSION}/gcc-${VERSION}.tar.bz2
     20  wget ftp://ftp.gnu.org/gnu/gcc/gcc-${VERSION}/gcc-${VERSION}.tar.bz2
    2021fi
    2122
     
    3132cd /usr/src/gcc-${VERSION}
    3233for file in $(find gcc/config -name "*.h"); do
    33         if [ "$(echo ${file} | grep -c bsd)" = "0" ]; then
    34                 if [ "$(cat ${file} | grep -c DYNAMIC_LINKER)" != "0" ]; then
    35                         echo "Modifying ${file}..."
    36                         sed -i '/DYNAMIC_LINKER/s@"/lib@"/tools/lib@' ${file}
    37                 fi
    38                 if [ "$(cat ${file} | grep -c DYNAMIC_LINKER)" != "0" ]; then
    39                         echo "Modifying ${file}..."
    40                         sed -i '/-dynamic-linker/s@ /lib@ /tools/lib@' ${file}
    41                 fi
    42         fi
     34  if [ "$(echo ${file} | grep -c bsd)" = "0" ]; then
     35    if [ "$(cat ${file} | grep -c DYNAMIC_LINKER)" != "0" ]; then
     36      echo "Modifying ${file}..."
     37      sed -i '/DYNAMIC_LINKER/s@"/lib@"/tools/lib@' ${file}
     38    fi
     39    if [ "$(cat ${file} | grep -c DYNAMIC_LINKER)" != "0" ]; then
     40      echo "Modifying ${file}..."
     41      sed -i '/-dynamic-linker/s@ /lib@ /tools/lib@' ${file}
     42    fi
     43  fi
    4344done
    4445
  • scripts/patch/ncurses-patch.sh

    rd8b9d99 r9676bac  
    99#
    1010if [ "${VERSION}" = "" ]; then
    11         echo "$0 - Ncurses_Version"
    12         echo "This will Create a Patch for Ncurses Ncurses_Version"
     11  echo "$0 - Ncurses_Version"
     12  echo "This will Create a Patch for Ncurses Ncurses_Version"
     13  exit 255
    1314fi
    1415
     
    2627#
    2728if ! [ -e ncurses-${VERSION}.tar.gz ]; then
    28         wget ftp://invisible-island.net/ncurses/ncurses-${VERSION}.tar.gz
     29  wget ftp://invisible-island.net/ncurses/ncurses-${VERSION}.tar.gz
    2930fi
    3031
     
    4243cd /tmp/ncurses-${VERSION}
    4344if [ "${ROLLUP}" != "" ]; then
    44         echo "Getting Rollup ${ROLLUP} Patch..."
    45         wget --quiet ftp://invisible-island.net/ncurses/${VERSION}/${ROLLUP}
    46         cd ${CURRENTDIR}
    47         echo "Applying Rollup ${ROLLUP} Patch..."
    48         cp /tmp/ncurses-${VERSION}/${ROLLUP} ${CURRENTDIR}/${ROLLUP}
    49         bunzip2 ${ROLLUP}
    50         ROLLUP2=$(echo ${ROLLUP} | sed -e 's/.bz2//g')
    51         sh ${ROLLUP2}
     45  echo "Getting Rollup ${ROLLUP} Patch..."
     46  wget --quiet ftp://invisible-island.net/ncurses/${VERSION}/${ROLLUP}
     47  cd ${CURRENTDIR}
     48  echo "Applying Rollup ${ROLLUP} Patch..."
     49  cp /tmp/ncurses-${VERSION}/${ROLLUP} ${CURRENTDIR}/${ROLLUP}
     50  bunzip2 ${ROLLUP}
     51  ROLLUP2=$(echo ${ROLLUP} | sed -e 's/.bz2//g')
     52  sh ${ROLLUP2}
    5253fi
    5354
     
    5556#
    5657for file in ${FILES}; do
    57         if [ "${ROLLPATCH}" != "" ]; then
    58                 TEST=$(echo ${file} | grep -c ${ROLLPATCH})
    59         else
    60                 TEST=0
    61         fi
    62         if [ "${TEST}" = "0" ]; then
    63                 cd /tmp/ncurses-${VERSION}
    64                 echo "Getting Patch ${file}..."
    65                 wget --quiet ftp://invisible-island.net/ncurses/${VERSION}/${file}
    66                 cd ${CURRENTDIR}
    67                 gunzip -c /tmp/ncurses-${VERSION}/${file} | patch --dry-run -s -f -Np1
    68                 if [ "$?" = "0" ]; then
    69                         echo "Apply Patch ${file}..."
    70                         gunzip -c /tmp/ncurses-${VERSION}/${file} | patch -Np1
    71                         LASTFILE=$(echo ${file} | cut -f2 -d. | cut -f2 -d-)
    72                 fi
    73         fi
     58  if [ "${ROLLPATCH}" != "" ]; then
     59    TEST=$(echo ${file} | grep -c ${ROLLPATCH})
     60  else
     61    TEST=0
     62  fi
     63  if [ "${TEST}" = "0" ]; then
     64    cd /tmp/ncurses-${VERSION}
     65    echo "Getting Patch ${file}..."
     66    wget --quiet ftp://invisible-island.net/ncurses/${VERSION}/${file}
     67    cd ${CURRENTDIR}
     68    gunzip -c /tmp/ncurses-${VERSION}/${file} | patch --dry-run -s -f -Np1
     69    if [ "$?" = "0" ]; then
     70      echo "Apply Patch ${file}..."
     71      gunzip -c /tmp/ncurses-${VERSION}/${file} | patch -Np1
     72      LASTFILE=$(echo ${file} | cut -f2 -d. | cut -f2 -d-)
     73    fi
     74  fi
    7475done
    7576
     
    7980#
    8081for dir in $(find * -type d); do
    81         cd /usr/src/ncurses-${VERSION}/${dir}
    82         for file in $(find . -name '*~'); do
    83                 rm -f ${file}
    84         done
    85         for file in $(find . -name '*.orig'); do
    86                 rm -f ${file}
    87         done
     82  cd /usr/src/ncurses-${VERSION}/${dir}
     83  for file in $(find . -name '*~'); do
     84    rm -f ${file}
     85  done
     86  for file in $(find . -name '*.orig'); do
     87    rm -f ${file}
     88  done
    8889done
    8990cd /usr/src/ncurses-${VERSION}
  • scripts/patch/readline-patch.sh

    rd8b9d99 r9676bac  
    99#
    1010if [ "${VERSION}" = "" ]; then
    11         echo "$0 - Readline_Version"
    12         echo "This will Create a Patch for Readline Readline_Version"
     11  echo "$0 - Readline_Version"
     12  echo "This will Create a Patch for Readline Readline_Version"
     13  exit 255
    1314fi
    1415
     
    2728#
    2829if ! [ -e readline-${VERSION}.tar.gz ]; then
    29         wget ftp://ftp.cwru.edu/pub/bash/readline-${VERSION}.tar.gz
     30  wget ftp://ftp.cwru.edu/pub/bash/readline-${VERSION}.tar.gz
    3031fi
    3132
     
    4445COUNT=1
    4546while [ ${COUNT} -le ${FILES} ]; do
    46         cd /tmp/readline-${VERSION}           
    47         DLCOUNT="${COUNT}"
    48         SKIPME=no
    49         if [ "${COUNT}" -lt "100" ]; then
    50                 DLCOUNT="0${COUNT}"
    51         fi
    52         if [ "${COUNT}" -lt "10" ]; then
    53                 DLCOUNT="00${COUNT}"
    54         fi
    55         for skip in ${SKIPPATCH} ; do
    56                 if [ "${DLCOUNT}" = "$skip" ]; then
    57                         echo "Patch readline${VERSION2}-${DLCOUNT} skipped"
    58                         SKIPPED="${SKIPPED} ${DLCOUNT}"
    59                         SKIPME=yes
    60                 fi
    61         done
    62         if [ "${SKIPME}" != "yes" ]; then
    63                 if ! [ -e ${VERSION}.${DLCOUNT} ]; then
    64                         wget --quiet ${PATCHURL}/readline${VERSION2}-${DLCOUNT}
    65                 fi
    66                 cd ${CURRENTDIR}
    67                 patch --dry-run -s -f -Np0 -i /tmp/readline-${VERSION}/readline${VERSION2}-${DLCOUNT}
    68                 if [ "$?" = "0" ]; then
    69                         echo "Patch readline${VERSION2}-${DLCOUNT} applied"
    70                         patch -s -Np0 -i /tmp/readline-${VERSION}/readline${VERSION2}-${DLCOUNT}
    71                 else
    72                         echo "Patch readline${VERSION2}-${DLCOUNT} not applied"
    73                         rm -f /tmp/readline-${VERSION}/readline${VERSION2}-${DLCOUNT}
    74                         SKIPPED="${SKIPPED} ${DLCOUNT}"
    75                 fi
    76         fi
    77         COUNT=`expr ${COUNT} + 1`
     47  cd /tmp/readline-${VERSION}           
     48  DLCOUNT="${COUNT}"
     49  SKIPME=no
     50  if [ "${COUNT}" -lt "100" ]; then
     51    DLCOUNT="0${COUNT}"
     52  fi
     53  if [ "${COUNT}" -lt "10" ]; then
     54    DLCOUNT="00${COUNT}"
     55  fi
     56  for skip in ${SKIPPATCH} ; do
     57    if [ "${DLCOUNT}" = "$skip" ]; then
     58      echo "Patch readline${VERSION2}-${DLCOUNT} skipped"
     59      SKIPPED="${SKIPPED} ${DLCOUNT}"
     60      SKIPME=yes
     61    fi
     62  done
     63  if [ "${SKIPME}" != "yes" ]; then
     64    if ! [ -e ${VERSION}.${DLCOUNT} ]; then
     65      wget --quiet ${PATCHURL}/readline${VERSION2}-${DLCOUNT}
     66    fi
     67    cd ${CURRENTDIR}
     68    patch --dry-run -s -f -Np0 -i /tmp/readline-${VERSION}/readline${VERSION2}-${DLCOUNT}
     69    if [ "$?" = "0" ]; then
     70      echo "Patch readline${VERSION2}-${DLCOUNT} applied"
     71      patch -s -Np0 -i /tmp/readline-${VERSION}/readline${VERSION2}-${DLCOUNT}
     72    else
     73      echo "Patch readline${VERSION2}-${DLCOUNT} not applied"
     74      rm -f /tmp/readline-${VERSION}/readline${VERSION2}-${DLCOUNT}
     75      SKIPPED="${SKIPPED} ${DLCOUNT}"
     76     fi
     77    fi
     78    COUNT=`expr ${COUNT} + 1`
    7879done
    7980
     
    8384#
    8485for dir in $(find * -type d); do
    85         cd /usr/src/readline-${VERSION}/${dir}
    86         for file in $(find . -name '*~'); do
    87                 rm -f ${file}
    88         done
    89         for file in $(find . -name '*.orig'); do
    90                 rm -f ${file}
    91         done
     86  cd /usr/src/readline-${VERSION}/${dir}
     87  for file in $(find . -name '*~'); do
     88    rm -f ${file}
     89  done
     90  for file in $(find . -name '*.orig'); do
     91    rm -f ${file}
     92  done
    9293done
    9394cd /usr/src/readline-${VERSION}
     
    104105echo "Description: Contains all upstream patches up to ${VERSION}-${FILES}" >> readline-${VERSION}-branch_update-x.patch
    105106if [ -n "${SKIPPED}" ]; then
    106         echo "            Thee following patches were skipped" >> readline-${VERSION}-branch_update-x.patch
    107         echo "            ${SKIPPED}" >> readline-${VERSION}-branch_update-x.patch
     107  echo "            Thee following patches were skipped" >> readline-${VERSION}-branch_update-x.patch
     108  echo "            ${SKIPPED}" >> readline-${VERSION}-branch_update-x.patch
    108109fi
    109110echo "" >> readline-${VERSION}-branch_update-x.patch
    110111diff -Naur readline-${VERSION}.orig readline-${VERSION} >> readline-${VERSION}-branch_update-x.patch
    111112echo "Created /usr/src/readline-${VERSION}-branch_update-x.patch."
    112 
  • scripts/patch/vim-patch.sh

    rd8b9d99 r9676bac  
    99#
    1010if [ "${VERSION}" = "" ]; then
    11         echo "$0 - Vim_Version"
    12         echo "This will Create a Patch for Vim Vim_Version"
     11  echo "$0 - Vim_Version"
     12  echo "This will Create a Patch for Vim Vim_Version"
     13  exit 255
    1314fi
    1415
     
    2728#
    2829if ! [ -e vim-${VERSION}.tar.bz2 ]; then
    29         wget ftp://ftp.vim.org/pub/vim/unix/vim-${VERSION}.tar.bz2
     30  wget ftp://ftp.vim.org/pub/vim/unix/vim-${VERSION}.tar.bz2
    3031fi
    3132
     
    4445COUNT=1
    4546while [ ${COUNT} -le ${FILES} ]; do
    46         cd /tmp/vim-${VERSION}           
    47         DLCOUNT="${COUNT}"
    48         SKIPME=no
    49         if [ "${COUNT}" -lt "100" ]; then
    50                 DLCOUNT="0${COUNT}"
    51         fi
    52         if [ "${COUNT}" -lt "10" ]; then
    53         DLCOUNT="00${COUNT}"
    54         fi
    55         for skip in ${SKIPPATCH} ; do
    56                 if [ "${DLCOUNT}" = "${skip}" ]; then
    57                         echo "Patch ${VERSION}.${DLCOUNT} skipped"
    58                         SKIPPED="${SKIPPED} ${DLCOUNT}"
    59                         SKIPME=yes
    60                 fi
    61         done
    62         if [ "${SKIPME}" != "yes" ]; then
    63         if ! [ -e ${VERSION}.${DLCOUNT} ]; then
    64                 wget --quiet $PATCHURL/${VERSION}.${DLCOUNT}
    65         fi
    66                 cd $CURRENTDIR
    67                 patch --dry-run -s -f -Np0 -i /tmp/vim-${VERSION}/${VERSION}.${DLCOUNT}
    68                 if [ "$?" = "0" ]; then
    69                 echo "Patch ${VERSION}.${DLCOUNT} applied"
    70                         patch -s -Np0 -i /tmp/vim-${VERSION}/${VERSION}.${DLCOUNT}
    71                 else
    72                         echo "Patch ${VERSION}.${DLCOUNT} not applied"
    73                         rm -f /tmp/vim-${VERSION}/${VERSION}.${DLCOUNT}
    74                         SKIPPED="${SKIPPED} ${DLCOUNT}"
    75                 fi
    76         fi
    77         COUNT=`expr ${COUNT} + 1`
     47  cd /tmp/vim-${VERSION}           
     48  DLCOUNT="${COUNT}"
     49  SKIPME=no
     50  if [ "${COUNT}" -lt "100" ]; then
     51    DLCOUNT="0${COUNT}"
     52  fi
     53  if [ "${COUNT}" -lt "10" ]; then
     54    DLCOUNT="00${COUNT}"
     55  fi
     56  for skip in ${SKIPPATCH} ; do
     57    if [ "${DLCOUNT}" = "${skip}" ]; then
     58      echo "Patch ${VERSION}.${DLCOUNT} skipped"
     59      SKIPPED="${SKIPPED} ${DLCOUNT}"
     60      SKIPME=yes
     61    fi
     62  done
     63  if [ "${SKIPME}" != "yes" ]; then
     64    if ! [ -e ${VERSION}.${DLCOUNT} ]; then
     65      wget --quiet $PATCHURL/${VERSION}.${DLCOUNT}
     66    fi
     67    cd $CURRENTDIR
     68    patch --dry-run -s -f -Np0 -i /tmp/vim-${VERSION}/${VERSION}.${DLCOUNT}
     69    if [ "$?" = "0" ]; then
     70      echo "Patch ${VERSION}.${DLCOUNT} applied"
     71      patch -s -Np0 -i /tmp/vim-${VERSION}/${VERSION}.${DLCOUNT}
     72    else
     73      echo "Patch ${VERSION}.${DLCOUNT} not applied"
     74      rm -f /tmp/vim-${VERSION}/${VERSION}.${DLCOUNT}
     75      SKIPPED="${SKIPPED} ${DLCOUNT}"
     76    fi
     77   fi
     78   COUNT=`expr ${COUNT} + 1`
    7879done
    7980
     
    8182#
    8283for dir in $(find * -type d); do
    83         cd /usr/src/vim${SERIES}
    84         for file in $(find . -name '*~'); do
    85                 rm -f ${file}
    86         done
    87         for file in $(find . -name '*.orig'); do
    88                 rm -f ${file}
    89         done
     84  cd /usr/src/vim${SERIES}
     85  for file in $(find . -name '*~'); do
     86    rm -f ${file}
     87  done
     88  for file in $(find . -name '*.orig'); do
     89    rm -f ${file}
     90  done
    9091done
    9192cd /usr/src/vim${SERIES}
     
    102103echo "Description: Contains all upstream patches up to ${VERSION}.${FILES}" >> vim-${VERSION}-branch_update-x.patch
    103104if [ -n "${SKIPPED}" ]; then
    104         echo "             The following patches were skipped" >> vim-${VERSION}-branch_update-x.patch
    105         echo "            ${SKIPPED}" >> vim-${VERSION}-branch_update-x.patch
     105  echo "             The following patches were skipped" >> vim-${VERSION}-branch_update-x.patch
     106  echo "            ${SKIPPED}" >> vim-${VERSION}-branch_update-x.patch
    106107fi
    107108echo "" >> vim-${VERSION}-branch_update-x.patch
    108109diff -Naur vim${SERIES}.orig vim${SERIES} >> vim-${VERSION}-branch_update-x.patch
    109110echo "Created /usr/src/vim-${VERSION}-branch_update-x.patch."
    110 
Note: See TracChangeset for help on using the changeset viewer.