{"id":4017,"url":"https://patchwork.libcamera.org/api/patches/4017/?format=json","web_url":"https://patchwork.libcamera.org/patch/4017/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/projects/1/?format=json","name":"libcamera","link_name":"libcamera","list_id":"libcamera_core","list_email":"libcamera-devel@lists.libcamera.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20200610153744.3225-1-scerveau@collabora.com>","date":"2020-06-10T15:37:44","name":"[libcamera-devel] meson: detect kernel version","commit_ref":null,"pull_url":null,"state":"superseded","archived":false,"hash":"8ffe4f25363dd60f2236e8e434ee55c2c7a9a86a","submitter":{"id":54,"url":"https://patchwork.libcamera.org/api/people/54/?format=json","name":"Stéphane Cerveau","email":"scerveau@collabora.com"},"delegate":null,"mbox":"https://patchwork.libcamera.org/patch/4017/mbox/","series":[{"id":986,"url":"https://patchwork.libcamera.org/api/series/986/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=986","date":"2020-06-10T15:37:44","name":"[libcamera-devel] meson: detect kernel version","version":1,"mbox":"https://patchwork.libcamera.org/series/986/mbox/"}],"comments":"https://patchwork.libcamera.org/api/patches/4017/comments/","check":"pending","checks":"https://patchwork.libcamera.org/api/patches/4017/checks/","tags":{},"headers":{"Return-Path":"<scerveau@collabora.com>","Received":["from bhuna.collabora.co.uk (bhuna.collabora.co.uk [46.235.227.227])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id CD31C600F7\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 10 Jun 2020 17:38:01 +0200 (CEST)","from [127.0.0.1] (localhost [127.0.0.1])\n\t(Authenticated sender: scerveau) with ESMTPSA id DF4042A22CB"],"From":"=?utf-8?q?St=C3=A9phane_Cerveau?= <scerveau@collabora.com>","To":"libcamera-devel@lists.libcamera.org","Date":"Wed, 10 Jun 2020 17:37:44 +0200","Message-Id":"<20200610153744.3225-1-scerveau@collabora.com>","X-Mailer":"git-send-email 2.17.1","MIME-Version":"1.0","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"8bit","Subject":"[libcamera-devel] [PATCH] meson: detect kernel version","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","X-List-Received-Date":"Wed, 10 Jun 2020 15:38:02 -0000"},"content":"Add kernel version detection to warn user\nthat only > 5.0.0 V4L API are supported in\nlibcamera.\n\nSigned-off-by: Stéphane Cerveau <scerveau@collabora.com>\n---\n meson.build | 6 ++++++\n 1 file changed, 6 insertions(+)","diff":"diff --git a/meson.build b/meson.build\nindex e898782..5063edb 100644\n--- a/meson.build\n+++ b/meson.build\n@@ -105,6 +105,12 @@ if get_option('test')\n     subdir('test')\n endif\n \n+kernel_version_req = '>= 5.0.0'\n+kernel_version = run_command('uname', '-r').stdout()\n+if not kernel_version.version_compare(kernel_version_req)\n+  warning('V4L2 API version @0@ is too old, @1@ is required, consider to upgrade your kernel version to use libcamera'.format(kernel_version, kernel_version_req))\n+endif\n+\n # Create a symlink from the build root to the source root. This is used when\n # running libcamera from the build directory to locate resources in the source\n # directory (such as IPA configuration files).\n","prefixes":["libcamera-devel"]}