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

rustbuild: Restore Config.libdir_relative #48362

Merged
merged 2 commits into from
Feb 25, 2018

Conversation

cuviper
Copy link
Member

@cuviper cuviper commented Feb 19, 2018

This re-introduces a Config.libdir_relative field, now derived from
libdir and made relative to prefix if necessary.

This fixes a regression from #46592 when --libdir is given an absolute
path. Builder::sysroot_libdir should always use a relative path so
its callers don't clobber system locations, and librustc also asserts
that CFG_LIBDIR_RELATIVE is really relative.

This re-introduces a `Config.libdir_relative` field, now derived from
`libdir` and made relative to `prefix` if necessary.

This fixes a regression from rust-lang#46592 when `--libdir` is given an absolute
path.  `Builder::sysroot_libdir` should always use a relative path so
its callers don't clobber system locations, and `librustc` also asserts
that `CFG_LIBDIR_RELATIVE` is really relative.
@rust-highfive
Copy link
Collaborator

r? @alexcrichton

(rust_highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Feb 19, 2018
@Mark-Simulacrum
Copy link
Member

Hm, so I think this is fine in general, but could we make libdir_relative a method on Config instead? It shouldn't really matter performance wise and it makes things easier from a maintenance viewpoint since there's no need to confirm it's kept up-to-date and think about it...

@cuviper
Copy link
Member Author

cuviper commented Feb 20, 2018

OK, it's now a method.

Can we also nominate this for beta?

@Mark-Simulacrum Mark-Simulacrum added beta-nominated Nominated for backporting to the compiler in the beta channel. beta-accepted Accepted for backporting to the compiler in the beta channel. labels Feb 20, 2018
@Mark-Simulacrum
Copy link
Member

@bors r+

I've accepted for beta backport.

@bors
Copy link
Contributor

bors commented Feb 20, 2018

📌 Commit 8174c0d has been approved by Mark-Simulacrum

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Feb 20, 2018
@cuviper
Copy link
Member Author

cuviper commented Feb 20, 2018

Thanks!

kennytm added a commit to kennytm/rust that referenced this pull request Feb 25, 2018
…ulacrum

rustbuild: Restore Config.libdir_relative

This re-introduces a `Config.libdir_relative` field, now derived from
`libdir` and made relative to `prefix` if necessary.

This fixes a regression from rust-lang#46592 when `--libdir` is given an absolute
path.  `Builder::sysroot_libdir` should always use a relative path so
its callers don't clobber system locations, and `librustc` also asserts
that `CFG_LIBDIR_RELATIVE` is really relative.
bors added a commit that referenced this pull request Feb 25, 2018
Rollup of 17 pull requests

- Successful merges: #47964, #47970, #48076, #48115, #48166, #48281, #48297, #48302, #48362, #48369, #48489, #48491, #48494, #48517, #48529, #48235, #48330
- Failed merges:
@bors bors merged commit 8174c0d into rust-lang:master Feb 25, 2018
@kennytm kennytm removed the beta-nominated Nominated for backporting to the compiler in the beta channel. label Mar 7, 2018
bors added a commit that referenced this pull request Mar 9, 2018
bors added a commit that referenced this pull request Mar 9, 2018
@cuviper cuviper deleted the libdir_relative branch April 17, 2018 18:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
beta-accepted Accepted for backporting to the compiler in the beta channel. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants