flathub / com.valvesoftware.Steam

https://flathub.org/apps/details/com.valvesoftware.Steam
339 stars 69 forks source link

udev updates fail to build #1114

Closed nanonyme closed 1 year ago

nanonyme commented 1 year ago

Creating issue here so we have trail outside various failing PR's

make[2]: Nothing to be done for 'install-exec-am'.
make[2]: Nothing to be done for 'install-data-am'.
make[2]: Leaving directory '/run/build/eudev/test'
make[1]: Leaving directory '/run/build/eudev/test'
Making install in hwdb
make[1]: Entering directory '/run/build/eudev/hwdb'
make[2]: Entering directory '/run/build/eudev/hwdb'
make[2]: Nothing to be done for 'install-exec-am'.
 /usr/bin/mkdir -p '/app/etc/udev/hwdb.d'
 /usr/bin/install -c -m 644 20-acpi-vendor.hwdb 20-bluetooth-vendor-product.hwdb 20-dmi-id.hwdb 20-net-ifname.hwdb 20-OUI.hwdb 20-pci-classes.hwdb 20-pci-vendor-model.hwdb 20-sdio-classes.hwdb 20-sdio-vendor-model.hwdb 20-usb-classes.hwdb 20-usb-vendor-model.hwdb 20-vmbus-class.hwdb 60-autosuspend-fingerprint-reader.hwdb 60-autosuspend.hwdb 60-evdev.hwdb 60-input-id.hwdb 60-keyboard.hwdb 60-seat.hwdb 60-sensor.hwdb 70-analyzers.hwdb 70-av-production.hwdb 70-cameras.hwdb 70-joystick.hwdb 70-mouse.hwdb 70-pointingstick.hwdb 70-pda.hwdb 70-touchpad.hwdb 80-ieee1394-unit-function.hwdb '/app/etc/udev/hwdb.d'
make[2]: Leaving directory '/run/build/eudev/hwdb'
make[1]: Leaving directory '/run/build/eudev/hwdb'
make[1]: Entering directory '/run/build/eudev'
make[2]: Entering directory '/run/build/eudev'
make[2]: Nothing to be done for 'install-exec-am'.
make[2]: Nothing to be done for 'install-data-am'.
make[2]: Leaving directory '/run/build/eudev'
make[1]: Leaving directory '/run/build/eudev'
FB: host_command_exited_cb 3673872 0
]2;flatpak-builder: Post-Install eudevFB: Running 'flatpak build --die-with-parent --env=FLATPAK_BUILDER_BUILDDIR=/run/build/eudev --nofilesystem=host:reset --filesystem=/srv/buildbot/worker/build-x86_64-3/build/.flatpak-builder/build/eudev-1 --bind-mount=/run/build/eudev=/srv/buildbot/worker/build-x86_64-3/build/.flatpak-builder/build/eudev-1 --build-dir=/run/build/eudev --bind-mount=/run/ccache=/srv/buildbot/worker/build-x86_64-3/build/.flatpak-builder/ccache --unshare=network --env=SOURCE_DATE_EPOCH=1686249550 '--env=CFLAGS=-O2 -g -pipe -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer ' '--env=CXXFLAGS=-O2 -g -pipe -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer ' '--env=LDFLAGS=-L/app/lib -Wl,-z,relro,-z,now -Wl,--as-needed ' --env=CCACHE_DIR=/run/ccache/disabled --env=PATH=/app/bin:/usr/bin --env=LD_LIBRARY_PATH=/app/lib --env=PKG_CONFIG_PATH=/app/lib/pkgconfig:/app/share/pkgconfig:/usr/lib/pkgconfig:/usr/share/pkgconfig --env=FLATPAK_BUILDER_N_JOBS=64 /srv/buildbot/worker/build-x86_64-3/build/.flatpak-builder/rofiles/rofiles-Gh6V62 /bin/sh -c 'udevadm hwdb --update'' on host
Failure writing database //etc/udev/hwdb.bin: Read-only file system
FB: host_command_exited_cb 3674498 256
]2;flatpak-builder: Cleanup eudevError: module eudev: Child process exited with code 1
FB: Unmounting read-only fs: fusermount -uz /srv/buildbot/worker/build-x86_64-3/build/.flatpak-builder/rofiles/rofiles-Gh6V62
nanonyme commented 1 year ago

Eg https://buildbot.flathub.org/#/builders/35/builds/5686

nanonyme commented 1 year ago

@gasinvein any clue what's going on here? Are we writing hwdb into wrong place?

nanonyme commented 1 year ago

Looks to me like the path comes from here https://github.com/eudev-project/eudev/blob/master/configure.ac#L175C27-L175C38

nanonyme commented 1 year ago

Full output attached stdio.log

nanonyme commented 1 year ago
    prefix:                  /app
    exec_prefix:             ${prefix}
    sysconfdir:              ${prefix}/etc
    datadir:                 ${datarootdir}
    includedir:              ${prefix}/include
    bindir:                  ${exec_prefix}/bin
    libdir:                  ${exec_prefix}/lib

    rootprefix:              ${prefix}
    rootlibdir:              ${exec_prefix}/lib
    rootlibexecdir:          ${exec_prefix}/lib/udev
    datarootdir:             ${prefix}/share
    rootrundir:              /run

    udevconfdir:             ${prefix}/etc/udev
    udevconffile:            ${prefix}/etc/udev/udev.conf
    udevhwdbdir:             ${prefix}/etc/udev/hwdb.d
    udevhwdbbin:             ${prefix}/etc/udev/hwdb.bin
nanonyme commented 1 year ago

This looks to me like a bug in hwdb? Expected path is /app/etc/udev/hwdb.bin after string combining operations.

nanonyme commented 1 year ago

I think we might be able to trick it to write to right place by using --usr which in our case writes to /app.