Skip to content

Commit

Permalink
Take JANA_HOME off of the plugin loader search path
Browse files Browse the repository at this point in the history
  • Loading branch information
nathanwbrei committed Aug 14, 2024
1 parent 69c6112 commit 8d25766
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions src/libraries/JANA/Services/JPluginLoader.cc
Original file line number Diff line number Diff line change
Expand Up @@ -73,17 +73,7 @@ void JPluginLoader::resolve_plugin_paths() {
while (getline(envvar_ss, path, ':')) add_plugin_path(path);
}

// 3. Next we look in the plugin directories relative to $JANA_HOME
if (const char* jana_home = getenv("JANA_HOME")) {
add_plugin_path(std::string(jana_home) + "/lib/JANA/plugins"); // In case we did a system install and want to avoid conflicts.
}

// 4. Finally we look in the JANA install directory.
// By checking here, the user no longer needs to set JANA_HOME in order to run built-in plugins
// such as janadot and JTest. The install directory is supposed to be the same as JANA_HOME,
// but we can't guarantee that because the user can set JANA_HOME to be anything they want.
// It would be nice if nothing in the JANA codebase itself relied on JANA_HOME, although we
// won't be removing it anytime soon because of build_scripts.
// 3. Finally we look in the JANA install directory.
add_plugin_path(JVersion::GetInstallDir() + "/lib/JANA/plugins");
}

Expand Down

0 comments on commit 8d25766

Please sign in to comment.