From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr1-x42c.google.com (mail-wr1-x42c.google.com [IPv6:2a00:1450:4864:20::42c]) by sourceware.org (Postfix) with ESMTPS id 2500B386EC11 for ; Fri, 17 Jun 2022 12:00:00 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 2500B386EC11 Received: by mail-wr1-x42c.google.com with SMTP id a15so5492047wrh.2 for ; Fri, 17 Jun 2022 05:00:00 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=zZvYSOY+47lhVlwOZMPyt+VjsGetIMUzZUv4GZlF6Sw=; b=PcZVH6LJvzoH86GPmr+Ua5q3mtEgUMUxPuU1dBbUVKHPPURJLhia3gy0Lld29eP7+0 Bg5Ufz6toVf32EONU0sJ6WqgXJajwjZwmr7tMpHGn69D6k1zObxRpELFttATHWTIkpEu YNRawFBQh6FrV/4JWxnoLBgW+XwqV3MwQuYSsWHdhbBU9Pwyd2vUV5IjJNxAbBMK995F fI1pUkGtWk942yMnPW8a3jU0fRSQGQh9GUhcycWOYBo2aoWa185j8TBFJIug0TIcrJvp +tZ/d2BGFgigwzabzwc+lxHAJF7TwdAN+bo9F4M8qy/xHOgCNK7CW7CM4EZF8TFtmBWc gmiw== X-Gm-Message-State: AJIora8oPVpEe0trSKq9lcuM/fg9kX6XnI5wePPUSEPzgdGNXhDyXkuG zRAWtbrluRQRYX4bMmK8KjtoYDfZsR7Suv5noFk= X-Google-Smtp-Source: AGRyM1sdQcIZHuCv9HliBSQxYICKTRkukR5Gi4wmAoPM/rDRKWl8yhRZIdMBcZiPeFD58xPrNRfhOGdb6Ge/VZv59tk= X-Received: by 2002:a05:6000:1812:b0:210:2eb1:4606 with SMTP id m18-20020a056000181200b002102eb14606mr9270687wrh.593.1655467198651; Fri, 17 Jun 2022 04:59:58 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Jonathan Wakely Date: Fri, 17 Jun 2022 12:59:47 +0100 Message-ID: Subject: Re: A ARM target question To: Gary Oblock Cc: Gary Oblock via Gcc-help Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-0.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-help@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-help mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 Jun 2022 12:00:01 -0000 On Fri, 17 Jun 2022 at 06:34, Gary Oblock via Gcc-help wrote: > > Stefan, > > I'm not at all clear which of those many config parameters are meaningful= l. > > I borrowed your --target and tried to build with this: > > ../sources/configure --prefix=3D$BASE/install --disable-bootstrap --enabl= e-language=3Dc --disable-multilib --target=3Darm-linux-gnueabihf > > That failed like this: > > echo | /home/gary/gcc_build_cross/objdir/./gcc/xgcc -B/home/gary/gcc_buil= d_cross/objdir/./gcc/ -E -dM - | \ > sed -n -e 's/^#define \([^_][a-zA-Z0-9_]*\).*/\1/p' \ > -e 's/^#define \(_[^_A-Z][a-zA-Z0-9_]*\).*/\1/p' | \ > sort -u > tmp-macro_list > cc1: error: no include path in which to search for stdc-predef.h Do you have a sysroot for the target? > There was another error after this: > > checking for arm-linux-gnueabihf-gcc... /home/gary/gcc_build_cross/objdir= /./gcc/xgcc -B/home/gary/gcc_build_cross/objdir/./gcc/ -B/home/gary/gcc_bui= ld_cross/install/arm-linux-gnueabihf/bin/ -B/home/gary/gcc_build_cross/inst= all/arm-linux-gnueabihf/lib/ -isystem /home/gary/gcc_build_cross/install/ar= m-linux-gnueabihf/include -isystem /home/gary/gcc_build_cross/install/arm-l= inux-gnueabihf/sys-include > checking for suffix of object files... configure: error: in `/home/gary/g= cc_build_cross/objdir/arm-linux-gnueabihf/libgcc': > configure: error: cannot compute suffix of object files: cannot compile > See `config.log' for more details > make[1]: *** [Makefile:15371: configure-target-libgcc] Error 1 > > Any idea what went wrong? Note I looked at the config.log and there were = lots of > errors there too (not that they were helpful to me.) You need to look in arm-linux-gnueabihf/libgcc/config.log not the top-level config.log, and look for the "cannot compute suffix" error. > > Many years ago I set up a simple GCC cross compiler for mips > as the starting point for the person creating a new target for a new chip= . > It didn't seems so crazy hard as this is proving to be. It's not crazy hard, you just have to do the right steps in the right order. It's not obvious, and not very well documented, but it's not actually difficult. Just a few commands in the right order.