GNU bug report logs - #70397
[PATCH] gnu: cppdap: Add cppdap to debug.scm.

Previous Next

Package: guix-patches;

Reported by: Daniel Ziltener <dziltener <at> lyrion.ch>

Date: Mon, 15 Apr 2024 14:26:02 UTC

Severity: normal

Tags: patch

Done: Z572 <zhengjunjie <at> iscas.ac.cn>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Zheng Junjie <zhengjunjie <at> iscas.ac.cn>
To: Daniel Ziltener <dziltener <at> lyrion.ch>, 70397 <at> debbugs.gnu.org
Subject: [bug#70397] [PATCH] gnu: cppdap: Add cppdap to debug.scm.
Date: Tue, 16 Apr 2024 00:42:33 +0800
[Message part 1 (text/plain, inline)]
hellow, i review this patch, and have some comment

Daniel Ziltener via Guix-patches via <guix-patches <at> gnu.org> writes:

> ---
>  gnu/packages/debug.scm | 31 +++++++++++++++++++++++++++++++

Usually our message goes something like this:

gnu: Add cppdap.
* gnu/packages/debug.scm (cppdap): New variable.

>  1 file changed, 31 insertions(+)
>
> diff --git a/gnu/packages/debug.scm b/gnu/packages/debug.scm
> index 6d4567acc4..7865dc32f4 100644
> --- a/gnu/packages/debug.scm
> +++ b/gnu/packages/debug.scm
> @@ -185,6 +185,37 @@ (define-public c-reduce
>  tools that process C/C++ code.")
>      (license license:ncsa)))
>  
> +(define-public cppdap
> +  (package
> +    (name "cppdap")
> +    (version "1.58.0-a")
> +    (source
> +     (origin
> +       (method git-fetch)
> +       (uri
> +        (git-reference
> +         (url "https://github.com/google/cppdap")
> +         (commit (string-append "dap-" version))))

usually we add (file-name (git-file-name name version)), 

and it have a "third_party" directory, we need remove it.

and see https://github.com/google/cppdap/pull/124 , it add a
CPPDAP_USE_EXTERNAL_GTEST_PACKAGE option to use system gtest. so we can
pick it.

> +       (sha256
> +        (base32
> +         "0fq2w35fw1lb5wya1nny45pk3a13b689k48calk1cmqmqpbcjn2b"))))
> +    (build-system cmake-build-system)
> +    (arguments
> +     (list
> +      #:configure-flags #~(list "-DCPPDAP_USE_EXTERNAL_NLOHMANN_JSON_PACKAGE=ON")
> +      #:phases #~(modify-phases %standard-phases
> +                   (delete 'check))))

if no test target, please use "#:tests? #f" and add commit about it.

and it have CPPDAP_BUILD_TESTS, so we can enable it.

> +    (propagated-inputs
> +     (list nlohmann-json))

need add some commit about why propagate nlohmann-json. and need add
(gnu packages cpp) module.

> +    (home-page "https://github.com/google/cppdap")
> +    (synopsis "C++ library for the Debug Adapter Protocol")
> +    (description
> +     "cppdap is a C++11 library (\"SDK\") implementation of the Debug Adapter Protocol,
> +providing an API for implementing a DAP client or server.
> +cppdap provides C++ type-safe structures for the full DAP specification, and provides
> + a simple way to add custom protocol messages.")

It's a little over the line count

> +    (license license:expat)))
> +
>  (define-public c-vise
>    (package
>      (name "c-vise")

The end result should be similar https://issues.guix.gnu.org/70397#1
[signature.asc (application/pgp-signature, inline)]

This bug report was last modified 1 year and 85 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.