aboutsummaryrefslogtreecommitdiffstats
path: root/src/c.zig
diff options
context:
space:
mode:
Diffstat (limited to 'src/c.zig')
-rw-r--r--src/c.zig12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/c.zig b/src/c.zig
index b46d0f4..7b46914 100644
--- a/src/c.zig
+++ b/src/c.zig
@@ -1,10 +1,14 @@
+const build_config = @import("build_config");
+
pub usingnamespace @cImport({
@cInclude("epoxy/gl.h");
@cInclude("GLFW/glfw3.h");
@cInclude("yaml.h");
@cInclude("lo/lo.h");
- @cInclude("lo/lo.h");
- @cInclude("libavcodec/avcodec.h");
- @cInclude("libavformat/avformat.h");
- @cInclude("libswscale/swscale.h");
+
+ if (build_config.have_ffmpeg) {
+ @cInclude("libavcodec/avcodec.h");
+ @cInclude("libavformat/avformat.h");
+ @cInclude("libswscale/swscale.h");
+ }
});