Skip to content

Commit 103e040

Browse files
Check if the libgccjit.so.0 file exists before creating a symlink to it
1 parent 2a2422c commit 103e040

File tree

1 file changed

+4
-4
lines changed
  • src/bootstrap/src/core/build_steps

1 file changed

+4
-4
lines changed

src/bootstrap/src/core/build_steps/gcc.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -124,10 +124,10 @@ impl Step for Gcc {
124124
command("make").current_dir(&out_dir).arg(format!("-j{}", builder.jobs())).run(builder);
125125
command("make").current_dir(&out_dir).arg("install").run(builder);
126126

127-
t!(builder.symlink_file(
128-
install_dir.join("lib/libgccjit.so"),
129-
install_dir.join("lib/libgccjit.so.0")
130-
));
127+
let lib_alias = install_dir.join("lib/libgccjit.so.0");
128+
if !lib_alias.exists() {
129+
t!(builder.symlink_file(install_dir.join("lib/libgccjit.so"), lib_alias,));
130+
}
131131

132132
t!(stamp.write());
133133

0 commit comments

Comments
 (0)