From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id OO11I3TvlGZfqwAA62LTzQ:P1 (envelope-from ) for ; Mon, 15 Jul 2024 09:44:20 +0000 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1.migadu.com with LMTPS id OO11I3TvlGZfqwAA62LTzQ (envelope-from ) for ; Mon, 15 Jul 2024 11:44:20 +0200 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b=iXD9mUSJ; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1721036660; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=PDt8ye9JgVD/bMgDkOnaLB5WZb6lxRGn/8iKxyw7o8w=; b=E2+iYznv4tT1SkEMUuLQMHHQkYKuyq5150j3DpZ+REw1SKB3qkmbYy7byfwc/48A0VYkM8 8GztdlDKGtCTGVFGLOoqefrTkM1rXb0x4m8Qc2L41a7rU7hJJdpS/YTuhzU4LG5MZwi35v 8liTTg2e04zDO13TNDyEO3x6XvEkQaXi9RxVIq3aV/8+ou3Z7g+ARBNDDohtHKX21U0Vpj KwTCsnEc1xqDkP45aj3KYyJimMyg03Y+qphxPkV9DYW83eJuG4ijFSBLU/MbJ/bFjvdn68 W/UUEkKZyY8Xg3Mi6Bc5mmrecUKO8/DorCs3/1OG4H+aeylgDWGWl/HMqbaagA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1721036660; a=rsa-sha256; cv=none; b=CKtMV9EHxs/Wpd/JxPYIfO60l7HKxTdreKVrmAqK+vwAufPMLhkWlaPie4+//GBxnOv6mN uqhrc2NoNU9+j/gLN1A7dxJyAW5QK8wpFjvWmOx0exauAaHkXOmLp6MpTBpSNmgoda9HV/ UMfnMf2m47Ghahm2n0TFRcV5p1DseEi8zWghWkyyksTDOOIPllexB2/QbsMF1olGUnCXs0 3gvt82AlQ3iBeEYzUPIUxXB4hJ9MR7ssULtY+F0I+PvTGecyS5OCLIRtcsV35Sx3o05ZfK zdZrP13gaHaiK/g4WpGkoxZYeC+LIgzgMK+wHiokXIRZDH0vb5TGZssD0YzBKA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b=iXD9mUSJ; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id DB8533F36B for ; Mon, 15 Jul 2024 11:44:19 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sTIFV-0002EI-UH; Mon, 15 Jul 2024 05:44:01 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sTIFU-0002CS-4P for guix-patches@gnu.org; Mon, 15 Jul 2024 05:44:00 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sTIFT-0005OG-Sd for guix-patches@gnu.org; Mon, 15 Jul 2024 05:43:59 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1sTIFV-0003Wf-NU for guix-patches@gnu.org; Mon, 15 Jul 2024 05:44:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#69554] [PATCH v2] build-system: cmake: Build tests depending on `#:tests?`. Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 15 Jul 2024 09:44:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 69554 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Hartmut Goebel Cc: 69554@debbugs.gnu.org Received: via spool by 69554-submit@debbugs.gnu.org id=B69554.172103659413482 (code B ref 69554); Mon, 15 Jul 2024 09:44:01 +0000 Received: (at 69554) by debbugs.gnu.org; 15 Jul 2024 09:43:14 +0000 Received: from localhost ([127.0.0.1]:59049 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sTIEj-0003VO-Hd for submit@debbugs.gnu.org; Mon, 15 Jul 2024 05:43:13 -0400 Received: from eggs.gnu.org ([209.51.188.92]:41860) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sTIEh-0003VB-Hp for 69554@debbugs.gnu.org; Mon, 15 Jul 2024 05:43:12 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sTICS-0004z7-V9; Mon, 15 Jul 2024 05:40:52 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:Date:References:In-Reply-To:Subject:To: From; bh=PDt8ye9JgVD/bMgDkOnaLB5WZb6lxRGn/8iKxyw7o8w=; b=iXD9mUSJB+agHVCroSI8 Oijaeuh7zCvEZRomS5nEad9+8Dz0NzRwA8K6gHFkDgvteR+uXVcr/BhDlu8FayCkXE8jLWTV1bTFv rSexb/alndLPyawrEbQoy6mT2yhO2ud8M5bXzrjOuh5OnaY4aXsI5tXv5xLY0bWbyzGN8RPEKn23S NfbfQ0Z/3w3tnXPANv1w0SmToLf4rh/HLAT/eTA9eKhrTAcly8tmlKudqo0Dq8viUypV9lliPVN8K Aj21NxaXllleFlgnTP00juk7hCOQw9tQb86x4joZm9M3kYsf4FsGkoq1NmrO4D07m30OlhUGgbVzV 7RunzrOVEQEmzA==; From: Ludovic =?UTF-8?Q?Court=C3=A8s?= In-Reply-To: <7676fd973fa640750306df216feb95c335b345de.1709593063.git.h.goebel@crazy-compilers.com> (Hartmut Goebel's message of "Mon, 4 Mar 2024 23:58:32 +0100") References: <7676fd973fa640750306df216feb95c335b345de.1709593063.git.h.goebel@crazy-compilers.com> Date: Mon, 15 Jul 2024 11:40:41 +0200 Message-ID: <87ed7v0z8m.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: -4.30 X-Spam-Score: -4.30 X-Migadu-Queue-Id: DB8533F36B X-Migadu-Scanner: mx11.migadu.com X-TUID: r/XiK293XBMB Hi Hartmut, Hartmut Goebel skribis: > * guix/build/cmake-build-system.scm (configure): New paremeter `#:tests?`. > Add cmake option "-DBUILD_TESTING=3D" with value "ON" or "OFF" depending > on build-system argument `#:tests?`. > * * doc/guix.texi (Inspecting Services)[cmake-build-system]: Document it. > --- > doc/guix.texi | 10 ++++++++++ > guix/build/cmake-build-system.scm | 7 ++++++- > 2 files changed, 16 insertions(+), 1 deletion(-) > > diff --git a/doc/guix.texi b/doc/guix.texi > index 87fe9f803c..409d076d12 100644 > --- a/doc/guix.texi > +++ b/doc/guix.texi > @@ -9617,6 +9617,16 @@ parameter specifies in abstract terms the flags pa= ssed to the compiler; > it defaults to @code{"RelWithDebInfo"} (short for ``release mode with > debugging information''), which roughly means that code is compiled with > @code{-O2 -g}, as is the case for Autoconf-based packages by default. > + > +Depending on the @code{#:tests?} parameter, the configure-flag > +@code{BUILD_TESTING} is set to @code{ON} resp. @code{OFF}. > +@code{BUILD_TESTING} is a > +@url{https://cmake.org/cmake/help/v3.28/module/CTest.html, standard > +defined by CMake} to enable or disable building tests. This aims to > +save build time if tests are not run anyway, while trying to ensure > +tests are build if they should be run. Anyhow, the CMakeLists.txt needs > +to implement handling this flag. My understanding is that =E2=80=98BUILD_TESTING=E2=80=99 is not standard, a= s the last sentence above suggests. Thus I=E2=80=99m reluctant to passing this flag unconditionally, as I guess it would fail for =E2=80=98CMakeLists.txt=E2=80= =99 that do not implement it, right? Thanks, Ludo=E2=80=99.