From: 이형주/Common Platform Lab(SR)/삼성전자 Date: Tue, 19 Apr 2022 22:52:20 +0000 (+0900) Subject: Fix mibc option for crossgen2 (#401) X-Git-Tag: submit/tizen/20220429.002649~4 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=0d39ff6c5020df54261cc6f9f5730244117c3443;p=platform%2Fcore%2Fdotnet%2Flauncher.git Fix mibc option for crossgen2 (#401) `--ibc-dir $(directory path)` to `--mibc $(file path)` Co-authored-by: 조웅석/Common Platform Lab(SR)/삼성전자 --- diff --git a/NativeLauncher/tool/dotnettool.cc b/NativeLauncher/tool/dotnettool.cc index 79334a5..3c15704 100644 --- a/NativeLauncher/tool/dotnettool.cc +++ b/NativeLauncher/tool/dotnettool.cc @@ -55,7 +55,7 @@ void DisplayUsage() { " (this option should be run as root)\n" "\n" "Options:\n" - " --ibc-dir - Specify a directory containing IBC files\n" + " --mibc - Specify Mibc files. Sepatated with ':'.\n" " --verbose - Display verbose information\n" " --inputbubble - Use inputbubble\n" " --inputbubbleref - Path of references for inputbubble (used with --inputbubble option)\n" @@ -78,8 +78,8 @@ void DisplayUsage() { " # dotnettool --ni-pkg org.tizen.FormsGallery\n" "4. Regenerate native images for all installed .net packages\n" " # dotnettool --ni-regen-all-app\n" - "5. Create native image for dll based on the IBC data\n" - " # dotnettool --ibc-dir /tmp/ibcdata/ --ni-dll /usr/bin/Tizen.Runtime.dll\n" + "5. Create native image for dll based on the Mibc data\n" + " # dotnettool --mibc /tmp/ibcdata/in.mibc --ni-dll /usr/bin/Tizen.Runtime.dll\n" "6. Remove profile for package\n" " # dotnettool --rm-app-profile org.tizen.FormsGallery\n" "\n"); @@ -124,10 +124,10 @@ int main(int argc, char* argv[]) opt->flags |= NI_FLAGS_PRINT_CMD; } else if (arg == "--skip-ro-app") { opt->flags |= NI_FLAGS_SKIP_RO_APP; - } else if (arg == "--ibc-dir") { + } else if (arg == "--mibc") { ++i; if (i >= argc) { - _SOUT("Directory path containing IBC files should be followed for --ibc-dir option"); + _SOUT("File path containing Mibc files should be followed for --mibc option"); DisplayUsage(); return 0; } @@ -137,8 +137,8 @@ int main(int argc, char* argv[]) std::vector paths; splitPath(std::string(argv[i]), paths); for (const auto &path : paths) { - if (!isDirectory(path)) { - _SERR("mibc path is missing or not exist"); + if (!isFile(path) || isDirectory(path)) { + _SERR("Mibc file path is missing or does not exist"); return -1; } opt->mibcPath.push_back(path);