From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: From: Marian Cichy Date: Mon, 22 Mar 2021 14:48:42 +0100 Message-Id: <20210322134842.20388-2-m.cichy@pengutronix.de> In-Reply-To: <20210322134842.20388-1-m.cichy@pengutronix.de> References: <20210322134842.20388-1-m.cichy@pengutronix.de> MIME-Version: 1.0 Subject: [ptxdist] [PATCH 2/2] libcamera: Add package List-Id: PTXdist Development Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: ptxdist@pengutronix.de Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ptxdist-bounces@pengutronix.de Sender: "ptxdist" To: ptxdist@pengutronix.de Cc: Marian Cichy libcamera is a new library to ease usage and configuration for camera devices. Currently, libcamera has no release tags. This version is based on commit 5154e14b from 2021-03-22. Signed-off-by: Marian Cichy --- rules/libcamera.in | 75 +++++++++++++++++++++++++++ rules/libcamera.make | 117 +++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 192 insertions(+) create mode 100644 rules/libcamera.in create mode 100644 rules/libcamera.make diff --git a/rules/libcamera.in b/rules/libcamera.in new file mode 100644 index 000000000..886f716f6 --- /dev/null +++ b/rules/libcamera.in @@ -0,0 +1,75 @@ +## SECTION=multimedia_libs + +menuconfig LIBCAMERA + tristate + prompt "libcamera " + select HOST_MESON + select HOST_SYSTEM_PYTHON3 + select HOST_SYSTEM_PYTHON3_PLY + select HOST_SYSTEM_PYTHON3_PYYAML + select HOST_SYSTEM_PYTHON3_JINJA2 + select GNUTLS + select OPENSSL + select BOOST if LIBCAMERA_PIPELINES_RASPBERRYPI + select GSTREAMER1 if LIBCAMERA_GSTREAMER + select GST_PLUGINS_BASE1 if LIBCAMERA_GSTREAMER + select LIBEVENT if LIBCAMERA_CAM + select QT5 if LIBCAMERA_QCAM + help + libcamera is a library to ease configuration and usage of camera devices/ + +if LIBCAMERA + +config LIBCAMERA_GSTREAMER + bool + prompt "libcamera GStreamer plugin" + help + Gstreamer libcamerasrc element + +config LIBCAMERA_CAM + bool + prompt "cam test application" + help + Demo application for libcamera + +config LIBCAMERA_QCAM + bool + prompt "qcam test application" + help + Qt demo application for libcamera + +config LIBCAMERA_TRACING + bool + prompt "Enable tracing" + +config LIBCAMERA_V4L2 + bool + prompt "V4L2 compatibility layer" + +comment "Pipelines" + +config LIBCAMERA_PIPELINES_IPU3 + bool + prompt "ipu3" + +config LIBCAMERA_PIPELINES_RASPBERRYPI + bool + prompt "raspberrypi" + +config LIBCAMERA_PIPELINES_RKISP1 + bool + prompt "rkisp1" + +config LIBCAMERA_PIPELINES_SIMPLE + bool + prompt "simple" + +config LIBCAMERA_PIPELINES_UVCVIDEO + bool + prompt "uvcvideo" + +config LIBCAMERA_PIPELINES_VIMC + bool + prompt "vimc" + +endif diff --git a/rules/libcamera.make b/rules/libcamera.make new file mode 100644 index 000000000..7e1ab6ae7 --- /dev/null +++ b/rules/libcamera.make @@ -0,0 +1,117 @@ +# -*-makefile-*- +# +# Copyright (C) 2021 by Marian Cichy +# +# 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 := 2021-02-01-g5154e14b +LIBCAMERA_MD5 := df003c77b6e6bda22d5ef72fed2540ad +LIBCAMERA := libcamera-$(LIBCAMERA_VERSION) +LIBCAMERA_SUFFIX := tar.xz +LIBCAMERA_URL := git://linuxtv.org/libcamera.git;tag=$(LIBCAMERA_VERSION) +LIBCAMERA_SOURCE := $(SRCDIR)/$(LIBCAMERA).$(LIBCAMERA_SUFFIX) +LIBCAMERA_DIR := $(BUILDDIR)/$(LIBCAMERA) +LIBCAMERA_LICENSE := unknown + +# ---------------------------------------------------------------------------- +# Get +# ---------------------------------------------------------------------------- + +#$(LIBCAMERA_SOURCE): +# @$(call targetinfo) +# @$(call get, LIBCAMERA) + +# ---------------------------------------------------------------------------- +# Prepare +# ---------------------------------------------------------------------------- + +#LIBCAMERA_CONF_ENV := $(CROSS_ENV) + +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINES_IPU3) += ipu3 +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINES_RASPBERRYPI) += raspberrypi +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINES_RKISP1) += rkisp1 +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINES_SIMPLE) += simple +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINES_UVCVIDEO) += uvcvideo +LIBCAMERA_PIPELINES-$(PTXCONF_LIBCAMERA_PIPELINES_VIMC) += vimc + +LIBCAMERA_CONF_TOOL := meson +LIBCAMERA_CONF_OPT := \ + $(CROSS_MESON_USR) \ + -Dandroid=disabled\ + -Ddocumentation=disabled \ + -Dgstreamer=$(call ptx/endis, PTXCONF_LIBCAMERA_GSTREAMER)d \ + -Dpipelines=$(subst $(space),$(comma),$(LIBCAMERA_PIPELINES-y)) \ + -Dqcam=$(call ptx/endis, PTXCONF_LIBCAMERA_QCAM)d \ + -Dtest=$(call ptx/truefalse, PTXCONF_LIBCAMERA_TEST) \ + -Dtracing=$(call ptx/endis, PTXCONF_LIBCAMERA_TRACING)d \ + -Dv4l2=$(call ptx/truefalse, PTXCONF_LIBCAMERA_V4L2) + +#$(STATEDIR)/libcamera.prepare: +# @$(call targetinfo) +# @$(call world/prepare, LIBCAMERA) +# @$(call touch) + +# ---------------------------------------------------------------------------- +# Compile +# ---------------------------------------------------------------------------- + +#$(STATEDIR)/libcamera.compile: +# @$(call targetinfo) +# @$(call world/compile, LIBCAMERA) +# @$(call touch) + +# ---------------------------------------------------------------------------- +# Install +# ---------------------------------------------------------------------------- + +#$(STATEDIR)/libcamera.install: +# @$(call targetinfo) +# @$(call world/install, LIBCAMERA) +# @$(call touch) + +# ---------------------------------------------------------------------------- +# Target-Install +# ---------------------------------------------------------------------------- + +$(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,"Marian Cichy ") + @$(call install_fixup, libcamera,DESCRIPTION,missing) + + @$(call install_lib, libcamera, 0, 0, 0644, libcamera) + +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 + + @$(call install_finish, libcamera) + + @$(call touch) + +# ---------------------------------------------------------------------------- +# Clean +# ---------------------------------------------------------------------------- + +#$(STATEDIR)/libcamera.clean: +# @$(call targetinfo) +# @$(call clean_pkg, LIBCAMERA) + +# vim: syntax=make -- 2.29.2 _______________________________________________ ptxdist mailing list ptxdist@pengutronix.de To unsubscribe, send a mail with subject "unsubscribe" to ptxdist-request@pengutronix.de