summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn-Mark Bell <jmb@netsurf-browser.org>2022-11-03 20:57:12 +0000
committerJohn-Mark Bell <jmb@netsurf-browser.org>2022-11-03 21:44:57 +0000
commit7a767da220c745dfc58a1c30281c3d1cb10d949a (patch)
tree04e180b41015c6d407f1556234173e916d0636b5
parent2f56bc568de9981bba35e798c30458d9cce2d704 (diff)
downloadnetsurf-7a767da220c745dfc58a1c30281c3d1cb10d949a.tar.gz
netsurf-7a767da220c745dfc58a1c30281c3d1cb10d949a.tar.bz2
Buildsystem: support arm-riscos-gnueabi
-rw-r--r--frontends/riscos/Makefile.tools40
1 files changed, 26 insertions, 14 deletions
diff --git a/frontends/riscos/Makefile.tools b/frontends/riscos/Makefile.tools
index 19a2e7768..8ef4dd019 100644
--- a/frontends/riscos/Makefile.tools
+++ b/frontends/riscos/Makefile.tools
@@ -18,25 +18,30 @@ ifeq ($(HOST),riscos)
ZIP := zip
else
# Cross-build for RO
- # Three options are available:
- # a. GCCSDK 3.4.6 - AOF (machine: arm-unknown-riscos)
- # b. GCCSDK 4 - ELF (machine: arm-unknown-riscos)
- # c. GCCSDK 8+ - ELF, using EABI (machine: arm-riscos-gnueabihf)
+ # Four options are available:
+ # a. GCCSDK 3.4.6 - AOF (machine: arm-unknown-riscos)
+ # b. GCCSDK 4 - ELF (machine: arm-unknown-riscos)
+ # c. GCCSDK 8+ - ELF, using soft-float EABI (machine: arm-riscos-gnueabi)
+ # d. GCCSDK 8+ - ELF, using hard-float EABI (machine: arm-riscos-gnueabihf)
# GCCSDK 3.4.6 and 4 are distinguished by GCCSDK 3.4.6 binary names
# not having the machine prefix (e.g. gcc), whereas GCCSDK 4 binaries
# do (e.g. arm-unknown-riscos-gcc).
# Search for the toolchain install locations if we haven't been told
- # The search order prefers GCCSDK 3.4.6/4 over 8+.
+ # The search order prefers GCCSDK 3.4.6/4 over 8+ and soft-float over hard.
ifeq ($(origin GCCSDK_INSTALL_ENV),undefined)
ifneq ($(realpath /opt/netsurf/arm-unknown-riscos/env),)
GCCSDK_INSTALL_ENV := /opt/netsurf/arm-unknown-riscos/env
else
- ifneq ($(realpath /opt/netsurf/arm-riscos-gnueabihf/env),)
- GCCSDK_INSTALL_ENV := /opt/netsurf/arm-riscos-gnueabihf/env
+ ifneq ($(realpath /opt/netsurf/arm-riscos-gnueabi/env),)
+ GCCSDK_INSTALL_ENV := /opt/netsurf/arm-riscos-gnueabi/env
else
- # No NetSurf-specific toolchain found: try the "normal" GCCSDK path
- GCCSDK_INSTALL_ENV := /home/riscos/env
+ ifneq ($(realpath /opt/netsurf/arm-riscos-gnueabihf/env),)
+ GCCSDK_INSTALL_ENV := /opt/netsurf/arm-riscos-gnueabihf/env
+ else
+ # No NetSurf-specific toolchain found: try the "normal" GCCSDK path
+ GCCSDK_INSTALL_ENV := /home/riscos/env
+ endif
endif
endif
endif
@@ -45,11 +50,15 @@ else
ifneq ($(realpath /opt/netsurf/arm-unknown-riscos/cross/bin),)
GCCSDK_INSTALL_CROSSBIN := /opt/netsurf/arm-unknown-riscos/cross/bin
else
- ifneq ($(realpath /opt/netsurf/arm-riscos-gnueabihf/cross/bin),)
- GCCSDK_INSTALL_CROSSBIN := /opt/netsurf/arm-riscos-gnueabihf/cross/bin
+ ifneq ($(realpath /opt/netsurf/arm-riscos-gnueabi/cross/bin),)
+ GCCSDK_INSTALL_CROSSBIN := /opt/netsurf/arm-riscos-gnueabi/cross/bin
else
- # No NetSurf-specific toolchain found: try the "normal" GCCSDK path
- GCCSDK_INSTALL_CROSSBIN := /home/riscos/cross/bin
+ ifneq ($(realpath /opt/netsurf/arm-riscos-gnueabihf/cross/bin),)
+ GCCSDK_INSTALL_CROSSBIN := /opt/netsurf/arm-riscos-gnueabihf/cross/bin
+ else
+ # No NetSurf-specific toolchain found: try the "normal" GCCSDK path
+ GCCSDK_INSTALL_CROSSBIN := /home/riscos/cross/bin
+ endif
endif
endif
endif
@@ -68,9 +77,12 @@ else
EXEEXT := ,e1f
ELF2AIF := $(GCCSDK_INSTALL_CROSSBIN)/elf2aif
else
- ifneq (,$(findstring arm-riscos-gnueabihf-gcc,$(CC)))
+ ifneq (,$(findstring arm-riscos-gnueabi,$(CC)))
# GCCSDK 8+
SUBTARGET := -elfeabi
+ ifneq (,$(findstring gnueabihf,$(CC)))
+ SUBTARGET := -elfeabihf
+ endif
EXEEXT := ,e1f
ELF2AIF := $(GCCSDK_INSTALL_CROSSBIN)/elf2aif -e
else