Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Split configuration into a separate header file #145

Open
paravoid opened this issue Jan 15, 2020 · 1 comment
Open

Split configuration into a separate header file #145

paravoid opened this issue Jan 15, 2020 · 1 comment

Comments

@paravoid
Copy link

miniz.h right now serves two purposes: generic headers/function prototypes and such, and #defines that the miniz user can change to alter behavior/code size (e.g. #define MINIZ_NO_STDIO).

It'd be ideal for the configuration to live in an entirely separate file to avoid mixing these two purposes. This would also allow users to check their configuration in their own VCS, and copy it & forward-port it when they need to use a newer version of miniz, rather than hand-picking for lines in miniz.h.

Additionally -and this may belong in a separate ticket- for some users it may make sense to not use the amalgated version and instead e.g. add miniz as a git submodule to their project. Given the amalgation process just concatenates the headers and is not actually unifdefing them or anything, it seems like this could be possible (but I may be missing something). In combination with the miniz_config.h split request above, this could perhaps allow for a pattern where one could add "#include "miniz_config.h"\n#include "miniz/miniz.h" in their project's tree (plus some Make code for building miniz.o), and have it do the right thing?

@caco3
Copy link

caco3 commented Nov 7, 2022

Bump, do I see it right that inclusion as a submodule still is not possible?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants