From a9b97111be7ced6be4b8c64f28f7c950425ca6f693960fec1a2504d9c53224f6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20Br=C3=BCns?= Date: Mon, 22 Dec 2025 19:11:50 +0100 Subject: [PATCH 1/2] Clean up spec file, fixes for IPA subpackage, cam/qcam split --- libcamera.changes | 16 ++++++++++++ libcamera.spec | 64 ++++++++++++++++++++++++++++++---------------- reproducible.patch | 21 --------------- 3 files changed, 58 insertions(+), 43 deletions(-) delete mode 100644 reproducible.patch diff --git a/libcamera.changes b/libcamera.changes index 078d156..bc92191 100644 --- a/libcamera.changes +++ b/libcamera.changes @@ -1,3 +1,19 @@ +------------------------------------------------------------------- +Mon Dec 22 17:57:30 UTC 2025 - Stefan Brüns + +- Various cleanups: + * Drop unused boost build dependency + * Replace reproducible.patch with equivalent "signed_ipa" build + condition, only require openssl/gnutls if enabled. + * Rename subpackage containing IPA modules and support-files + from "tools" to "ipa". + * Use automatic selection of IPA modules/pipelines: + + ARM SoC specific ISPs are disabled on x86_64 + + RPi and mali-c55 are now enabled on aarch64 + * Split cam/qcam package, to reduce runtime dependencies + notably on small SoCs (only SDL or Qt6 required) + * Drop disfunctional SLE/Leap 15.x conditionals + ------------------------------------------------------------------- Tue Dec 16 14:24:09 UTC 2025 - Antonio Teixeira diff --git a/libcamera.spec b/libcamera.spec index e1498b6..71c15b6 100644 --- a/libcamera.spec +++ b/libcamera.spec @@ -23,6 +23,11 @@ %else %define extname %nil %endif + +# Signing breaks reproducible builds, see +# https://gitlab.freedesktop.org/camera/libcamera/-/issues/233 +%bcond_with signed_ipa + Name: libcamera%extname Version: 0.6.0 Release: 0 @@ -33,13 +38,7 @@ URL: https://libcamera.org/ #Git-Web: https://git.libcamera.org/libcamera/libcamera.git/ Source: libcamera-%version.tar.xz Source1: baselibs.conf -Patch0: reproducible.patch -BuildRequires: boost-devel BuildRequires: c++_compiler -%if 0%{?suse_version} <= 1500 -BuildRequires: gcc11 -BuildRequires: gcc11-c++ -%endif BuildRequires: meson >= 1.0.1 BuildRequires: pkg-config BuildRequires: python3-Jinja2 @@ -47,15 +46,18 @@ BuildRequires: python3-PyYAML BuildRequires: python3-ply BuildRequires: xz BuildRequires: pkgconfig(glib-2.0) -BuildRequires: pkgconfig(gnutls) BuildRequires: pkgconfig(gstreamer-video-1.0) BuildRequires: pkgconfig(libevent_pthreads) BuildRequires: pkgconfig(libtiff-4) BuildRequires: pkgconfig(libudev) -BuildRequires: pkgconfig(openssl) BuildRequires: pkgconfig(pybind11) BuildRequires: pkgconfig(python3) BuildRequires: pkgconfig(yaml-0.1) +%if %{with signed_ipa} +# OpenSSL used for signing, gnutls for runtime verification +BuildRequires: openssl +BuildRequires: pkgconfig(gnutls) +%endif %if "@BUILD_FLAVOR@" != "" BuildRequires: pkgconfig(Qt6Core) BuildRequires: pkgconfig(Qt6Gui) @@ -108,24 +110,43 @@ libcamera is an experimental camera user-space API. This subpackage contains the header files. -%package tools -Summary: Command-line utilities from libcamera -Group: Development/Tools/Other +%package ipa +Summary: Plugins for hardware specific image processing blocks +Group: System/Libraries +# Previously named libcamera-tools, although it provides none +Provides: libcamera-tools = %{version}-%{release} +Obsoletes: libcamera-tools < %{version}-%{release} -%description tools +%description ipa libcamera is an experimental camera user-space API. +This package provides plugins for interfacing with various ISP +(Image Signal Processor) hardware blocks, as well as +calibration data for some camera sensors. + %package -n libcamera-cam Summary: Command-line interfaces for libcamera Group: Development/Tools/Other -# Heavy runtime deps (SDL, Qt6) +# Heavy runtime deps (SDL) %description -n libcamera-cam libcamera is an experimental camera user-space API. -"cam" is a command-line utility to interact with cameras. The initial state is -limited and only supports listing cameras in the system and selecting a camera -to interact with. +"cam" is a command-line utility to interact with cameras. It allows +to query and set image stream properties, and to capture the stream +to a file or show a live view. + +%package -n libcamera-qcam +Summary: Qt interfaces for libcamera +Group: Development/Tools/Other +# Heavy runtime deps (Qt6) + +%description -n libcamera-qcam +libcamera is an experimental camera user-space API. + +"qcam" is a Qt interface to interact with cameras. It allows to +query and set image stream properties, and to capture the stream +to a file or show a live view. %package -n gstreamer-plugins-libcamera Summary: GStreamer plugins from libcamera @@ -146,10 +167,6 @@ Python bindings for libcamera. %autosetup -p1 -n libcamera-%version %build -%if 0%{?suse_version} <= 1500 -export CC=gcc-11 -export CXX=g++-11 -%endif %meson \ -Ddocumentation=disabled \ %if "@BUILD_FLAVOR@" != "" @@ -158,7 +175,7 @@ export CXX=g++-11 -Dqcam=disabled \ %endif -Dv4l2=false -Dtracing=disabled \ - -Dpipelines=ipu3,rkisp1,simple,uvcvideo,vimc \ + -Dpipelines=auto,vimc \ -Dlc-compliance=disabled %meson_build @@ -168,6 +185,7 @@ cd "%buildroot" %if "@BUILD_FLAVOR@" != "" find . ! -type d ! -path ./usr/bin/cam ! -path ./usr/bin/qcam -print -delete %else +# Delete limited variant without SDL rm -v usr/bin/cam %endif @@ -188,7 +206,7 @@ rm -v usr/bin/cam %_libdir/libcamera.so %_libdir/pkgconfig/*.pc -%files tools +%files ipa %_libexecdir/libcamera/ %_libdir/libcamera/ %_datadir/libcamera/ @@ -203,6 +221,8 @@ rm -v usr/bin/cam %files -n libcamera-cam %_bindir/cam + +%files -n libcamera-qcam %_bindir/qcam %endif diff --git a/reproducible.patch b/reproducible.patch deleted file mode 100644 index 6e2efc4..0000000 --- a/reproducible.patch +++ /dev/null @@ -1,21 +0,0 @@ -Date: 2024-09-21 -Author: Bernhard M. Wiedemann - -Skip module signing for https://bugzilla.opensuse.org/show_bug.cgi?id=1217690 -reproducible builds, until we can get a better upstream solution -such as -https://lists.libcamera.org/pipermail/libcamera-devel/2024-January/040244.html - -diff --git a/src/meson.build b/src/meson.build -index 8eb8f05..41e556d 100644 ---- a/src/meson.build -+++ b/src/meson.build -@@ -16,7 +16,7 @@ summary({ - - # Module Signing - openssl = find_program('openssl', required : false) --if openssl.found() -+if false - ipa_priv_key = custom_target('ipa-priv-key', - output : ['ipa-priv-key.pem'], - command : [gen_ipa_priv_key, '@OUTPUT@']) -- 2.51.1 From 0757b5ddc3089ae638b82ab464eddaaa1fe71274c58be7d36c9e4cf6076dad2d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20Br=C3=BCns?= Date: Tue, 23 Dec 2025 22:01:24 +0100 Subject: [PATCH 2/2] Add libpisp build dependency for ARM targets --- libcamera.changes | 1 + libcamera.spec | 3 +++ 2 files changed, 4 insertions(+) diff --git a/libcamera.changes b/libcamera.changes index bc92191..c71d053 100644 --- a/libcamera.changes +++ b/libcamera.changes @@ -10,6 +10,7 @@ Mon Dec 22 17:57:30 UTC 2025 - Stefan Brüns * Use automatic selection of IPA modules/pipelines: + ARM SoC specific ISPs are disabled on x86_64 + RPi and mali-c55 are now enabled on aarch64 + * Add libpisp build dependency for ARM targets * Split cam/qcam package, to reduce runtime dependencies notably on small SoCs (only SDL or Qt6 required) * Drop disfunctional SLE/Leap 15.x conditionals diff --git a/libcamera.spec b/libcamera.spec index 71c15b6..b9990a2 100644 --- a/libcamera.spec +++ b/libcamera.spec @@ -58,6 +58,9 @@ BuildRequires: pkgconfig(yaml-0.1) BuildRequires: openssl BuildRequires: pkgconfig(gnutls) %endif +%ifarch aarch64 %{arm} +BuildRequires: pkgconfig(libpisp) +%endif %if "@BUILD_FLAVOR@" != "" BuildRequires: pkgconfig(Qt6Core) BuildRequires: pkgconfig(Qt6Gui) -- 2.51.1