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

Add optional release_extra rpm tag to distinguish rebuilt rpms #198

Closed
wants to merge 1 commit into
base: 8.0
from

Conversation

Projects
None yet
2 participants
@sjmudd

sjmudd commented Feb 7, 2018

If I download a src rpm built by Oracle and want to rebuild it with different options then I can do something like:

$ rpmbuild --rebuild --define 'with_ssl system' mysql-community-5.7.21-1.el7.src.rpm

However, doing this means the rebuilt rpms will have exactly the same name as the original one. It's not clear from the rpm name alone[1] that I have built this new rpm so there's a clear chance of confusion.

This patch provides for an optional --define argument, release_extra, that can be used when rebuilding rpms from the src rpm so that the new rpm will be named slightly differently.

e.g.

$ rpmbuild --rebuild --define 'release_extra .sjm' --define 'with_ssl system' mysql-community-5.7.21-1.el7.src.rpm

would create a binary filename of the form mysql-community-server-5.7.20-1.sjm.el7.x86_64.rpm which is easily distinguishable from the original rpms built by Oracle. The release version change is minimal so any existing software that sees this will only need minimal adjustments should it see these newly named rpms.

This argument would NOT be used by Oracle but only by any users who want to simplify the way rebuilt packages can be distinguished from the upstream originals.

[1] rpm -qi mysql-community-server would show you the build host etc.

Add optional release_extra rpm tag to distinguish rebuilt rpms
If I download a src rpm built by Oracle and want to rebuild it
with different options then I can do something like:

$ rpmbuild --rebuild --clean --define 'with_ssl system' mysql-community-5.7.21-1.el7.src.rpm

However, doing this means the rebuilt rpms will have exactly the same
name as the original one. It's not clear from the rpm name alone[1] that
I have built this new rpm so there's a clear chance of confusion.

This patch provides for an optional --define argument, release_extra,
that can be used when rebuilding rpms from the src rpm so that the new
rpm will be named slightly differently.

e.g.

$ rpmbuild --rebuild --clean --define 'release_extra .sjm' --define 'with_ssl system' mysql-community-5.7.21-1.el7.src.rpm

would create a binary filename of the form
mysql-community-server-5.7.20-1.sjm.el7.x86_64.rpm which is easily
distinguishable from the original rpms built by Oracle. The release
version change is minimal so any existing software that sees this will
only need minimal adjustments should it see these newly named rpms.

This argument would NOT be used by Oracle but only by any users who
want to simplify the way rebuilt packages can be distinguished from
the upstream originals.

[1] rpm -qi mysql-community-server would show you the build host etc.
@sjmudd

This comment has been minimized.

Show comment
Hide comment
@sjmudd

sjmudd Feb 7, 2018

Note: this PR is for 8.0. I'd like to do an equivalent one for the current GA version 5.7 too.

sjmudd commented Feb 7, 2018

Note: this PR is for 8.0. I'd like to do an equivalent one for the current GA version 5.7 too.

@mysql-oca-bot

This comment has been minimized.

Show comment
Hide comment
@mysql-oca-bot

mysql-oca-bot Feb 7, 2018

Hi, thank you for your contribution. Please confirm this code is submitted under the terms of the OCA (Oracle's Contribution Agreement) you have previously signed by cutting and pasting the following text as a comment:
"I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it."
Thanks

mysql-oca-bot commented Feb 7, 2018

Hi, thank you for your contribution. Please confirm this code is submitted under the terms of the OCA (Oracle's Contribution Agreement) you have previously signed by cutting and pasting the following text as a comment:
"I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it."
Thanks

@sjmudd

This comment has been minimized.

Show comment
Hide comment
@sjmudd

sjmudd Feb 7, 2018

I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it.

sjmudd commented Feb 7, 2018

I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it.

@sjmudd

This comment has been minimized.

Show comment
Hide comment
@sjmudd

sjmudd Feb 8, 2018

Related: https://bugs.mysql.com/bug.php?id=89583. I can't figure out how to build the rpms from the git tree to test this process properly (at least for 8.0.4) as there appear to be no instructions on how this process works.

sjmudd commented Feb 8, 2018

Related: https://bugs.mysql.com/bug.php?id=89583. I can't figure out how to build the rpms from the git tree to test this process properly (at least for 8.0.4) as there appear to be no instructions on how this process works.

@mysql-oca-bot

This comment has been minimized.

Show comment
Hide comment
@mysql-oca-bot

mysql-oca-bot Feb 8, 2018

Hi, thank you for your contribution. Your code has been assigned to an internal queue. Please follow
bug http://bugs.mysql.com/bug.php?id=89593 for updates.
Thanks

mysql-oca-bot commented Feb 8, 2018

Hi, thank you for your contribution. Your code has been assigned to an internal queue. Please follow
bug http://bugs.mysql.com/bug.php?id=89593 for updates.
Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment