Conversation
carlopi
left a comment
There was a problem hiding this comment.
Main question: can we get away from static linking the libc++ ?
I see that working with, question is if we can manage without.
I think in general this will not work because the standard alpine distribution doesn't include these libraries. Not linking it means requiring users to always install them in their Alpine containers when they want to use duckdb. This error happened trying to run duckdb (libstdc++ and libgcc linked) in the standard Metabase container which uses alpine, and loading httpfs (no libstdc++ and libgcc linked). Also this does mean the extensions need to have statically linked libstdc++ and libgcc. Idk if there's a better solution here. |
|
But I think the problem here is that v1.1.2 has no concept (yet) of musl. Would it be possible to run the same workflow again using a recent duckdb commit (such as 09cef57892 the one currently backed in duckdb-java) |
I tried this again on this branch and it still fails |
|
Hello |
|
Hi, yes, preliminary JDBC Also, may I ask which JDK build are you considering to use on Alpine, is it glibc-based or musl-based? |
|
Hi |
|
@hrl20: I realize my previous comments are void, thanks for the explanation. |
|
@staticlibs: unsure how to proceed, I think it's more appropriate for you to make a call |
This change adds experimental support for building JDBC driver with musl libc on x86_64 and aarch64 Linux. It is based on duckdb#120 PR. New artifacts are NOT combined into the unified JAR, instead they are published to Maven with custom classifiers `linux_amd64_musl` and `linux_aarch64_musl`. Co-authored-by: hrl20 <louisa@motherduck.com>
This change adds experimental support for building JDBC driver with musl libc on x86_64 and aarch64 Linux. It is based on #120 PR. New artifacts are NOT combined into the unified JAR, instead they are published to Maven with custom classifiers `linux_amd64_musl` and `linux_aarch64_musl`. Co-authored-by: hrl20 <louisa@motherduck.com>
|
Thanks for this PR, and sorry for the long waiting time with it! I've incorporated it into #226, the nightly dev version can be used now from the Maven snapshots repo: <dependencies>
<dependency>
<groupId>org.duckdb</groupId>
<artifactId>duckdb_jdbc</artifactId>
<version>1.3.0-SNAPSHOT</version>
<classifier>linux_amd64_musl</classifier>
</dependency>
<dependencies>
<repositories>
<repository>
<id>oss-sonatype</id>
<name>oss-sonatype</name>
<url>https://oss.sonatype.org/content/repositories/snapshots/</url>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>Notable changes from the original PR:
|

Build duckdb_java for Alpine linux on amd64
(arm64 is possible but takes 4+ hours on the default GHA runner, so skipping for now)