AMIGAOS4: Add support for AmigaOS4 platform

This commit is contained in:
Le Philousophe
2020-08-26 19:58:58 +00:00
parent 575fed1dd0
commit fd4e4a8266
32 changed files with 728 additions and 0 deletions
+34
View File
@@ -122,6 +122,40 @@ def _3ds():
register_platform(platform)
_3ds()
def amigaos4():
platform = Platform("amigaos4")
platform.env["CXX"] = "ccache /usr/local/amigaos4/bin/ppc-amigaos-c++"
platform.configureargs.append("--host=ppc-amigaos")
platform.buildconfigureargs = {
builds.ScummVMBuild: [ "--enable-static" ],
}
platform.packaging_cmd = {
builds.ScummVMBuild: "amigaosdist",
builds.ScummVMToolsBuild: "amigaos4dist"
}
platform.built_files = {
builds.ScummVMBuild: [ "Games:ScummVM", "Games:ScummVM.info" ],
builds.ScummVMToolsBuild: [
"construct_mohawk",
"create_sjisfnt",
"decine",
#"decompile", # Decompiler currently not built - BOOST library not present
"degob",
"dekyra",
"descumm",
"desword2",
"extract_mohawk",
"gob_loadcalc",
#"scummvm-tools", # GUI tools currently not built - WxWidgets library not present
"scummvm-tools-cli"
],
}
platform.archiveext = "zip"
platform.testable = False
platform.run_tests = False
register_platform(platform)
amigaos4()
def android(suffix, scummvm_target, ndk_target, cxx_target, abi_version):
platform = Platform("android_{0}".format(suffix))
platform.compatibleBuilds = (builds.ScummVMBuild, )
+94
View File
@@ -0,0 +1,94 @@
FROM toolchains/common AS helpers
m4_include(`paths.m4')m4_dnl
m4_include(`packages.m4')m4_dnl
FROM debian:stable-slim
USER root
WORKDIR /usr/src
# Copy and execute each step separately to avoid invalidating cache
COPY --from=helpers /lib-helpers/prepare.sh lib-helpers/
RUN lib-helpers/prepare.sh
COPY --from=helpers /lib-helpers/functions.sh lib-helpers/
COPY functions-platform.sh lib-helpers/
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
bison \
flex \
gcc \
g++ \
lhasa \
libgmp-dev \
libmpc-dev \
libmpfr-dev \
python \
texinfo && \
rm -rf /var/lib/apt/lists/*
ENV CROSS_PREFIX=/usr/local/amigaos4 HOST=ppc-amigaos
ENV PREFIX=$CROSS_PREFIX/$HOST
local_package(toolchain)
# Build regina-rexx interpreter as Debian removed it
local_package(regina-rexx)
# Install various wrappers
local_package(amiga-shims)
# We add PATH here for *-config and platform specific binaries
ENV \
def_binaries(`${CROSS_PREFIX}/bin/${HOST}-', `ar, as, c++filt, ld, nm, objcopy, objdump, ranlib, readelf, strings, strip') \
def_binaries(`${CROSS_PREFIX}/bin/${HOST}-', `gcc, cpp, c++') \
CC=${CROSS_PREFIX}/bin/${HOST}-gcc \
def_aclocal(`${PREFIX}') \
def_pkg_config(`${PREFIX}') \
PATH=$PATH:${CROSS_PREFIX}/bin:${PREFIX}/bin \
LDFLAGS="-athread=native"
local_package(zlib)
local_package(libpng)
local_package(libjpeg)
#helpers_package(faad2)
local_package(libmad)
local_package(libogg)
local_package(libtheora)
local_package(libvorbis)
local_package(libflac)
local_package(libmpeg2)
local_package(liba52)
#local_package(libiconv)
local_package(libopenssl)
# Needed by precompiled libcurl
local_package(pthreads)
local_package(librtmp)
local_package(libcurl)
local_package(libfreetype)
local_package(libfribidi)
local_package(libsdl2)
local_package(libsdl2_net)
# No fluidsynth
+131
View File
@@ -0,0 +1,131 @@
do_lha_fetch () {
local pkg_name
pkg_name=$(basename $1)
if [ -d "$pkg_name"/ ]; then
rm -r "$pkg_name"/
fi
wget --no-hsts --progress=dot "http://os4depot.net/share/development/library/$1.lha" -O "$pkg_name.lha"
__do_verify "$pkg_name.lha" "$3"
mkdir "$pkg_name"
cd "$pkg_name"
lha x "../$pkg_name.lha"
do_patch
# No quotes to let globbing occur
cd ./$2
}
do_lha_install () {
local loc d lib srclib dstlib f gen_so dynamic
if [ "$1" = "dynamic" ]; then
dynamic=true
else
dynamic=
fi
for d in local Local; do
if [ -d "$d" ]; then
loc=$d
break
fi
done
if [ -z "$loc" ]; then
error "Can't find Local directory"
fi
# Fix potentialy missing rights
chmod -R go+rX $loc
# When installing static, remove dynamic libraries
if [ -z "$dynamic" ]; then
for lib in newlib clib2; do
if [ -d "$loc/$lib/lib" ]; then
find "$loc/$lib/lib" '(' -name '*.so' -o -name '*.so.*' ')' -delete
fi
done
fi
# Common files like include
for d in include; do
if [ -d $loc/common/$d ]; then
cp -R $loc/common/$d/. $DESTDIR/$PREFIX/$d/
fi
done
# Files specific to libc used (newlib or clib2)
for d in include lib; do
if [ -d $loc/newlib/$d ]; then
cp -R $loc/newlib/$d/. $DESTDIR/$PREFIX/$d/
fi
if [ -d $loc/clib2/$d -a -d $DESTDIR/$PREFIX/$d/clib2 ]; then
cp -R $loc/clib2/$d/. $DESTDIR/$PREFIX/$d/clib2/
fi
done
for lib in newlib clib2; do
srclib=$loc/$lib/lib
if [ "$lib" != "newlib" ]; then
dstlib=$DESTDIR/$PREFIX/lib/$lib
else
dstlib=$DESTDIR/$PREFIX/lib
fi
if [ ! -d $srclib ]; then
continue
fi
# Create symlink for .so
for f in "$srclib"/*.so.*; do
# If glob didn't match anything it will be used in the loop
# Avoid it now
if [ ! -e "$f" ]; then
continue
fi
f=$(basename "$f")
gen_so="${f%.so.*}.so"
if [ -e "$dstlib/$gen_so" ]; then
continue
fi
ln -sf "$f" "$dstlib/$gen_so"
done
# Fix pkg-config paths
for f in "$srclib"/pkgconfig/*.pc; do
# If glob didn't match anything it will be used in the loop
# Avoid it now
if [ ! -e "$f" ]; then
continue
fi
f=$(basename "$f")
sed -i -e "s#^prefix=.*\$#prefix=$PREFIX#" "$dstlib/pkgconfig/$f"
sed -i -e "s#^exec_prefix=.*\$#exec_prefix=$PREFIX#" "$dstlib/pkgconfig/$f"
sed -i -e 's#^libdir=.*$#libdir=${pcfiledir}/..#' "$dstlib/pkgconfig/$f"
sed -i -e 's#^includedir=.*/include#includedir=${prefix}/include#' "$dstlib/pkgconfig/$f"
done
done
# Install and fix config files the best we can
for f in $loc/newlib/bin/*-config; do
if [ ! -e "$f" ]; then
continue
fi
if ! head -n1 $f | grep -q '^#![ ]*/bin/sh'; then
continue
fi
cp $f $DESTDIR/$PREFIX/bin/
f="$DESTDIR/$PREFIX/bin/$(basename "$f")"
sed -i -e "s#^[ \\t]*prefix=.*\$#prefix=\"$PREFIX\"#" "$f"
sed -i -e 's#^[ \t]*exec_prefix=.*$#exec_prefix="${prefix}"#' "$f"
sed -i -e 's#^[ \t]*libdir=.*$#libdir="${prefix}/lib"#' "$f"
sed -i -e 's#^[ \t]*includedir=\("\?\).*/include#includedir=\1${prefix}/include#' "$f"
chmod +x "$f"
done
}
+15
View File
@@ -0,0 +1,15 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
for f in "${PACKAGE_DIR}"/*; do
if [ "$(basename "$f")" = "build.sh" ]; then
continue
fi
cp "$f" "${CROSS_PREFIX}/bin/"
done
# gdate is exactly the GNU date
ln -s /bin/date "${CROSS_PREFIX}/bin/gdate"
+5
View File
@@ -0,0 +1,5 @@
#! /bin/sh
# TODO: Parse arguments
exec cp "$@"
+5
View File
@@ -0,0 +1,5 @@
#! /bin/sh
# TODO: Parse arguments
exec rm "$@"
+5
View File
@@ -0,0 +1,5 @@
#! /bin/sh
# TODO: Parse arguments
exec mkdir "$@"
+11
View File
@@ -0,0 +1,11 @@
#! /bin/sh
BIN_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
# Ensure shims are in the path
export PATH=$PATH:$BIN_DIR
# Ask for Amiga Rexx version
export REGINA_OPTIONS="AREXX_BIFS AREXX_SEMANTICS"
exec "$BIN_DIR"/rexx "$@"
+13
View File
@@ -0,0 +1,13 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch audio/liba52 "liba52/SDK"
do_lha_install
do_clean_bdir
+18
View File
@@ -0,0 +1,18 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch misc/libcurl "SDK"
do_lha_install
#chmod +x "$PREFIX/bin/curl-config"
#rm "$PREFIX/bin/curl-config"
# Fix specific part of curl-config
sed -i -e 's#-L/SDK/local/newlib#-L${exec_prefix}#' "$PREFIX/bin/curl-config"
do_clean_bdir
+13
View File
@@ -0,0 +1,13 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch audio/libflac "libflac-*/SDK"
do_lha_install
do_clean_bdir
+16
View File
@@ -0,0 +1,16 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch graphics/libfreetype "Freetype2/SDK"
do_lha_install
#chmod +x "$PREFIX/bin/freetype-config"
#rm "$PREFIX/bin/freetype-config"
do_clean_bdir
+13
View File
@@ -0,0 +1,13 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch misc/libfribidi "libfribidi-*/SDK"
do_lha_install
do_clean_bdir
+13
View File
@@ -0,0 +1,13 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch misc/libiconv_so "libiconv-*"
do_lha_install
do_clean_bdir
+13
View File
@@ -0,0 +1,13 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch graphics/libjpeg SDK
do_lha_install
do_clean_bdir
+13
View File
@@ -0,0 +1,13 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch audio/libmad "libmad-*/SDK"
do_lha_install
do_clean_bdir
+13
View File
@@ -0,0 +1,13 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch graphics/libmpeg2 "libmpeg2-*/SDK"
do_lha_install
do_clean_bdir
+13
View File
@@ -0,0 +1,13 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch audio/libogg
do_lha_install
do_clean_bdir
+13
View File
@@ -0,0 +1,13 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch misc/libopenssl "libOpenSSL/SDK"
do_lha_install
do_clean_bdir
+16
View File
@@ -0,0 +1,16 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch graphics/libpng
do_lha_install
#chmod +x "$PREFIX"/bin/libpng*-config
#rm "$PREFIX"/bin/libpng*-config
do_clean_bdir
+13
View File
@@ -0,0 +1,13 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch misc/librtmp "SDK"
do_lha_install
do_clean_bdir
+17
View File
@@ -0,0 +1,17 @@
#! /bin/sh
SDL2_VERSION=2.0.12
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_http_fetch SDL2 "https://github.com/AmigaPorts/SDL/releases/download/v$SDL2_VERSION-amigaos4/SDL2.lha" 'lha x'
cd SDK
do_lha_install
do_clean_bdir
+16
View File
@@ -0,0 +1,16 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch misc/libsdl2_net "SDL2_net-*/SDK"
do_lha_install
# Set threading model as SDL2_net is multithread
sed -i -e '/^Libs:/s#$# -athread=native#' "$PREFIX/lib/pkgconfig/SDL2_net.pc"
do_clean_bdir
+13
View File
@@ -0,0 +1,13 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch graphics/libtheora
do_lha_install
do_clean_bdir
+13
View File
@@ -0,0 +1,13 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch audio/libvorbis
do_lha_install
do_clean_bdir
+13
View File
@@ -0,0 +1,13 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch misc/pthreads "SDK"
do_lha_install
do_clean_bdir
+22
View File
@@ -0,0 +1,22 @@
#! /bin/sh
REXX_VERSION=3.9.3
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_http_fetch regina-rexx "https://sourceforge.net/projects/regina-rexx/files/regina-rexx/${REXX_VERSION}/regina-rexx-${REXX_VERSION}.tar.gz/download" 'tar xzf'
./configure --prefix="${CROSS_PREFIX}"
# Force using 1 job at a time as Makefile seems to not handle parallelism
do_make -j1
do_make -j1 install
do_clean_bdir
# Cleanup wget HSTS
rm -f $HOME/.wget-hsts
+36
View File
@@ -0,0 +1,36 @@
#! /bin/sh
TOOLCHAIN_VERSION=724a64c6e0c95a8f548be23a084843200d11e63d
# Versions of components to use provided by toolchain
BINUTILS_VER=2.23.2
GCC_VER=8
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_git_fetch adtools "https://github.com/sba1/adtools.git" "${TOOLCHAIN_VERSION}"
# gild uses git am which needs author information
# Don't pollute home directory
HOME="$(pwd)" git config --global user.email "nobody@localhost"
HOME="$(pwd)" git config --global user.name "Gild patch"
# Don't gild clone as it will download everything
# Checkout will shallow clone what's needed, more efficient
HOME="$(pwd)" gild/bin/gild checkout binutils "${BINUTILS_VER}"
HOME="$(pwd)" gild/bin/gild checkout gcc "${GCC_VER}"
do_make -C native-build gcc-cross
# Fix missing rights for library files
chmod -R go+rX "${CROSS_PREFIX}"
do_clean_bdir
# Cleanup wget HSTS
rm -f $HOME/.wget-hsts
@@ -0,0 +1,62 @@
diff --git a/gcc-build/features.mk b/gcc-build/features.mk
index 6f1c678..d9317fa 100644
--- a/gcc-build/features.mk
+++ b/gcc-build/features.mk
@@ -11,3 +11,5 @@ FEATURES=\
ifeq ($(shell test $(MAJOR_VERSION) -ge 8; echo $$?), 0)
FEATURES+=--enable-threads=amigaos --enable-lto
endif
+
+FEATURES+=--disable-shared
diff --git a/gcc/4.9/patches/0001-Changes-for-AmigaOS-version-of-gcc.patch b/gcc/4.9/patches/0001-Changes-for-AmigaOS-version-of-gcc.patch
index adc6ab8..d4f0d61 100644
--- a/gcc/4.9/patches/0001-Changes-for-AmigaOS-version-of-gcc.patch
+++ b/gcc/4.9/patches/0001-Changes-for-AmigaOS-version-of-gcc.patch
@@ -955,7 +955,7 @@ index 0000000000000000000000000000000000000000..4556163c22a8fadc51c9ed7401c7e6c4
+/* default linker specs */
+#undef REAL_LIBGCC_SPEC
+#define REAL_LIBGCC_SPEC "\
-+%{static|static-libgcc: %{!use-dynld: -lgcc -lgcc_eh} %{use-dynld: -lgcc} }%{!static:%{!static-libgcc:%{!shared:%{!shared-libgcc: %{!use-dynld: -lgcc -lgcc_eh} %{use-dynld: -lgcc}}%{shared-libgcc:-lgcc}}%{shared:%{shared-libgcc:-lgcc}%{!shared-libgcc:-lgcc}}}}"
++%{static|static-libgcc: -lgcc}%{!static:%{!static-libgcc:%{!shared:%{!shared-libgcc: %{!use-dynld: -lgcc} %{use-dynld: -lgcc}}%{shared-libgcc:-lgcc}}%{shared:%{shared-libgcc:-lgcc}%{!shared-libgcc:-lgcc}}}}"
+
+
+/* make newlib the default */
diff --git a/gcc/5/patches/0001-Changes-for-AmigaOS-version-of-gcc.patch b/gcc/5/patches/0001-Changes-for-AmigaOS-version-of-gcc.patch
index ad32733..4d2fad7 100644
--- a/gcc/5/patches/0001-Changes-for-AmigaOS-version-of-gcc.patch
+++ b/gcc/5/patches/0001-Changes-for-AmigaOS-version-of-gcc.patch
@@ -955,7 +955,7 @@ index 0000000000000000000000000000000000000000..94fa93c0be047c08987d7acbc7c71413
+/* default linker specs */
+#undef REAL_LIBGCC_SPEC
+#define REAL_LIBGCC_SPEC "\
-+%{static|static-libgcc: %{!use-dynld: -lgcc -lgcc_eh} %{use-dynld: -lgcc} }%{!static:%{!static-libgcc:%{!shared:%{!shared-libgcc: %{!use-dynld: -lgcc -lgcc_eh} %{use-dynld: -lgcc}}%{shared-libgcc:-lgcc}}%{shared:%{shared-libgcc:-lgcc}%{!shared-libgcc:-lgcc}}}}"
++%{static|static-libgcc: -lgcc}%{!static:%{!static-libgcc:%{!shared:%{!shared-libgcc: %{!use-dynld: -lgcc} %{use-dynld: -lgcc}}%{shared-libgcc:-lgcc}}%{shared:%{shared-libgcc:-lgcc}%{!shared-libgcc:-lgcc}}}}"
+
+
+/* make newlib the default */
diff --git a/gcc/6/patches/0001-Changes-for-AmigaOS-version-of-gcc.patch b/gcc/6/patches/0001-Changes-for-AmigaOS-version-of-gcc.patch
index 0e0b6c2..f9e292c 100644
--- a/gcc/6/patches/0001-Changes-for-AmigaOS-version-of-gcc.patch
+++ b/gcc/6/patches/0001-Changes-for-AmigaOS-version-of-gcc.patch
@@ -956,7 +956,7 @@ index 0000000000000000000000000000000000000000..0d06f2dd48c7d97bbd192b26d530b18b
+/* default linker specs */
+#undef REAL_LIBGCC_SPEC
+#define REAL_LIBGCC_SPEC "\
-+%{static|static-libgcc: %{!use-dynld: -lgcc -lgcc_eh} %{use-dynld: -lgcc} }%{!static:%{!static-libgcc:%{!shared:%{!shared-libgcc: %{!use-dynld: -lgcc -lgcc_eh} %{use-dynld: -lgcc}}%{shared-libgcc:-lgcc}}%{shared:%{shared-libgcc:-lgcc}%{!shared-libgcc:-lgcc}}}}"
++%{static|static-libgcc: -lgcc}%{!static:%{!static-libgcc:%{!shared:%{!shared-libgcc: %{!use-dynld: -lgcc} %{use-dynld: -lgcc}}%{shared-libgcc:-lgcc}}%{shared:%{shared-libgcc:-lgcc}%{!shared-libgcc:-lgcc}}}}"
+
+
+/* make newlib the default */
diff --git a/gcc/8/patches/0001-Changes-for-AmigaOS-version-of-gcc.patch b/gcc/8/patches/0001-Changes-for-AmigaOS-version-of-gcc.patch
index 4e4edf5..7caefa8 100644
--- a/gcc/8/patches/0001-Changes-for-AmigaOS-version-of-gcc.patch
+++ b/gcc/8/patches/0001-Changes-for-AmigaOS-version-of-gcc.patch
@@ -960,7 +960,7 @@ index 0000000000000000000000000000000000000000..1153ece337930f7bbf5f9978bf6f3faf
+/* default linker specs */
+#undef REAL_LIBGCC_SPEC
+#define REAL_LIBGCC_SPEC "\
-+%{static|static-libgcc: %{!use-dynld: -lgcc -lgcc_eh} %{use-dynld: -lgcc} }%{!static:%{!static-libgcc:%{!shared:%{!shared-libgcc: %{!use-dynld: -lgcc -lgcc_eh} %{use-dynld: -lgcc}}%{shared-libgcc:-lgcc}}%{shared:%{shared-libgcc:-lgcc}%{!shared-libgcc:-lgcc}}}}"
++%{static|static-libgcc: -lgcc}%{!static:%{!static-libgcc:%{!shared:%{!shared-libgcc: %{!use-dynld: -lgcc} %{use-dynld: -lgcc}}%{shared-libgcc:-lgcc}}%{shared:%{shared-libgcc:-lgcc}%{!shared-libgcc:-lgcc}}}}"
+
+
+/* make newlib the default */
@@ -0,0 +1,13 @@
diff --git a/native-build/makefile b/native-build/makefile
index 26d508a..2b540dd 100644
--- a/native-build/makefile
+++ b/native-build/makefile
@@ -36,7 +36,7 @@ endif
GCC_BRANCH_NAME:=$(word 1, $(subst ., , $(GCC_VERSION)))
-SDK_URL=http://www.hyperion-entertainment.biz/index.php?option=com_registration&view=download&format=raw&file=69&Itemid=82
+SDK_URL=http://www.hyperion-entertainment.biz/index.php?option=com_registration&view=download&format=raw&file=82&Itemid=82
SDK_VERSION=53.30
# Native tools
+13
View File
@@ -0,0 +1,13 @@
#! /bin/sh
PACKAGE_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
HELPERS_DIR=$PACKAGE_DIR/../..
. $HELPERS_DIR/functions.sh
do_make_bdir
do_lha_fetch misc/libz Zlib/SDK
do_lha_install
do_clean_bdir
+30
View File
@@ -0,0 +1,30 @@
FROM toolchains/amigaos4 AS toolchain
m4_include(`paths.m4')m4_dnl
m4_include(`debian-builder-base.m4')m4_dnl
ENV CROSS_PREFIX=/usr/local/amigaos4 HOST=ppc-amigaos
ENV PREFIX=$CROSS_PREFIX/$HOST
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
lhasa \
libgmp10 \
libmpc3 \
libmpfr6 && \
rm -rf /var/lib/apt/lists/*
COPY --from=toolchain $CROSS_PREFIX $CROSS_PREFIX/
# We add PATH here for *-config and platform specific binaries
ENV \
def_binaries(`${CROSS_PREFIX}/bin/${HOST}-', `ar, as, c++filt, ld, nm, objcopy, objdump, ranlib, readelf, strings, strip') \
def_binaries(`${CROSS_PREFIX}/bin/${HOST}-', `gcc, cpp, c++') \
CC=${CROSS_PREFIX}/bin/${HOST}-gcc \
def_aclocal(`${PREFIX}') \
def_pkg_config(`${PREFIX}') \
PATH=$PATH:${CROSS_PREFIX}/bin:${PREFIX}/bin \
LDFLAGS="-athread=native"
m4_include(`run-buildbot.m4')m4_dnl