Skip to content

Difference between ZPL_STATIC and ZPL_STATIC_BUILD? #96

Answered by zpl-zak
ib00 asked this question in Q&A
Discussion options

You must be logged in to vote

ZPL_STATIC_LIB is used when you intend to compile zpl into its own .lib file.

Whereas ZPL_STATIC enforces static linkage of symbols within compilation units that define ZPL_IMPLEMENTATION, thus ensuring symbols don't leak outside the unit. This is useful if you intend to compile zpl with different compile-time switches in multiple source files, each relying on ZPL_IMPLEMENTATION to pull the code in and avoid having symbol collisions in between them.

Sorry for the very late response!

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by ib00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants