mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
* [ptxdist] [PATCH v4 0/1] libcamera: new package
@ 2022-09-17 18:33 Matthias Fend
  2022-09-17 18:33 ` [ptxdist] [PATCH v4 1/1] " Matthias Fend
  0 siblings, 1 reply; 4+ messages in thread
From: Matthias Fend @ 2022-09-17 18:33 UTC (permalink / raw)
  To: ptxdist

libcamera is an open source camera stack and framework for Linux, Android,
and ChromeOS.

Since libcamera is still quite new and there are no released versions yet,
a git snapshot is used.

A patch is currently required to deactivate the automatic git-based version
generation, otherwise the git information from the BSP repository will be
used incorrectly. This may lead to a build error, at least to an incorrect
version.
However, since libcamera versioning is currently being discussed, the patch
may be dropped in the near future.

Changelog:
v4:
- Corrected list of licenses
- Always disable tracing with lttng
- Change prompt for backtrace config to distinguish from lttng tracing

v3:
 - Select HOST_OPENSSL (currently mandatory)
 - Reorder Kconfig menu
 - Make IPAs dependent on their associated pipeline
 - Added option to enable cam tool KMS sink
 - Make module signing optional and crypto library selectable

v2:
 - Changed format of git version tag
 - Use list-based processing for IPAs
 - Add a comment to note why IPA modules are not stripped
 - Some source format fixes

Matthias Fend (1):
  libcamera: new package

 ...t-information-for-version-generation.patch |  29 ++++
 .../libcamera-2022-08-30-g68683d3811a8/series |   4 +
 rules/libcamera.in                            | 129 ++++++++++++++++
 rules/libcamera.make                          | 143 ++++++++++++++++++
 4 files changed, 305 insertions(+)
 create mode 100644 patches/libcamera-2022-08-30-g68683d3811a8/0001-do-not-use-git-information-for-version-generation.patch
 create mode 100644 patches/libcamera-2022-08-30-g68683d3811a8/series
 create mode 100644 rules/libcamera.in
 create mode 100644 rules/libcamera.make

-- 
2.25.1




^ permalink raw reply	[flat|nested] 4+ messages in thread

* [ptxdist] [PATCH v4 1/1] libcamera: new package
  2022-09-17 18:33 [ptxdist] [PATCH v4 0/1] libcamera: new package Matthias Fend
@ 2022-09-17 18:33 ` Matthias Fend
  2022-09-28 14:28   ` [ptxdist] [APPLIED] " Michael Olbrich
  2022-10-18  7:37   ` [ptxdist] [PATCH v4 1/1] " Christian Melki
  0 siblings, 2 replies; 4+ messages in thread
From: Matthias Fend @ 2022-09-17 18:33 UTC (permalink / raw)
  To: ptxdist

libcamera is an open source camera stack and framework for Linux, Android,
and ChromeOS.

Signed-off-by: Matthias Fend <matthias.fend@emfend.at>
---
 ...t-information-for-version-generation.patch |  29 ++++
 .../libcamera-2022-08-30-g68683d3811a8/series |   4 +
 rules/libcamera.in                            | 129 ++++++++++++++++
 rules/libcamera.make                          | 143 ++++++++++++++++++
 4 files changed, 305 insertions(+)
 create mode 100644 patches/libcamera-2022-08-30-g68683d3811a8/0001-do-not-use-git-information-for-version-generation.patch
 create mode 100644 patches/libcamera-2022-08-30-g68683d3811a8/series
 create mode 100644 rules/libcamera.in
 create mode 100644 rules/libcamera.make

