Ver código fonte

build.zig: fix raygui inclusion in windows crosscompilation (#4489)

pull/4523/head
kimierik 4 semanas atrás
committed by GitHub
pai
commit
532167d28b
Nenhuma chave conhecida encontrada para esta assinatura no banco de dados ID da chave GPG: B5690EEEBB952194
1 arquivos alterados com 2 adições e 0 exclusões
  1. +2
    -0
      build.zig

+ 2
- 0
build.zig Ver arquivo

@ -302,12 +302,14 @@ fn compileRaylib(b: *std.Build, target: std.Build.ResolvedTarget, optimize: std.
}
pub fn addRaygui(b: *std.Build, raylib: *std.Build.Step.Compile, raygui_dep: *std.Build.Dependency) void {
const raylib_dep = b.dependencyFromBuildZig(@This(), .{});
var gen_step = b.addWriteFiles();
raylib.step.dependOn(&gen_step.step);
const raygui_c_path = gen_step.add("raygui.c", "#define RAYGUI_IMPLEMENTATION\n#include \"raygui.h\"\n");
raylib.addCSourceFile(.{ .file = raygui_c_path });
raylib.addIncludePath(raygui_dep.path("src"));
raylib.addIncludePath(raylib_dep.path("src"));
raylib.installHeader(raygui_dep.path("src/raygui.h"), "raygui.h");
}

Carregando…
Cancelar
Salvar