Skip to content

Commit

Permalink
Bundle compiler rt when compiling flecs as static library
Browse files Browse the repository at this point in the history
  • Loading branch information
BeanCheeseBurrito committed Nov 9, 2024
1 parent b8af781 commit 3ef5373
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/Flecs.NET.Native/build.zig
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,10 @@ pub fn compileFlecs(options: anytype, b: *Build, lib_type: LibType) void {

lib.linkLibC();

if (lib_type == LibType.Static) {
lib.bundle_compiler_rt = true;
}

lib.defineCMacro(if (options.optimize == .Debug) "FLECS_DEBUG" else "FLECS_NDEBUG", null);
lib.defineCMacro(if (lib_type == LibType.Shared) "flecs_EXPORTS" else "flecs_STATIC", null);

Expand Down

0 comments on commit 3ef5373

Please sign in to comment.