{
ni_error_e ret;
+ // NI fils of TAC-related dlls under /opt/usr/dotnet should not be created under .native_image directory.
+ // So, unset NI_FLAGS_APPNI temporally and restore it after running AOT.
bool isAppNI = false;
if (opt->flags & NI_FLAGS_APPNI) {
+ opt->flags &= ~NI_FLAGS_APPNI;
isAppNI = true;
}
}
if (!needNIList.empty()) {
- // NI fils of TAC-related dlls under /opt/usr/dotnet should not be created under .native_image directory.
- // So, unset NI_FLAGS_APPNI temporally and restore it after running AOT.
- opt->flags &= ~NI_FLAGS_APPNI;
ret = doAOTList(needNIList, refPaths, opt);
- if (isAppNI) {
- opt->flags |= NI_FLAGS_APPNI;
- }
if (ret != NI_ERROR_NONE) {
return ret;
}
}
if (isAppNI) {
+ opt->flags |= NI_FLAGS_APPNI;
for (auto &niPath : niList) {
if (exist(niPath)) {
std::string symNIPath = concatPath(targetPath, getFileName(niPath));