Skip to content

Commit

Permalink
Search for nginx folder based on CARGO_MANIFEST_DIR
Browse files Browse the repository at this point in the history
  • Loading branch information
gabioprisan committed Oct 25, 2023
1 parent af739c5 commit c286d4f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion nginx_module/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,9 @@ fn search_nginx_root_folder() -> String {

// First, try to find the include folders in any of the parent folders of this folder,
// This is the case when this is a submodule of nginx
let manifest_dir = env!("CARGO_MANIFEST_DIR");
for base in base_locations {
let folder = base.to_string();
let folder = format!("{manifest_dir}/{base}");
if check_nginx_root(Path::new(&folder)) {
return folder;
}
Expand Down

0 comments on commit c286d4f

Please sign in to comment.