From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 0C06359CB2 for ; Mon, 18 Apr 2016 08:07:10 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 48E1821C125; Mon, 18 Apr 2016 08:07:06 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id CEF7321C125 for ; Mon, 18 Apr 2016 08:07:05 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 62A1C3406C0 for ; Mon, 18 Apr 2016 08:07:04 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id A0D0513FE for ; Mon, 18 Apr 2016 08:07:01 +0000 (UTC) From: "Michael Haubenwallner" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Michael Haubenwallner" Message-ID: <1460966760.c658ad8cc73fde6590c34fce7af7340b76c01d21.haubi@gentoo> Subject: [gentoo-commits] repo/proj/prefix:master commit in: eclass/ X-VCS-Repository: repo/proj/prefix X-VCS-Files: eclass/toolchain.eclass X-VCS-Directories: eclass/ X-VCS-Committer: haubi X-VCS-Committer-Name: Michael Haubenwallner X-VCS-Revision: c658ad8cc73fde6590c34fce7af7340b76c01d21 X-VCS-Branch: master Date: Mon, 18 Apr 2016 08:07:01 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: dc0942cf-1927-4bf4-9132-34a4178338a6 X-Archives-Hash: 04cad3a54e434da2bd2868bcc4b4882b commit: c658ad8cc73fde6590c34fce7af7340b76c01d21 Author: Michael Haubenwallner ssi-schaefer com> AuthorDate: Fri Apr 15 09:15:09 2016 +0000 Commit: Michael Haubenwallner gentoo org> CommitDate: Mon Apr 18 08:06:00 2016 +0000 URL: https://gitweb.gentoo.org/repo/proj/prefix.git/commit/?id=c658ad8c toolchain.eclass: support CYGWINPORTS_GITREV to take patches from github.com/cygwinports/gcc eclass/toolchain.eclass | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass index 2696110..149a991 100644 --- a/eclass/toolchain.eclass +++ b/eclass/toolchain.eclass @@ -366,6 +366,10 @@ get_gcc_src_uri() { fi fi + # Cygwin patches from https://github.com/cygwinports/gcc + [[ -n ${CYGWINPORTS_GITREV} ]] && \ + GCC_SRC_URI+=" elibc_Cygwin? ( https://github.com/cygwinports/gcc/archive/${CYGWINPORTS_GITREV}.zip )" + echo "${GCC_SRC_URI}" } @@ -484,6 +488,8 @@ gcc_quick_unpack() { use_if_iuse boundschecking && unpack "bounds-checking-gcc-${HTB_GCC_VER}-${HTB_VER}.patch.bz2" + [[ -n ${CYGWINPORTS_GITREV} ]] && use elibc_Cygwin && unpack "${CYGWINPORTS_GITREV}.zip" + popd > /dev/null } @@ -508,6 +514,7 @@ toolchain_src_prepare() { fi do_gcc_HTB_patches do_gcc_PIE_patches + do_gcc_CYGWINPORTS_patches epatch_user if ( tc_version_is_at_least 4.8.2 || use hardened ) && ! use vanilla ; then @@ -656,6 +663,19 @@ do_gcc_PIE_patches() { BRANDING_GCC_PKGVERSION="${BRANDING_GCC_PKGVERSION}, pie-${PIE_VER}" } +do_gcc_CYGWINPORTS_patches() { + [[ -n ${CYGWINPORTS_GITREV} ]] || return 0 + use elibc_Cygwin || return 0 + + local p d="${WORKDIR}/gcc-${CYGWINPORTS_GITREV}" + for p in $( + eval "$(sed -ne '/PATCH_URI="/,/"/p' < "${d}"/gcc.cygport)" + echo ${PATCH_URI} + ); do + epatch "${d}/${p}" + done +} + # configure to build with the hardened GCC specs as the default make_gcc_hard() { # we want to be able to control the pie patch logic via something other @@ -1010,7 +1030,7 @@ toolchain_src_configure() { confgcc+=( --enable-shared ) fi case ${CHOST} in - mingw*|*-mingw*|*-cygwin) + mingw*|*-mingw*) confgcc+=( --enable-threads=win32 ) ;; *) confgcc+=( --enable-threads=posix ) ;;