Renamed targets. Added linux_ prefix
mips32 -> linux_mips32 mipsel32 -> linux_mipsel32
This commit is contained in:
committed by
ilmat192
parent
b7978c3a1f
commit
0fb788d580
+2
-2
@@ -155,7 +155,7 @@ internal open class LinuxBasedPlatform(val distribution: Distribution)
|
||||
"${targetSysRoot}/usr/lib64/crt1.o",
|
||||
"${targetSysRoot}/usr/lib64/crti.o", "${libGcc}/crtbegin.o",
|
||||
"-L${llvmLib}", "-L${libGcc}"))
|
||||
if (distribution.target != KonanTarget.MIPS32 && distribution.target != KonanTarget.MIPSEL32) add("--hash-style=gnu") // MIPS doesn't support hash-style=gnu
|
||||
if (distribution.target != KonanTarget.LINUX_MIPS32 && distribution.target != KonanTarget.LINUX_MIPSEL32) add("--hash-style=gnu") // MIPS doesn't support hash-style=gnu
|
||||
addAll(specificLibs)
|
||||
addAll(listOf("-L${targetSysRoot}/../lib", "-L${targetSysRoot}/lib", "-L${targetSysRoot}/usr/lib"))
|
||||
if (optimize) addAll(listOf("-plugin", "$llvmLib/LLVMgold.so") + pluginOptimizationFlags)
|
||||
@@ -219,7 +219,7 @@ internal class LinkStage(val context: Context) {
|
||||
|
||||
private val platform = when (target) {
|
||||
KonanTarget.LINUX, KonanTarget.RASPBERRYPI,
|
||||
KonanTarget.MIPS32, KonanTarget.MIPSEL32 ->
|
||||
KonanTarget.LINUX_MIPS32, KonanTarget.LINUX_MIPSEL32 ->
|
||||
LinuxBasedPlatform(distribution)
|
||||
KonanTarget.MACBOOK, KonanTarget.IPHONE, KonanTarget.IPHONE_SIM ->
|
||||
MacOSBasedPlatform(distribution)
|
||||
|
||||
@@ -149,52 +149,52 @@ abiSpecificLibraries.raspberrypi = \
|
||||
usr/lib/arm-linux-gnueabihf
|
||||
|
||||
# MIPS
|
||||
targetToolchain.linux-mips32 = target-gcc-toolchain-2-linux-mips/x86_64-unknown-linux-gnu
|
||||
dependencies.linux-mips32 = \
|
||||
targetToolchain.linux-linux_mips32 = target-gcc-toolchain-2-linux-mips/x86_64-unknown-linux-gnu
|
||||
dependencies.linux-linux_mips32 = \
|
||||
clang-llvm-3.9.0-linux-x86-64 \
|
||||
target-gcc-toolchain-2-linux-mips \
|
||||
target-sysroot-2-mips \
|
||||
libffi-3.2.1-2-linux-x86-64 \
|
||||
libffi-3.2.1-2-linux-mips
|
||||
quadruple.mips32 = mips-unknown-linux-gnu
|
||||
entrySelector.mips32 = --defsym main=Konan_main
|
||||
linkerOptimizationFlags.mips32 = --gc-sections
|
||||
targetSysRoot.mips32 = target-sysroot-2-mips
|
||||
quadruple.linux_mips32 = mips-unknown-linux-gnu
|
||||
entrySelector.linux_mips32 = --defsym main=Konan_main
|
||||
linkerOptimizationFlags.linux_mips32 = --gc-sections
|
||||
targetSysRoot.linux_mips32 = target-sysroot-2-mips
|
||||
# We could reuse host toolchain here.
|
||||
libffiDir.mips32 = libffi-3.2.1-2-linux-mips
|
||||
linkerKonanFlags.mips32 = -Bstatic -lstdc++ -Bdynamic -ldl -lm -lpthread
|
||||
libffiDir.linux_mips32 = libffi-3.2.1-2-linux-mips
|
||||
linkerKonanFlags.linux_mips32 = -Bstatic -lstdc++ -Bdynamic -ldl -lm -lpthread
|
||||
# targetSysroot-relative.
|
||||
libGcc.mips32 = lib/gcc/mips-unknown-linux-gnu/4.9.4
|
||||
llvmLtoFlags.mips32 =
|
||||
llvmLtoOptFlags.mips32 = -O3 -function-sections
|
||||
llvmLtoNooptFlags.mips32 = -O1
|
||||
dynamicLinker.mips32 = /lib/ld.so.1
|
||||
libGcc.linux_mips32 = lib/gcc/mips-unknown-linux-gnu/4.9.4
|
||||
llvmLtoFlags.linux_mips32 =
|
||||
llvmLtoOptFlags.linux_mips32 = -O3 -function-sections
|
||||
llvmLtoNooptFlags.linux_mips32 = -O1
|
||||
dynamicLinker.linux_mips32 = /lib/ld.so.1
|
||||
# targetSysRoot relative
|
||||
abiSpecificLibraries.mips32 =
|
||||
abiSpecificLibraries.linux_mips32 =
|
||||
|
||||
# MIPSel
|
||||
targetToolchain.linux-mipsel32 = target-gcc-toolchain-2-linux-mips/x86_64-unknown-linux-gnu
|
||||
dependencies.linux-mipsel32 = \
|
||||
targetToolchain.linux-linux_mipsel32 = target-gcc-toolchain-2-linux-mips/x86_64-unknown-linux-gnu
|
||||
dependencies.linux-linux_mipsel32 = \
|
||||
clang-llvm-3.9.0-linux-x86-64 \
|
||||
target-gcc-toolchain-2-linux-mips \
|
||||
target-sysroot-2-mipsel \
|
||||
libffi-3.2.1-2-linux-x86-64 \
|
||||
libffi-3.2.1-2-linux-mipsel
|
||||
quadruple.mipsel32 = mipsel-unknown-linux-gnu
|
||||
entrySelector.mipsel32 = --defsym main=Konan_main
|
||||
linkerOptimizationFlags.mipsel32 = --gc-sections
|
||||
targetSysRoot.mipsel32 = target-sysroot-2-mipsel
|
||||
quadruple.linux_mipsel32 = mipsel-unknown-linux-gnu
|
||||
entrySelector.linux_mipsel32 = --defsym main=Konan_main
|
||||
linkerOptimizationFlags.linux_mipsel32 = --gc-sections
|
||||
targetSysRoot.linux_mipsel32 = target-sysroot-2-mipsel
|
||||
# We could reuse host toolchain here.
|
||||
libffiDir.mipsel32 = libffi-3.2.1-2-linux-mipsel
|
||||
linkerKonanFlags.mipsel32 = -Bstatic -lstdc++ -Bdynamic -ldl -lm -lpthread
|
||||
libffiDir.linux_mipsel32 = libffi-3.2.1-2-linux-mipsel
|
||||
linkerKonanFlags.linux_mipsel32 = -Bstatic -lstdc++ -Bdynamic -ldl -lm -lpthread
|
||||
# targetSysroot-relative.
|
||||
libGcc.mipsel32 = lib/gcc/mipsel-unknown-linux-gnu/4.9.4
|
||||
llvmLtoFlags.mipsel32 =
|
||||
llvmLtoOptFlags.mipsel32 = -O3 -function-sections
|
||||
llvmLtoNooptFlags.mipsel32 = -O1
|
||||
dynamicLinker.mipsel32 = /lib/ld.so.1
|
||||
libGcc.linux_mipsel32 = lib/gcc/mipsel-unknown-linux-gnu/4.9.4
|
||||
llvmLtoFlags.linux_mipsel32 =
|
||||
llvmLtoOptFlags.linux_mipsel32 = -O3 -function-sections
|
||||
llvmLtoNooptFlags.linux_mipsel32 = -O1
|
||||
dynamicLinker.linux_mipsel32 = /lib/ld.so.1
|
||||
# targetSysRoot relative
|
||||
abiSpecificLibraries.mipsel32 =
|
||||
abiSpecificLibraries.linux_mipsel32 =
|
||||
|
||||
# Android ARM32, based on NDK for android-21.
|
||||
targetToolchain.osx-android_arm32 = target-toolchain-21-osx-android_arm32
|
||||
|
||||
@@ -2085,8 +2085,8 @@ kotlinNativeInterop {
|
||||
|
||||
task interop0(type: RunInteropKonanTest) {
|
||||
disabled = (project.testTarget == 'wasm32') || // No interop for wasm yet.
|
||||
(project.testTarget == 'mips32') || // st_uid of '/' is not equal to 0 when using qemu
|
||||
(project.testTarget == 'mipsel32')
|
||||
(project.testTarget == 'linux_mips32') || // st_uid of '/' is not equal to 0 when using qemu
|
||||
(project.testTarget == 'linux_mipsel32')
|
||||
goldValue = "0\n0\n"
|
||||
source = "interop/basics/0.kt"
|
||||
interop = 'sysstat'
|
||||
@@ -2113,8 +2113,8 @@ task interop3(type: RunInteropKonanTest) {
|
||||
// There are plans to provide a solution and turn this
|
||||
// test back on.
|
||||
disabled = (project.testTarget == 'raspberrypi') ||
|
||||
(project.testTarget == 'mips32') ||
|
||||
(project.testTarget == 'mipsel32') ||
|
||||
(project.testTarget == 'linux_mips32') ||
|
||||
(project.testTarget == 'linux_mipsel32') ||
|
||||
(project.testTarget == 'wasm32') // No interop for wasm yet.
|
||||
goldValue = "8 9 12 13 14 \n"
|
||||
source = "interop/basics/3.kt"
|
||||
@@ -2130,14 +2130,14 @@ task interop4(type: RunInteropKonanTest) {
|
||||
|
||||
task interop_bitfields(type: RunInteropKonanTest) {
|
||||
disabled = (project.testTarget == 'wasm32') // No interop for wasm yet.
|
||||
expectedFail = (project.testTarget == 'mips32') // fails because of big-endiannes
|
||||
expectedFail = (project.testTarget == 'linux_mips32') // fails because of big-endiannes
|
||||
source = "interop/basics/bf.kt"
|
||||
interop = 'bitfields'
|
||||
}
|
||||
|
||||
task interop_funptr(type: RunInteropKonanTest) {
|
||||
disabled = (project.testTarget == 'wasm32') // No interop for wasm yet.
|
||||
expectedFail = (project.testTarget == 'mips32') // fails because of big-endiannes
|
||||
expectedFail = (project.testTarget == 'linux_mips32') // fails because of big-endiannes
|
||||
goldValue = "42\n17\n1\n0\n"
|
||||
source = "interop/basics/funptr.kt"
|
||||
interop = 'cfunptr'
|
||||
|
||||
Reference in New Issue
Block a user