spdlog built with the zig build system. Original: https://github.com/jessechounard/spdlog
Find a file
Aleksandr Lebedev e7c211fc64
Some checks failed
Continuous Integration / build (push) Has been cancelled
Update to 1.16.0 and Zig v0.15
2025-11-19 15:39:00 +01:00
.github/workflows Create ci.yml 2025-03-20 13:17:01 -05:00
.gitignore Initial commit 2025-03-19 23:23:30 -05:00
build.zig Update to 1.16.0 and Zig v0.15 2025-11-19 15:39:00 +01:00
build.zig.zon Update to 1.16.0 and Zig v0.15 2025-11-19 15:39:00 +01:00
LICENSE Initial commit 2025-03-19 23:23:30 -05:00
manifest.scm Update to 1.16.0 and Zig v0.15 2025-11-19 15:39:00 +01:00
README.md Added instructions to readme 2025-03-20 00:11:22 -05:00

spdlog

This is spdlog, packaged for Zig. (Intended for C++ projects using Zig as a build tool.)

Usage

First, update your build.zig.zon:

zig fetch --save git+https://github.com/jessechounard/spdlog

Next, in your build.zig, you can access the library as a dependency:

const spdlog_dep = b.dependency("spdlog", .{
    .target = target,
    .optimize = optimize,
});
const spdlog_lib = spdlog_dep.artifact("spdlog");

exe.root_module.linkLibrary(spdlog_lib);

Finally, in your C++ file, you can use the library:

#include <spdlog/spdlog.h>

int main() {
  spdlog::info("Hello, world (from spdlog)!");
  return 0;
}