Skip to content

Commit

Permalink
Add support for C3 to bindgen
Browse files Browse the repository at this point in the history
  • Loading branch information
radekm committed Nov 13, 2024
1 parent 7e50f80 commit b9e6e94
Show file tree
Hide file tree
Showing 5 changed files with 455 additions and 1 deletion.
4 changes: 4 additions & 0 deletions .github/workflows/gen_bindings.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,10 @@ jobs:
with:
repository: colinbellino/sokol-jai
path: bindgen/sokol-jai
- uses: actions/checkout@main
with:
repository: radekm/sokol-c3
path: bindgen/sokol-c3
- name: generate
run: |
cd bindgen
Expand Down
1 change: 1 addition & 0 deletions bindgen/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,4 @@ sokol-odin/
sokol-rust/
sokol-d/
sokol-jai/
sokol-c3/
1 change: 1 addition & 0 deletions bindgen/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ To update the Zig bindings:
> git clone https://github.com/floooh/sokol-rust
> git clone https://github.com/floooh/sokol-d
> git clone https://github.com/colinbellino/sokol-jai
> git clone https://github.com/radekm/sokol-c3
> python3 gen_all.py
```

Expand Down
8 changes: 7 additions & 1 deletion bindgen/gen_all.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import os, gen_nim, gen_zig, gen_odin, gen_rust, gen_d, gen_jai
import os, gen_nim, gen_zig, gen_odin, gen_rust, gen_d, gen_jai, gen_c3

tasks = [
[ '../sokol_log.h', 'slog_', [] ],
Expand Down Expand Up @@ -56,3 +56,9 @@
for task in tasks:
[c_header_path, main_prefix, dep_prefixes] = task
gen_rust.gen(c_header_path, main_prefix, dep_prefixes)

# C3
gen_c3.prepare()
for task in tasks:
[c_header_path, main_prefix, dep_prefixes] = task
gen_c3.gen(c_header_path, main_prefix, dep_prefixes)
Loading

0 comments on commit b9e6e94

Please sign in to comment.