From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.oetec.com (mail.oetec.com [108.160.241.186]) by sourceware.org (Postfix) with ESMTPS id DA5263858D33 for ; Sat, 2 Dec 2023 20:23:59 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org DA5263858D33 Authentication-Results: sourceware.org; dmarc=pass (p=quarantine dis=none) header.from=blastwave.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=blastwave.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org DA5263858D33 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=108.160.241.186 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1701548642; cv=none; b=r8JOzX8jioQvipy8keQE8BxAgtt4pRAcS5rBAXo/LwGyZT6QFUqMoITNOIMzpfbUUPQuq8dr/tui/QHnra2a8W1sH9YN7uItGCb/l1LwjIibW2sQvXwrygc2OUYy/83NwWINi73+Q22iqmLGbKxAyXQL6YO7QQmuhF82X0WZxBs= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1701548642; c=relaxed/simple; bh=/6QiI+Owu7M1Z6ClDYB4R8VqlnFsleoQ3nj6EPJQo30=; h=DKIM-Signature:Message-ID:Date:MIME-Version:Subject:To:From; b=ML7oQW1hwgHpbMKHUUgGK2fFmqQBeOz7iOLk1MOWjwBLMSkAAyFxHPhZQDpnixYAedrZ+7Twqxb/CjLpSX7f8MXdMuJolYjZyPz6APoX0zH2tnXxz4iV5r4cLhJYySpuYXCop0qxGEYgBKJQRSdWXkWshrd07J3QdPvVxHNXQkw= ARC-Authentication-Results: i=1; server2.sourceware.org Received: from [172.16.35.9] (cpe8c6a8d4d360a-cm8c6a8d4d3608.cpe.net.cable.rogers.com [99.253.151.152]) (authenticated bits=0) by mail.oetec.com (8.17.1/8.16.1) with ESMTPSA id 3B2KNuYD056098 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Sat, 2 Dec 2023 15:23:57 -0500 (EST) (envelope-from dclarke@blastwave.org) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=blastwave.org; s=default; t=1701548637; bh=/6QiI+Owu7M1Z6ClDYB4R8VqlnFsleoQ3nj6EPJQo30=; h=Date:Subject:To:References:From:In-Reply-To; b=GiTdhuO9EmnDEWhPOdfcgsg+v+nt7F5atZoSwJiLMxossn8r9k3lT3LGVuvPGOZ89 JuWNTwS84ED9gpiXgOq4mak+RAnhZvllU7q8MyWy2LA1PF8cTRzl2OtOb5NdRCuqcS NnTw4+ZVDfXZts2TFa3uwAUJhcbXaDLpp8HfdJBP2Y3iO84a4FNk7cZ9vXKdNlTOWW rAv1QP/xZraCG3zdom4SkL15gkmHQK82GrLaabEFJUWPgHvb5BayhcG5CIiK38iMbM k9El8+/reB6M1C7GzGCURsnErQyvqWNGc7ZTNMeAgjt3h0l7e14CA07LHjFOcv/+U/ dUElT4Qo1x0rw== Message-ID: <3b23b414-af0e-0fe0-7d39-fb9a3ec8b525@blastwave.org> Date: Sat, 2 Dec 2023 15:23:56 -0500 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.15.0 Subject: Re: Issues Building GNU GCC 4.5.4 - IRIX 5.3XFS Content-Language: en-CA To: gcc-help@gcc.gnu.org References: From: Dennis Clarke Organization: GENUNIX In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-oetec-MailScanner-Information: Please contact the ISP for more information X-oetec-MailScanner-ID: 3B2KNuYD056098 X-oetec-MailScanner: Found to be clean X-oetec-MailScanner-From: dclarke@blastwave.org X-Spam-Status: No, score=-3.2 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,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 List-Id: On 12/2/23 14:06, Darcy Wilson via Gcc-help wrote: > Hi there, > This looks like a fun little project :) > Object file format error in: /usr/tgcware/gcc45/lib/gcc/mips-sgi-irix5.3/4.5.3/irix-crti.o: bad symbolic header (magic number) > collect2: ld returned 1 exit status > Yikes. Can you dump out the first 16 bytes of that file please ? Better yet can you compile a hello.c like so : io$ cat hello.c #define _XOPEN_SOURCE 500 #include int main ( int argc, char **argv ) { printf("This is 32-bit armv7l.\n"); return 42; } io$ $CC $CFLAGS $CPPFLAGS -c -o hello.o hello.c io$ file hello.o hello.o: ELF 32-bit LSB relocatable, ARM, EABI5 version 1 (SYSV), with debug_info, not stripped io$ od -Ax -t x1 -v -N 32 hello.o 000000 7f 45 4c 46 01 01 01 00 00 00 00 00 00 00 00 00 000010 01 00 28 00 01 00 00 00 00 00 00 00 00 00 00 00 000020 My hope is that the first four bytes you see in irix-crti.o are just the usual 0x7F 45 4C 46 for an ELF file. The next three bytes on your machine may be interesting and I also hope they are 01 01 01. I do not recall if the old MIPS R4400 was big endian or not. So one of those bytes may be a 02. Then in offset 0x12 you should have either : #define EM_MIPS 8 /* MIPS R3000 big-endian */ #define EM_MIPS_RS3_LE 10 /* MIPS R3000 little-endian */ Regardless you have software that came from someone else and you really do not know how it was built nor what hardware ( if any ) was used. So it would be nice to know that the ELF files are actually reasonable on the cool MIPS R4400 snazzy box you have there. > It's calling ld from, > > /usr/bin/../lib/ld > > And then the build process stops, saying that the C Compiler cannot Yeah ... it would do that if the software really doesn't work on your hardware. > Any help would be appreciated Let's start by just seeing if you can run gcc --version and then gcc -v with whatever you have there from the planet Jupiter. Dennis Clarke RISC-V/SPARC/PPC/ARM/CISC UNIX and Linux spoken