aboutsummaryrefslogtreecommitdiff
path: root/src/codegen.cpp
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2020-09-09 00:05:38 -0700
committerAndrew Kelley <andrew@ziglang.org>2020-09-09 09:28:05 -0700
commit193ad413f03322b047bbfe17c4b2b368ba6bc097 (patch)
tree5be27a318191ad64cb96e6702e55326f4255f182 /src/codegen.cpp
parentc99e34a00e1e839effbc8b257a400eb3b643fa12 (diff)
downloadzig-193ad413f03322b047bbfe17c4b2b368ba6bc097.tar.gz
zig-193ad413f03322b047bbfe17c4b2b368ba6bc097.zip
stage2: compiling C objects with clang
* add target_util.zig which has ported code from src/target.cpp * Module gains an arena that owns memory used during initialization that has the same lifetime as the Module. Useful for constructing file paths and lists of strings that have mixed lifetimes. - The Module memory itself is allocated in this arena. init/deinit are modified to be create/destroy. - root_name moves to the arena and no longer needs manual free * implement the ability to invoke `zig clang` as a subprocess - there are lots of TODOs that should be solved before merging * Module now requires a Random object and zig_lib_dir * Module now requires a path to its own executable or any zig executable that can do `zig clang`. * Wire up more CLI options. * Module creates "zig-cache" directory and "tmp" and "o" subdirectories ("h" is created by the cache_hash) * stubbed out some of the things linker code needs to do with TODO prints * delete dead code for computing compiler id. the previous commit eliminated the need for it. * add `zig translate-c` CLI option but it's not fully hooked up yet. It should be possible for this to be fully wired up before merging this branch. * `zig targets` now uses canonical data for available_libcs
Diffstat (limited to 'src/codegen.cpp')
0 files changed, 0 insertions, 0 deletions