Add include fstream header for boost 1.83.0 (#525)
[platform/core/dotnet/launcher.git] / NativeLauncher / tool / multi_target_resolver.cc
index 264dc6d..5c12aaa 100644 (file)
@@ -15,6 +15,7 @@
  */
 
 #include <string>
+#include <fstream>
 #include <pkgmgr-info.h>
 
 #include "log.h"
@@ -202,28 +203,29 @@ static int appResolveCb(pkgmgrinfo_appinfo_h handle, void *user_data)
        return 0;
 }
 
-int resolveAllApps()
+void resolveAllApps()
 {
        int ret = 0;
 
        pkgmgrinfo_appinfo_filter_h handle;
        ret = pkgmgrinfo_appinfo_filter_create(&handle);
        if (ret != PMINFO_R_OK) {
-               return -1;
+               _SERR("Failed to create pkgmgrinfo");
+               return;
        }
 
        ret = pkgmgrinfo_appinfo_filter_add_string(handle, PMINFO_APPINFO_PROP_APP_TYPE, "dotnet");
        if (ret != PMINFO_R_OK) {
                pkgmgrinfo_appinfo_filter_destroy(handle);
-               return -1;
+               _SERR("Failed to add pkgmgrinfo filter app type");
+               return;
        }
 
        ret = pkgmgrinfo_appinfo_filter_foreach_appinfo(handle, appResolveCb, NULL);
        if (ret != PMINFO_R_OK) {
                pkgmgrinfo_appinfo_filter_destroy(handle);
-               return -1;
+               _SERR("Failed to remove unused multi-targeting files");
+               return;
        }
        pkgmgrinfo_appinfo_filter_destroy(handle);
-
-       return 0;
 }