Skip to content
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

rpm: Fix make rpm on Debian/Ubuntu #15365

Merged
merged 1 commit into from
Oct 6, 2023
Merged

Conversation

siv0
Copy link
Contributor

@siv0 siv0 commented Oct 6, 2023

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 via alien.

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 38
  • git clean -fdx; ./autogen.sh; ./configure; make deb on a Debian 12
  • git clean -fdx; ./autogen.sh; ./configure; make native-deb on a Debian 12
    and comparing the location of the completion file in the binary packages.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Performance enhancement (non-breaking change which improves efficiency)
  • Code cleanup (non-breaking change which makes code smaller or more readable)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Library ABI change (libzfs, libzfs_core, libnvpair, libuutil and libzfsbootenv)
  • Documentation (a change to man pages or other documentation)

Checklist:

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 via `alien`.

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

Signed-off-by: Stoiko Ivanov <[email protected]>
@behlendorf behlendorf added the Status: Accepted Ready to integrate (reviewed, tested) label Oct 6, 2023
@behlendorf behlendorf merged commit 74ed1ae into openzfs:master Oct 6, 2023
17 of 25 checks passed
behlendorf pushed a commit to behlendorf/zfs that referenced this pull request Oct 6, 2023
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 via `alien`.

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

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Stoiko Ivanov <[email protected]>
Closes openzfs#15355
Closes openzfs#15365
behlendorf pushed a commit that referenced this pull request Oct 7, 2023
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 via `alien`.

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

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Stoiko Ivanov <[email protected]>
Closes #15355
Closes #15365
lundman pushed a commit to openzfsonwindows/openzfs that referenced this pull request Dec 12, 2023
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 via `alien`.

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

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Stoiko Ivanov <[email protected]>
Closes openzfs#15355
Closes openzfs#15365
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Accepted Ready to integrate (reviewed, tested)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants