diff options
author | George Shapovalov <george@gentoo.org> | 2013-08-02 17:38:57 +0000 |
---|---|---|
committer | George Shapovalov <george@gentoo.org> | 2013-08-02 17:38:57 +0000 |
commit | f78386389c33d1b1f38651b1464e331a59448bdf (patch) | |
tree | da92f8d04592bebdd18821b152501346adf7579f /eclass | |
parent | Remove old. (diff) | |
download | historical-f78386389c33d1b1f38651b1464e331a59448bdf.tar.gz historical-f78386389c33d1b1f38651b1464e331a59448bdf.tar.bz2 historical-f78386389c33d1b1f38651b1464e331a59448bdf.zip |
added basic checks for empty patch dirs
Diffstat (limited to 'eclass')
-rw-r--r-- | eclass/gnatbuild.eclass | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/eclass/gnatbuild.eclass b/eclass/gnatbuild.eclass index c099e2a5b864..6f7261ed2496 100644 --- a/eclass/gnatbuild.eclass +++ b/eclass/gnatbuild.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2012 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/gnatbuild.eclass,v 1.55 2012/09/15 16:16:53 zmedico Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/gnatbuild.eclass,v 1.56 2013/08/02 17:38:57 george Exp $ # # Author: George Shapovalov <george@gentoo.org> # Belongs to: ada herd <ada@gentoo.org> @@ -337,9 +337,16 @@ gnatbuild_src_unpack() { cd "${S}" # patching gcc sources, following the toolchain - if [[ -d "${FILESDIR}"/${SLOT} ]] ; then - EPATCH_MULTI_MSG="Applying Gentoo patches ..." \ - epatch "${FILESDIR}"/${SLOT}/*.patch + # first, the common patches + if [[ -d "${FILESDIR}"/patches ]] && [[ ! -z $(ls "${FILESDIR}"/patches/*.patch 2>/dev/null) ]] ; then + EPATCH_MULTI_MSG="Applying common Gentoo patches ..." \ + epatch "${FILESDIR}"/patches/*.patch + fi + # + # then per SLOT + if [[ -d "${FILESDIR}"/patches/${SLOT} ]] && [[ ! -z $(ls "${FILESDIR}"/patches/${SLOT}/*.patch 2>/dev/null) ]] ; then + EPATCH_MULTI_MSG="Applying SLOT-specific Gentoo patches ..." \ + epatch "${FILESDIR}"/patches/${SLOT}/*.patch fi # Replacing obsolete head/tail with POSIX compliant ones ht_fix_file */configure |