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

build: fix BINDIR_DEPTH computation on Windows #3075

Merged
merged 1 commit into from
Oct 9, 2022

Conversation

ret2libc
Copy link
Member

@ret2libc ret2libc commented Oct 7, 2022

Your checklist for this pull request

  • I've read the guidelines for contributing to this repository
  • I made sure to follow the project's coding style
  • I've documented or updated the documentation of every function and struct this PR changes. If not so I've explained why.
  • I've added tests that prove my fix is effective or that my feature works (if possible)
  • I've updated the rizin book with the relevant information (if needed)

Detailed description

Before there was a special case for the root dir and it was implemented by using os.sep as the representation for the root. That did not work on Windows. This commit rewrite the BINDIR_DEPTH computation's logic to use Path objects instead.

Test plan

  1. Download windows build
  2. Install it under D:\ (or C:\ or whatever)
  3. Run rizin -H and check that the various directories make sense.

Before the patch RZ_LIBDIR was like C:\bin\lib, but the correct value should be C:\bin.

Closing issues

...

Before there was a special case for the root dir and it was implemented
by using `os.sep` as the representation for the root. That did not work
on Windows. This commit rewrite the BINDIR_DEPTH computation's logic to
use Path objects instead.
@XVilka XVilka merged commit eaec1a8 into dev Oct 9, 2022
@XVilka XVilka deleted the dist-windows-portable-fix branch October 9, 2022 02:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants