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

When using extended LLVM check if the include folder is present #400

Merged
merged 1 commit into from
Dec 5, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 12 additions & 3 deletions src/toolchain/llvm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -177,10 +177,19 @@ impl Installable for Llvm {
let mut exports: Vec<String> = Vec::new();

#[cfg(unix)]
let is_installed = Path::new(&self.path).exists();
let install_path = if self.extended {
Path::new(&self.path).join("esp-clang").join("include")
} else {
Path::new(&self.path).to_path_buf()
};
#[cfg(windows)]
let is_installed = self.path.join(&self.version).exists();
if is_installed {
let install_path = if self.extended {
self.path.join(&self.version).join("include")
} else {
self.path.join(&self.version)
};

if install_path.exists() {
warn!(
"Previous installation of LLVM exists in: '{}'. Reusing this installation",
self.path.to_str().unwrap()
Expand Down