Skip to content

meson: honor default_library=static - #858

Open
ebraminio wants to merge 1 commit into
libusb:masterfrom
ebraminio:meson-static
Open

ebraminio wants to merge 1 commit into
libusb:masterfrom
ebraminio:meson-static

Conversation

@ebraminio

Copy link
Copy Markdown

HIDAPI's Meson build hands the work to CMake, but it currently drops Meson's default_library choice on the floor. Asking for -Ddefault_library=static still builds a shared library, which breaks downstream/wrap builds that need static linking.

The CMake project already understands BUILD_SHARED_LIBS, so forward OFF when static is requested. Shared remains the default and is unchanged.

The Meson shim delegates to the CMake build without forwarding the requested
library type, so default_library=static still produced shared libraries.
Forward BUILD_SHARED_LIBS=OFF when static is requested; the default shared
build is unchanged.

This branch has not been deployed

No deployments
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.

1 participant