aboutsummaryrefslogtreecommitdiff
path: root/src/codegen.cpp
diff options
context:
space:
mode:
authorAndrew Kelley <superjoe30@gmail.com>2017-04-21 01:56:12 -0400
committerAndrew Kelley <superjoe30@gmail.com>2017-04-21 01:56:12 -0400
commitfb492d19ebb56466f04a2a88c7d3c0a9833f2e0d (patch)
tree2d87121db6510c014c34d9a8f7071eb1805ba52a /src/codegen.cpp
parent599215cee46b83d052f57a3e6566098900332e38 (diff)
downloadzig-fb492d19ebb56466f04a2a88c7d3c0a9833f2e0d.tar.gz
zig-fb492d19ebb56466f04a2a88c7d3c0a9833f2e0d.zip
zig build system supports building a library
See #329 Supporting work: * move std.cstr.Buffer0 to std.buffer.Buffer * add build.zig to example/shared_library/ and add an automated test for it * add std.list.List.resizeDown * improve std.os.makePath - no longer recursive - takes into account . and .. * add std.os.path.isAbsolute * add std.os.path.resolve * reimplement std.os.path.dirname - no longer requires an allocator - handles edge cases correctly
Diffstat (limited to 'src/codegen.cpp')
-rw-r--r--src/codegen.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/codegen.cpp b/src/codegen.cpp
index 735c3f19a9..d8c3e0e2d6 100644
--- a/src/codegen.cpp
+++ b/src/codegen.cpp
@@ -155,6 +155,12 @@ void codegen_set_test_name_prefix(CodeGen *g, Buf *prefix) {
g->test_name_prefix = prefix;
}
+void codegen_set_lib_version(CodeGen *g, size_t major, size_t minor, size_t patch) {
+ g->version_major = major;
+ g->version_minor = minor;
+ g->version_patch = patch;
+}
+
void codegen_set_is_test(CodeGen *g, bool is_test_build) {
g->is_test_build = is_test_build;
}