Skip to content

doccaico/libxml2-zig-windows

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

libxml2-zig-windows

This binding tested on libxml2 2.12.6 and Zig master version. It's Windows only.

Fetch

$ zig fetch --save=libxml2 https://github.com/doccaico/libxml2-zig-windows/archive/<git-commit-hash>.tar.gz

Usage

// build.zig

const libxml2 = b.dependency("libxml2", .{ .target = target, .optimize = optimize });
exe.linkLibrary(libxml2.artifact("libxml2"));

// src/main.zig

const std = @import("std");

const c = @cImport({
    @cInclude("libxml/xmlreader.h");
});

[your code ...]

See more examples

Tests

$ git clone https://github.com/doccaico/libxml2-zig-windows.git
$ cd libxml2-zig-windows

# Builds all the examples
$ zig build examples

# To list available examples
$ zig build --help

Based on mitchellh/zig-build-libxml2 and ianprime0509/zig-libxml2

About

libxml2 built using Zig build system for Windows

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages