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

zstream: force-install zstreamdump link #12143

Merged
merged 1 commit into from
May 30, 2021

Conversation

nabijaczleweli
Copy link
Contributor

@nabijaczleweli nabijaczleweli commented May 27, 2021

Motivation and Context

What a blunder!

Description

It didn't occur to me that that's a supported configuration; as seen in this CI log, for example: http://build.zfsonlinux.org/builders/FreeBSD%20stable%2F13%20amd64%20%28TEST%29/builds/1138/steps/shell_1/logs/install

How Has This Been Tested?

Ran it.

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:

  • My code follows the OpenZFS code style requirements.
  • I have updated the documentation accordingly.
  • I have read the contributing document.
  • I have added tests to cover my changes. – none apply
  • I have run the ZFS Test Suite with this change applied. – CI should
  • All commit messages are properly formatted and contain Signed-off-by.

It didn't occur to me that that's a supported configuration;
as seen in
  http://build.zfsonlinux.org/builders/FreeBSD%20stable%2F13%20amd64%20%28TEST%29/builds/1138/steps/shell_1/logs/install

Also cd to work around some funny platforms as noted in AC_PROG_LN_S doc

Fixes: dd00925 "zstreamdump: replace
 with link to zstream"
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Copy link

@ghost ghost left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for catching this, it slipped my mind when I encountered it!

Why cd though?

@ghost ghost added the Status: Code Review Needed Ready for review and testing label May 27, 2021
@nabijaczleweli
Copy link
Contributor Author

nabijaczleweli commented May 27, 2021

Quoth autohell doc:

If you make a link in a directory other than the current directory, its meaning depends on whether ‘ln’ or ‘ln -s’ is used. To safely create links using ‘$(LN_S)’, either find out which form is used and adjust the arguments, or always invoke ln in the directory where the link is to be created.
In other words, it does not work to do:

$(LN_S) foo /x/bar

Instead, do:

(cd /x && $(LN_S) foo bar)

This isn't too much of a deal on Normal systems, since they all support symlinks and hence have ln -s, so both forms create /x/bar -> foo (the ln form would make /x/bar a link to the same file as ./foo I think?), but it also won't hurt

Copy link
Contributor

@behlendorf behlendorf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for catching this!

@jwk404 jwk404 added Status: Accepted Ready to integrate (reviewed, tested) and removed Status: Code Review Needed Ready for review and testing labels May 28, 2021
@behlendorf behlendorf merged commit d484a72 into openzfs:master May 30, 2021
behlendorf pushed a commit to behlendorf/zfs that referenced this pull request Jun 8, 2021
Accidentally introduced by commit dd00925.

Force-install the zstreamdump link, this is a supported configuration
and the install should not fail if it needs to overwrite an existing
file.

Also cd to work around some funny platforms as noted in AC_PROG_LN_S doc

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Ryan Moeller <ryan@iXsystems.com>
Reviewed-by: Allan Jude <allan@klarasystems.com>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#12143
behlendorf pushed a commit to behlendorf/zfs that referenced this pull request Jun 9, 2021
Accidentally introduced by commit dd00925.

Force-install the zstreamdump link, this is a supported configuration
and the install should not fail if it needs to overwrite an existing
file.

Also cd to work around some funny platforms as noted in AC_PROG_LN_S doc

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Ryan Moeller <ryan@iXsystems.com>
Reviewed-by: Allan Jude <allan@klarasystems.com>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#12143
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.

4 participants