-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Ensure all compilers are mipsel not mipseb (#13)
* Ensure 2.6.x are mipsel not mipseb * Ensure all compilers target mipsel by default * whoops
- Loading branch information
Showing
19 changed files
with
131 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
build-*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,12 @@ | ||
ifndef VERSION | ||
$(error You must specify a VERSION e.g. VERSION=2.8.1) | ||
endif | ||
|
||
all: | ||
docker compose up -d --build | ||
mkdir -p build-gcc-$(VERSION) | ||
docker compose up --build && docker compose down | ||
|
||
clean: | ||
rm -rf build/ | ||
rm -rf build-gcc-*/ | ||
|
||
.PHONY: all |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
--- mips.h 1994-07-11 19:22:16.000000000 +0100 | ||
+++ mips-patched.h 2023-10-04 08:36:53.516458765 +0100 | ||
@@ -544,8 +544,8 @@ | ||
/* Names to predefine in the preprocessor for this target machine. */ | ||
|
||
#ifndef CPP_PREDEFINES | ||
-#define CPP_PREDEFINES "-Dmips -Dunix -Dhost_mips -DMIPSEB -DR3000 -DSYSTYPE_BSD43 \ | ||
--D_mips -D_unix -D_host_mips -D_MIPSEB -D_R3000 -D_SYSTYPE_BSD43 \ | ||
+#define CPP_PREDEFINES "-Dmips -Dunix -Dhost_mips -DMIPSEL -DR3000 -DSYSTYPE_BSD43 \ | ||
+-D_mips -D_unix -D_host_mips -D_MIPSEL -D_R3000 -D_SYSTYPE_BSD43 \ | ||
-Asystem(unix) -Asystem(bsd) -Acpu(mips) -Amachine(mips)" | ||
#endif | ||
|
||
@@ -901,6 +901,11 @@ | ||
*/ | ||
#define BITS_BIG_ENDIAN 0 | ||
|
||
+/* Force little-endian */ | ||
+#define MIPSEL | ||
+#define BYTES_BIG_ENDIAN 0 | ||
+#define WORDS_BIG_ENDIAN 0 | ||
+ | ||
/* Define this if most significant byte of a word is the lowest numbered. */ | ||
#ifndef BYTES_BIG_ENDIAN | ||
#ifndef DECSTATION |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
--- mips.h 1995-06-15 19:32:41.000000000 +0000 | ||
+++ mips-patched.h 2023-10-04 09:29:22.998515730 +0000 | ||
@@ -406,6 +406,9 @@ | ||
| TARGET_ENDIAN_DEFAULT)} \ | ||
} | ||
|
||
+/* Default little-endian */ | ||
+#define TARGET_ENDIAN_DEFAULT -MASK_BIG_ENDIAN | ||
+ | ||
/* Default target_flags if no switches are specified */ | ||
|
||
#ifndef TARGET_DEFAULT |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
--- gcc-2.6.3/sdbout.c 1994-09-30 22:23:57.000000000 +0100 | ||
+++ gcc-2.7.1/sdbout.c 1995-06-15 13:07:11.000000000 +0100 | ||
@@ -53,2 +54,2 @@ | ||
@@ -56,2 +57,2 @@ | ||
-#if defined(USG) && !defined(MIPS) && !defined (hpux) && !defined(WINNT) | ||
+#if defined(USG) && !defined(MIPS) && !defined (hpux) && !defined(_WIN32) && !defined(__linux__) | ||
#include <syms.h> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
typedef struct { | ||
unsigned int field; | ||
} Foo; | ||
|
||
unsigned char bar(Foo* foo) { | ||
return foo->field; | ||
} |