From be551ce96a416df537a6f091401451ad589c77a2 Mon Sep 17 00:00:00 2001 From: "pius.lee" Date: Wed, 31 Aug 2016 00:05:53 +0900 Subject: [PATCH] Remove ini file and fix argument problem for appfw Change-Id: I0aaae6699ebc1a469e546d89f96a91183d307b91 --- NativeLauncher/CMakeLists.txt | 8 +- NativeLauncher/dotnet-launcher.ini | 6 -- NativeLauncher/src/launcher.cc | 96 ++++++++++++++------- NativeLauncher/src/waiter.cc | 2 +- Tizen.Runtime/Tizen.Runtime.csproj | 24 +++--- Tizen.Runtime/Tizen.Runtime/AssemblyLoader.cs | 7 +- Tizen.Runtime/Tizen.Runtime/AssemblyManager.cs | 98 +++++++++++----------- .../Tizen.Runtime/DefaultConfigAttribute.cs | 26 ++---- Tizen.Runtime/Tizen.Runtime/Interop.cs | 10 ++- packaging/dotnet-launcher.spec | 14 +++- test_build_on_desktop.sh | 11 ++- 11 files changed, 174 insertions(+), 128 deletions(-) delete mode 100644 NativeLauncher/dotnet-launcher.ini diff --git a/NativeLauncher/CMakeLists.txt b/NativeLauncher/CMakeLists.txt index 8e203a3..d2ef94e 100644 --- a/NativeLauncher/CMakeLists.txt +++ b/NativeLauncher/CMakeLists.txt @@ -22,6 +22,13 @@ IF(DEFINED LAUNCHER_ASSEMBLY_PATH) SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} -DLAUNCHER_ASSEMBLY_PATH=${LAUNCHER_ASSEMBLY_PATH}") ENDIF(DEFINED LAUNCHER_ASSEMBLY_PATH) +IF(DEFINED DEVICE_API_DIR) + SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} -DDEVICE_API_DIR=${DEVICE_API_DIR}") +ENDIF(DEFINED DEVICE_API_DIR) + +IF(DEFINED RUNTIME_DIR) + SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} -DRUNTIME_DIR=${RUNTIME_DIR}") +ENDIF(DEFINED RUNTIME_DIR) SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} -std=c++11") SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} -Wl,-zdefs" ) @@ -63,5 +70,4 @@ IF(NOT DEFINED NO_TIZEN) INSTALL(TARGETS ${PROJECT_NAME} DESTINATION ${BINDIR}) INSTALL(TARGETS ${LAUNCHER_LIB} DESTINATION ${LIBDIR}) INSTALL(FILES dotnet.loader DESTINATION ${LOADERDIR}) - INSTALL(FILES dotnet-launcher.ini DESTINATION ${CONFIGDIR}) ENDIF(NOT DEFINED NO_TIZEN) diff --git a/NativeLauncher/dotnet-launcher.ini b/NativeLauncher/dotnet-launcher.ini deleted file mode 100644 index 6a5d91a..0000000 --- a/NativeLauncher/dotnet-launcher.ini +++ /dev/null @@ -1,6 +0,0 @@ -[dotnet] -libcoreclr = /opt/usr/share/dotnet/shared/Microsoft.NETCore.App/1.0.0/libcoreclr.so -coreclr_dir = /opt/usr/share/dotnet/shared/Microsoft.NETCore.App/1.0.0 -tpa_dirs = /opt/usr/share/dotnet/shared/Microsoft.NETCore.App/1.0.0:/usr/share/assembly -native_so_search_dirs = /opt/usr/share/dotnet/shared/Microsoft.NETCore.App/1.0.0:/usr/share/assembly -launcher_assembly = /usr/bin/Tizen.Runtime.exe diff --git a/NativeLauncher/src/launcher.cc b/NativeLauncher/src/launcher.cc index 84c3811..35762f5 100644 --- a/NativeLauncher/src/launcher.cc +++ b/NativeLauncher/src/launcher.cc @@ -22,19 +22,46 @@ #include "tini.hpp" -#define __STR(x) #x -#define __XSTR(x) __STR(x) +#define __XSTR(x) #x +#define __STR(x) __XSTR(x) -#ifdef LAUNCHER_CONFIG_PATH -#define LAUNCHER_CONFIG __XSTR(LAUNCHER_CONFIG_PATH) +#ifndef NO_TIZEN + +#ifndef DEVICE_API_DIR + #error "DEVICE_API_DIR must be exist." +#endif + +#ifndef RUNTIME_DIR + #error "RUNTIME_DIR must be exist." +#endif + +#ifndef LAUNCHER_ASSEMBLY_PATH + #error "LAUNCHER_ASSEMBLY_PATH must be exist." +#endif + +#define CONST const +#else + +#define CONST +#include +#endif + +#ifdef DEVICE_API_DIR +static CONST std::string DeviceAPIDirectory(__STR(DEVICE_API_DIR)); +#else +static std::string DeviceAPIDirectory; +#endif +#ifdef RUNTIME_DIR +static CONST std::string RuntimeDirectory(__STR(RUNTIME_DIR)); #else -#define LAUNCHER_CONFIG "/etc/dotnet-launcher.ini" +static std::string RuntimeDirectory; #endif -static const std::string LauncherConfig(LAUNCHER_CONFIG); -#ifdef LAUNCHER_CONFIG_PATH -#undef LAUNCHER_CONFIG -#undef LAUNCHER_CONFIG_PATH +#ifdef LAUNCHER_ASSEMBLY_PATH +static CONST std::string LauncherAssembly(__STR(LAUNCHER_ASSEMBLY_PATH)); +#else +static std::string LauncherAssembly; #endif + #undef __STR #undef __XSTR @@ -82,7 +109,6 @@ std::string ReadSelfPath() { return ""; } -/* static std::string ConcatPath(const std::string& path1, const std::string& path2) { std::string path(path1); @@ -98,6 +124,7 @@ static std::string ConcatPath(const std::string& path1, const std::string& path2 return path; } +/* static void AppendPath(std::string& path1, const std::string& path2) { if (path1.back() == PATH_SEPARATOR) @@ -132,6 +159,10 @@ static std::string Basename(const std::string& path) { return path.substr(0, pos); } + else + { + return std::string("."); + } return path; } @@ -167,7 +198,7 @@ static std::string AssembliesInDirectory(const char *directory) if (dir == nullptr) { - _ERR("can not open directory : %s", directory); + _ERR("can not open directory : [%s]", directory); return std::string(); } @@ -226,7 +257,7 @@ static std::string AssembliesInDirectory(const char *directory) assembly.append(directory); assembly += PATH_SEPARATOR; assembly.append(filename); - _DBG("TPA : %s", assembly.c_str()); + //_DBG("TPA : %s", assembly.c_str()); tpaList += assembly + ':'; } } @@ -239,24 +270,17 @@ static std::string AssembliesInDirectory(const char *directory) static int RunLauncherDll(int argc, char* argv[]) { - std::ifstream iniStream(LauncherConfig); - std::stringstream iniString; - iniString << iniStream.rdbuf(); - tini::ini launcherIni(iniString); + std::string coreclr_dir(RuntimeDirectory); + std::string libcoreclr(ConcatPath(coreclr_dir, "libcoreclr.so")); + std::string tpa_dirs(coreclr_dir + ":" + DeviceAPIDirectory); + std::string native_so_search_dirs(tpa_dirs); + std::string launcher_assembly(AbsolutePath(LauncherAssembly)); - _DBG("config file [%s]", LauncherConfig.c_str()); - _DBG("%s", launcherIni.to_string().c_str()); - - auto &dotnet = launcherIni["dotnet"]; - -#define DOTNET_FIND(key, defaultValue) \ - ((dotnet.find(key) == dotnet.end()) ? defaultValue : dotnet[key]) - std::string libcoreclr = DOTNET_FIND("libcoreclr", "libcoreclr.so"); - std::string coreclr_dir = DOTNET_FIND("coreclr_dir", "/opt/usr/share/dotnet/shared/Microsoft.NETCore.App/1.0.0/"); - std::string tpa_dirs = DOTNET_FIND("tpa_dirs", coreclr_dir + ":" + "/usr/share/assembly"); - std::string native_so_search_dirs = DOTNET_FIND("native_so_search_dirs", tpa_dirs); - std::string launcher_assembly = AbsolutePath(DOTNET_FIND("launcher_assembly", "/usr/bin/Tizen.Runtime.dll")); -#undef DOTNET_FIND + if (launcher_assembly.empty()) + { + _ERR("Invalid Launcher assembly path."); + return 1; + } std::string launcher_dir = Basename(launcher_assembly); std::string trusted_assemblies = launcher_assembly + ":"; @@ -274,7 +298,6 @@ static int RunLauncherDll(int argc, char* argv[]) _DBG("native_so_search_dir : %s", native_so_search_dirs.c_str()); _DBG("launcher_assembly : %s", launcher_assembly.c_str()); _DBG("launcher_dir : %s", launcher_dir.c_str()); - _DBG("-------------------------------------------------"); void *coreclrLib = dlopen(libcoreclr.c_str(), RTLD_NOW | RTLD_LOCAL); if (coreclrLib == nullptr) @@ -317,7 +340,7 @@ static int RunLauncherDll(int argc, char* argv[]) "UseLatestBehaviorWhenTFMNotSpecified" }; - _DBG("trusted platform assemblies : %s", propertyValues[0]); + //_DBG("trusted platform assemblies : %s", propertyValues[0]); _DBG("app_path : %s", propertyValues[1]); _DBG("app_ni_path : %s", propertyValues[2]); _DBG("native dll search path : %s", propertyValues[3]); @@ -383,6 +406,17 @@ static int RunLauncherDll(int argc, char* argv[]) int main(int argc, char *argv[]) { +#ifdef NO_TIZEN + const char *_deviceapi_directory = getenv("DeviceAPIDirectory"); + const char *_runtime_directory = getenv("RuntimeDirectory"); + const char *_launcher_assembly = getenv("LauncherAssembly"); + if (_deviceapi_directory != nullptr) + DeviceAPIDirectory = _deviceapi_directory; + if (_runtime_directory != nullptr) + RuntimeDirectory = _runtime_directory; + if (_launcher_assembly != nullptr) + LauncherAssembly = _launcher_assembly; +#endif _DBG("launcher started"); return RunLauncherDll(argc, argv); } diff --git a/NativeLauncher/src/waiter.cc b/NativeLauncher/src/waiter.cc index c7cb794..6447d4a 100644 --- a/NativeLauncher/src/waiter.cc +++ b/NativeLauncher/src/waiter.cc @@ -258,7 +258,7 @@ bool WaiterContext::Request() bool WaiterContext::Execute(const char *path, const char *app_root, int argc, char *argv[]) { if (Step == Status::Requested && Executed != nullptr && - Executed(path, app_root, argc, argv, Data)) + Executed(path, app_root, argc, argv, Data) == 0) { Step = Status::Executed; return true; diff --git a/Tizen.Runtime/Tizen.Runtime.csproj b/Tizen.Runtime/Tizen.Runtime.csproj index ed996ac..a0fce08 100644 --- a/Tizen.Runtime/Tizen.Runtime.csproj +++ b/Tizen.Runtime/Tizen.Runtime.csproj @@ -3,16 +3,16 @@ Debug - AnyCPU - exe + AnyCPU + exe Tizen.Runtime - true - full + true + full bin/ - DEBUG;TRACE + DEBUG;TRACE @@ -44,22 +44,24 @@ + + + + + - - <_Parameter1>ConfigPath=$(LauncherConfigPath) + + <_Parameter1>PreloadPath=$(PreloadPath) + OutputFile="Config.cs"> - - - diff --git a/Tizen.Runtime/Tizen.Runtime/AssemblyLoader.cs b/Tizen.Runtime/Tizen.Runtime/AssemblyLoader.cs index a80e781..4b4a30b 100644 --- a/Tizen.Runtime/Tizen.Runtime/AssemblyLoader.cs +++ b/Tizen.Runtime/Tizen.Runtime/AssemblyLoader.cs @@ -38,19 +38,18 @@ namespace Tizen.Runtime protected override Assembly Load(AssemblyName assemblyName) { - ALog.Debug($"Load DLL : {assemblyName.Name}"); Assembly asm = null; try { - asm = Assembly.Load(assemblyName); + //asm = AssemblyLoadContext.Default.Load(assemblyName); + asm = AssemblyLoadContext.Default.LoadFromAssemblyName(assemblyName); } catch (Exception ex) when (ex is FileNotFoundException || ex is BadImageFormatException || ex is FileLoadException) { - ALog.Debug("Search DLL in added directories"); foreach (string dir in DllDirectories) { FileInfo f = new FileInfo(Path.Combine(dir, $"{assemblyName.Name}.dll")); @@ -66,11 +65,9 @@ namespace Tizen.Runtime protected override IntPtr LoadUnmanagedDll(string unmanagedDllName) { - ALog.Debug($"Load Native : {unmanagedDllName}"); IntPtr native = base.LoadUnmanagedDll(unmanagedDllName); if (native == IntPtr.Zero) { - ALog.Debug("Search native lib in added directories"); foreach (string dir in NativeDirectories) { FileInfo f = new FileInfo(Path.Combine(dir, unmanagedDllName)); diff --git a/Tizen.Runtime/Tizen.Runtime/AssemblyManager.cs b/Tizen.Runtime/Tizen.Runtime/AssemblyManager.cs index 1f50867..0eeaffa 100644 --- a/Tizen.Runtime/Tizen.Runtime/AssemblyManager.cs +++ b/Tizen.Runtime/Tizen.Runtime/AssemblyManager.cs @@ -12,43 +12,19 @@ namespace Tizen.Runtime { try { - string configPath = "file:///etc/dotnet-launcher.ini"; + string preloadPath = ""; ICustomAttributeProvider assembly = typeof(AssemblyManager).GetTypeInfo().Assembly; var attributes = assembly.GetCustomAttributes(typeof(DefaultConfigAttribute), false); - if (attributes.Length > 0 && attributes[0] is DefaultConfigAttribute) + foreach (DefaultConfigAttribute dca in attributes) { - DefaultConfigAttribute dca = (DefaultConfigAttribute)attributes[0]; - FileInfo f = new FileInfo(dca.Config["ConfigPath"]); - if (File.Exists(f.FullName)) + ALog.Debug($"{dca.Key} = {dca.Value}"); + if (dca.Key == "PreloadPath") { - configPath = "file://"+f.FullName; + preloadPath = dca.Value; } } - Ini ini = new Ini(new Uri(configPath)); - var dotnet = ini["dotnet"]; - foreach(var kv in dotnet) - { - ALog.Debug(kv.Key + " = " + kv.Value); - } - - string preloadDlls = ""; - string preloadDllDirs = ""; - var preloads = ini["preloads"]; - if (preloads != null) - { - foreach (string key in preloads.Keys) - { - FileInfo f = new FileInfo(key); - if (File.Exists(f.FullName)) - { - preloadDlls += f.FullName + ":"; - preloadDllDirs += f.Directory + ":"; - } - } - } - - if (!Initialize(preloadDllDirs, preloadDlls)) + if (!Initialize(preloadPath)) { return 1; } @@ -71,11 +47,12 @@ namespace Tizen.Runtime { try { - FileInfo f = new FileInfo(path); - CurrentAssemblyLoaderContext.AddSearchableDirectory(f.Directory.FullName); - DirectoryInfo d = new DirectoryInfo(app_root); - CurrentAssemblyLoaderContext.AddSearchableDirectory(d.FullName); - Execute(path); + DirectoryInfo libdir = new DirectoryInfo(Path.Combine(app_root, "lib")); + if (Directory.Exists(libdir.FullName)) + { + CurrentAssemblyLoaderContext.AddSearchableDirectory(libdir.FullName); + } + Execute(path, argv); } catch(Exception e) { @@ -126,34 +103,57 @@ namespace Tizen.Runtime } } - public static bool Initialize(string searchableDirectories, string preloadDllPaths) + public static bool Initialize(string preloadDirectory) { try { CurrentAssemblyLoaderContext = new AssemblyLoader(); - if (searchableDirectories != null) + if (!string.IsNullOrEmpty(preloadDirectory)) { - string[] dirs = searchableDirectories.Split(new char[]{':'}, StringSplitOptions.None); - foreach (string dir in dirs) + Console.WriteLine($"[{preloadDirectory}]"); + DirectoryInfo d = new DirectoryInfo(preloadDirectory); + if (Directory.Exists(d.FullName)) { - CurrentAssemblyLoaderContext.AddSearchableDirectory(dir); + CurrentAssemblyLoaderContext.AddSearchableDirectory(d.FullName); + string[] dlls = Directory.GetFiles(d.FullName, "*.dll"); + + foreach (string dll in dlls) + { + ALog.Debug($"preload dll : {dll}"); + CurrentAssemblyLoaderContext.LoadFromAssemblyPath(dll); + } } } - if (preloadDllPaths != null) + /* + string LD_LIBRARY_PATH = Environment.GetEnvironmentVariable("LD_LIBRARY_PATH"); + if (!string.IsNullOrEmpty(LD_LIBRARY_PATH)) { - string[] dllPaths = preloadDllPaths.Split(new char[]{':'}, StringSplitOptions.None); - foreach (string dllPath in dllPaths) + string[] dirs = LD_LIBRARY_PATH.Split(new char[]{':'}, StringSplitOptions.None); + foreach (string dir in dirs) { - if (string.IsNullOrWhiteSpace(dllPath)) continue; - FileInfo f = new FileInfo(dllPath); - if (File.Exists(f.FullName)) + DirectoryInfo d = new DirectoryInfo(dir); + if (Directory.Exists(d.FullName)) { - CurrentAssemblyLoaderContext.LoadFromAssemblyPath(f.FullName); + CurrentAssemblyLoaderContext.AddSearchableDirectory(d.FullName); } } } + + DirectoryInfo libdir = new DirectoryInfo("/lib"); + if (Directory.Exists(libdir.FullName)) + { + CurrentAssemblyLoaderContext.AddSearchableDirectory(libdir.FullName); + } + + DirectoryInfo usrlibdir = new DirectoryInfo("/usr/lib"); + if (Directory.Exists(usrlibdir.FullName)) + { + CurrentAssemblyLoaderContext.AddSearchableDirectory(usrlibdir.FullName); + } + */ + } catch (Exception e) { @@ -164,7 +164,7 @@ namespace Tizen.Runtime return true; } - public static void Execute(string dllPath) + public static void Execute(string dllPath, string[] argv) { try { @@ -174,7 +174,7 @@ namespace Tizen.Runtime Assembly asm = CurrentAssemblyLoaderContext.LoadFromAssemblyPath(f.FullName); if (asm == null) throw new FileNotFoundException($"{f.FullName} is not found"); if (asm.EntryPoint == null) throw new ArgumentException($"{f.FullName} did not have EntryPoint"); - asm.EntryPoint.Invoke(null, new string[]{null}); + asm.EntryPoint.Invoke(null, new object[]{argv}); } } catch (Exception e) diff --git a/Tizen.Runtime/Tizen.Runtime/DefaultConfigAttribute.cs b/Tizen.Runtime/Tizen.Runtime/DefaultConfigAttribute.cs index f5ba0b0..b0a4cd6 100644 --- a/Tizen.Runtime/Tizen.Runtime/DefaultConfigAttribute.cs +++ b/Tizen.Runtime/Tizen.Runtime/DefaultConfigAttribute.cs @@ -1,27 +1,19 @@ using System; using System.Collections.Generic; -[AttributeUsage(AttributeTargets.Assembly)] +[AttributeUsage(AttributeTargets.Assembly, AllowMultiple = true)] public class DefaultConfigAttribute : Attribute { public DefaultConfigAttribute() : this(string.Empty) {} public DefaultConfigAttribute(string txt) { - Config = new Dictionary(); - string[] keyvalues = txt.Split(new string[] {","}, StringSplitOptions.None); - foreach (string kvstr in keyvalues) - { - int eq_pos = kvstr.IndexOf('='); - if (eq_pos == -1) - throw new FormatException("Config must be written like \"Key1=Value1, Key2=Value2\""); + int eq_pos = txt.IndexOf('='); + if (eq_pos == -1) + throw new FormatException("Config must be written like \"Key1=Value1\""); - string key = kvstr.Substring(0, eq_pos).Trim(); - string value = kvstr.Substring(eq_pos+1).Trim(); - Config[key] = value; - } - } - public Dictionary Config - { - get; - set; + Key = txt.Substring(0, eq_pos).Trim(); + Value = txt.Substring(eq_pos+1).Trim(); } + + public string Key { get; private set; } + public string Value { get; private set; } } diff --git a/Tizen.Runtime/Tizen.Runtime/Interop.cs b/Tizen.Runtime/Tizen.Runtime/Interop.cs index 3476a81..52ceeac 100644 --- a/Tizen.Runtime/Tizen.Runtime/Interop.cs +++ b/Tizen.Runtime/Tizen.Runtime/Interop.cs @@ -7,7 +7,15 @@ internal static class Interop internal delegate int PreparedCallback(IntPtr userData); internal delegate int RequestedCallback(IntPtr userData); - internal delegate int ExecutedCallback(string path, string app_root, int argc, string[] argv, IntPtr userData); + + [UnmanagedFunctionPointer(CallingConvention.Cdecl)] + internal delegate int ExecutedCallback( + [In] string path, + [In] string app_root, + [In] int argc, + [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)] + [In] string[] argv, + [In] IntPtr userData); [DllImport(Launcher)] internal static extern void register_launching_callback( diff --git a/packaging/dotnet-launcher.spec b/packaging/dotnet-launcher.spec index 7dd32fa..62864e8 100644 --- a/packaging/dotnet-launcher.spec +++ b/packaging/dotnet-launcher.spec @@ -1,3 +1,5 @@ +%{!?dotnet_assembly_path: %define dotnet_assembly_path %{_datadir}/assembly} + Name: dotnet-launcher Summary: Launchpad plugin for dotnet apps Version: 0.0.2 @@ -28,6 +30,9 @@ Requires(preun): /usr/bin/systemctl %define _loaderdir %{_prefix}/share/aul %define _configdir /etc +%define _device_api_dir %{dotnet_assembly_path} +%define _runtime_dir /opt/usr/share/dotnet/shared/Microsoft.NETCore.App/1.0.0 +%define _preload_dir /opt/usr/share/dotnet.tizen/preload %description Launchpad plugin for launching dotnet apps @@ -49,12 +54,18 @@ cmake \ -DLOADERDIR=%{_loaderdir} \ -DCONFIGDIR=%{_configdir} \ -DCMAKE_BUILD_TYPE=%{_buildmode} \ + -DDEVICE_API_DIR=%{_device_api_dir} \ + -DRUNTIME_DIR=%{_runtime_dir} \ + -DLAUNCHER_ASSEMBLY_PATH=%{_bindir}/Tizen.Runtime.exe \ -DVERSION=%{version} \ NativeLauncher make %{?jobs:-j%jobs} -xbuild /p:Configuration=%{_buildmode} Tizen.Runtime/Tizen.Runtime.csproj +xbuild \ + /p:Configuration=%{_buildmode} \ + /p:PreloadPath=%{_preload_dir} \ + Tizen.Runtime/Tizen.Runtime.csproj %install rm -rf %{buildroot} @@ -63,7 +74,6 @@ install -p -m 644 Tizen.Runtime/bin/Tizen.Runtime.exe %{buildroot}%{_bindir} %files %manifest dotnet-launcher.manifest -%config /etc/dotnet-launcher.ini %{_loaderdir}/dotnet.loader %caps(cap_mac_admin,cap_setgid=ei) %{_bindir}/dotnet-launcher %caps(cap_mac_admin,cap_setgid=ei) %{_libdir}/libdnclauncher.so diff --git a/test_build_on_desktop.sh b/test_build_on_desktop.sh index 90a8583..a013029 100755 --- a/test_build_on_desktop.sh +++ b/test_build_on_desktop.sh @@ -4,16 +4,19 @@ #TizenDeviceAPIPath=`readlink -e ../dlls/tizen_deviceapis/` CoreFXRefPath=`readlink -e ../dlls/desktop/` TizenDeviceAPIPath=`readlink -e ../dlls/tizen_deviceapis/` -LauncherConfigPath=./dotnet-launcher.ini RoslynCscDir=/home/idkiller/work/runtime/roslyn/Binaries/Debug/csccore RoslynCscExe=csc +RuntimeDir=/usr/share/dotnet/shared/Microsoft.NETCore.App/1.0.0 +TizenDeviceAPIDir=`readlink -e ../dlls/tizen_deviceapis/` +PreloadPath=`readlink -e ./preloads` + + mkdir build cd build -cmake -DCMAKE_BUILD_TYPE=Debug -DNO_TIZEN=1 -DLAUNCHER_CONFIG_PATH=$LauncherConfigPath -DLAUNCHER_ASSEMBLY_PATH=Tizen.Runtime.dll ../NativeLauncher/ +cmake -DCMAKE_BUILD_TYPE=Debug -DNO_TIZEN=1 -DLAUNCHER_ASSEMBLY_PATH=Tizen.Runtime.exe -DDEVICE_API_DIR=$TizenDeviceAPIDir -DRUNTIME_DIR=$RuntimeDir ../NativeLauncher/ make xbuild /t:Clean ../Tizen.Runtime/Tizen.Runtime.csproj #xbuild /verbosity:diagnostic /p:CLOG=1 /p:ExternalCscPath=/home/idkiller/work/runtime/roslyn/Binaries/Debug/csccore/csc.exe /p:LauncherConfigPath=$LauncherConfigPath /p:CoreFXRefPath=$CoreFXRefPath /p:TizenDeviceAPIPath=$TizenDeviceAPIPath ../Tizen.Runtime/Tizen.Runtime.csproj -xbuild /p:CLOG=1 /p:ExternalCscDir=$RoslynCscDir /p:ExternalCscExe=$RoslynCscExe /p:LauncherConfigPath=$LauncherConfigPath /p:CoreFXRefPath=$CoreFXRefPath /p:TizenDeviceAPIPath=$TizenDeviceAPIPath ../Tizen.Runtime/Tizen.Runtime.csproj +xbuild /p:CLOG=1 /p:ExternalCscDir=$RoslynCscDir /p:ExternalCscExe=$RoslynCscExe /p:LauncherConfigPath=$LauncherConfigPath /p:CoreFXRefPath=$CoreFXRefPath /p:TizenDeviceAPIPath=$TizenDeviceAPIPath /p:PreloadPath=$PreloadPath ../Tizen.Runtime/Tizen.Runtime.csproj cp ../Tizen.Runtime/bin/Tizen.Runtime.* . -cp ../NativeLauncher/dotnet-launcher.ini . -- 2.7.4