diff --git a/patches/libcamera-2022-08-30-g68683d3811a8/0001-do-not-use-git-information-for-version-generation.patch b/patches/libcamera-2022-08-30-g68683d3811a8/0001-do-not-use-git-information-for-version-generation.patch
new file mode 100644
index 000000000..3e5c5ce68
--- /dev/null
+++ b/patches/libcamera-2022-08-30-g68683d3811a8/0001-do-not-use-git-information-for-version-generation.patch
@@ -0,0 +1,29 @@
+From: Matthias Fend <matthias.fend@emfend.at>
+Date: Wed, 31 Aug 2022 16:54:20 +0200
+Subject: [PATCH] do not use git information for version generation
+
+Since libcamera is checked out without a git repo, git version reports the
+version of the BSP. Since this is obviously wrong, just use the project
+version.
+
+Signed-off-by: Matthias Fend <matthias.fend@emfend.at>
+---
+ meson.build | 5 ++---
+ 1 file changed, 2 insertions(+), 3 deletions(-)
+
+diff --git a/meson.build b/meson.build
+index 72919102ad55..e333df59388d 100644
+--- a/meson.build
++++ b/meson.build
+@@ -20,9 +20,8 @@ libcamera_git_version = run_command('utils/gen-version.sh',
+                                     meson.project_build_root(),
+                                     meson.project_source_root(),
+                                     check: false).stdout().strip()
+-if libcamera_git_version == ''
+-    libcamera_git_version = meson.project_version()
+-endif
++
++libcamera_git_version = meson.project_version()
+ 
+ libcamera_version = libcamera_git_version.split('+')[0]
+ 
diff --git a/patches/libcamera-2022-08-30-g68683d3811a8/series b/patches/libcamera-2022-08-30-g68683d3811a8/series
new file mode 100644
index 000000000..6ca42eafc
--- /dev/null
+++ b/patches/libcamera-2022-08-30-g68683d3811a8/series
@@ -0,0 +1,4 @@
+# generated by git-ptx-patches
+#tag:base --start-number 1
+0001-do-not-use-git-information-for-version-generation.patch
+# c3a57143ea9764ab95b84a7fb79896f4  - git-ptx-patches magic
diff --git a/rules/libcamera.in b/rules/libcamera.in
new file mode 100644
index 000000000..1f2d70aad
--- /dev/null
+++ b/rules/libcamera.in
@@ -0,0 +1,129 @@
+## SECTION=multimedia_libs
+
+menuconfig LIBCAMERA
+	bool
+	select HOST_MESON
+	select HOST_SYSTEM_PYTHON3
+	select HOST_SYSTEM_PYTHON3_JINJA2
+	select HOST_SYSTEM_PYTHON3_PYYAML
+	select HOST_SYSTEM_PYTHON3_PLY
+	select HOST_OPENSSL
+	select GNUTLS				if LIBCAMERA_IPA_MODULE_SIGN_GNUTLS
+	select OPENSSL				if LIBCAMERA_IPA_MODULE_SIGN_OPENSSL
+	select UDEV_LIBUDEV
+	select LIBYAML
+	select LIBUNWIND			if LIBCAMERA_BACKTRACE
+	select GSTREAMER1			if LIBCAMERA_GSTREAMER
+	select GST_PLUGINS_BASE1		if LIBCAMERA_GSTREAMER
+	select LIBEVENT				if LIBCAMERA_CAM
+	select LIBDRM				if LIBCAMERA_CAM_KMS_SINK
+	select QT5				if LIBCAMERA_QCAM
+	select QT5_MODULE_QTBASE		if LIBCAMERA_QCAM
+	select QT5_MODULE_QTBASE_GUI		if LIBCAMERA_QCAM
+	select QT5_MODULE_QTBASE_WIDGETS	if LIBCAMERA_QCAM
+	prompt "libcamera                     "
+	help
+	  A complex camera support library for Linux, Android, and ChromeOS.
+
+if LIBCAMERA
+
+config LIBCAMERA_GSTREAMER
+	bool
+	prompt "Install GStreamer plugin"
+
+config LIBCAMERA_CAM
+	bool
+	prompt "Install cam test application"
+
+if LIBCAMERA_CAM
+
+config LIBCAMERA_CAM_KMS_SINK
+	bool
+	prompt "Enable KMS sink"
+endif
+
+config LIBCAMERA_QCAM
+	bool
+	prompt "Install qcam test application"
+
+config LIBCAMERA_BACKTRACE
+	bool
+	prompt "Add support for backtraces"
+
+menu "Platforms"
+
+config LIBCAMERA_PIPELINE_IPU3
+	bool
+	prompt "ipu3 pipeline"
+
+config LIBCAMERA_IPA_IPU3
+	bool
+	default y
+	prompt "ipu3 IPA"
+	depends on LIBCAMERA_PIPELINE_IPU3
+
+config LIBCAMERA_PIPELINE_RASPBERRYPI
+	bool
+	prompt "raspberrypi pipeline"
+
+config LIBCAMERA_IPA_RASPBERRYPI
+	bool
+	default y
+	prompt "raspberrypi IPA"
+	depends on LIBCAMERA_PIPELINE_RASPBERRYPI
+
+config LIBCAMERA_PIPELINE_RKISP1
+	bool
+	prompt "rkisp1 pipeline"
+
+config LIBCAMERA_IPA_RKISP1
+	bool
+	default y
+	prompt "rkisp1 IPA"
+	depends on LIBCAMERA_PIPELINE_RKISP1
+
+config LIBCAMERA_PIPELINE_SIMPLE
+	bool
+	prompt "simple pipeline"
+
+config LIBCAMERA_PIPELINE_UVCVIDEO
+	bool
+	prompt "uvcvideo pipeline"
+
+config LIBCAMERA_PIPELINE_VIMC
+	bool
+	prompt "vimc pipeline"
+
+config LIBCAMERA_IPA_VIMC
+	bool
+	default y
+	prompt "vimc IPA"
+	depends on LIBCAMERA_PIPELINE_VIMC
+
+endmenu
+
+config LIBCAMERA_IPA_MODULE_SIGN
+	bool
+	default y
+	prompt "Enable IPA module signing"
+	help
+	  Without IPA module signing, all IPA modules will be isolated in a
+	  separate process. This adds an unnecessary extra overhead at runtime.
+
+if LIBCAMERA_IPA_MODULE_SIGN
+
+choice
+	prompt "Crypt provider"
+	default LIBCAMERA_IPA_MODULE_SIGN_GNUTLS
+
+config LIBCAMERA_IPA_MODULE_SIGN_GNUTLS
+	bool "gnutls"
+
+config LIBCAMERA_IPA_MODULE_SIGN_OPENSSL
+	bool "openssl (libcrypto)"
+
+endchoice
+
+endif
+
+endif
diff --git a/rules/libcamera.make b/rules/libcamera.make
new file mode 100644
index 000000000..a6560fb48
--- /dev/null
+++ b/rules/libcamera.make
@@ -0,0 +1,143 @@
+# -*-makefile-*-
+#
+# Copyright (C) 2022 by Matthias Fend <matthias.fend@emfend.at>
+#
+# For further information about the PTXdist project and license conditions
+# see the README file.
+#
+
+#
+# We provide this package
+#
+PACKAGES-$(PTXCONF_LIBCAMERA) += libcamera
+
+#
+# Paths and names
+#
+LIBCAMERA_VERSION	:= 2022-08-30-g68683d3811a8
+LIBCAMERA_MD5		:= 2f5a985257a0797e0bd0b4182ef9bc9c
+LIBCAMERA		:= libcamera-$(LIBCAMERA_VERSION)
+LIBCAMERA_SUFFIX	:= tar.gz
+LIBCAMERA_URL		:= https://git.libcamera.org/libcamera/libcamera.git;tag=$(LIBCAMERA_VERSION)
+LIBCAMERA_SOURCE	:= $(SRCDIR)/$(LIBCAMERA).$(LIBCAMERA_SUFFIX)
+LIBCAMERA_DIR		:= $(BUILDDIR)/$(LIBCAMERA)
+LIBCAMERA_LICENSE	:= Apache-2.0 AND \
+			   BSD-2-Clause AND BSD-3-Clause AND \
+			   CC0-1.0 AND CC-BY-SA-4.0 AND \
+			   GPL-2.0-or-later AND GPL-2.0 WITH Linux-syscall-note AND \
+			   (GPL-2.0-or-later WITH Linux-syscall-note OR MIT) AND LGPL-2.1-or-later
+LIBCAMERA_LICENSE_FILES	:= file://LICENSES/Apache-2.0.txt;md5=3b83ef96387f14655fc854ddc3c6bd57 \
+			   file://LICENSES/BSD-2-Clause.txt;md5=63d6ee386b8aaba70b1bf15a79ca50f2 \
+			   file://LICENSES/BSD-3-Clause.txt;md5=954f4d71a37096249f837652a7f586c0 \
+			   file://LICENSES/CC0-1.0.txt;md5=6fd064768b8d61c31ddd0540570fbd33 \
+			   file://LICENSES/CC-BY-SA-4.0.txt;md5=598a2bb2d212cf9bc240fb554efcb169 \
+			   file://LICENSES/GPL-2.0-or-later.txt;md5=fed54355545ffd980b814dab4a3b312c \
+			   file://LICENSES/GPL-2.0.txt;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+			   file://LICENSES/Linux-syscall-note.txt;md5=370f20aa0795bf47c9a50d8cee5a7cfb \
+			   file://LICENSES/GPL-2.0+.txt;md5=fed54355545ffd980b814dab4a3b312c \
+			   file://LICENSES/MIT.txt;md5=38aa75cf4c4c87f018227d5ec9638d75 \
+			   file://LICENSES/LGPL-2.1-or-later.txt;md5=2a4f4fd2128ea2f65047ee63fbca9f68
+
+# ----------------------------------------------------------------------------
+# Prepare
+# ----------------------------------------------------------------------------
+
+LIBCAMERA_IPAS-y					:=
+LIBCAMERA_IPAS-$(PTXCONF_LIBCAMERA_IPA_IPU3)		+= ipu3
+LIBCAMERA_IPASC-$(PTXCONF_LIBCAMERA_IPA_RASPBERRYPI)	+= raspberrypi
+LIBCAMERA_IPASM-$(PTXCONF_LIBCAMERA_IPA_RASPBERRYPI)	+= rpi
+LIBCAMERA_IPAS-$(PTXCONF_LIBCAMERA_IPA_RKISP1)		+= rkisp1
+LIBCAMERA_IPAS-$(PTXCONF_LIBCAMERA_IPA_VIMC)		+= vimc
+
+LIBCAMERA_IPASC-y	+= $(LIBCAMERA_IPAS-y)
+LIBCAMERA_IPASM-y	+= $(LIBCAMERA_IPAS-y)
+
+LIBCAMERA_PIPELINES-y						:=
+LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_IPU3)		+= ipu3
+LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_RASPBERRYPI)	+= raspberrypi
+LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_RKISP1)	+= rkisp1
+LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_SIMPLE)	+= simple
+LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_UVCVIDEO)	+= uvcvideo
+LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_VIMC)		+= vimc
+
+LIBCAMERA_CONF_TOOL	:= meson
+LIBCAMERA_CONF_OPT	:= \
+	$(CROSS_MESON_USR) \
+	-Dandroid=disabled \
+	-Dcam=$(call ptx/endis,PTXCONF_LIBCAMERA_CAM)d \
+	-Ddocumentation=disabled \
+	-Dgstreamer=$(call ptx/endis,PTXCONF_LIBCAMERA_GSTREAMER)d \
+	-Dipas=$(subst $(ptx/def/space),$(ptx/def/comma),$(strip $(LIBCAMERA_IPASC-y))) \
+	-Dlc-compliance=disabled \
+	-Dpipelines=$(subst $(ptx/def/space),$(ptx/def/comma),$(strip $(LIBCAMERA_PIPELINES-y))) \
+	-Dqcam=$(call ptx/endis,PTXCONF_LIBCAMERA_QCAM)d \
+	-Dtest=false \
+	-Dtracing=disabled \
+	-Dv4l2=false \
+	-Dpycamera=disabled
+
+# ----------------------------------------------------------------------------
+# Target-Install
+# ----------------------------------------------------------------------------
+
+define install_ipa
+	@$(call install_copy, libcamera, 0, 0, 0755, -, \
+		/usr/libexec/libcamera/$(strip $(1))_ipa_proxy)
+	@$(call install_alternative_tree, libcamera, 0, 0, \
+		/usr/share/libcamera/ipa/$(strip $(1)))
+endef
+
+define install_ipa_module_signed
+	# The IPA modules must not be stripped, otherwise the associated
+	# signatures will no longer be valid.
+	@$(call install_copy, libcamera, 0, 0, 0644, -, \
+		/usr/lib/libcamera/ipa_$(strip $(1)).so, n)
+	@$(call install_copy, libcamera, 0, 0, 0644, -, \
+		/usr/lib/libcamera/ipa_$(strip $(1)).so.sign)
+endef
+
+define install_ipa_module
+	@$(call install_copy, libcamera, 0, 0, 0644, -, \
+		/usr/lib/libcamera/ipa_$(strip $(1)).so)
+endef
+
+$(STATEDIR)/libcamera.targetinstall:
+	@$(call targetinfo)
+
+	@$(call install_init, libcamera)
+	@$(call install_fixup, libcamera, PRIORITY, optional)
+	@$(call install_fixup, libcamera, SECTION, base)
+	@$(call install_fixup, libcamera, AUTHOR, "Matthias Fend <matthias.fend@emfend.at>")
+	@$(call install_fixup, libcamera, DESCRIPTION, missing)
+
+	@$(call install_lib, libcamera, 0, 0, 0644, libcamera)
+	@$(call install_lib, libcamera, 0, 0, 0644, libcamera-base)
+
+	@$(foreach ipa,$(LIBCAMERA_IPASC-y), \
+		$(call install_ipa, $(ipa))$(ptx/nl))
+
+ifdef PTXCONF_LIBCAMERA_IPA_MODULE_SIGN
+	@$(foreach ipa_module,$(LIBCAMERA_IPASM-y), \
+		$(call install_ipa_module_signed, $(ipa_module))$(ptx/nl))
+else
+	@$(foreach ipa_module,$(LIBCAMERA_IPASM-y), \
+		$(call install_ipa_module, $(ipa_module))$(ptx/nl))
+endif
+
+ifdef PTXCONF_LIBCAMERA_GSTREAMER
+	@$(call install_lib, libcamera, 0, 0, 0644, gstreamer-1.0/libgstlibcamera)
+endif
+
+ifdef PTXCONF_LIBCAMERA_CAM
+	@$(call install_copy, libcamera, 0, 0, 0755, -, /usr/bin/cam)
+endif
+
+ifdef PTXCONF_LIBCAMERA_QCAM
+	@$(call install_copy, libcamera, 0, 0, 0755, -, /usr/bin/qcam)
+endif
+
+	@$(call install_finish, libcamera)
+
+	@$(call touch)
+
+# vim: syntax=make
-- 
2.25.1




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [ptxdist] [APPLIED] libcamera: new package
  2022-09-17 18:33 ` [ptxdist] [PATCH v4 1/1] " Matthias Fend
@ 2022-09-28 14:28   ` Michael Olbrich
  2022-10-18  7:37   ` [ptxdist] [PATCH v4 1/1] " Christian Melki
  1 sibling, 0 replies; 4+ messages in thread
From: Michael Olbrich @ 2022-09-28 14:28 UTC (permalink / raw)
  To: ptxdist; +Cc: Matthias Fend

Thanks, applied as 7180a2509014617c5215f36201f8897e1de87156.

Michael

[sent from post-receive hook]

On Wed, 28 Sep 2022 16:28:59 +0200, Matthias Fend <matthias.fend@emfend.at> wrote:
> libcamera is an open source camera stack and framework for Linux, Android,
> and ChromeOS.
> 
> Signed-off-by: Matthias Fend <matthias.fend@emfend.at>
> Message-Id: <20220917183350.1838893-2-matthias.fend@emfend.at>
> Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
> 
> diff --git a/patches/libcamera-2022-08-30-g68683d3811a8/0001-do-not-use-git-information-for-version-generation.patch b/patches/libcamera-2022-08-30-g68683d3811a8/0001-do-not-use-git-information-for-version-generation.patch
> new file mode 100644
> index 000000000000..3e5c5ce68768
> --- /dev/null
> +++ b/patches/libcamera-2022-08-30-g68683d3811a8/0001-do-not-use-git-information-for-version-generation.patch
> @@ -0,0 +1,29 @@
> +From: Matthias Fend <matthias.fend@emfend.at>
> +Date: Wed, 31 Aug 2022 16:54:20 +0200
> +Subject: [PATCH] do not use git information for version generation
> +
> +Since libcamera is checked out without a git repo, git version reports the
> +version of the BSP. Since this is obviously wrong, just use the project
> +version.
> +
> +Signed-off-by: Matthias Fend <matthias.fend@emfend.at>
> +---
> + meson.build | 5 ++---
> + 1 file changed, 2 insertions(+), 3 deletions(-)
> +
> +diff --git a/meson.build b/meson.build
> +index 72919102ad55..e333df59388d 100644
> +--- a/meson.build
> ++++ b/meson.build
> +@@ -20,9 +20,8 @@ libcamera_git_version = run_command('utils/gen-version.sh',
> +                                     meson.project_build_root(),
> +                                     meson.project_source_root(),
> +                                     check: false).stdout().strip()
> +-if libcamera_git_version == ''
> +-    libcamera_git_version = meson.project_version()
> +-endif
> ++
> ++libcamera_git_version = meson.project_version()
> + 
> + libcamera_version = libcamera_git_version.split('+')[0]
> + 
> diff --git a/patches/libcamera-2022-08-30-g68683d3811a8/series b/patches/libcamera-2022-08-30-g68683d3811a8/series
> new file mode 100644
> index 000000000000..6ca42eafc0ac
> --- /dev/null
> +++ b/patches/libcamera-2022-08-30-g68683d3811a8/series
> @@ -0,0 +1,4 @@
> +# generated by git-ptx-patches
> +#tag:base --start-number 1
> +0001-do-not-use-git-information-for-version-generation.patch
> +# c3a57143ea9764ab95b84a7fb79896f4  - git-ptx-patches magic
> diff --git a/rules/libcamera.in b/rules/libcamera.in
> new file mode 100644
> index 000000000000..1f2d70aad8ca
> --- /dev/null
> +++ b/rules/libcamera.in
> @@ -0,0 +1,129 @@
> +## SECTION=multimedia_libs
> +
> +menuconfig LIBCAMERA
> +	bool
> +	select HOST_MESON
> +	select HOST_SYSTEM_PYTHON3
> +	select HOST_SYSTEM_PYTHON3_JINJA2
> +	select HOST_SYSTEM_PYTHON3_PYYAML
> +	select HOST_SYSTEM_PYTHON3_PLY
> +	select HOST_OPENSSL
> +	select GNUTLS				if LIBCAMERA_IPA_MODULE_SIGN_GNUTLS
> +	select OPENSSL				if LIBCAMERA_IPA_MODULE_SIGN_OPENSSL
> +	select UDEV_LIBUDEV
> +	select LIBYAML
> +	select LIBUNWIND			if LIBCAMERA_BACKTRACE
> +	select GSTREAMER1			if LIBCAMERA_GSTREAMER
> +	select GST_PLUGINS_BASE1		if LIBCAMERA_GSTREAMER
> +	select LIBEVENT				if LIBCAMERA_CAM
> +	select LIBDRM				if LIBCAMERA_CAM_KMS_SINK
> +	select QT5				if LIBCAMERA_QCAM
> +	select QT5_MODULE_QTBASE		if LIBCAMERA_QCAM
> +	select QT5_MODULE_QTBASE_GUI		if LIBCAMERA_QCAM
> +	select QT5_MODULE_QTBASE_WIDGETS	if LIBCAMERA_QCAM
> +	prompt "libcamera                     "
> +	help
> +	  A complex camera support library for Linux, Android, and ChromeOS.
> +
> +if LIBCAMERA
> +
> +config LIBCAMERA_GSTREAMER
> +	bool
> +	prompt "Install GStreamer plugin"
> +
> +config LIBCAMERA_CAM
> +	bool
> +	prompt "Install cam test application"
> +
> +if LIBCAMERA_CAM
> +
> +config LIBCAMERA_CAM_KMS_SINK
> +	bool
> +	prompt "Enable KMS sink"
> +endif
> +
> +config LIBCAMERA_QCAM
> +	bool
> +	prompt "Install qcam test application"
> +
> +config LIBCAMERA_BACKTRACE
> +	bool
> +	prompt "Add support for backtraces"
> +
> +menu "Platforms"
> +
> +config LIBCAMERA_PIPELINE_IPU3
> +	bool
> +	prompt "ipu3 pipeline"
> +
> +config LIBCAMERA_IPA_IPU3
> +	bool
> +	default y
> +	prompt "ipu3 IPA"
> +	depends on LIBCAMERA_PIPELINE_IPU3
> +
> +config LIBCAMERA_PIPELINE_RASPBERRYPI
> +	bool
> +	prompt "raspberrypi pipeline"
> +
> +config LIBCAMERA_IPA_RASPBERRYPI
> +	bool
> +	default y
> +	prompt "raspberrypi IPA"
> +	depends on LIBCAMERA_PIPELINE_RASPBERRYPI
> +
> +config LIBCAMERA_PIPELINE_RKISP1
> +	bool
> +	prompt "rkisp1 pipeline"
> +
> +config LIBCAMERA_IPA_RKISP1
> +	bool
> +	default y
> +	prompt "rkisp1 IPA"
> +	depends on LIBCAMERA_PIPELINE_RKISP1
> +
> +config LIBCAMERA_PIPELINE_SIMPLE
> +	bool
> +	prompt "simple pipeline"
> +
> +config LIBCAMERA_PIPELINE_UVCVIDEO
> +	bool
> +	prompt "uvcvideo pipeline"
> +
> +config LIBCAMERA_PIPELINE_VIMC
> +	bool
> +	prompt "vimc pipeline"
> +
> +config LIBCAMERA_IPA_VIMC
> +	bool
> +	default y
> +	prompt "vimc IPA"
> +	depends on LIBCAMERA_PIPELINE_VIMC
> +
> +endmenu
> +
> +config LIBCAMERA_IPA_MODULE_SIGN
> +	bool
> +	default y
> +	prompt "Enable IPA module signing"
> +	help
> +	  Without IPA module signing, all IPA modules will be isolated in a
> +	  separate process. This adds an unnecessary extra overhead at runtime.
> +
> +if LIBCAMERA_IPA_MODULE_SIGN
> +
> +choice
> +	prompt "Crypt provider"
> +	default LIBCAMERA_IPA_MODULE_SIGN_GNUTLS
> +
> +config LIBCAMERA_IPA_MODULE_SIGN_GNUTLS
> +	bool "gnutls"
> +
> +config LIBCAMERA_IPA_MODULE_SIGN_OPENSSL
> +	bool "openssl (libcrypto)"
> +
> +endchoice
> +
> +endif
> +
> +endif
> diff --git a/rules/libcamera.make b/rules/libcamera.make
> new file mode 100644
> index 000000000000..a6560fb4835e
> --- /dev/null
> +++ b/rules/libcamera.make
> @@ -0,0 +1,143 @@
> +# -*-makefile-*-
> +#
> +# Copyright (C) 2022 by Matthias Fend <matthias.fend@emfend.at>
> +#
> +# For further information about the PTXdist project and license conditions
> +# see the README file.
> +#
> +
> +#
> +# We provide this package
> +#
> +PACKAGES-$(PTXCONF_LIBCAMERA) += libcamera
> +
> +#
> +# Paths and names
> +#
> +LIBCAMERA_VERSION	:= 2022-08-30-g68683d3811a8
> +LIBCAMERA_MD5		:= 2f5a985257a0797e0bd0b4182ef9bc9c
> +LIBCAMERA		:= libcamera-$(LIBCAMERA_VERSION)
> +LIBCAMERA_SUFFIX	:= tar.gz
> +LIBCAMERA_URL		:= https://git.libcamera.org/libcamera/libcamera.git;tag=$(LIBCAMERA_VERSION)
> +LIBCAMERA_SOURCE	:= $(SRCDIR)/$(LIBCAMERA).$(LIBCAMERA_SUFFIX)
> +LIBCAMERA_DIR		:= $(BUILDDIR)/$(LIBCAMERA)
> +LIBCAMERA_LICENSE	:= Apache-2.0 AND \
> +			   BSD-2-Clause AND BSD-3-Clause AND \
> +			   CC0-1.0 AND CC-BY-SA-4.0 AND \
> +			   GPL-2.0-or-later AND GPL-2.0 WITH Linux-syscall-note AND \
> +			   (GPL-2.0-or-later WITH Linux-syscall-note OR MIT) AND LGPL-2.1-or-later
> +LIBCAMERA_LICENSE_FILES	:= file://LICENSES/Apache-2.0.txt;md5=3b83ef96387f14655fc854ddc3c6bd57 \
> +			   file://LICENSES/BSD-2-Clause.txt;md5=63d6ee386b8aaba70b1bf15a79ca50f2 \
> +			   file://LICENSES/BSD-3-Clause.txt;md5=954f4d71a37096249f837652a7f586c0 \
> +			   file://LICENSES/CC0-1.0.txt;md5=6fd064768b8d61c31ddd0540570fbd33 \
> +			   file://LICENSES/CC-BY-SA-4.0.txt;md5=598a2bb2d212cf9bc240fb554efcb169 \
> +			   file://LICENSES/GPL-2.0-or-later.txt;md5=fed54355545ffd980b814dab4a3b312c \
> +			   file://LICENSES/GPL-2.0.txt;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
> +			   file://LICENSES/Linux-syscall-note.txt;md5=370f20aa0795bf47c9a50d8cee5a7cfb \
> +			   file://LICENSES/GPL-2.0+.txt;md5=fed54355545ffd980b814dab4a3b312c \
> +			   file://LICENSES/MIT.txt;md5=38aa75cf4c4c87f018227d5ec9638d75 \
> +			   file://LICENSES/LGPL-2.1-or-later.txt;md5=2a4f4fd2128ea2f65047ee63fbca9f68
> +
> +# ----------------------------------------------------------------------------
> +# Prepare
> +# ----------------------------------------------------------------------------
> +
> +LIBCAMERA_IPAS-y					:=
> +LIBCAMERA_IPAS-$(PTXCONF_LIBCAMERA_IPA_IPU3)		+= ipu3
> +LIBCAMERA_IPASC-$(PTXCONF_LIBCAMERA_IPA_RASPBERRYPI)	+= raspberrypi
> +LIBCAMERA_IPASM-$(PTXCONF_LIBCAMERA_IPA_RASPBERRYPI)	+= rpi
> +LIBCAMERA_IPAS-$(PTXCONF_LIBCAMERA_IPA_RKISP1)		+= rkisp1
> +LIBCAMERA_IPAS-$(PTXCONF_LIBCAMERA_IPA_VIMC)		+= vimc
> +
> +LIBCAMERA_IPASC-y	+= $(LIBCAMERA_IPAS-y)
> +LIBCAMERA_IPASM-y	+= $(LIBCAMERA_IPAS-y)
> +
> +LIBCAMERA_PIPELINES-y						:=
> +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_IPU3)		+= ipu3
> +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_RASPBERRYPI)	+= raspberrypi
> +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_RKISP1)	+= rkisp1
> +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_SIMPLE)	+= simple
> +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_UVCVIDEO)	+= uvcvideo
> +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_VIMC)		+= vimc
> +
> +LIBCAMERA_CONF_TOOL	:= meson
> +LIBCAMERA_CONF_OPT	:= \
> +	$(CROSS_MESON_USR) \
> +	-Dandroid=disabled \
> +	-Dcam=$(call ptx/endis,PTXCONF_LIBCAMERA_CAM)d \
> +	-Ddocumentation=disabled \
> +	-Dgstreamer=$(call ptx/endis,PTXCONF_LIBCAMERA_GSTREAMER)d \
> +	-Dipas=$(subst $(ptx/def/space),$(ptx/def/comma),$(strip $(LIBCAMERA_IPASC-y))) \
> +	-Dlc-compliance=disabled \
> +	-Dpipelines=$(subst $(ptx/def/space),$(ptx/def/comma),$(strip $(LIBCAMERA_PIPELINES-y))) \
> +	-Dqcam=$(call ptx/endis,PTXCONF_LIBCAMERA_QCAM)d \
> +	-Dtest=false \
> +	-Dtracing=disabled \
> +	-Dv4l2=false \
> +	-Dpycamera=disabled
> +
> +# ----------------------------------------------------------------------------
> +# Target-Install
> +# ----------------------------------------------------------------------------
> +
> +define install_ipa
> +	@$(call install_copy, libcamera, 0, 0, 0755, -, \
> +		/usr/libexec/libcamera/$(strip $(1))_ipa_proxy)
> +	@$(call install_alternative_tree, libcamera, 0, 0, \
> +		/usr/share/libcamera/ipa/$(strip $(1)))
> +endef
> +
> +define install_ipa_module_signed
> +	# The IPA modules must not be stripped, otherwise the associated
> +	# signatures will no longer be valid.
> +	@$(call install_copy, libcamera, 0, 0, 0644, -, \
> +		/usr/lib/libcamera/ipa_$(strip $(1)).so, n)
> +	@$(call install_copy, libcamera, 0, 0, 0644, -, \
> +		/usr/lib/libcamera/ipa_$(strip $(1)).so.sign)
> +endef
> +
> +define install_ipa_module
> +	@$(call install_copy, libcamera, 0, 0, 0644, -, \
> +		/usr/lib/libcamera/ipa_$(strip $(1)).so)
> +endef
> +
> +$(STATEDIR)/libcamera.targetinstall:
> +	@$(call targetinfo)
> +
> +	@$(call install_init, libcamera)
> +	@$(call install_fixup, libcamera, PRIORITY, optional)
> +	@$(call install_fixup, libcamera, SECTION, base)
> +	@$(call install_fixup, libcamera, AUTHOR, "Matthias Fend <matthias.fend@emfend.at>")
> +	@$(call install_fixup, libcamera, DESCRIPTION, missing)
> +
> +	@$(call install_lib, libcamera, 0, 0, 0644, libcamera)
> +	@$(call install_lib, libcamera, 0, 0, 0644, libcamera-base)
> +
> +	@$(foreach ipa,$(LIBCAMERA_IPASC-y), \
> +		$(call install_ipa, $(ipa))$(ptx/nl))
> +
> +ifdef PTXCONF_LIBCAMERA_IPA_MODULE_SIGN
> +	@$(foreach ipa_module,$(LIBCAMERA_IPASM-y), \
> +		$(call install_ipa_module_signed, $(ipa_module))$(ptx/nl))
> +else
> +	@$(foreach ipa_module,$(LIBCAMERA_IPASM-y), \
> +		$(call install_ipa_module, $(ipa_module))$(ptx/nl))
> +endif
> +
> +ifdef PTXCONF_LIBCAMERA_GSTREAMER
> +	@$(call install_lib, libcamera, 0, 0, 0644, gstreamer-1.0/libgstlibcamera)
> +endif
> +
> +ifdef PTXCONF_LIBCAMERA_CAM
> +	@$(call install_copy, libcamera, 0, 0, 0755, -, /usr/bin/cam)
> +endif
> +
> +ifdef PTXCONF_LIBCAMERA_QCAM
> +	@$(call install_copy, libcamera, 0, 0, 0755, -, /usr/bin/qcam)
> +endif
> +
> +	@$(call install_finish, libcamera)
> +
> +	@$(call touch)
> +
> +# vim: syntax=make



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [ptxdist] [PATCH v4 1/1] libcamera: new package
  2022-09-17 18:33 ` [ptxdist] [PATCH v4 1/1] " Matthias Fend
  2022-09-28 14:28   ` [ptxdist] [APPLIED] " Michael Olbrich
@ 2022-10-18  7:37   ` Christian Melki
  1 sibling, 0 replies; 4+ messages in thread
