| ... | @@ -117,6 +117,7 @@ pub fn buildLibCXX(comp: *Compilation) !void { | ... | @@ -117,6 +117,7 @@ pub fn buildLibCXX(comp: *Compilation) !void { |
| 117 | | 117 | |
| 118 | const cxxabi_include_path = try comp.zig_lib_directory.join(arena, &[_][]const u8{ "libcxxabi", "include" }); | 118 | const cxxabi_include_path = try comp.zig_lib_directory.join(arena, &[_][]const u8{ "libcxxabi", "include" }); |
| 119 | const cxx_include_path = try comp.zig_lib_directory.join(arena, &[_][]const u8{ "libcxx", "include" }); | 119 | const cxx_include_path = try comp.zig_lib_directory.join(arena, &[_][]const u8{ "libcxx", "include" }); |
| | 120 | const cxx_src_include_path = try comp.zig_lib_directory.join(arena, &[_][]const u8{ "libcxx", "src" }); |
| 120 | var c_source_files = try std.ArrayList(Compilation.CSourceFile).initCapacity(arena, libcxx_files.len); | 121 | var c_source_files = try std.ArrayList(Compilation.CSourceFile).initCapacity(arena, libcxx_files.len); |
| 121 | | 122 | |
| 122 | for (libcxx_files) |cxx_src| { | 123 | for (libcxx_files) |cxx_src| { |
| ... | @@ -173,6 +174,9 @@ pub fn buildLibCXX(comp: *Compilation) !void { | ... | @@ -173,6 +174,9 @@ pub fn buildLibCXX(comp: *Compilation) !void { |
| 173 | try cflags.append("-I"); | 174 | try cflags.append("-I"); |
| 174 | try cflags.append(cxxabi_include_path); | 175 | try cflags.append(cxxabi_include_path); |
| 175 | | 176 | |
| | 177 | try cflags.append("-I"); |
| | 178 | try cflags.append(cxx_src_include_path); |
| | 179 | |
| 176 | if (target_util.supports_fpic(target)) { | 180 | if (target_util.supports_fpic(target)) { |
| 177 | try cflags.append("-fPIC"); | 181 | try cflags.append("-fPIC"); |
| 178 | } | 182 | } |
| ... | @@ -269,6 +273,7 @@ pub fn buildLibCXXABI(comp: *Compilation) !void { | ... | @@ -269,6 +273,7 @@ pub fn buildLibCXXABI(comp: *Compilation) !void { |
| 269 | | 273 | |
| 270 | const cxxabi_include_path = try comp.zig_lib_directory.join(arena, &[_][]const u8{ "libcxxabi", "include" }); | 274 | const cxxabi_include_path = try comp.zig_lib_directory.join(arena, &[_][]const u8{ "libcxxabi", "include" }); |
| 271 | const cxx_include_path = try comp.zig_lib_directory.join(arena, &[_][]const u8{ "libcxx", "include" }); | 275 | const cxx_include_path = try comp.zig_lib_directory.join(arena, &[_][]const u8{ "libcxx", "include" }); |
| | 276 | const cxx_src_include_path = try comp.zig_lib_directory.join(arena, &[_][]const u8{ "libcxx", "src" }); |
| 272 | var c_source_files = try std.ArrayList(Compilation.CSourceFile).initCapacity(arena, libcxxabi_files.len); | 277 | var c_source_files = try std.ArrayList(Compilation.CSourceFile).initCapacity(arena, libcxxabi_files.len); |
| 273 | | 278 | |
| 274 | for (libcxxabi_files) |cxxabi_src| { | 279 | for (libcxxabi_files) |cxxabi_src| { |
| ... | @@ -311,6 +316,9 @@ pub fn buildLibCXXABI(comp: *Compilation) !void { | ... | @@ -311,6 +316,9 @@ pub fn buildLibCXXABI(comp: *Compilation) !void { |
| 311 | try cflags.append("-I"); | 316 | try cflags.append("-I"); |
| 312 | try cflags.append(cxx_include_path); | 317 | try cflags.append(cxx_include_path); |
| 313 | | 318 | |
| | 319 | try cflags.append("-I"); |
| | 320 | try cflags.append(cxx_src_include_path); |
| | 321 | |
| 314 | if (target_util.supports_fpic(target)) { | 322 | if (target_util.supports_fpic(target)) { |
| 315 | try cflags.append("-fPIC"); | 323 | try cflags.append("-fPIC"); |
| 316 | } | 324 | } |