Comments on: Static binaries for a C++ application https://arangodb.com/2018/04/static-binaries-c-plus-plus-application/ The database for graph and beyond Mon, 05 Aug 2024 12:02:55 +0000 hourly 1 https://wordpress.org/?v=6.7.1 By: Max Neunhöffer https://arangodb.com/2018/04/static-binaries-c-plus-plus-application/#comment-93 Mon, 23 Sep 2019 08:50:00 +0000 https://www.arangodb.com/?p=25237#comment-93 Hi,
as far as I understand the Alpine Linux people have created packages for gcc and libstdc++ which work with libmusl and thus without using glibc extensions. We are also not using glibc extensions. Therefore, we seem to be fine. The static linking installs everything we need into the static executable.
At the time when this article was written, I did some experiments with clang++ on Alpine to produce static executables, but this did not work at the time. Therefore I went the gcc route and this has worked beautifully so far.
Does this answer your question?
Cheers,
Max.

]]>
By: Julio Guerra https://arangodb.com/2018/04/static-binaries-c-plus-plus-application/#comment-92 Mon, 23 Sep 2019 07:13:33 +0000 https://www.arangodb.com/?p=25237#comment-92 Hello,
I am surprised you did not get issues with the libstdc++ that uses glibc extensions, including the shared libgcc for the stack unwinding. The g++ you install and use in you Alpine uses it. Do they end up in your static binary? I am looking for the same portability but for a shared library and got stuck at that point. I am heading to using the libc++ from llvm to try to get rid of these.

]]>