| ... | @@ -289,6 +289,7 @@ const FrameworkLinkInfo = struct { | ... | @@ -289,6 +289,7 @@ const FrameworkLinkInfo = struct { |
| 289 | pub const IncludeDir = union(enum) { | 289 | pub const IncludeDir = union(enum) { |
| 290 | path: LazyPath, | 290 | path: LazyPath, |
| 291 | path_system: LazyPath, | 291 | path_system: LazyPath, |
| | 292 | path_after: LazyPath, |
| 292 | framework_path: LazyPath, | 293 | framework_path: LazyPath, |
| 293 | framework_path_system: LazyPath, | 294 | framework_path_system: LazyPath, |
| 294 | other_step: *Compile, | 295 | other_step: *Compile, |
| ... | @@ -1062,6 +1063,12 @@ pub fn addObject(self: *Compile, obj: *Compile) void { | ... | @@ -1062,6 +1063,12 @@ pub fn addObject(self: *Compile, obj: *Compile) void { |
| 1062 | self.linkLibraryOrObject(obj); | 1063 | self.linkLibraryOrObject(obj); |
| 1063 | } | 1064 | } |
| 1064 | | 1065 | |
| | 1066 | pub fn addAfterIncludePath(self: *Compile, path: LazyPath) void { |
| | 1067 | const b = self.step.owner; |
| | 1068 | self.include_dirs.append(IncludeDir{ .path_after = path.dupe(b) }) catch @panic("OOM"); |
| | 1069 | path.addStepDependencies(&self.step); |
| | 1070 | } |
| | 1071 | |
| 1065 | pub fn addSystemIncludePath(self: *Compile, path: LazyPath) void { | 1072 | pub fn addSystemIncludePath(self: *Compile, path: LazyPath) void { |
| 1066 | const b = self.step.owner; | 1073 | const b = self.step.owner; |
| 1067 | self.include_dirs.append(IncludeDir{ .path_system = path.dupe(b) }) catch @panic("OOM"); | 1074 | self.include_dirs.append(IncludeDir{ .path_system = path.dupe(b) }) catch @panic("OOM"); |
| ... | @@ -1842,6 +1849,10 @@ fn make(step: *Step, prog_node: *std.Progress.Node) !void { | ... | @@ -1842,6 +1849,10 @@ fn make(step: *Step, prog_node: *std.Progress.Node) !void { |
| 1842 | try zig_args.append("-isystem"); | 1849 | try zig_args.append("-isystem"); |
| 1843 | try zig_args.append(include_path.getPath(b)); | 1850 | try zig_args.append(include_path.getPath(b)); |
| 1844 | }, | 1851 | }, |
| | 1852 | .path_after => |include_path| { |
| | 1853 | try zig_args.append("-idirafter"); |
| | 1854 | try zig_args.append(include_path.getPath(b)); |
| | 1855 | }, |
| 1845 | .framework_path => |include_path| { | 1856 | .framework_path => |include_path| { |
| 1846 | try zig_args.append("-F"); | 1857 | try zig_args.append("-F"); |
| 1847 | try zig_args.append(include_path.getPath2(b, step)); | 1858 | try zig_args.append(include_path.getPath2(b, step)); |