mirror of
https://github.com/roc-lang/roc.git
synced 2025-12-10 19:19:19 +00:00
fix how benchmark script is loaded on main
To get #6921 working, we need the benchmark script to pull glue.zig correctly on main. As such, we need to load it into a lib dir such that it is found in the correct relative path. This hopefully will get the benchmarking working on the other PR. Also, switch over to `lib` dir first cause that is what is seen in the wide.
This commit is contained in:
parent
27b36a8f1f
commit
109cafcafe
2 changed files with 9 additions and 9 deletions
|
|
@ -81,13 +81,13 @@ pub fn get_relative_path(sub_path: &Path) -> Option<PathBuf> {
|
|||
}
|
||||
|
||||
fn find_zig_glue_path() -> PathBuf {
|
||||
// First try using the repo path relative to the executable location.
|
||||
let path = get_relative_path(Path::new("crates/compiler/builtins/bitcode/src/glue.zig"));
|
||||
// First try using a lib path relative to the executable.
|
||||
let path = get_relative_path(Path::new("lib/glue.zig"));
|
||||
if let Some(path) = path {
|
||||
return path;
|
||||
}
|
||||
// Fallback on a lib path relative to the executable location.
|
||||
let path = get_relative_path(Path::new("lib/glue.zig"));
|
||||
// Fallback on the repo path relative to the executable location.
|
||||
let path = get_relative_path(Path::new("crates/compiler/builtins/bitcode/src/glue.zig"));
|
||||
if let Some(path) = path {
|
||||
return path;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue