[Native] Enable real Android Native executables (#4624)
* Add AndroidProgramType binary option, override entry point, fix linker flags * Add Konan_main_standalone entry point to the Android runtime * Add compiler warning * Make standalone programs print to stdout * Fix warning message and readability
This commit is contained in:
@@ -16,6 +16,9 @@ RUNTIME_WEAK int32_t Kotlin_gcAggressive = 0;
|
||||
RUNTIME_WEAK int32_t Kotlin_workerExceptionHandling = 0;
|
||||
RUNTIME_WEAK int32_t Kotlin_freezingEnabled = 1;
|
||||
RUNTIME_WEAK const Kotlin_getSourceInfo_FunctionType Kotlin_getSourceInfo_Function = nullptr;
|
||||
#ifdef KONAN_ANDROID
|
||||
RUNTIME_WEAK int32_t Kotlin_printToAndroidLogcat = 1;
|
||||
#endif
|
||||
|
||||
ALWAYS_INLINE compiler::DestroyRuntimeMode compiler::destroyRuntimeMode() noexcept {
|
||||
return static_cast<compiler::DestroyRuntimeMode>(Kotlin_destroyRuntimeMode);
|
||||
@@ -32,3 +35,9 @@ ALWAYS_INLINE compiler::WorkerExceptionHandling compiler::workerExceptionHandlin
|
||||
ALWAYS_INLINE bool compiler::freezingEnabled() noexcept {
|
||||
return Kotlin_freezingEnabled != 0;
|
||||
}
|
||||
|
||||
#ifdef KONAN_ANDROID
|
||||
ALWAYS_INLINE bool compiler::printToAndroidLogcat() noexcept {
|
||||
return Kotlin_printToAndroidLogcat != 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user