Skip to content

Conversation

@vadz
Copy link
Contributor

@vadz vadz commented Nov 9, 2025

To avoid surprises in the projects consuming the library, don't define BUILD_SHARED_LIBS option ourselves but just use its value, if provided, to define HTTPLIB_SHARED option which can be also set directly to specify whether we should build static or shared library.

Closes #2263.


Note: I didn't update the documentation because I didn't find any mention of how to build the library there, please let me know if I've missed anything. I also didn't update the use of BUILD_SHARED_LIBS in test/make-shared-library.sh just to show that it still works the same as before.

To avoid surprises in the projects consuming the library, don't define
BUILD_SHARED_LIBS option ourselves but just use its value, if provided,
to define HTTPLIB_SHARED option which can be also set directly to
specify whether we should build static or shared library.

Closes yhirose#2263.
@yhirose
Copy link
Owner

yhirose commented Nov 10, 2025

@sum01 @jimmy-park could you please review this change for me as usual? Thanks!

@vadz
Copy link
Contributor Author

vadz commented Nov 10, 2025

No idea why the CI tests fail but this seems completely unrelated to the changes here.

@yhirose yhirose merged commit 1acf188 into yhirose:master Nov 11, 2025
25 of 31 checks passed
@yhirose
Copy link
Owner

yhirose commented Nov 11, 2025

Thanks all!

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

Successfully merging this pull request may close these issues.

Defining BUILD_SHARED_LIBS option may break superproject build when using add_subdirectory

3 participants