MaartenBaert / ssr

SimpleScreenRecorder, a screen recorder for Linux
http://www.maartenbaert.be/simplescreenrecorder/
GNU General Public License v3.0
2.59k stars 290 forks source link

Can't build anymore under Ubuntu Unity 22.04... #1046

Open Creteil opened 1 month ago

Creteil commented 1 month ago

Hi,

I always build from latest source code from github, by the way, today, trying to build after git pull the latest changes, break the build process...

It look like the build across the « libpipewire » broken the build when this library is not installed/available :

Here is the relevant error :

-- Checking for module 'libpipewire-0.3'
--   No package 'libpipewire-0.3' found
CMake Error at /usr/share/cmake-3.30/Modules/FindPackageHandleStandardArgs.cmake:233 (message):
  Could NOT find PipeWire (missing: PIPEWIRE_LIBRARY PIPEWIRE_INCLUDE_DIR)
Call Stack (most recent call first):
  /usr/share/cmake-3.30/Modules/FindPackageHandleStandardArgs.cmake:603 (_FPHSA_FAILURE_MESSAGE)
  cmake/FindPipeWire.cmake:10 (find_package_handle_standard_args)
  src/CMakeLists.txt:16 (find_package)

-- Configuring incomplete, errors occurred!
    cd obj-x86_64-linux-gnu && tail -v -n \+0 CMakeCache.txt

Maybe, a check is needed to build across « libpulse » if we try to build under a distribution that is not already migrated to « pipewire » ?

Does it make sense ?

Last time I successfully build from github source code (commit gc092f3e), it was linked (autodetected ?) across « libpulse », not « libpipewire » :

oem@oem-ThinkPad-P15-Gen-1:~/tmp/Building/ssr/simplescreenrecorder-0.4.4-27$ ldd /usr/bin/simplescreenrecorder | grep -i "pulse\|pipewire"
    libpulse.so.0 => /lib/x86_64-linux-gnu/libpulse.so.0 (0x00007996dbbab000)
    libpulsecommon-15.99.so => /usr/lib/x86_64-linux-gnu/pulseaudio/libpulsecommon-15.99.so (0x00007996d6901000)
oem@oem-ThinkPad-P15-Gen-1:~/tmp/Building/ssr/simplescreenrecorder-0.4.4-27$ ll /srv/local-apt-repository/*simple*
16540 -rw-r--r-- 1 oem oem   32456 2023-08-31 15:02:10.811433981 +0200 /srv/local-apt-repository/simplescreenrecorder-lib_0.4.4-9-gc092f3e_amd64.deb
16539 -rw-r--r-- 1 oem oem 1407858 2023-08-31 15:02:11.799442637 +0200 /srv/local-apt-repository/simplescreenrecorder_0.4.4-9-gc092f3e_amd64.deb
oem@oem-ThinkPad-P15-Gen-1:~/tmp/Building/ssr/simplescreenrecorder-0.4.4-27$
Creteil commented 1 month ago

Correction, « libpipewire » is installed on the system :

oem@oem-ThinkPad-P15-Gen-1:~/tmp/Building/ssr/simplescreenrecorder-0.4.4-27$ dpkg -l | grep -i libpipewire
ii  libpipewire-0.3-0:amd64                          1.2.3-1~22.04.sav0                                         amd64        libraries for the PipeWire multimedia server
ii  libpipewire-0.3-common                           1.2.3-1~22.04.sav0                                         all          libraries for the PipeWire multimedia server - common files
ii  libpipewire-0.3-modules:amd64                    1.2.3-1~22.04.sav0                                         amd64        libraries for the PipeWire multimedia server - modules
oem@oem-ThinkPad-P15-Gen-1:~/tmp/Building/ssr/simplescreenrecorder-0.4.4-27$

But the distribution seem to use the default « pulseaudio » sound system, even I can see « pipewire » processes also running :

oem@oem-ThinkPad-P15-Gen-1:~/tmp/Building/ssr/simplescreenrecorder-0.4.4-27$ ps auxwf | grep "pulse\|pipe" | grep -v grep
oem         5212  0.0  0.0  98508  7924 ?        S<sl oct.17   0:00  \_ /usr/bin/pipewire
oem         5213  0.0  0.0  93676  6612 ?        Ssl  oct.17   0:00  \_ /usr/bin/pipewire-media-session
oem         5214  0.0  0.0  87020  5240 ?        Ssl  oct.17   0:00  \_ /usr/bin/pipewire -c filter-chain.conf
oem         5215  0.0  0.0 2739904 31480 ?       S<sl oct.17   0:00  \_ /usr/bin/pulseaudio --daemonize=no --log-target=journal
oem@oem-ThinkPad-P15-Gen-1:~/tmp/Building/ssr/simplescreenrecorder-0.4.4-27$

Any suggestion is welcome...

MaartenBaert commented 1 month ago

I think you are missing the -dev package. In any case, you can compile without PipeWire support using -DWITH_PIPEWIRE=FALSE, this will give you the old behavior again.

Creteil commented 1 month ago

Thanks, a simple « sudo apt install libpipewire-0.3-dev » re-establish the possibility to build the package... 👍

Creteil commented 1 month ago

The new package automatically linked to the 2 library if I understand well...

oem@oem-ThinkPad-P15-Gen-1:~/tmp/Building/ssr$ ldd /usr/bin/simplescreenrecorder | grep -i "pulse\|pipewire"
    libpipewire-0.3.so.0 => /lib/x86_64-linux-gnu/libpipewire-0.3.so.0 (0x000078301d708000)
    libpulse.so.0 => /lib/x86_64-linux-gnu/libpulse.so.0 (0x000078301ec6b000)
    libpulsecommon-15.99.so => /usr/lib/x86_64-linux-gnu/pulseaudio/libpulsecommon-15.99.so (0x0000783018101000)
oem@oem-ThinkPad-P15-Gen-1:~/tmp/Building/ssr$