From: Christian Melki @ 2022-10-18  7:37 UTC (permalink / raw)
  To: matthias.fend; +Cc: ptxdist

Hi.

Seems libcamera is now available as a released version.
https://www.phoronix.com/news/libcamera-First-Release

Regards,
Christian

On 9/17/22 8:33 PM, Matthias Fend wrote:
> libcamera is an open source camera stack and framework for Linux, Android,
> and ChromeOS.
> 
> Signed-off-by: Matthias Fend <matthias.fend@emfend.at>
> ---
>   ...t-information-for-version-generation.patch |  29 ++++
>   .../libcamera-2022-08-30-g68683d3811a8/series |   4 +
>   rules/libcamera.in                            | 129 ++++++++++++++++
>   rules/libcamera.make                          | 143 ++++++++++++++++++
>   4 files changed, 305 insertions(+)
>   create mode 100644 patches/libcamera-2022-08-30-g68683d3811a8/0001-do-not-use-git-information-for-version-generation.patch
>   create mode 100644 patches/libcamera-2022-08-30-g68683d3811a8/series
>   create mode 100644 rules/libcamera.in
>   create mode 100644 rules/libcamera.make
> 
> diff --git a/patches/libcamera-2022-08-30-g68683d3811a8/0001-do-not-use-git-information-for-version-generation.patch b/patches/libcamera-2022-08-30-g68683d3811a8/0001-do-not-use-git-information-for-version-generation.patch
> new file mode 100644
> index 000000000..3e5c5ce68
> --- /dev/null
> +++ b/patches/libcamera-2022-08-30-g68683d3811a8/0001-do-not-use-git-information-for-version-generation.patch
> @@ -0,0 +1,29 @@
> +From: Matthias Fend <matthias.fend@emfend.at>
> +Date: Wed, 31 Aug 2022 16:54:20 +0200
> +Subject: [PATCH] do not use git information for version generation
> +
> +Since libcamera is checked out without a git repo, git version reports the
> +version of the BSP. Since this is obviously wrong, just use the project
> +version.
> +
> +Signed-off-by: Matthias Fend <matthias.fend@emfend.at>
> +---
> + meson.build | 5 ++---
> + 1 file changed, 2 insertions(+), 3 deletions(-)
> +
> +diff --git a/meson.build b/meson.build
> +index 72919102ad55..e333df59388d 100644
> +--- a/meson.build
> ++++ b/meson.build
> +@@ -20,9 +20,8 @@ libcamera_git_version = run_command('utils/gen-version.sh',
> +                                     meson.project_build_root(),
> +                                     meson.project_source_root(),
> +                                     check: false).stdout().strip()
> +-if libcamera_git_version == ''
> +-    libcamera_git_version = meson.project_version()
> +-endif
> ++
> ++libcamera_git_version = meson.project_version()
> +
> + libcamera_version = libcamera_git_version.split('+')[0]
> +
> diff --git a/patches/libcamera-2022-08-30-g68683d3811a8/series b/patches/libcamera-2022-08-30-g68683d3811a8/series
> new file mode 100644
> index 000000000..6ca42eafc
> --- /dev/null
> +++ b/patches/libcamera-2022-08-30-g68683d3811a8/series
> @@ -0,0 +1,4 @@
> +# generated by git-ptx-patches
> +#tag:base --start-number 1
> +0001-do-not-use-git-information-for-version-generation.patch
> +# c3a57143ea9764ab95b84a7fb79896f4  - git-ptx-patches magic
> diff --git a/rules/libcamera.in b/rules/libcamera.in
> new file mode 100644
> index 000000000..1f2d70aad
> --- /dev/null
> +++ b/rules/libcamera.in
> @@ -0,0 +1,129 @@
> +## SECTION=multimedia_libs
> +
> +menuconfig LIBCAMERA
> +	bool
> +	select HOST_MESON
> +	select HOST_SYSTEM_PYTHON3
> +	select HOST_SYSTEM_PYTHON3_JINJA2
> +	select HOST_SYSTEM_PYTHON3_PYYAML
> +	select HOST_SYSTEM_PYTHON3_PLY
> +	select HOST_OPENSSL
> +	select GNUTLS				if LIBCAMERA_IPA_MODULE_SIGN_GNUTLS
> +	select OPENSSL				if LIBCAMERA_IPA_MODULE_SIGN_OPENSSL
> +	select UDEV_LIBUDEV
> +	select LIBYAML
> +	select LIBUNWIND			if LIBCAMERA_BACKTRACE
> +	select GSTREAMER1			if LIBCAMERA_GSTREAMER
> +	select GST_PLUGINS_BASE1		if LIBCAMERA_GSTREAMER
> +	select LIBEVENT				if LIBCAMERA_CAM
> +	select LIBDRM				if LIBCAMERA_CAM_KMS_SINK
> +	select QT5				if LIBCAMERA_QCAM
> +	select QT5_MODULE_QTBASE		if LIBCAMERA_QCAM
> +	select QT5_MODULE_QTBASE_GUI		if LIBCAMERA_QCAM
> +	select QT5_MODULE_QTBASE_WIDGETS	if LIBCAMERA_QCAM
> +	prompt "libcamera                     "
> +	help
> +	  A complex camera support library for Linux, Android, and ChromeOS.
> +
> +if LIBCAMERA
> +
> +config LIBCAMERA_GSTREAMER
> +	bool
> +	prompt "Install GStreamer plugin"
> +
> +config LIBCAMERA_CAM
> +	bool
> +	prompt "Install cam test application"
> +
> +if LIBCAMERA_CAM
> +
> +config LIBCAMERA_CAM_KMS_SINK
> +	bool
> +	prompt "Enable KMS sink"
> +endif
> +
> +config LIBCAMERA_QCAM
> +	bool
> +	prompt "Install qcam test application"
> +
> +config LIBCAMERA_BACKTRACE
> +	bool
> +	prompt "Add support for backtraces"
> +
> +menu "Platforms"
> +
> +config LIBCAMERA_PIPELINE_IPU3
> +	bool
> +	prompt "ipu3 pipeline"
> +
> +config LIBCAMERA_IPA_IPU3
> +	bool
> +	default y
> +	prompt "ipu3 IPA"
> +	depends on LIBCAMERA_PIPELINE_IPU3
> +
> +config LIBCAMERA_PIPELINE_RASPBERRYPI
> +	bool
> +	prompt "raspberrypi pipeline"
> +
> +config LIBCAMERA_IPA_RASPBERRYPI
> +	bool
> +	default y
> +	prompt "raspberrypi IPA"
> +	depends on LIBCAMERA_PIPELINE_RASPBERRYPI
> +
> +config LIBCAMERA_PIPELINE_RKISP1
> +	bool
> +	prompt "rkisp1 pipeline"
> +
> +config LIBCAMERA_IPA_RKISP1
> +	bool
> +	default y
> +	prompt "rkisp1 IPA"
> +	depends on LIBCAMERA_PIPELINE_RKISP1
> +
> +config LIBCAMERA_PIPELINE_SIMPLE
> +	bool
> +	prompt "simple pipeline"
> +
> +config LIBCAMERA_PIPELINE_UVCVIDEO
> +	bool
> +	prompt "uvcvideo pipeline"
> +
> +config LIBCAMERA_PIPELINE_VIMC
> +	bool
> +	prompt "vimc pipeline"
> +
> +config LIBCAMERA_IPA_VIMC
> +	bool
> +	default y
> +	prompt "vimc IPA"
> +	depends on LIBCAMERA_PIPELINE_VIMC
> +
> +endmenu
> +
> +config LIBCAMERA_IPA_MODULE_SIGN
> +	bool
> +	default y
> +	prompt "Enable IPA module signing"
> +	help
> +	  Without IPA module signing, all IPA modules will be isolated in a
> +	  separate process. This adds an unnecessary extra overhead at runtime.
> +
> +if LIBCAMERA_IPA_MODULE_SIGN
> +
> +choice
> +	prompt "Crypt provider"
> +	default LIBCAMERA_IPA_MODULE_SIGN_GNUTLS
> +
> +config LIBCAMERA_IPA_MODULE_SIGN_GNUTLS
> +	bool "gnutls"
> +
> +config LIBCAMERA_IPA_MODULE_SIGN_OPENSSL
> +	bool "openssl (libcrypto)"
> +
> +endchoice
> +
> +endif
> +
> +endif
> diff --git a/rules/libcamera.make b/rules/libcamera.make
> new file mode 100644
> index 000000000..a6560fb48
> --- /dev/null
> +++ b/rules/libcamera.make
> @@ -0,0 +1,143 @@
> +# -*-makefile-*-
> +#
> +# Copyright (C) 2022 by Matthias Fend <matthias.fend@emfend.at>
> +#
> +# For further information about the PTXdist project and license conditions
> +# see the README file.
> +#
> +
> +#
> +# We provide this package
> +#
> +PACKAGES-$(PTXCONF_LIBCAMERA) += libcamera
> +
> +#
> +# Paths and names
> +#
> +LIBCAMERA_VERSION	:= 2022-08-30-g68683d3811a8
> +LIBCAMERA_MD5		:= 2f5a985257a0797e0bd0b4182ef9bc9c
> +LIBCAMERA		:= libcamera-$(LIBCAMERA_VERSION)
> +LIBCAMERA_SUFFIX	:= tar.gz
> +LIBCAMERA_URL		:= https://git.libcamera.org/libcamera/libcamera.git;tag=$(LIBCAMERA_VERSION)
> +LIBCAMERA_SOURCE	:= $(SRCDIR)/$(LIBCAMERA).$(LIBCAMERA_SUFFIX)
> +LIBCAMERA_DIR		:= $(BUILDDIR)/$(LIBCAMERA)
> +LIBCAMERA_LICENSE	:= Apache-2.0 AND \
> +			   BSD-2-Clause AND BSD-3-Clause AND \
> +			   CC0-1.0 AND CC-BY-SA-4.0 AND \
> +			   GPL-2.0-or-later AND GPL-2.0 WITH Linux-syscall-note AND \
> +			   (GPL-2.0-or-later WITH Linux-syscall-note OR MIT) AND LGPL-2.1-or-later
> +LIBCAMERA_LICENSE_FILES	:= file://LICENSES/Apache-2.0.txt;md5=3b83ef96387f14655fc854ddc3c6bd57 \
> +			   file://LICENSES/BSD-2-Clause.txt;md5=63d6ee386b8aaba70b1bf15a79ca50f2 \
> +			   file://LICENSES/BSD-3-Clause.txt;md5=954f4d71a37096249f837652a7f586c0 \
> +			   file://LICENSES/CC0-1.0.txt;md5=6fd064768b8d61c31ddd0540570fbd33 \
> +			   file://LICENSES/CC-BY-SA-4.0.txt;md5=598a2bb2d212cf9bc240fb554efcb169 \
> +			   file://LICENSES/GPL-2.0-or-later.txt;md5=fed54355545ffd980b814dab4a3b312c \
> +			   file://LICENSES/GPL-2.0.txt;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
> +			   file://LICENSES/Linux-syscall-note.txt;md5=370f20aa0795bf47c9a50d8cee5a7cfb \
> +			   file://LICENSES/GPL-2.0+.txt;md5=fed54355545ffd980b814dab4a3b312c \
> +			   file://LICENSES/MIT.txt;md5=38aa75cf4c4c87f018227d5ec9638d75 \
> +			   file://LICENSES/LGPL-2.1-or-later.txt;md5=2a4f4fd2128ea2f65047ee63fbca9f68
> +
> +# ----------------------------------------------------------------------------
> +# Prepare
> +# ----------------------------------------------------------------------------
> +
> +LIBCAMERA_IPAS-y					:=
> +LIBCAMERA_IPAS-$(PTXCONF_LIBCAMERA_IPA_IPU3)		+= ipu3
> +LIBCAMERA_IPASC-$(PTXCONF_LIBCAMERA_IPA_RASPBERRYPI)	+= raspberrypi
> +LIBCAMERA_IPASM-$(PTXCONF_LIBCAMERA_IPA_RASPBERRYPI)	+= rpi
> +LIBCAMERA_IPAS-$(PTXCONF_LIBCAMERA_IPA_RKISP1)		+= rkisp1
> +LIBCAMERA_IPAS-$(PTXCONF_LIBCAMERA_IPA_VIMC)		+= vimc
> +
> +LIBCAMERA_IPASC-y	+= $(LIBCAMERA_IPAS-y)
> +LIBCAMERA_IPASM-y	+= $(LIBCAMERA_IPAS-y)
> +
> +LIBCAMERA_PIPELINES-y						:=
> +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_IPU3)		+= ipu3
> +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_RASPBERRYPI)	+= raspberrypi
> +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_RKISP1)	+= rkisp1
> +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_SIMPLE)	+= simple
> +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_UVCVIDEO)	+= uvcvideo
> +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINE_VIMC)		+= vimc
> +
> +LIBCAMERA_CONF_TOOL	:= meson
> +LIBCAMERA_CONF_OPT	:= \
> +	$(CROSS_MESON_USR) \
> +	-Dandroid=disabled \
> +	-Dcam=$(call ptx/endis,PTXCONF_LIBCAMERA_CAM)d \
> +	-Ddocumentation=disabled \
> +	-Dgstreamer=$(call ptx/endis,PTXCONF_LIBCAMERA_GSTREAMER)d \
> +	-Dipas=$(subst $(ptx/def/space),$(ptx/def/comma),$(strip $(LIBCAMERA_IPASC-y))) \
> +	-Dlc-compliance=disabled \
> +	-Dpipelines=$(subst $(ptx/def/space),$(ptx/def/comma),$(strip $(LIBCAMERA_PIPELINES-y))) \
> +	-Dqcam=$(call ptx/endis,PTXCONF_LIBCAMERA_QCAM)d \
> +	-Dtest=false \
> +	-Dtracing=disabled \
> +	-Dv4l2=false \
> +	-Dpycamera=disabled
> +
> +# ----------------------------------------------------------------------------
> +# Target-Install
> +# ----------------------------------------------------------------------------
> +
> +define install_ipa
> +	@$(call install_copy, libcamera, 0, 0, 0755, -, \
> +		/usr/libexec/libcamera/$(strip $(1))_ipa_proxy)
> +	@$(call install_alternative_tree, libcamera, 0, 0, \
> +		/usr/share/libcamera/ipa/$(strip $(1)))
> +endef
> +
> +define install_ipa_module_signed
> +	# The IPA modules must not be stripped, otherwise the associated
> +	# signatures will no longer be valid.
> +	@$(call install_copy, libcamera, 0, 0, 0644, -, \
> +		/usr/lib/libcamera/ipa_$(strip $(1)).so, n)
> +	@$(call install_copy, libcamera, 0, 0, 0644, -, \
> +		/usr/lib/libcamera/ipa_$(strip $(1)).so.sign)
> +endef
> +
> +define install_ipa_module
> +	@$(call install_copy, libcamera, 0, 0, 0644, -, \
> +		/usr/lib/libcamera/ipa_$(strip $(1)).so)
> +endef
> +
> +$(STATEDIR)/libcamera.targetinstall:
> +	@$(call targetinfo)
> +
> +	@$(call install_init, libcamera)
> +	@$(call install_fixup, libcamera, PRIORITY, optional)
> +	@$(call install_fixup, libcamera, SECTION, base)
> +	@$(call install_fixup, libcamera, AUTHOR, "Matthias Fend <matthias.fend@emfend.at>")
> +	@$(call install_fixup, libcamera, DESCRIPTION, missing)
> +
> +	@$(call install_lib, libcamera, 0, 0, 0644, libcamera)
> +	@$(call install_lib, libcamera, 0, 0, 0644, libcamera-base)
> +
> +	@$(foreach ipa,$(LIBCAMERA_IPASC-y), \
> +		$(call install_ipa, $(ipa))$(ptx/nl))
> +
> +ifdef PTXCONF_LIBCAMERA_IPA_MODULE_SIGN
> +	@$(foreach ipa_module,$(LIBCAMERA_IPASM-y), \
> +		$(call install_ipa_module_signed, $(ipa_module))$(ptx/nl))
> +else
> +	@$(foreach ipa_module,$(LIBCAMERA_IPASM-y), \
> +		$(call install_ipa_module, $(ipa_module))$(ptx/nl))
> +endif
> +
> +ifdef PTXCONF_LIBCAMERA_GSTREAMER
> +	@$(call install_lib, libcamera, 0, 0, 0644, gstreamer-1.0/libgstlibcamera)
> +endif
> +
> +ifdef PTXCONF_LIBCAMERA_CAM
> +	@$(call install_copy, libcamera, 0, 0, 0755, -, /usr/bin/cam)
> +endif
> +
> +ifdef PTXCONF_LIBCAMERA_QCAM
> +	@$(call install_copy, libcamera, 0, 0, 0755, -, /usr/bin/qcam)
> +endif
> +
> +	@$(call install_finish, libcamera)
> +
> +	@$(call touch)
> +
> +# vim: syntax=make



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-10-18  7:40 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-17 18:33 [ptxdist] [PATCH v4 0/1] libcamera: new package Matthias Fend
2022-09-17 18:33 ` [ptxdist] [PATCH v4 1/1] " Matthias Fend
2022-09-28 14:28   ` [ptxdist] [APPLIED] " Michael Olbrich
2022-10-18  7:37   ` [ptxdist] [PATCH v4 1/1] " Christian Melki

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox