-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2 from kassane/fixes
some fixes
- Loading branch information
Showing
70 changed files
with
82 additions
and
874 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: Zig Build | ||
|
||
on: [push, pull_request] | ||
|
||
jobs: | ||
build: | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
runs-on: [ubuntu-latest, macos-latest, windows-latest] | ||
runs-on: ${{ matrix.runs-on }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
submodules: recursive | ||
fetch-depth: 0 | ||
- uses: goto-bus-stop/setup-zig@v2 | ||
with: | ||
version: 0.10.1 | ||
|
||
- name: Build Summary | ||
run: zig build -freference-trace |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
zig-cache/ | ||
zig-out/ |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
const Builder = @import("std").build.Builder; | ||
|
||
pub fn build(b: *Builder) void { | ||
const target = b.standardTargetOptions(.{}); | ||
const mode = b.standardReleaseOptions(); //-Drelease-safe|release-fast|release-small | ||
|
||
const lib = b.addSharedLibrary("function_parameter", "src/function_parameter.zig", .unversioned); | ||
lib.setBuildMode(mode); | ||
lib.setTarget(target); | ||
lib.linkLibC(); // next function need libc | ||
lib.install(); | ||
|
||
const exe = b.addExecutable("CortexC", null); | ||
exe.addCSourceFile("src/main.c", &.{ | ||
"-Wall", | ||
"-Wextra", | ||
// "-Werror", | ||
}); | ||
exe.setBuildMode(mode); | ||
exe.setTarget(target); | ||
exe.addIncludePath("src"); | ||
exe.linkLibrary(lib); | ||
exe.linkLibC(); | ||
exe.install(); | ||
|
||
const run_cmd = exe.run(); | ||
run_cmd.step.dependOn(b.getInstallStep()); | ||
if (b.args) |args| { | ||
run_cmd.addArgs(args); | ||
} | ||
|
||
// zig build run - running Exe. | ||
const run_step = b.step("run", b.fmt("Run the {s} app.", .{exe.name})); | ||
run_step.dependOn(&run_cmd.step); | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
Binary file not shown.
Empty file.
Empty file.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.