| ... | @@ -284,7 +284,7 @@ fn configureStage2(b: *Builder, exe: var, ctx: Context) !void { | ... | @@ -284,7 +284,7 @@ fn configureStage2(b: *Builder, exe: var, ctx: Context) !void { |
| 284 | exe.addObjectFile(libstdcxx_path); | 284 | exe.addObjectFile(libstdcxx_path); |
| 285 | | 285 | |
| 286 | exe.linkSystemLibrary("pthread"); | 286 | exe.linkSystemLibrary("pthread"); |
| 287 | } else if (exe.target.isDarwin()) { | 287 | } else if (exe.target.isDarwin() or exe.target.isFreeBSD()) { |
| 288 | exe.linkSystemLibrary("c++"); | 288 | exe.linkSystemLibrary("c++"); |
| 289 | } | 289 | } |
| 290 | | 290 | |
| ... | @@ -293,6 +293,10 @@ fn configureStage2(b: *Builder, exe: var, ctx: Context) !void { | ... | @@ -293,6 +293,10 @@ fn configureStage2(b: *Builder, exe: var, ctx: Context) !void { |
| 293 | } | 293 | } |
| 294 | | 294 | |
| 295 | if (exe.target.getOs() != builtin.Os.windows) { | 295 | if (exe.target.getOs() != builtin.Os.windows) { |
| | 296 | if (exe.target.isFreeBSD()) { |
| | 297 | exe.addLibPath("/usr/local/lib"); |
| | 298 | // TODO use pkg-config |
| | 299 | } |
| 296 | exe.linkSystemLibrary("xml2"); | 300 | exe.linkSystemLibrary("xml2"); |
| 297 | } | 301 | } |
| 298 | exe.linkSystemLibrary("c"); | 302 | exe.linkSystemLibrary("c"); |