/[gentoo-x86]/eclass/base.eclass
Gentoo

Diff of /eclass/base.eclass

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

Revision 1.42 Revision 1.45
1# Copyright 1999-2008 Gentoo Foundation 1# Copyright 1999-2008 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/base.eclass,v 1.42 2010/01/11 17:23:04 scarabeus Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/base.eclass,v 1.45 2010/01/20 12:57:13 spatz Exp $
4 4
5# @ECLASS: base.eclass 5# @ECLASS: base.eclass
6# @MAINTAINER: 6# @MAINTAINER:
7# QA Team <qa@gentoo.org> 7# QA Team <qa@gentoo.org>
8# 8#
14 14
15inherit eutils 15inherit eutils
16 16
17BASE_EXPF="src_unpack src_compile src_install" 17BASE_EXPF="src_unpack src_compile src_install"
18case "${EAPI:-0}" in 18case "${EAPI:-0}" in
19 2|3|4) BASE_EXPF="src_prepare src_configure" ;; 19 2|3|4) BASE_EXPF+=" src_prepare src_configure" ;;
20 *) ;; 20 *) ;;
21esac 21esac
22 22
23EXPORT_FUNCTIONS ${BASE_EXPF} 23EXPORT_FUNCTIONS ${BASE_EXPF}
24 24
72 72
73 pushd "${S}" > /dev/null 73 pushd "${S}" > /dev/null
74 if [[ "$(declare -p PATCHES 2>/dev/null 2>&1)" == "declare -a"* ]]; then 74 if [[ "$(declare -p PATCHES 2>/dev/null 2>&1)" == "declare -a"* ]]; then
75 for x in "${PATCHES[@]}"; do 75 for x in "${PATCHES[@]}"; do
76 debug-print "$FUNCNAME: applying patch from ${x}" 76 debug-print "$FUNCNAME: applying patch from ${x}"
77 [[ -f "${x}" ]] && epatch "${x}"
78 if [[ -d "${x}" ]]; then 77 if [[ -d "${x}" ]]; then
79 # Use standardized names and locations with bulk patching 78 # Use standardized names and locations with bulk patching
80 # Patch directory is ${WORKDIR}/patch 79 # Patch directory is ${WORKDIR}/patch
81 # See epatch() in eutils.eclass for more documentation 80 # See epatch() in eutils.eclass for more documentation
82 EPATCH_SUFFIX=${EPATCH_SUFFIX:=patch} 81 EPATCH_SUFFIX=${EPATCH_SUFFIX:=patch}
86 # variable and restore later 85 # variable and restore later
87 oldval=${EPATCH_SOURCE} 86 oldval=${EPATCH_SOURCE}
88 EPATCH_SOURCE=${x} 87 EPATCH_SOURCE=${x}
89 epatch 88 epatch
90 EPATCH_SOURCE=${oldval} 89 EPATCH_SOURCE=${oldval}
90 else
91 epatch "${x}"
91 fi 92 fi
92 done 93 done
93 else 94 else
94 for x in ${PATCHES}; do 95 for x in ${PATCHES}; do
95 debug-print "$FUNCNAME: patching from ${x}" 96 debug-print "$FUNCNAME: patching from ${x}"

Legend:
Removed from v.1.42  
changed lines
  Added in v.1.45

  ViewVC Help
Powered by ViewVC 1.1.20