From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16873 invoked by alias); 28 Apr 2017 18:59:12 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 16850 invoked by uid 89); 28 Apr 2017 18:59:11 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=UD:conf, 20170418, 2017-04-18 X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 28 Apr 2017 18:59:08 +0000 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 825FCFBAB; Fri, 28 Apr 2017 18:59:09 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 825FCFBAB Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=law@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 825FCFBAB Received: from localhost.localdomain (ovpn-117-12.phx2.redhat.com [10.3.117.12]) by smtp.corp.redhat.com (Postfix) with ESMTP id 6399017BB6; Fri, 28 Apr 2017 18:59:08 +0000 (UTC) Subject: Re: [PATCH] Fix fixincludes for canadian cross builds - next try To: Bernd Edlinger Cc: Yvan Roux , Bruce Korb , "gcc-patches@gcc.gnu.org" , Richard Biener , Jakub Jelinek , Matthew Fortune References: <4b114aec-1ab7-7054-1086-a06d3b358a27@gnu.org> From: Jeff Law Message-ID: <2d83a6cb-1bef-f16c-15ef-7bd14b71c238@redhat.com> Date: Fri, 28 Apr 2017 19:13:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2017-04/txt/msg01529.txt.bz2 On 04/20/2017 01:11 PM, Bernd Edlinger wrote: > Hi! > > This is my new attempt to clean up the different cross compiler > configurations. It turned out to be a very complicated matter, > so I thought it would be better to postpone it to the stage1. > > In a canadian cross compiler setup we have a different header dir path > for use in the build and later on the target, which is written to > install-tools/mkheaders.conf, so I propose to export SYSTEM_HEADER_DIR > and BUILD_SYSTEM_HEADER_DIR from configure.ac to be used in Makefile.in. > > I also removed unnecessary handling of --with-headers, because > the headers are copied to sys-include and thus it is not necessary to > use the original path here. > > If --with-sysroot or --with-build-sysroot is used the SYSTEM_HEADER_DIR > or BUILD_SYSTEM_HEADER_DIR contain $${sysroot_headers_suffix}, > which is normally an empty string, but on mips it may be something > like "mips-r2" which gets appended to the sysroot for use of fixincludes > but "target_header_dir" which is used in configure to find things like > the GLIBC version it is not used. I assume that that either does > not create problems and is silently ignored, or that people have a > work around, my patch should not change that, however I have not been > able to setup a sysroot for mips*-img-linux* or mips*-mti-linux* which > seem to be the only targets where this might make a difference. > > I have tested all different combinations of --with-sysroot / > --with-build-sysroot. Even a native build with --with-sysroot works. > Except go of course: cross-builds are a no-go area for the go language > in general;) > > As before I would appreciate your kind help with testing the many > different build setups. > > > So far I have tested native x86_64-pc-linux-gnu and arm-linux-gnueabihf > cross build configurations. And everything looks sane. > > Is it OK for trunk? > > > Thanks > Bernd. > > > fixinc.diff > > > 2017-04-18 Bernd Edlinger > > * configure.ac (SYSTEM_HEADER_DIR, BUILD_SYSTEM_HEADER_DIR, > target_header_dir): Set correctly. > * configure: Regenerated. > * Makefile.in (BUILD_SYSTEM_HEADER_DIR): New make variabe. > (LIMITS_H_TEST, if_multiarch, stmp-fixinc): Use BUILD_SYSTEM_HEADER_DIR > instead of SYSTEM_HEADER_DIR. OK. Please watch for fallout. I'm not entirely sure mingw is working right now, but they're often affected by this stuff. jeff