diff --git a/Dockerfile b/Dockerfile index 37488e8..24336d4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,7 +3,8 @@ FROM ${BUILD_FROM} SHELL ["/bin/ash", "-o", "pipefail", "-c"] -ARG ALSA_VERSION +ARG ALSA_LIB_VERSION +ARG ALSA_TOOLS_VERSION ARG PULSE_VERSION COPY patches /usr/src/patches @@ -15,6 +16,7 @@ RUN \ libltdl \ alsa-utils \ alsa-lib \ + alsa-plugins-pulse \ dbus-libs \ tdb-libs \ bluez-libs \ @@ -45,11 +47,11 @@ RUN \ patch \ \ && curl -L -s --retry 5 \ - "ftp://ftp.alsa-project.org/pub/lib/alsa-ucm-conf-${ALSA_VERSION}.tar.bz2" \ + "https://www.alsa-project.org/files/pub/lib/alsa-ucm-conf-${ALSA_LIB_VERSION}.tar.bz2" \ | tar xvfj - -C /usr/share/alsa --strip-components=1 \ \ && curl -L -s --retry 5 \ - "ftp://ftp.alsa-project.org/pub/lib/alsa-topology-conf-${ALSA_VERSION}.tar.bz2" \ + "https://www.alsa-project.org/files/pub/lib/alsa-topology-conf-${ALSA_TOOLS_VERSION}.tar.bz2" \ | tar xvfj - -C /usr/share/alsa --strip-components=1 \ \ && git clone -b v${PULSE_VERSION} --depth 1 \ @@ -75,7 +77,7 @@ RUN \ -Dalsa=enabled \ -Dasyncns=disabled \ -Davahi=disabled \ - -Dbluez5=true \ + -Dbluez5=enabled \ -Ddbus=enabled \ -Dfftw=enabled \ -Dglib=enabled \ @@ -93,6 +95,7 @@ RUN \ -Dsystemd=disabled \ -Dudev=enabled \ -Dx11=disabled \ + -Ddoxygen=false \ -Dudevrulesdir=/usr/lib/udev/rules.d \ . output \ && ninja -C output \ diff --git a/build.yaml b/build.yaml index eb90ed6..7f47850 100644 --- a/build.yaml +++ b/build.yaml @@ -1,17 +1,18 @@ image: homeassistant/{arch}-hassio-audio shadow_repository: ghcr.io/home-assistant build_from: - aarch64: ghcr.io/home-assistant/aarch64-base:3.13 - armhf: ghcr.io/home-assistant/armhf-base:3.13 - armv7: ghcr.io/home-assistant/armv7-base:3.13 - amd64: ghcr.io/home-assistant/amd64-base:3.13 - i386: ghcr.io/home-assistant/i386-base:3.13 + aarch64: ghcr.io/home-assistant/aarch64-base:3.17 + armhf: ghcr.io/home-assistant/armhf-base:3.17 + armv7: ghcr.io/home-assistant/armv7-base:3.17 + amd64: ghcr.io/home-assistant/amd64-base:3.17 + i386: ghcr.io/home-assistant/i386-base:3.17 codenotary: signer: notary@home-assistant.io base_image: notary@home-assistant.io args: - ALSA_VERSION: 1.2.5.1 - PULSE_VERSION: 14.2 + ALSA_LIB_VERSION: 1.2.8 + ALSA_TOOLS_VERSION: 1.2.5 + PULSE_VERSION: 16.1 labels: io.hass.type: audio org.opencontainers.image.title: Home Assistant Audio Plugin diff --git a/patches/check_uid.patch b/patches/check_uid.patch deleted file mode 100644 index a54ede3..0000000 --- a/patches/check_uid.patch +++ /dev/null @@ -1,13 +0,0 @@ ---- pulseaudio-4.0.orig/src/pulsecore/core-util.c 2014-01-12 23:31:26.281525000 -0800 -+++ pulseaudio-4.0/src/pulsecore/core-util.c 2014-01-12 23:32:32.977118803 -0800 -@@ -1524,10 +1524,6 @@ - if (stat(p, &st) < 0) - return -errno; - --#ifdef HAVE_GETUID -- if (st.st_uid != getuid()) -- return -EACCES; --#endif - - return 0; - } \ No newline at end of file diff --git a/patches/link-libintl.patch b/patches/link-libintl.patch index 95b58ec..7dbbb3e 100644 --- a/patches/link-libintl.patch +++ b/patches/link-libintl.patch @@ -1,9 +1,9 @@ diff --git a/meson.build b/meson.build -index a10a1b3c8..c4cf8c6a9 100644 +index 658eeee..349752e 100644 --- a/meson.build +++ b/meson.build -@@ -296,6 +296,12 @@ if cc.has_function('SYS_memfd_create', prefix : '#include ') - cdata.set('HAVE_MEMFD', 1) +@@ -307,6 +307,12 @@ else + libintl_dep = cc.find_library('intl') endif +if cc.has_function('libintl_dgettext') @@ -15,119 +15,16 @@ index a10a1b3c8..c4cf8c6a9 100644 # Symbols if cc.has_header_symbol('signal.h', 'SIGXCPU') -diff --git a/src/daemon/meson.build b/src/daemon/meson.build -index 9bc3bf18e..9c9f807e7 100644 ---- a/src/daemon/meson.build -+++ b/src/daemon/meson.build -@@ -31,7 +31,7 @@ executable('pulseaudio', - include_directories : [configinc, topinc], - link_args : ['-ffast-math'], - link_with : [libpulsecore, libpulsecommon, libpulse], -- dependencies : [ltdl_dep, cap_dep, dbus_dep, libsystemd_dep, dl_dep], -+ dependencies : [ltdl_dep, cap_dep, dbus_dep, libsystemd_dep, dl_dep, libintl_dep], - c_args : pa_c_args, - ) - -diff --git a/src/meson.build b/src/meson.build -index c9b71a484..832c0de0d 100644 ---- a/src/meson.build -+++ b/src/meson.build -@@ -183,7 +183,7 @@ libpulsecommon = shared_library('pulsecommon-' + pa_version_major_minor, - install_dir : privlibdir, - dependencies : [ - libm_dep, thread_dep, dl_dep, shm_dep, iconv_dep, sndfile_dep, dbus_dep, -- x11_dep, libsystemd_dep, glib_dep, gtk_dep, asyncns_dep -+ x11_dep, libsystemd_dep, glib_dep, gtk_dep, asyncns_dep, libintl_dep, - ], - implicit_include_directories : false) - diff --git a/src/pulse/meson.build b/src/pulse/meson.build -index 00c686772..2a6f78489 100644 +index aaebff5..3f68ac3 100644 --- a/src/pulse/meson.build +++ b/src/pulse/meson.build -@@ -81,10 +81,10 @@ libpulse = shared_library('pulse', - link_args : [nodelete_link_args, versioning_link_args], - install : true, - install_rpath : privlibdir, -- dependencies : [libm_dep, thread_dep, libpulsecommon_dep, dbus_dep, dl_dep, iconv_dep], -+ dependencies : [libm_dep, thread_dep, libpulsecommon_dep, dbus_dep, dl_dep, iconv_dep, libintl_dep], +@@ -84,7 +84,7 @@ libpulse = shared_library('pulse', + dependencies : [libm_dep, thread_dep, libpulsecommon_dep, dbus_dep, dl_dep, iconv_dep, libintl_dep], implicit_include_directories : false) -libpulse_dep = declare_dependency(link_with: libpulse) +libpulse_dep = declare_dependency(link_with: libpulse, dependencies: libintl_dep) - install_data( + install_headers( libpulse_headers, 'simple.h', -diff --git a/src/pulsecore/meson.build b/src/pulsecore/meson.build -index 19f6b9e99..0bd596cbd 100644 ---- a/src/pulsecore/meson.build -+++ b/src/pulsecore/meson.build -@@ -198,7 +198,7 @@ libpulsecore = shared_library('pulsecore-' + pa_version_major_minor, - install_rpath : privlibdir, - install_dir : privlibdir, - link_with : libpulsecore_simd_lib, -- dependencies : [libm_dep, libpulsecommon_dep, libpulse_dep, ltdl_dep, shm_dep, sndfile_dep, database_dep, dbus_dep, libatomic_ops_dep, orc_dep, samplerate_dep, soxr_dep, speex_dep, x11_dep], -+ dependencies : [libm_dep, libpulsecommon_dep, libpulse_dep, ltdl_dep, shm_dep, sndfile_dep, database_dep, dbus_dep, libatomic_ops_dep, orc_dep, samplerate_dep, soxr_dep, speex_dep, x11_dep, libintl_dep], - implicit_include_directories : false) - - libpulsecore_dep = declare_dependency(link_with: libpulsecore) -diff --git a/src/tests/meson.build b/src/tests/meson.build -index 621c2c965..a03d73cdb 100644 ---- a/src/tests/meson.build -+++ b/src/tests/meson.build -@@ -53,7 +53,7 @@ default_tests = [ - [ 'queue-test', 'queue-test.c', - [ check_dep, libpulse_dep, libpulsecommon_dep, libpulsecore_dep ] ], - [ 'resampler-test', 'resampler-test.c', -- [ libpulse_dep, libpulsecommon_dep, libpulsecore_dep ] ], -+ [ libpulse_dep, libpulsecommon_dep, libpulsecore_dep, libintl_dep ] ], - [ 'rtpoll-test', 'rtpoll-test.c', - [ check_dep, libpulse_dep, libpulsecommon_dep, libpulsecore_dep ] ], - [ 'smoother-test', 'smoother-test.c', -diff --git a/src/utils/meson.build b/src/utils/meson.build -index d00e030ae..dedf4e404 100644 ---- a/src/utils/meson.build -+++ b/src/utils/meson.build -@@ -15,7 +15,7 @@ executable('pacat', - install_rpath : privlibdir, - include_directories : [configinc, topinc], - link_with : [libpulsecommon, libpulse], -- dependencies : [sndfile_dep], -+ dependencies : [sndfile_dep, libintl_dep], - c_args : pa_c_args, - ) - -@@ -36,7 +36,7 @@ executable('pactl', - install_rpath : privlibdir, - include_directories : [configinc, topinc], - link_with : [libpulsecommon, libpulse], -- dependencies : [sndfile_dep], -+ dependencies : [sndfile_dep, libintl_dep], - c_args : pa_c_args, - ) - -@@ -50,6 +50,7 @@ executable('pasuspender', - install_rpath : privlibdir, - include_directories : [configinc, topinc], - link_with : [libpulsecommon, libpulse], -+ dependencies: [libintl_dep], - c_args : pa_c_args, - ) - -@@ -63,6 +64,7 @@ executable('pacmd', - install_rpath : privlibdir, - include_directories : [configinc, topinc], - link_with : [libpulsecommon, libpulse], -+ dependencies: [libintl_dep], - c_args : pa_c_args, - ) - -@@ -77,7 +79,7 @@ if x11_dep.found() - install_rpath : privlibdir, - include_directories : [configinc, topinc], - link_with : [libpulsecommon, libpulse], -- dependencies : [x11_dep], -+ dependencies : [x11_dep, libintl_dep], - c_args : pa_c_args, - ) - endif diff --git a/patches/remove-once-test.patch b/patches/remove-once-test.patch new file mode 100644 index 0000000..757bcbe --- /dev/null +++ b/patches/remove-once-test.patch @@ -0,0 +1,16 @@ +--- a/src/tests/meson.build ++++ b/src/tests/meson.build +@@ -111,13 +111,6 @@ + ] + endif + +- if host_machine.system() != 'darwin' +- default_tests += [ +- [ 'once-test', 'once-test.c', +- [ check_dep, thread_dep, libpulse_dep, libpulsecommon_dep, libpulsecore_dep, libatomic_ops_dep ] ], +- ] +- endif +- + if alsa_dep.found() + default_tests += [ + [ 'alsa-mixer-path-test', 'alsa-mixer-path-test.c',