Add switches for crossgen (#91)
[platform/core/dotnet/launcher.git] / NativeLauncher / tool / tac_common.cc
index b767c91..1614e77 100644 (file)
@@ -235,7 +235,7 @@ tac_error_e resetTACPackage(const std::string& pkgId)
        return TAC_ERROR_NONE;
 }
 
-tac_error_e createTACPackage(const std::string& pkgId)
+tac_error_e createTACPackage(const std::string& pkgId, DWORD flags)
 {
        std::string pkgRoot;
        if (getRootPath(pkgId, pkgRoot) < 0) {
@@ -254,7 +254,7 @@ tac_error_e createTACPackage(const std::string& pkgId)
                                                std::string originPath = bf::read_symlink(symPath).string();
                                                std::string originNiPath = originPath.substr(0, originPath.rfind(".dll")) + ".ni.dll";
                                                if (!bf::exists(originNiPath)) {
-                                                       if(createNiDll(originPath, false) != NI_ERROR_NONE) {
+                                                       if(createNiDll(originPath, flags) != NI_ERROR_NONE) {
                                                                fprintf(stderr, "Failed to create NI file [%s]\n", originPath.c_str());
                                                                return TAC_ERROR_UNKNOWN;
                                                        }
@@ -282,11 +282,11 @@ tac_error_e createTACPackage(const std::string& pkgId)
        return TAC_ERROR_NONE;
 }
 
-tac_error_e regenerateTAC()
+tac_error_e regenerateTAC(DWORD flags)
 {
        const std::string tacDir[] = {__TAC_DIR};
        removeNiUnderDirs(tacDir, 1);
-       createNiUnderTAC(tacDir, 1);
+       createNiUnderTAC(tacDir, 1, flags);
        return TAC_ERROR_NONE;
 }