From: j-h.choi Date: Thu, 27 Apr 2023 04:46:45 +0000 (+0900) Subject: [Tizen S] Integrate app types(dotnet, dotnet-nui) X-Git-Tag: accepted/tizen/unified/20230601.163008^0 X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fdotnet%2Flauncher.git;a=commitdiff_plain;h=21fb9cc94d130340384105d4a7e29e43ff6a2bd2 [Tizen S] Integrate app types(dotnet, dotnet-nui) --- diff --git a/Managed/Tizen.Runtime/Preloader.cs b/Managed/Tizen.Runtime/Preloader.cs index aa8de31..ea0737b 100644 --- a/Managed/Tizen.Runtime/Preloader.cs +++ b/Managed/Tizen.Runtime/Preloader.cs @@ -50,7 +50,11 @@ namespace Tizen.Runtime if (!Directory.Exists(preloadPath)) return; + // If TIZEN_UIFW is not set or NUI, do not preload UI related dll string uifw = System.Environment.GetEnvironmentVariable("TIZEN_UIFW"); + if (uifw == null || uifw != "NUI") + return; + string[] paths = Directory.GetFiles(preloadPath, "*.preload"); Array.Sort(paths); foreach (string path in paths) @@ -69,12 +73,8 @@ namespace Tizen.Runtime if (fileName.IndexOf('.') != 2) continue; - // if TIZEN_UIFW is not set, do not preload UI related dll - if (uifw == null && (fileName.Contains("NUI") || fileName.Contains("ElmSharp") || fileName.Contains("XSF"))) - continue; - else if (uifw == "ElmSharp" && (fileName.Contains("NUI") || fileName.Contains("XSF"))) - continue; - else if (uifw == "NUI" && (fileName.Contains("ElmSharp") || fileName.Contains("XSF"))) + // TIZEN_UIFW only set NUI + if (fileName.Contains("ElmSharp") || fileName.Contains("XSF")) continue; try diff --git a/NativeLauncher/CMakeLists.txt b/NativeLauncher/CMakeLists.txt index 0360af7..ca8cc27 100644 --- a/NativeLauncher/CMakeLists.txt +++ b/NativeLauncher/CMakeLists.txt @@ -295,9 +295,6 @@ INSTALL(TARGETS ${DOTNET_APPTYPE_PLUGIN} DESTINATION ${INSTALL_PLUGIN_DIR}) INSTALL(FILES dotnet.loader DESTINATION ${LOADERDIR}) INSTALL(FILES dotnet.launcher DESTINATION ${LOADERDIR}) INSTALL(FILES dotnet.debugger DESTINATION ${LOADERDIR}) -INSTALL(FILES dotnet-nui.loader DESTINATION ${LOADERDIR}) -INSTALL(FILES dotnet-nui.launcher DESTINATION ${LOADERDIR}) -INSTALL(FILES dotnet-nui.debugger DESTINATION ${LOADERDIR}) INSTALL(FILES inc/coreclr_host.h DESTINATION ${INCLUDEDIR}) INSTALL(FILES inc/dotnet_launcher_plugin.h DESTINATION ${INCLUDEDIR}) INSTALL(FILES inc/ni_common.h DESTINATION ${INCLUDEDIR}) diff --git a/NativeLauncher/dotnet-nui.debugger b/NativeLauncher/dotnet-nui.debugger deleted file mode 100644 index cdff55c..0000000 --- a/NativeLauncher/dotnet-nui.debugger +++ /dev/null @@ -1,100 +0,0 @@ -[DEBUGGER] -NAME LLDB-SERVER -EXE /home/owner/share/tmp/sdk_tools/lldb/bin/lldb-server -APP_TYPE dotnet-nui -EXTRA_KEY __DLP_DEBUG_ARG__ -EXTRA_ENV CORECLR_GDBJIT -EXTRA_ENV COMPlus_ZapDisable - -[DEBUGGER] -NAME LLDB-MI -EXE /opt/usr/home/owner/share/tmp/sdk_tools/lldb/bin/lldb-mi -APP_TYPE dotnet-nui -EXTRA_KEY __DLP_ATTACH_ARG__ -ATTACH true - -[DEBUGGER] -NAME NETCOREDBG -EXE /home/owner/share/tmp/sdk_tools/netcoredbg/netcoredbg -APP_TYPE dotnet-nui -EXTRA_KEY __DLP_DEBUG_ARG__ - -[DEBUGGER] -NAME HEAPTRACK -EXE /home/owner/share/tmp/sdk_tools/profctl/profctl -APP_TYPE dotnet-nui -DEFAULT_OPT -v -DEFAULT_OPT -p -DEFAULT_OPT /home/owner/share/tmp/sdk_tools/heaptrack/heaptrack_fifo -DEFAULT_OPT -w -DEFAULT_OPT -e -DEFAULT_OPT /home/owner/share/tmp/sdk_tools/heaptrack/heaptrack_interpret -DEFAULT_OPT -o -DEFAULT_OPT /home/owner/share/tmp/sdk_tools/profctl/profctl_heaptrack.log -DEFAULT_OPT -E -DEFAULT_OPT DUMP_HEAPTRACK_OUTPUT=/home/owner/share/tmp/sdk_tools/heaptrack/heaptrack_fifo -DEFAULT_OPT CORECLR_PROFILER={C7BAD323-25F0-4C0B-B354-566390B215CA} -DEFAULT_OPT CORECLR_PROFILER_PATH=/home/owner/share/tmp/sdk_tools/heaptrack/libprofiler.so -DEFAULT_OPT CORECLR_ENABLE_PROFILING=1 -DEFAULT_OPT COMPlus_LogEnable=1 -DEFAULT_OPT -c -DEFAULT_OPT 6005 -DEFAULT_OPT -d -DEFAULT_OPT 6006 -DEFAULT_OPT -- - -[DEBUGGER] -NAME COREPROFILER -EXE /home/owner/share/tmp/sdk_tools/profctl/profctl -APP_TYPE dotnet-nui -DEFAULT_OPT -v -DEFAULT_OPT -i -DEFAULT_OPT -p -DEFAULT_OPT /home/owner/share/tmp/sdk_tools/coreprofiler/trace.log -DEFAULT_OPT -w -DEFAULT_OPT -o -DEFAULT_OPT /home/owner/share/tmp/sdk_tools/profctl/profctl_coreprofiler.log -DEFAULT_OPT -E -DEFAULT_OPT CORECLR_PROFILER={101DA8FE-FDCA-4D0E-9712-7639CDE48EBA} -DEFAULT_OPT CORECLR_PROFILER_PATH=/home/owner/share/tmp/sdk_tools/coreprofiler/libcoreprof.so -DEFAULT_OPT PROF_TRACE_FILENAME=/home/owner/share/tmp/sdk_tools/coreprofiler/trace.log -DEFAULT_OPT PROF_CONFIG_FILENAME=/home/owner/share/tmp/sdk_tools/coreprofiler/profiler.config -DEFAULT_OPT CORECLR_ENABLE_PROFILING=1 -DEFAULT_OPT COMPlus_EnableEventLog=1 -DEFAULT_OPT COMPlus_ZapDisable=1 -DEFAULT_OPT -c -DEFAULT_OPT 6001 -DEFAULT_OPT -d -DEFAULT_OPT 6002 -DEFAULT_OPT -s -DEFAULT_OPT 6003 -DEFAULT_OPT -- - -[DEBUGGER] -NAME LIVEPROFILER -EXE /home/owner/share/tmp/sdk_tools/profctl/profctl -APP_TYPE dotnet-nui -DEFAULT_OPT -v -DEFAULT_OPT -i -DEFAULT_OPT -p -DEFAULT_OPT /home/owner/share/tmp/sdk_tools/coreprofiler/trace.log -DEFAULT_OPT -w -DEFAULT_OPT -o -DEFAULT_OPT /home/owner/share/tmp/sdk_tools/profctl/profctl_liveprofiler.log -DEFAULT_OPT -E -DEFAULT_OPT CORECLR_PROFILER={101DA8FE-FDCA-4D0E-9712-7639CDE48EBA} -DEFAULT_OPT CORECLR_PROFILER_PATH=/home/owner/share/tmp/sdk_tools/coreprofiler/libcoreprof.so -DEFAULT_OPT PROF_TRACE_FILENAME=/home/owner/share/tmp/sdk_tools/coreprofiler/trace.log -DEFAULT_OPT PROF_CONFIG_FILENAME=/home/owner/share/tmp/sdk_tools/coreprofiler/profiler.config -DEFAULT_OPT CORECLR_ENABLE_PROFILING=1 -DEFAULT_OPT COMPlus_EnableEventLog=1 -DEFAULT_OPT COMPlus_ZapDisable=1 -DEFAULT_OPT -c -DEFAULT_OPT 6001 -DEFAULT_OPT -d -DEFAULT_OPT 6002 -DEFAULT_OPT -s -DEFAULT_OPT 6003 -DEFAULT_OPT -- -DEFAULT_OPT /home/owner/share/tmp/sdk_tools/netcoredbg/netcoredbg -EXTRA_KEY __DLP_DEBUG_ARG__ diff --git a/NativeLauncher/dotnet-nui.launcher b/NativeLauncher/dotnet-nui.launcher deleted file mode 100644 index 5543c2c..0000000 --- a/NativeLauncher/dotnet-nui.launcher +++ /dev/null @@ -1,12 +0,0 @@ -[LAUNCHER] -NAME dotnet-nui-launcher -EXE /usr/bin/dotnet-launcher -APP_TYPE dotnet-nui -EXTRA_ARG --PADDING_TO_CHANGE_CMDLINE_PADDING_TO_CHANGE_CMDLINE_PADDING_TO_CHANGE_CMDLINE_PADDING_TO_CHANGE_CMDLINE -EXTRA_ARG --profile -EXTRA_ARG --appType -EXTRA_ARG dotnet-nui -EXTRA_ARG TIZEN_UIFW -EXTRA_ARG NUI -EXTRA_ARG --standalone - diff --git a/NativeLauncher/dotnet-nui.loader b/NativeLauncher/dotnet-nui.loader deleted file mode 100644 index b047051..0000000 --- a/NativeLauncher/dotnet-nui.loader +++ /dev/null @@ -1,11 +0,0 @@ -[LOADER] -NAME dotnet-nui-loader -EXE /usr/bin/dotnet-nui-loader -APP_TYPE dotnet-nui -DETECTION_METHOD TIMEOUT|DEMAND -TIMEOUT 5000 -ON_BOOT OFF -HYDRA OFF -EXTRA --appType dotnet-nui -EXTRA TIZEN_UIFW NUI -EXTRA --profile true diff --git a/NativeLauncher/dotnet.debugger b/NativeLauncher/dotnet.debugger index 22338b2..27f4f5d 100644 --- a/NativeLauncher/dotnet.debugger +++ b/NativeLauncher/dotnet.debugger @@ -1,7 +1,7 @@ [DEBUGGER] NAME LLDB-SERVER EXE /home/owner/share/tmp/sdk_tools/lldb/bin/lldb-server -APP_TYPE dotnet +APP_TYPE dotnet|dotnet-nui EXTRA_KEY __DLP_DEBUG_ARG__ EXTRA_ENV CORECLR_GDBJIT EXTRA_ENV COMPlus_ZapDisable @@ -9,20 +9,20 @@ EXTRA_ENV COMPlus_ZapDisable [DEBUGGER] NAME LLDB-MI EXE /opt/usr/home/owner/share/tmp/sdk_tools/lldb/bin/lldb-mi -APP_TYPE dotnet +APP_TYPE dotnet|dotnet-nui EXTRA_KEY __DLP_ATTACH_ARG__ ATTACH true [DEBUGGER] NAME NETCOREDBG -EXE /home/owner/share/tmp/sdk_tools/netcoredbg/netcoredbg -APP_TYPE dotnet -EXTRA_KEY __DLP_DEBUG_ARG__ +EXE /home/owner/share/tmp/sdk_tools/netcoredbg/netcoredbg +APP_TYPE dotnet|dotnet-nui +EXTRA_KEY __DLP_DEBUG_ARG__ [DEBUGGER] NAME HEAPTRACK EXE /home/owner/share/tmp/sdk_tools/profctl/profctl -APP_TYPE dotnet +APP_TYPE dotnet|dotnet-nui DEFAULT_OPT -v DEFAULT_OPT -p DEFAULT_OPT /home/owner/share/tmp/sdk_tools/heaptrack/heaptrack_fifo @@ -46,7 +46,7 @@ DEFAULT_OPT -- [DEBUGGER] NAME COREPROFILER EXE /home/owner/share/tmp/sdk_tools/profctl/profctl -APP_TYPE dotnet +APP_TYPE dotnet|dotnet-nui DEFAULT_OPT -v DEFAULT_OPT -i DEFAULT_OPT -p @@ -73,7 +73,7 @@ DEFAULT_OPT -- [DEBUGGER] NAME LIVEPROFILER EXE /home/owner/share/tmp/sdk_tools/profctl/profctl -APP_TYPE dotnet +APP_TYPE dotnet|dotnet-nui DEFAULT_OPT -v DEFAULT_OPT -i DEFAULT_OPT -p diff --git a/NativeLauncher/dotnet.launcher b/NativeLauncher/dotnet.launcher index 4e77926..0895e2d 100644 --- a/NativeLauncher/dotnet.launcher +++ b/NativeLauncher/dotnet.launcher @@ -1,12 +1,12 @@ [LAUNCHER] NAME dotnet-launcher EXE /usr/bin/dotnet-launcher -APP_TYPE dotnet +APP_TYPE dotnet|dotnet-nui EXTRA_ARG --PADDING_TO_CHANGE_CMDLINE_PADDING_TO_CHANGE_CMDLINE_PADDING_TO_CHANGE_CMDLINE_PADDING_TO_CHANGE_CMDLINE EXTRA_ARG --profile EXTRA_ARG --appType EXTRA_ARG dotnet EXTRA_ARG TIZEN_UIFW -EXTRA_ARG ElmSharp +EXTRA_ARG NUI EXTRA_ARG --standalone diff --git a/NativeLauncher/dotnet.loader b/NativeLauncher/dotnet.loader index bf78a99..237b1c3 100644 --- a/NativeLauncher/dotnet.loader +++ b/NativeLauncher/dotnet.loader @@ -1,14 +1,14 @@ [LOADER] -NAME dotnet-loader +NAME dotnet-loader # for candidate mode -EXE /usr/bin/dotnet-loader +EXE /usr/bin/dotnet-loader # for hydra mode -#EXE /usr/bin/dotnet-hydra-loader -APP_TYPE dotnet -DETECTION_METHOD TIMEOUT|DEMAND -TIMEOUT 5000 -ON_BOOT OFF -HYDRA OFF -EXTRA --appType dotnet -EXTRA TIZEN_UIFW ElmSharp -EXTRA --profile true +#EXE /usr/bin/dotnet-hydra-loader +APP_TYPE dotnet|dotnet-nui +DETECTION_METHOD TIMEOUT|DEMAND +TIMEOUT 5000 +ON_BOOT OFF +HYDRA OFF +EXTRA --appType dotnet +EXTRA TIZEN_UIFW NUI +EXTRA --profile true diff --git a/NativeLauncher/launcher/exec/launcher.cc b/NativeLauncher/launcher/exec/launcher.cc index d26d7f9..d7cc8e6 100644 --- a/NativeLauncher/launcher/exec/launcher.cc +++ b/NativeLauncher/launcher/exec/launcher.cc @@ -53,7 +53,7 @@ int main(int argc, char *argv[]) bool paddingExist = false; bool profile = false; const char* appType = "dotnet"; - const char* UIFWType = "ElmSharp"; + const char* UIFWType = "NUI"; const char* appRootPath = NULL; char appId[APPID_MAX_LENGTH] = {0,}; diff --git a/packaging/dotnet-launcher.spec b/packaging/dotnet-launcher.spec index 83533a5..a352ce5 100644 --- a/packaging/dotnet-launcher.spec +++ b/packaging/dotnet-launcher.spec @@ -190,17 +190,12 @@ install -m 0755 packaging/%{_rw_dotnet_update_script} %{buildroot}/%{_rw_update_ %post mkdir -p /opt/etc/skel/.dotnet chsmack -t -a User::App::Shared /opt/etc/skel/.dotnet -ln -sf /usr/bin/dotnet-loader /usr/bin/dotnet-nui-loader -chsmack -a User /usr/bin/dotnet-nui-loader %files %manifest dotnet-launcher.manifest %{_loaderdir}/dotnet.loader %{_loaderdir}/dotnet.launcher %{_loaderdir}/dotnet.debugger -%{_loaderdir}/dotnet-nui.loader -%{_loaderdir}/dotnet-nui.launcher -%{_loaderdir}/dotnet-nui.debugger %{_native_lib_dir}/libsqlite3.so %{_bindir}/tpatool %{_bindir}/dotnettool