From 6ea547542ecf4d2b798b5e3c5e2673a4b96ace23 Mon Sep 17 00:00:00 2001 From: Woongsuk Cho Date: Wed, 7 Nov 2018 19:21:13 +0900 Subject: [PATCH] Allow ni common initialization for arm architecture only. AOTed dlls which generated under x86 architecture do not work correctly. So, skip ni file generation except arm architecture. NI_COMMON module can be used by other tools (for example vd-nitool) So, add architecture checking code in the initNICommon() function --- NativeLauncher/installer-plugin/ni_common.cc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/NativeLauncher/installer-plugin/ni_common.cc b/NativeLauncher/installer-plugin/ni_common.cc index 4c5ca44..9ca229e 100644 --- a/NativeLauncher/installer-plugin/ni_common.cc +++ b/NativeLauncher/installer-plugin/ni_common.cc @@ -254,6 +254,7 @@ static void createCoreLibNI(bool enableR2R) int initNICommon(NiCommonOption* option) { +#if defined(__arm__) // get interval value const char* intervalFile = "/usr/share/dotnet.tizen/lib/crossgen_interval.txt"; std::ifstream inFile(intervalFile); @@ -274,6 +275,10 @@ int initNICommon(NiCommonOption* option) __tpa = getTPA(); return 0; +#else + fprintf(stderr, "crossgen supports arm architecture only. skip ni file generation\n"); + return -1; +#endif } void finalizeNICommon() -- 2.7.4