diff --git a/Dockerfile.alpine-musl b/Dockerfile.alpine-musl index 51f2d82..0718714 100644 --- a/Dockerfile.alpine-musl +++ b/Dockerfile.alpine-musl @@ -72,8 +72,20 @@ RUN git clone https://git.laantungir.net/laantungir/nostr_core_lib.git /build/no RUN cd nostr_core_lib && \ chmod +x build.sh && \ sed -i 's/CFLAGS="-Wall -Wextra -std=c99 -fPIC -O2"/CFLAGS="-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=0 -Wall -Wextra -std=c99 -fPIC -O2"/' build.sh && \ + if [ "$(uname -m)" = "aarch64" ] && ! command -v aarch64-linux-gnu-gcc >/dev/null 2>&1; then \ + ln -sf /usr/bin/gcc /usr/local/bin/aarch64-linux-gnu-gcc; \ + fi && \ rm -f *.o *.a 2>/dev/null || true && \ - ./build.sh --nips=1,6,13,17,19,42,44,59 + ./build.sh --nips=1,6,13,17,19,42,44,59 && \ + if [ -f libnostr_core_arm64.a ]; then \ + cp libnostr_core_arm64.a libnostr_core.a; \ + elif [ -f libnostr_core_x64.a ]; then \ + cp libnostr_core_x64.a libnostr_core.a; \ + else \ + echo "ERROR: No supported nostr_core static library produced"; \ + ls -la *.a 2>/dev/null || true; \ + exit 1; \ + fi # Copy web interface files for embedding # Note: Changes to api/ files will trigger rebuild from this point @@ -110,7 +122,7 @@ RUN if [ "$DEBUG_BUILD" = "true" ]; then \ src/request_validator.c src/relay_client.c \ nostr_core_lib/nostr_core/core_relay_pool.c \ -o /build/ginxsom-fcgi_static \ - nostr_core_lib/libnostr_core_x64.a \ + nostr_core_lib/libnostr_core.a \ -lfcgi -lsqlite3 -lsecp256k1 -lssl -lcrypto -lcurl \ -lnghttp2 -lcares -lidn2 -lunistring -lpsl -lbrotlidec -lbrotlicommon \ -lz -lpthread -lm -ldl && \ diff --git a/build/ginxsom-fcgi_static_x86_64 b/build/ginxsom-fcgi_static_x86_64 index 910429b..b1b46cd 100755 Binary files a/build/ginxsom-fcgi_static_x86_64 and b/build/ginxsom-fcgi_static_x86_64 differ diff --git a/src/ginxsom.h b/src/ginxsom.h index 0a4b8c6..88a4ee1 100644 --- a/src/ginxsom.h +++ b/src/ginxsom.h @@ -10,8 +10,8 @@ // Version information (auto-updated by build system) #define VERSION_MAJOR 0 #define VERSION_MINOR 2 -#define VERSION_PATCH 1 -#define VERSION "v0.2.1" +#define VERSION_PATCH 2 +#define VERSION "v0.2.2" #include #include