Add bindings

This commit is contained in:
G3bE 2020-02-15 19:58:03 +10:00
commit abd32b7cc8
Failed to generate hash of commit
9 changed files with 1626 additions and 0 deletions

30
projectSetup.sh Executable file
View file

@ -0,0 +1,30 @@
if [ "$#" -ne 1 ]; then
PROJECT_NAME='Project'
else
PROJECT_NAME=$1
fi
mkdir "$PROJECT_NAME" && cd "$PROJECT_NAME" || exit
touch build.zig
echo 'const Builder = @import("std").build.Builder;
pub fn build(b: *Builder) void {
const mode = b.standardReleaseOptions();
const exe = b.addExecutable('"$PROJECT_NAME"', "src/main.zig");
exe.setBuildMode(mode);
exe.linkSystemLibrary("raylib");
exe.install();
const run_cmd = exe.run();
run_cmd.step.dependOn(b.getInstallStep());
const run_step = b.step("run", "Run the app");
run_step.dependOn(&run_cmd.step);
}
' >> build.zig
mkdir src
cp ../lib/* src
cp ../examples/core/BasicWindow.zig src
mv src/BasicWindow.zig src/main.zig