-
Notifications
You must be signed in to change notification settings - Fork 196
Align MANPATH handling in lmod.spec to preserve system man pages (#2070) #2105
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
@Amrithasuresh If you look at the result of the CI runs there will be an RPM which you can test locally to see if your change works as expected. |
lmod fails to build on opensuse:
I think this is related to your PR to fix things around apparmor. Any ides how this could be fixed? |
Test Results 30 files - 9 30 suites - 9 37s ⏱️ -33s Results for commit 00a80bc. ± Comparison against base commit bf2f5cd. This pull request removes 22 and adds 1 tests. Note that renamed tests count towards both.
♻️ This comment has been updated with latest results. |
7f740a1
to
07efc5e
Compare
@Amrithasuresh can you rebase this PR. The errors should be fixed. |
Sure. Will do. |
…em man pages - Initialize MANPATH if unset to use system default paths - Append Lmod's own man directory using upstream 'addto' helper script - Prevents module MANPATH overrides that hide system man pages (fixes openhpc#2070) - Applied changes in both bash (lmod.sh) and csh (lmod.csh) profile scripts Signed-off-by: Suresh Panneerselvam <sureshcbt@gmail.com>
- Cleaned up MANPATH assignment in csh script as per review feedback Signed-off-by: Suresh Panneerselvam <sureshcbt@gmail.com>
Thanks for fixing this. Merged. |
It required a fixup: diff --git a/components/admin/lmod/SPECS/lmod.spec b/components/admin/lmod/SPECS/lmod.spec
index e3af2b423..a323a64b1 100644
--- a/components/admin/lmod/SPECS/lmod.spec
+++ b/components/admin/lmod/SPECS/lmod.spec
@@ -116,7 +116,7 @@ if [ -z "\${MANPATH:-}" ]; then
export MANPATH=":"
fi
# Initialize MANPATH if unset, then safely append Lmod's man directory using addto helper
-export MANPATH=\$(${OHPC_ADMIN}/lmod/lmod/libexec/addto MANPATH ${OHPC_ADMIN}/lmod/lmod/share/man)
+export MANPATH=\$(%{OHPC_ADMIN}/lmod/lmod/libexec/addto MANPATH %{OHPC_ADMIN}/lmod/lmod/share/man)
# Set BASH_ENV for environment
export BASH_ENV=%{OHPC_ADMIN}/lmod/lmod/init/bash
@@ -162,7 +162,7 @@ if ( ! $?MANPATH ) then
setenv MANPATH ":"
endif
# Initialize MANPATH if unset, then safely append Lmod's man directory using addto helper
-setenv MANPATH `${OHPC_ADMIN}/lmod/lmod/libexec/addto MANPATH ${OHPC_ADMIN}/lmod/lmod/share/man`
+setenv MANPATH `%{OHPC_ADMIN}/lmod/lmod/libexec/addto MANPATH %{OHPC_ADMIN}/lmod/lmod/share/man`
# Initialize modules system
source %{OHPC_ADMIN}/lmod/lmod/init/csh >/dev/null There was a mixup between shell variables and RPM variables. |
@adrianreber Thank you so much for the review and support! I'm still a beginner in open-source contributions, but I would love to continue helping OpenHPC if possible. I have a few hours weekly. Please let me know if there are any small issues, tasks, or documentation areas where I could contribute. |
Reach out on the OpenHPC slack to me and we can discuss possible things to do. |
Summary
This PR updates the
lmod.spec
file to align MANPATH handlingChanges
lmod.sh
) and csh (lmod.csh
) profile scriptsRelated Issue
Fixes: #2070
Signed-off-by
Suresh Panneerselvam sureshcbt@gmail.com