-
Notifications
You must be signed in to change notification settings - Fork 105
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
Drivers are unusable when statically linked with CMake #2562
Comments
There's an existing PR to unvendor dependencies: #2546 |
The redefinition is intentional, but maybe we should provide an option to omit it. We could also optionally install headers (frankly, the expected method of usage is via the driver manager so this is all untrodden ground) |
If the expected method of usage is via the driver manager, why is anything redefined at all? Shouldn't only e.g. |
I have also always wondered this 🙂 |
Woops, I made a mistake in my original post; to be clear
Rereading this, I slightly misunderstood. I'm not saying to install the existing headers with everything exposed, I'm saying that there should be a header that exposes |
You can link the postgres driver and use the Adbc* functions. |
As in linking just the postgres driver and not the driver manager? Seems like an over optimisation? |
You loose a bit of documentation but it's pretty easy to use a macro to just call the driver callbacks: At the very least, an opt-out of getting any symbols other than the init function seems helpful (I also happen to think turning them off by default might lead to less accidental problems as people build more ADBC drivers into things). |
What happened?
Taking the postgres driver as an example:
adbc_driver_postgresql
links toadbc_driver_common
and a few other vendored dependencies like nanoarrow. Onlyadbc_driver_postgresql
is installed; the other libraries are missing. This leads to a linking error since the symbols provided in the other libraries are missing.AdbcDatabaseGetOption
). This leads to a duplicate symbol error when you try to link both the ADBC driver manager library and the postgresql driver together.PostgresqlDriverInit
is not declared in any installed header (the driver does not install any headers?), which complicates using it withAdbcDriverManagerDatabaseSetInitFunc
. This is less egregious as it's not that hard to just declare the function signature manually, but it is still odd that it's not provided.Stack Trace
No response
How can we reproduce the bug?
Environment/Setup
C driver version 1.4.0
The text was updated successfully, but these errors were encountered: