2021-08-05 20:00:27 +00:00
|
|
|
# Maintainer: Sam L. Yes <samlukeyes123@gmail.com>
|
|
|
|
|
|
|
|
pkgname=libcamera-clang-git
|
2021-10-28 19:19:06 +00:00
|
|
|
pkgver=r3203.76bd9f3d
|
2021-08-05 20:00:27 +00:00
|
|
|
pkgrel=1
|
2021-10-28 19:19:06 +00:00
|
|
|
pkgdesc='A complex camera support library for Linux, Android, and ChromeOS (built with LLVM toolchain)'
|
2021-08-05 20:00:27 +00:00
|
|
|
arch=('x86_64' 'i686')
|
|
|
|
url='https://libcamera.org/'
|
2021-10-28 19:19:06 +00:00
|
|
|
provides=('libcamera' 'libcamera-git')
|
2021-08-05 20:00:27 +00:00
|
|
|
conflicts=('libcamera')
|
|
|
|
makedepends=(
|
2021-10-28 19:19:06 +00:00
|
|
|
'python-yaml' 'python-ply' 'python-jinja' 'pkgconf' 'gnutls' 'openssl' 'git'
|
2021-08-05 20:00:27 +00:00
|
|
|
'udev' # for device hotplug enumeration
|
|
|
|
'gstreamer' # for gstreamer support
|
|
|
|
'qt5-tools' # for 'qcam'
|
|
|
|
'libevent' # for 'cam'
|
2021-10-28 19:19:06 +00:00
|
|
|
#'gtest' # for 'lc-compliance'
|
|
|
|
'meson'
|
2021-08-05 20:00:27 +00:00
|
|
|
'clang>=5.0'
|
|
|
|
)
|
|
|
|
depends=(
|
2021-10-28 19:19:06 +00:00
|
|
|
'libc++'
|
2021-08-05 20:00:27 +00:00
|
|
|
'gst-plugins-base-libs' # for gstreamer support
|
|
|
|
#'lttng-ust' # for tracing with LTTng
|
|
|
|
)
|
|
|
|
optdepends=(
|
|
|
|
'qt5-base: for qcam test application'
|
|
|
|
'libevent: for test commands'
|
|
|
|
)
|
|
|
|
license=('LGPL' 'GPL' 'Apache' 'BSD' 'MIT' 'custom')
|
|
|
|
options=('!docs')
|
2021-10-28 19:19:06 +00:00
|
|
|
source=('git+https://git.linuxtv.org/libcamera.git')
|
2021-08-05 20:00:27 +00:00
|
|
|
md5sums=('SKIP')
|
|
|
|
_licensedir=/usr/share/licenses/${pkgname}
|
|
|
|
|
|
|
|
prepare() {
|
|
|
|
sed -i 's|py_compile=True,||' ${srcdir}/libcamera/utils/ipc/mojo/public/tools/mojom/mojom/generate/template_expander.py
|
|
|
|
}
|
|
|
|
|
|
|
|
pkgver() {
|
|
|
|
cd libcamera
|
|
|
|
printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
|
|
|
|
}
|
|
|
|
|
|
|
|
build() {
|
|
|
|
cd "${srcdir}/libcamera"
|
|
|
|
CC=clang CXX=clang++ arch-meson build \
|
|
|
|
-Dwerror=false \
|
|
|
|
-Dv4l2=true \
|
|
|
|
-Dipas=ipu3,vimc \
|
|
|
|
-Dpipelines=ipu3,uvcvideo,vimc \
|
|
|
|
-Ddocumentation=disabled \
|
2021-10-28 19:19:06 +00:00
|
|
|
-Dlc-compliance=disabled \
|
2021-08-05 20:00:27 +00:00
|
|
|
-Dtracing=disabled # comment this line to enable LTTng support
|
|
|
|
ninja -C build
|
|
|
|
}
|
|
|
|
|
|
|
|
check() {
|
|
|
|
cd ${srcdir}/libcamera
|
|
|
|
meson test -C build
|
|
|
|
}
|
|
|
|
|
|
|
|
package() {
|
|
|
|
cd "$srcdir/libcamera"
|
|
|
|
DESTDIR="${pkgdir}" ninja -C build install
|
|
|
|
|
|
|
|
# Install licenses
|
|
|
|
install -d ${pkgdir}/${_licensedir}/LICENSES
|
|
|
|
install -m644 COPYING.rst ${pkgdir}/${_licensedir}
|
|
|
|
install -m644 LICENSES/{BSD-{2,3}-Clause,CC-BY-SA-4.0,CC0-1.0,MIT,Linux-syscall-note}.txt ${pkgdir}/${_licensedir}/LICENSES
|
|
|
|
}
|