From: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Date: Sun, 5 Oct 2025 22:23:55 +0000 (+0000) Subject: Fix Alpine HDHomeRun crash by building statically with generic CPU flags X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=refs%2Fpull%2F1949%2Fhead;p=thirdparty%2Ftvheadend.git Fix Alpine HDHomeRun crash by building statically with generic CPU flags Co-authored-by: Flole998 <9951871+Flole998@users.noreply.github.com> --- diff --git a/Containerfile.alpine b/Containerfile.alpine index 4dbae8683..04eaefd6c 100644 --- a/Containerfile.alpine +++ b/Containerfile.alpine @@ -25,7 +25,6 @@ RUN apk add --no-cache \ 'git' \ 'gnu-libiconv-dev' \ 'libdvbcsa-dev' \ - 'libhdhomerun-dev' \ 'libva-dev' \ 'libvpx-dev' \ 'linux-headers' \ @@ -41,12 +40,11 @@ RUN apk add --no-cache \ 'zlib-dev' \ && \ git config --global --add safe.directory '/src/data/dvb-scan' && \ - ./configure \ + CFLAGS="-O2 -mtune=generic" ./configure \ --prefix='/usr/local' \ --disable-doc \ --disable-execinfo \ --disable-ffmpeg_static \ - --disable-hdhomerun_static \ --disable-libfdkaac_static \ --disable-libmfx_static \ --disable-libopus_static \ @@ -92,7 +90,6 @@ RUN apk add --no-cache \ 'gnu-libiconv-libs' \ 'libcrypto3' \ 'libdvbcsa' \ - 'libhdhomerun-libs' \ 'libssl3' \ 'liburiparser' \ 'libva' \ diff --git a/Makefile.hdhomerun b/Makefile.hdhomerun index 21e58bfac..aa7b3d0b5 100644 --- a/Makefile.hdhomerun +++ b/Makefile.hdhomerun @@ -22,6 +22,9 @@ include $(DIR)/.config.mk unexport CFLAGS unexport LDFLAGS +# Use generic CPU tuning to avoid illegal instructions in containers +CFLAGS += -O2 -mtune=generic + ifeq ($(CONFIG_PIE),yes) CFLAGS += -fPIE else