rpm: Fix make rpm
on Debian/Ubuntu
#15365
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The recent patch to change the bash completion install location based on the Distribution, ignored that it should still be possible to create RPMs on Debian derived systems. Additionally
make deb
itself creates RPMs and converts them viaalien
.This patch adds the bashcompletiondir variable to the rpm defines and uses this for the location, where to get the bash completion file.
It still changes the location on Debian/Ubuntu systems in the final packages from /etc/bash_completion.d to
/usr/share/bash-completion/completions
Fixes: e69ade3
Motivation and Context
#15355
similar to #15354
Description
the bashcompletiondir autoconf variable is passed to the rpm utilities and used as source-dir for the bash completion file.
This results in a difference of installation location for the completion on Debian/Ubuntu systems (as compared to
builds which don't contain e69ade3):
without this patch and e69ade3 it is installed in /etc/bash_completion.d
with both it ends up in /usr/share/bash-completion/completions/
How Has This Been Tested?
running:
git clean -fdx; ./autogen.sh; ./configure; make rpm
on a Fedora 38git clean -fdx; ./autogen.sh; ./configure; make deb
on a Debian 12git clean -fdx; ./autogen.sh; ./configure; make native-deb
on a Debian 12and comparing the location of the completion file in the binary packages.
Types of changes
Checklist:
Signed-off-by
.