From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: <ard.biesheuvel@linaro.org> Received: from mail-io0-x234.google.com (mail-io0-x234.google.com [IPv6:2607:f8b0:4001:c06::234]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 09DC921A16EFC for <edk2-devel@lists.01.org>; Thu, 18 May 2017 14:52:26 -0700 (PDT) Received: by mail-io0-x234.google.com with SMTP id p24so37333134ioi.0 for <edk2-devel@lists.01.org>; Thu, 18 May 2017 14:52:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=/TVJ3H7XHEhKLz7rjV8/TpnUDwMwunRUAO10JEuaGyE=; b=LJ8nvNYlQBUbVNUzVezQ8f/fC/EHEvCNTORFi30KmU01EYC/jfv0NDzT7xe00PjLcI ieyLxtIX2VAxzkATefgxWuXarxqsSZwvFBshf318qStrw7hs/Y7b3W9u6peK0rCiXt2B qqlUT39sWj1qDhy78G00HlywqtaJvyPTQsIAs= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=/TVJ3H7XHEhKLz7rjV8/TpnUDwMwunRUAO10JEuaGyE=; b=lbTVaKq8/H9Lcym12rk4sMgcJQ0ISx9fW33UDZnIt/T4wg+UM/M+zAlzq0Ti0Uk7GJ yDewjKzbaymdx+sLu7Nhg8sRJ7fOUNDsiWe/1BVvS2232E3AdV8Yr0jW15k8gTi5K2uq hbGi3CU5o81AcZooIkfbjGxypzM2PJdzdXPSglJ19LQ/S1pCeZK/UoYXKfCTw8kWo260 iNN8ImMuGHF8JnsQk4KiTwaWXxn0oIoOJ2eTq3KNNHmoZzgN7GwbYIOpSuuDmweygwY6 3fJl0BDdSxzXF00Bfv2IF7PxEUTDYdarhoO5hASjK+/rNCoxlkBzIruGba5qpIUFkO+q RmdA== X-Gm-Message-State: AODbwcA8aNpvH57i/p86WhnPXRHLi42O9DmaWrRichGiexnv67XJ1M1M E9uQkpYE/Fu4ZFeUAk9mFLnu/h9BAomt X-Received: by 10.107.130.166 with SMTP id m38mr7434861ioi.87.1495144345274; Thu, 18 May 2017 14:52:25 -0700 (PDT) MIME-Version: 1.0 Received: by 10.107.164.24 with HTTP; Thu, 18 May 2017 14:52:24 -0700 (PDT) In-Reply-To: <20170518210532.kfdccrlch2s5427b@xps13.dannf> References: <20170518210532.kfdccrlch2s5427b@xps13.dannf> From: Ard Biesheuvel <ard.biesheuvel@linaro.org> Date: Thu, 18 May 2017 22:52:24 +0100 Message-ID: <CAKv+Gu8rpwv70wgu40zHApDXNtVqX6xtq2nCG93Hr3jpxHDJEg@mail.gmail.com> To: dann frazier <dannf@debian.org> Cc: "edk2-devel@lists.01.org" <edk2-devel@lists.01.org>, Leif Lindholm <leif.lindholm@linaro.org> Subject: Re: [PATCH] BaseTools/GCC ARM/AARCH64: Force disable PIE X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development <edk2-devel.lists.01.org> List-Unsubscribe: <https://lists.01.org/mailman/options/edk2-devel>, <mailto:edk2-devel-request@lists.01.org?subject=unsubscribe> List-Archive: <http://lists.01.org/pipermail/edk2-devel/> List-Post: <mailto:edk2-devel@lists.01.org> List-Help: <mailto:edk2-devel-request@lists.01.org?subject=help> List-Subscribe: <https://lists.01.org/mailman/listinfo/edk2-devel>, <mailto:edk2-devel-request@lists.01.org?subject=subscribe> X-List-Received-Date: Thu, 18 May 2017 21:52:26 -0000 Content-Type: text/plain; charset="UTF-8" On 18 May 2017 at 22:05, dann frazier <dannf@debian.org> wrote: > After Debian's toolchain switched to PIE by default, our edk2 builds began > to fail to build (GCC49 w/ gcc 6.3). This patch fixes the build by forcing > off PIE for both ARM and AARCH64 builds. > > Contributed-under: TianoCore Contribution Agreement 1.0 > Signed-off-by: dann frazier <dannf@debian.org> > --- > BaseTools/Conf/tools_def.template | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/BaseTools/Conf/tools_def.template b/BaseTools/Conf/tools_def.template > index 427ef1bb3a..cf35cb1353 100755 > --- a/BaseTools/Conf/tools_def.template > +++ b/BaseTools/Conf/tools_def.template > @@ -4339,9 +4339,9 @@ DEFINE GCC_ALL_CC_FLAGS = -g -Os -fshort-wchar -fno-builtin -fno-stri > DEFINE GCC_IA32_CC_FLAGS = DEF(GCC_ALL_CC_FLAGS) -m32 -malign-double -freorder-blocks -freorder-blocks-and-partition -O2 -mno-stack-arg-probe > DEFINE GCC_X64_CC_FLAGS = DEF(GCC_ALL_CC_FLAGS) -mno-red-zone -Wno-address -mno-stack-arg-probe > DEFINE GCC_IPF_CC_FLAGS = DEF(GCC_ALL_CC_FLAGS) -minline-int-divide-min-latency > -DEFINE GCC_ARM_CC_FLAGS = DEF(GCC_ALL_CC_FLAGS) -mlittle-endian -mabi=aapcs -fno-short-enums -funsigned-char -ffunction-sections -fdata-sections -fomit-frame-pointer -Wno-address -mthumb -mfloat-abi=soft > +DEFINE GCC_ARM_CC_FLAGS = DEF(GCC_ALL_CC_FLAGS) -mlittle-endian -mabi=aapcs -fno-short-enums -funsigned-char -ffunction-sections -fdata-sections -fomit-frame-pointer -Wno-address -mthumb -mfloat-abi=soft -fno-pie -no-pie > DEFINE GCC_ARM_CC_XIPFLAGS = -mno-unaligned-access > -DEFINE GCC_AARCH64_CC_FLAGS = DEF(GCC_ALL_CC_FLAGS) -mlittle-endian -fno-short-enums -fverbose-asm -funsigned-char -ffunction-sections -fdata-sections -Wno-address -fno-asynchronous-unwind-tables -fno-pic > +DEFINE GCC_AARCH64_CC_FLAGS = DEF(GCC_ALL_CC_FLAGS) -mlittle-endian -fno-short-enums -fverbose-asm -funsigned-char -ffunction-sections -fdata-sections -Wno-address -fno-asynchronous-unwind-tables -fno-pic -fno-pie -no-pie Please remove the -no-pie from the shared CC_FLAGS: my 4.9 toolchain does not appear to support it. > DEFINE GCC_AARCH64_CC_XIPFLAGS = -mstrict-align > DEFINE GCC_DLINK_FLAGS_COMMON = -nostdlib --pie > DEFINE GCC_DLINK2_FLAGS_COMMON = -Wl,--script=$(EDK_TOOLS_PATH)/Scripts/GccBase.lds > -- > 2.11.0 > Please cc Liming and Yonghong when sending out your v2. Thanks, Ard.