/[gentoo-x86]/eclass/kernel-2.eclass
Gentoo

Diff of /eclass/kernel-2.eclass

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.111 Revision 1.112
1# Copyright 1999-2005 Gentoo Foundation 1# Copyright 1999-2005 Gentoo Foundation
2# Distributed under the terms of the GNU General Public License v2 2# Distributed under the terms of the GNU General Public License v2
3# $Header: /var/cvsroot/gentoo-x86/eclass/kernel-2.eclass,v 1.111 2005/03/10 22:37:55 johnm Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/kernel-2.eclass,v 1.112 2005/03/13 00:27:19 r3pek Exp $
4 4
5# Description: kernel.eclass rewrite for a clean base regarding the 2.6 5# Description: kernel.eclass rewrite for a clean base regarding the 2.6
6# series of kernel with back-compatibility for 2.4 6# series of kernel with back-compatibility for 2.4
7# 7#
8# Maintainer: John Mylchreest <johnm@gentoo.org> 8# Maintainer: John Mylchreest <johnm@gentoo.org>
468 unset z 468 unset z
469 STRICT_COUNT=$((${STRICT_COUNT} + 1)) 469 STRICT_COUNT=$((${STRICT_COUNT} + 1))
470 for((y=0; y<$((6 - ${#STRICT_COUNT})); y++)); 470 for((y=0; y<$((6 - ${#STRICT_COUNT})); y++));
471 do z="${z}0"; 471 do z="${z}0";
472 done 472 done
473 STRICT_COUNT="${z}${STRICT_COUNT}" 473 PATCH_ORDER="${z}${STRICT_COUNT}"
474 474
475 mkdir -p ${KPATCH_DIR}/${STRICT_COUNT}/ 475 mkdir -p ${KPATCH_DIR}/${PATCH_ORDER}/
476 ${PIPE_CMD} ${i/:*/} -C ${KPATCH_DIR}/${STRICT_COUNT}/ 1>/dev/null 476 ${PIPE_CMD} ${i/:*/} -C ${KPATCH_DIR}/${PATCH_ORDER}/ 1>/dev/null
477 else 477 else
478 ${PIPE_CMD} ${i/:*/} -C ${KPATCH_DIR} 1>/dev/null 478 ${PIPE_CMD} ${i/:*/} -C ${KPATCH_DIR} 1>/dev/null
479 fi 479 fi
480 480
481 if [ $? == 0 ]; then 481 if [ $? == 0 ]; then
517 unset z 517 unset z
518 STRICT_COUNT=$((${STRICT_COUNT} + 1)) 518 STRICT_COUNT=$((${STRICT_COUNT} + 1))
519 for((y=0; y<$((6 - ${#STRICT_COUNT})); y++)); 519 for((y=0; y<$((6 - ${#STRICT_COUNT})); y++));
520 do z="${z}0"; 520 do z="${z}0";
521 done 521 done
522 STRICT_COUNT="${z}${STRICT_COUNT}" 522 PATCH_ORDER="${z}${STRICT_COUNT}"
523 523
524 mkdir -p ${KPATCH_DIR}/${STRICT_COUNT}/ 524 mkdir -p ${KPATCH_DIR}/${PATCH_ORDER}/
525 $(${PIPE_CMD} ${i} > ${KPATCH_DIR}/${STRICT_COUNT}/${x}.patch${PATCH_LEVEL}) 525 $(${PIPE_CMD} ${i} > ${KPATCH_DIR}/${PATCH_ORDER}/${x}.patch${PATCH_LEVEL})
526 else 526 else
527 $(${PIPE_CMD} ${i} > ${KPATCH_DIR}/${x}.patch${PATCH_LEVEL}) 527 $(${PIPE_CMD} ${i} > ${KPATCH_DIR}/${x}.patch${PATCH_LEVEL})
528 fi 528 fi
529 fi 529 fi
530 fi 530 fi
550 for i in $(find ${x} -maxdepth 1 -iname "*.patch*" -or -iname "*.diff*" | sort -n); do 550 for i in $(find ${x} -maxdepth 1 -iname "*.patch*" -or -iname "*.diff*" | sort -n); do
551 STDERR_T="${T}/${i/*\//}" 551 STDERR_T="${T}/${i/*\//}"
552 STDERR_T="${STDERR_T/.patch*/.err}" 552 STDERR_T="${STDERR_T/.patch*/.err}"
553 553
554 [ -z ${i/*.patch*/} ] && PATCH_DEPTH=${i/*.patch/} 554 [ -z ${i/*.patch*/} ] && PATCH_DEPTH=${i/*.patch/}
555 [ -z ${i/*.diff*/} ] && PATCH_DEPTH=${i/*.diff/} 555 #[ -z ${i/*.diff*/} ] && PATCH_DEPTH=${i/*.diff/}
556 556
557 if [ -z "${PATCH_DEPTH}" ]; then PATCH_DEPTH=0; fi 557 if [ -z "${PATCH_DEPTH}" ]; then PATCH_DEPTH=0; fi
558 558
559 ebegin "Applying ${i/*\//} (-p${PATCH_DEPTH}+)" 559 ebegin "Applying ${i/*\//} (-p${PATCH_DEPTH}+)"
560 while [ ${PATCH_DEPTH} -lt 5 ]; do 560 while [ ${PATCH_DEPTH} -lt 5 ]; do

Legend:
Removed from v.1.111  
changed lines
  Added in v.1.112

  ViewVC Help
Powered by ViewVC 1.1.20