# Felix Queißner - Zig Build Explained - Part 2 (Highlights)

## Metadata
**Review**:: [readwise.io](https://readwise.io/bookreview/56244246)
**Source**:: #from/readwise #from/reader
**Zettel**:: #zettel/fleeting
**Status**:: #x
**Authors**:: [[Felix Queißner]]
**Full Title**:: Zig Build Explained - Part 2
**Category**:: #articles #readwise/articles
**Category Icon**:: 📰
**URL**:: [zig.news](https://zig.news/xq/zig-build-explained-part-2-1850)
**Host**:: [[zig.news]]
**Highlighted**:: [[2025-11-14]]
**Created**:: [[2025-11-15]]
## Highlights
- exe.linkLibC(); ([View Highlight](https://read.readwise.io/read/01ka10n6ev9q5r0703755xd8c0)) ^957323221
`linkLibC` will setup header include paths
- We only covered C files until now, but building a C++ project isn't much harder. You still use `addCSourceFile`, but just pass a file that has a typical C++ file extension like `cpp`, `cxx`, `c++` or `cc` ([View Highlight](https://read.readwise.io/read/01ka10rt9stnw8n7edn12smejg)) ^957323360
- As you can see, we also need to call `linkLibCpp` which will link the c++ standard library shipped with Zig. ([View Highlight](https://read.readwise.io/read/01ka10s1c82ywy6bay6wsx4205)) ^957323364
- With `defineCMacro` we can define our own macros like we pass them with the `-D` compiler flag. ([View Highlight](https://read.readwise.io/read/01ka10thg29j3w2f5j3msv4zam)) ^957323425
- We then just have to call `addCSourceFiles` once per file collection and are ready to rock. ([View Highlight](https://read.readwise.io/read/01ka10w00zdsdhst173z2g65k2)) ^957323479
- Zig does not only support building C and C++, but also supports building Objective C via clang! ([View Highlight](https://read.readwise.io/read/01ka10wbga13jcgv9fv1rwaq00)) ^957323534
- The entry point of your application **must** be in Zig code right now ([View Highlight](https://read.readwise.io/read/01ka10xb1m79d88y4rdztzzny1)) ^957323551