cs: add configuration for {Free,Open,Net}BSD on {ARMv6,AArch64,PowerPC}
It's not clear how many of these combinations work right now, but they should be close, and the intent is that they're supported. I succcessfully built for FreeBSD on AArch64 and Chez Scheme for NetBSD on PowerPC32.
This commit is contained in:
parent
c0af3a253b
commit
8ea5b58393
|
@ -8,9 +8,9 @@ Supported platforms:
|
||||||
* Windows: x86, x86_64
|
* Windows: x86, x86_64
|
||||||
* Mac OS: x86, x86_64, AArch64, PowerPC32
|
* Mac OS: x86, x86_64, AArch64, PowerPC32
|
||||||
* Linux: x86, x86_64, ARMv6, AArch64, PowerPC32
|
* Linux: x86, x86_64, ARMv6, AArch64, PowerPC32
|
||||||
* FreeBSD: x86, x86_64
|
* FreeBSD: x86, x86_64, ARMv6, AArch64, PowerPC32
|
||||||
* OpenBSD: x86, x86_64
|
* OpenBSD: x86, x86_64, ARMv6, AArch64, PowerPC32
|
||||||
* NetBSD: x86, x86_64
|
* NetBSD: x86, x86_64, ARMv6, AArch64, PowerPC32
|
||||||
* Solaris: x86, x86_64
|
* Solaris: x86, x86_64
|
||||||
* Android: ARMv7, AArch64
|
* Android: ARMv7, AArch64
|
||||||
* iOS: AArch64
|
* iOS: AArch64
|
||||||
|
|
|
@ -43,6 +43,13 @@ void S_doflush(uptr start, uptr end) {
|
||||||
sys_icache_invalidate((void *)start, (char *)end-(char *)start);
|
sys_icache_invalidate((void *)start, (char *)end-(char *)start);
|
||||||
#else
|
#else
|
||||||
__clear_cache((char *)start, (char *)end);
|
__clear_cache((char *)start, (char *)end);
|
||||||
|
# if defined(__clang__) && defined(__aarch64__) && !defined(__APPLE__)
|
||||||
|
/* Seem to need an extra combination of barriers here to make up for
|
||||||
|
something in Clang's __clear_cache() */
|
||||||
|
asm volatile ("dsb ish\n\t"
|
||||||
|
"isb"
|
||||||
|
: : : "memory");
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -35,6 +35,8 @@
|
||||||
|
|
||||||
#if (machine_type == machine_type_pb)
|
#if (machine_type == machine_type_pb)
|
||||||
# undef FLUSHCACHE
|
# undef FLUSHCACHE
|
||||||
|
#else
|
||||||
|
# undef PORTABLE_BYTECODE_BIGENDIAN
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/*****************************************/
|
/*****************************************/
|
||||||
|
|
95
racket/src/ChezScheme/configure
vendored
95
racket/src/ChezScheme/configure
vendored
|
@ -94,20 +94,7 @@ fi
|
||||||
|
|
||||||
case "${CONFIG_UNAME}" in
|
case "${CONFIG_UNAME}" in
|
||||||
Linux)
|
Linux)
|
||||||
if uname -a | egrep 'i386|i686|amd64|athlon|x86_64' > /dev/null 2>&1 ; then
|
unixsuffix=le
|
||||||
m32=i3le
|
|
||||||
m64=a6le
|
|
||||||
tm32=ti3le
|
|
||||||
tm64=ta6le
|
|
||||||
elif uname -a | grep -i power > /dev/null 2>&1 ; then
|
|
||||||
m32=ppc32le
|
|
||||||
tm32=tppc32le
|
|
||||||
elif uname -a | egrep 'armv|aarch64' > /dev/null 2>&1 ; then
|
|
||||||
m32=arm32le
|
|
||||||
m64=arm64le
|
|
||||||
tm32=tarm32le
|
|
||||||
tm64=tarm64le
|
|
||||||
fi
|
|
||||||
installprefix=/usr
|
installprefix=/usr
|
||||||
installmansuffix=share/man
|
installmansuffix=share/man
|
||||||
;;
|
;;
|
||||||
|
@ -120,32 +107,17 @@ case "${CONFIG_UNAME}" in
|
||||||
installmansuffix=man
|
installmansuffix=man
|
||||||
;;
|
;;
|
||||||
FreeBSD)
|
FreeBSD)
|
||||||
if uname -a | egrep 'i386|i686|amd64|athlon|x86_64' > /dev/null 2>&1 ; then
|
unixsuffix=fb
|
||||||
m32=i3fb
|
|
||||||
m64=a6fb
|
|
||||||
tm32=ti3fb
|
|
||||||
tm64=ta6fb
|
|
||||||
fi
|
|
||||||
installprefix=/usr/local
|
installprefix=/usr/local
|
||||||
installmansuffix=man
|
installmansuffix=man
|
||||||
;;
|
;;
|
||||||
OpenBSD)
|
OpenBSD)
|
||||||
if uname -a | egrep 'i386|i686|amd64|athlon|x86_64' > /dev/null 2>&1 ; then
|
unixsuffix=ob
|
||||||
m32=i3ob
|
|
||||||
m64=a6ob
|
|
||||||
tm32=ti3ob
|
|
||||||
tm64=ta6ob
|
|
||||||
fi
|
|
||||||
installprefix=/usr/local
|
installprefix=/usr/local
|
||||||
installmansuffix=man
|
installmansuffix=man
|
||||||
;;
|
;;
|
||||||
NetBSD)
|
NetBSD)
|
||||||
if uname -a | egrep 'i386|i686|amd64|athlon|x86_64' > /dev/null 2>&1 ; then
|
unixsuffix=nb
|
||||||
m32=i3nb
|
|
||||||
m64=a6nb
|
|
||||||
tm32=ti3nb
|
|
||||||
tm64=ta6nb
|
|
||||||
fi
|
|
||||||
installprefix=/usr
|
installprefix=/usr
|
||||||
installmansuffix=share/man
|
installmansuffix=share/man
|
||||||
gzipmanpages=no
|
gzipmanpages=no
|
||||||
|
@ -190,6 +162,23 @@ case "${CONFIG_UNAME}" in
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
if [ "$unixsuffix" != "" ] ; then
|
||||||
|
if uname -a | egrep 'i386|i686|amd64|athlon|x86_64' > /dev/null 2>&1 ; then
|
||||||
|
m32=i3${unixsuffix}
|
||||||
|
m64=a6${unixsuffix}
|
||||||
|
tm32=ti3${unixsuffix}
|
||||||
|
tm64=ta6${unixsuffix}
|
||||||
|
elif uname -a | egrep 'power|macppc' > /dev/null 2>&1 ; then
|
||||||
|
m32=ppc32${unixsuffix}
|
||||||
|
tm32=tppc32${unixsuffix}
|
||||||
|
elif uname -a | egrep 'armv|aarch64' > /dev/null 2>&1 ; then
|
||||||
|
m32=arm32${unixsuffix}
|
||||||
|
m64=arm64${unixsuffix}
|
||||||
|
tm32=tarm32${unixsuffix}
|
||||||
|
tm64=tarm64${unixsuffix}
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
threads=""
|
threads=""
|
||||||
bits=""
|
bits=""
|
||||||
|
|
||||||
|
@ -510,36 +499,15 @@ if [ "$cflagsset" = "no" ] ; then
|
||||||
a6le)
|
a6le)
|
||||||
CFLAGS="-m64 -msse2 ${optFlags}"
|
CFLAGS="-m64 -msse2 ${optFlags}"
|
||||||
;;
|
;;
|
||||||
a6fb|a6nb|a6ob)
|
|
||||||
CFLAGS="-m64 ${optFlags}"
|
|
||||||
;;
|
|
||||||
a6s2)
|
|
||||||
CFLAGS="-m64 ${optFlags}"
|
|
||||||
;;
|
|
||||||
a6osx)
|
|
||||||
CFLAGS="-m64 ${optFlags}"
|
|
||||||
;;
|
|
||||||
arm64osx)
|
|
||||||
CFLAGS="-arch arm64 ${optFlags}"
|
|
||||||
;;
|
|
||||||
a6nt)
|
a6nt)
|
||||||
CFLAGS="${optFlags}"
|
CFLAGS="${optFlags}"
|
||||||
;;
|
;;
|
||||||
arm32le|tarm32le|arm64le|tarm64le)
|
a6*)
|
||||||
CFLAGS="${optFlags}"
|
CFLAGS="-m64 ${optFlags}"
|
||||||
;;
|
;;
|
||||||
i3le)
|
i3le)
|
||||||
CFLAGS="-m32 -msse2 ${optFlags}"
|
CFLAGS="-m32 -msse2 ${optFlags}"
|
||||||
;;
|
;;
|
||||||
i3fb|i3nb|i3ob)
|
|
||||||
CFLAGS="-m32 ${optFlags}"
|
|
||||||
;;
|
|
||||||
i3s2)
|
|
||||||
CFLAGS="-m32 ${optFlags}"
|
|
||||||
;;
|
|
||||||
i3osx)
|
|
||||||
CFLAGS="-m32 ${optFlags}"
|
|
||||||
;;
|
|
||||||
i3nt)
|
i3nt)
|
||||||
CFLAGS="${optFlags}"
|
CFLAGS="${optFlags}"
|
||||||
;;
|
;;
|
||||||
|
@ -547,12 +515,21 @@ if [ "$cflagsset" = "no" ] ; then
|
||||||
CC=qcc
|
CC=qcc
|
||||||
CFLAGS="-m32 -N2048K ${optFlags}"
|
CFLAGS="-m32 -N2048K ${optFlags}"
|
||||||
;;
|
;;
|
||||||
ppc32le)
|
i3*)
|
||||||
CFLAGS="-m32 ${optFlags}"
|
CFLAGS="-m32 ${optFlags}"
|
||||||
;;
|
;;
|
||||||
|
arm32*)
|
||||||
|
CFLAGS="-m32 ${optFlags}"
|
||||||
|
;;
|
||||||
|
arm64osx)
|
||||||
|
CFLAGS="-arch arm64 ${optFlags}"
|
||||||
|
;;
|
||||||
ppc32osx)
|
ppc32osx)
|
||||||
CFLAGS="${optFlags}"
|
CFLAGS="${optFlags}"
|
||||||
;;
|
;;
|
||||||
|
ppc32*)
|
||||||
|
CFLAGS="-m32 ${optFlags}"
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -699,13 +676,13 @@ case "${flagsmuni}" in
|
||||||
i3le)
|
i3le)
|
||||||
mdldflags="-melf_i386"
|
mdldflags="-melf_i386"
|
||||||
;;
|
;;
|
||||||
ppc32le|arm32le|arm64le)
|
*le)
|
||||||
;;
|
|
||||||
a6fb|a6ob|a6nb|i3fb|i3ob)
|
|
||||||
;;
|
;;
|
||||||
i3nb)
|
i3nb)
|
||||||
mdldflags="-m elf_i386"
|
mdldflags="-m elf_i386"
|
||||||
;;
|
;;
|
||||||
|
*fb|*ob|*nb)
|
||||||
|
;;
|
||||||
*osx)
|
*osx)
|
||||||
;;
|
;;
|
||||||
a6s2)
|
a6s2)
|
||||||
|
|
|
@ -396,6 +396,15 @@
|
||||||
arm64le tarm64le
|
arm64le tarm64le
|
||||||
arm64osx tarm64osx
|
arm64osx tarm64osx
|
||||||
ppc32osx tppc32osx
|
ppc32osx tppc32osx
|
||||||
|
arm32fb tarm32fb
|
||||||
|
ppc32fb tppc32fb
|
||||||
|
arm64fb tarm64fb
|
||||||
|
arm32ob tarm32ob
|
||||||
|
ppc32ob tppc32ob
|
||||||
|
arm64ob tarm64ob
|
||||||
|
arm32nb tarm32nb
|
||||||
|
ppc32nb tppc32nb
|
||||||
|
arm64nb tarm64nb
|
||||||
)
|
)
|
||||||
|
|
||||||
(include "machine.def")
|
(include "machine.def")
|
||||||
|
|
5
racket/src/ChezScheme/s/ppc32nb.def
Normal file
5
racket/src/ChezScheme/s/ppc32nb.def
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
(define-constant machine-type (constant machine-type-ppc32nb))
|
||||||
|
(features iconv expeditor)
|
||||||
|
(define-constant time-t-bits 64)
|
||||||
|
(include "ppc32.def")
|
||||||
|
(include "default.def")
|
5
racket/src/ChezScheme/s/tppc32nb.def
Normal file
5
racket/src/ChezScheme/s/tppc32nb.def
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
(define-constant machine-type (constant machine-type-tppc32nb))
|
||||||
|
(features iconv expeditor pthreads)
|
||||||
|
(define-constant time-t-bits 64)
|
||||||
|
(include "ppc32.def")
|
||||||
|
(include "default.def")
|
|
@ -54,7 +54,13 @@ case "$Mhost" in
|
||||||
a6osx) ;;
|
a6osx) ;;
|
||||||
a6s2) ;;
|
a6s2) ;;
|
||||||
arm32le) ;;
|
arm32le) ;;
|
||||||
|
arm32fb) ;;
|
||||||
|
arm32ob) ;;
|
||||||
|
arm32nb) ;;
|
||||||
arm64le) ;;
|
arm64le) ;;
|
||||||
|
arm64fb) ;;
|
||||||
|
arm64ob) ;;
|
||||||
|
arm64nb) ;;
|
||||||
arm64osx) ;;
|
arm64osx) ;;
|
||||||
i3fb) ;;
|
i3fb) ;;
|
||||||
i3le) ;;
|
i3le) ;;
|
||||||
|
@ -65,7 +71,9 @@ case "$Mhost" in
|
||||||
i3qnx) ;;
|
i3qnx) ;;
|
||||||
i3s2) ;;
|
i3s2) ;;
|
||||||
ppc32le) ;;
|
ppc32le) ;;
|
||||||
ppc32osx) ;;
|
ppc32fb) ;;
|
||||||
|
ppc32ob) ;;
|
||||||
|
ppc32nb) ;;
|
||||||
ppc32osx) ;;
|
ppc32osx) ;;
|
||||||
arm64osx) ;;
|
arm64osx) ;;
|
||||||
ta6fb) ;;
|
ta6fb) ;;
|
||||||
|
@ -76,7 +84,13 @@ case "$Mhost" in
|
||||||
ta6osx) ;;
|
ta6osx) ;;
|
||||||
ta6s2) ;;
|
ta6s2) ;;
|
||||||
tarm32le) ;;
|
tarm32le) ;;
|
||||||
|
tarm32fb) ;;
|
||||||
|
tarm32ob) ;;
|
||||||
|
tarm32nb) ;;
|
||||||
tarm64le) ;;
|
tarm64le) ;;
|
||||||
|
tarm64fb) ;;
|
||||||
|
tarm64ob) ;;
|
||||||
|
tarm64nb) ;;
|
||||||
tarm64osx) ;;
|
tarm64osx) ;;
|
||||||
ti3fb) ;;
|
ti3fb) ;;
|
||||||
ti3le) ;;
|
ti3le) ;;
|
||||||
|
@ -86,6 +100,9 @@ case "$Mhost" in
|
||||||
ti3osx) ;;
|
ti3osx) ;;
|
||||||
ti3s2) ;;
|
ti3s2) ;;
|
||||||
tppc32le) ;;
|
tppc32le) ;;
|
||||||
|
tppc32fb) ;;
|
||||||
|
tppc32ob) ;;
|
||||||
|
tppc32nb) ;;
|
||||||
tppc32osx) ;;
|
tppc32osx) ;;
|
||||||
tarm64osx) ;;
|
tarm64osx) ;;
|
||||||
*) echo "Unrecognized machine name $Mhost"; exit 1 ;;
|
*) echo "Unrecognized machine name $Mhost"; exit 1 ;;
|
||||||
|
|
|
@ -38,9 +38,18 @@
|
||||||
arm32le tarm32le arm64le tarm64le
|
arm32le tarm32le arm64le tarm64le
|
||||||
ppc32le tppc32le)
|
ppc32le tppc32le)
|
||||||
'linux]
|
'linux]
|
||||||
[(a6ob ta6ob i3ob ti3ob) 'openbsd]
|
[(a6fb ta6fb i3fb ti3fb
|
||||||
[(a6fb ta6fb i3fb ti3fb) 'freebsd]
|
arm32fb tarm32fb arm64fb tarm64fb
|
||||||
[(a6nb ta6nb i3nb ti3nb) 'netbsd]
|
ppc32fb tppc32fb)
|
||||||
|
'freebsd]
|
||||||
|
[(a6ob ta6ob i3ob ti3ob
|
||||||
|
arm32ob tarm32ob arm64ob tarm64ob
|
||||||
|
ppc32ob tppc32ob)
|
||||||
|
'openbsd]
|
||||||
|
[(a6nb ta6nb i3nb ti3nb
|
||||||
|
arm32nb tarm32nb arm64nb tarm64nb
|
||||||
|
ppc32nb tppc32nb)
|
||||||
|
'netbsd]
|
||||||
[(a6s2 ta6s2 i3s2 ti3s2) 'solaris]
|
[(a6s2 ta6s2 i3s2 ti3s2) 'solaris]
|
||||||
[(i3qnx) 'qnx]
|
[(i3qnx) 'qnx]
|
||||||
[else (error 'system-type "internal error: unknown operating system")]))
|
[else (error 'system-type "internal error: unknown operating system")]))
|
||||||
|
@ -64,10 +73,22 @@
|
||||||
i3s2 ti3s2
|
i3s2 ti3s2
|
||||||
i3qnx)
|
i3qnx)
|
||||||
'i386]
|
'i386]
|
||||||
[(arm32le tarm32le) 'arm]
|
[(arm32le tarm32le
|
||||||
[(arm64le tarm64le arm64osx tarm64osx) 'aarch64]
|
arm32fb tarm32fb
|
||||||
|
arm32ob tarm32ob
|
||||||
|
arm32nb tarm32nb)
|
||||||
|
'arm]
|
||||||
|
[(arm64le tarm64le
|
||||||
|
arm64osx tarm64osx
|
||||||
|
arm64fb tarm64fb
|
||||||
|
arm64ob tarm64ob
|
||||||
|
arm64nb tarm64nb)
|
||||||
|
'aarch64]
|
||||||
[(ppc32le tppc32le
|
[(ppc32le tppc32le
|
||||||
ppc32osx tppc32osx)
|
ppc32osx tppc32osx
|
||||||
|
ppc32fb tppc32fb
|
||||||
|
ppc32ob tppc32ob
|
||||||
|
ppc32nb tppc32nb)
|
||||||
'ppc]
|
'ppc]
|
||||||
[else (error 'system-type "internal error: unknown architecture")]))
|
[else (error 'system-type "internal error: unknown architecture")]))
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user