[bug#78316,electronics-team] gnu: python-hdlmake: Update to 3.4dev1-0.9338e3e.

Message ID 4f7ed71fab3045a19ff031ebfc293ac1aee052a2.1746708572.git.csantosb@inventati.org
State New
Headers
Series [bug#78316,electronics-team] gnu: python-hdlmake: Update to 3.4dev1-0.9338e3e. |

Commit Message

Cayetano Santos May 8, 2025, 12:49 p.m. UTC
  * gnu/packages/fpga.scm (python-hdlmake): Update to 3.4dev1-0.9338e3e.

Change-Id: Ied124a3ceb22be427c5255b5d139f5f63031e260
---

[source]: Update URL.
[homepage]: Update URL.

 gnu/packages/fpga.scm | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)


base-commit: 4fe484ee7e9d598a9d0a249c375b75a14b95d1b4
--
2.49.0
  

Comments

Gabriel Wicki May 12, 2025, 12:04 p.m. UTC | #1
LGTM, but: Does the project officially change their home-page?  If so,
please state that in the commit message.

Thanks for your time and effort!
gabber
  
Maxim Cournoyer May 12, 2025, 12:52 p.m. UTC | #2
Hi,

Cayetano Santos <csantosb@inventati.org> writes:

> * gnu/packages/fpga.scm (python-hdlmake): Update to 3.4dev1-0.9338e3e.
>
> Change-Id: Ied124a3ceb22be427c5255b5d139f5f63031e260
> ---
>
> [source]: Update URL.
> [homepage]: Update URL.

Ah, these should have appeared in the change log (commit message), not
in this patch metadata/comment area.  I've fixed it locally.

>  gnu/packages/fpga.scm | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm
> index 2298dde595..e2a0b19a7d 100644
> --- a/gnu/packages/fpga.scm
> +++ b/gnu/packages/fpga.scm
> @@ -776,26 +776,26 @@ (define-public openfpgaloader
>      (license license:asl2.0)))
>  
>  (define-public python-hdlmake
> -  (let ((commit "3cb248fdad601c579b59fd7c194402871209bc54")
> +  (let ((commit "9338e3e7a8784e63d16496a3fa8234d9e5aa7621")
>          (revision "0"))
>      (package
>        (name "python-hdlmake")
> -      (version (git-version "3.3" revision commit))
> +      (version (git-version "3.4dev1" revision commit))

The version here is not correct, according to (info "(guix) Version
Numbers").  The version string of a git snapshot should be based on the
latest upstream version, which is still 3.3.  Since we're not bumping
the version the revision number needs to go up by one.

>        (source
>         (origin
>           (method git-fetch)
>           (uri (git-reference
> -               (url "https://ohwr.org/project/hdl-make")
> +               (url "https://gitlab.com/ohwr/project/hdl-make/")
>                 (commit commit)))
>           (file-name (git-file-name name version))
>           (sha256
> -          (base32 "08ivnhxyp44agmifqb4pjbxj23p43qqcg73s2y2z1hqk2six3fdx"))))
> +          (base32 "13d0zvpch0k758r2c2vq3vhd9nbydy01jnv2ddfvb6d3xpb4wzrj"))))
>        (build-system pyproject-build-system)
>        (arguments
>         `(#:tests? #f))
>        (native-inputs (list python-setuptools python-wheel))
>        (propagated-inputs (list python-six))
> -      (home-page "https://ohwr.org/projects/hdl-make")
> +      (home-page "https://gitlab.com/ohwr/project/hdl-make/")

LGTM.  Applied with the following fix-ups (I also enabled the tests):

--8<---------------cut here---------------start------------->8---
1 file changed, 7 insertions(+), 5 deletions(-)
gnu/packages/fpga.scm | 12 +++++++-----

modified   gnu/packages/fpga.scm
@@ -774,10 +774,10 @@ (define-public openfpgaloader
 
 (define-public python-hdlmake
   (let ((commit "9338e3e7a8784e63d16496a3fa8234d9e5aa7621")
-        (revision "0"))
+        (revision "1"))
     (package
       (name "python-hdlmake")
-      (version (git-version "3.4dev1" revision commit))
+      (version (git-version "3.3" revision commit))
       (source
        (origin
          (method git-fetch)
@@ -788,9 +788,11 @@ (define-public python-hdlmake
          (sha256
           (base32 "13d0zvpch0k758r2c2vq3vhd9nbydy01jnv2ddfvb6d3xpb4wzrj"))))
       (build-system pyproject-build-system)
-      (arguments
-       `(#:tests? #f))
-      (native-inputs (list python-setuptools python-wheel))
+      (arguments (list #:phases #~(modify-phases %standard-phases
+                                    (add-before 'check 'chdir
+                                      (lambda _
+                                        (chdir "testsuite"))))))
+      (native-inputs (list python-pytest python-setuptools python-wheel))
       (propagated-inputs (list python-six))
       (home-page "https://gitlab.com/ohwr/project/hdl-make/")
       (synopsis "Generate multi-purpose makefiles for HDL projects")

[back]
--8<---------------cut here---------------end--------------->8---
  
Cayetano Santos May 12, 2025, 1:17 p.m. UTC | #3
>lun. 12 mai 2025 at 21:52, Maxim Cournoyer <maxim.cournoyer@gmail.com> wrote:

>>  (define-public python-hdlmake
>> -  (let ((commit "3cb248fdad601c579b59fd7c194402871209bc54")
>> +  (let ((commit "9338e3e7a8784e63d16496a3fa8234d9e5aa7621")
>>          (revision "0"))
>>      (package
>>        (name "python-hdlmake")
>> -      (version (git-version "3.3" revision commit))
>> +      (version (git-version "3.4dev1" revision commit))
>
> The version here is not correct, according to (info "(guix) Version
> Numbers").  The version string of a git snapshot should be based on the
> latest upstream version, which is still 3.3.  Since we're not bumping
> the version the revision number needs to go up by one.

Once built and installed, ‘hdlmake --version’ returns "3.4dev1" as for
"hdlmake/_version.py", which is weird when one installs 3.3.

C.
  
Maxim Cournoyer May 13, 2025, 1:24 a.m. UTC | #4
Hi Cayetano,

Cayetano Santos <csantosb@inventati.org> writes:

>>lun. 12 mai 2025 at 21:52, Maxim Cournoyer <maxim.cournoyer@gmail.com> wrote:
>
>>>  (define-public python-hdlmake
>>> -  (let ((commit "3cb248fdad601c579b59fd7c194402871209bc54")
>>> +  (let ((commit "9338e3e7a8784e63d16496a3fa8234d9e5aa7621")
>>>          (revision "0"))
>>>      (package
>>>        (name "python-hdlmake")
>>> -      (version (git-version "3.3" revision commit))
>>> +      (version (git-version "3.4dev1" revision commit))
>>
>> The version here is not correct, according to (info "(guix) Version
>> Numbers").  The version string of a git snapshot should be based on the
>> latest upstream version, which is still 3.3.  Since we're not bumping
>> the version the revision number needs to go up by one.
>
> Once built and installed, ‘hdlmake --version’ returns "3.4dev1" as for
> "hdlmake/_version.py", which is weird when one installs 3.3.

I see.  We could always use 3.4dev1 and add a comment telling the next
person updating it where it comes from, e.g.

;; The git snapshot base version is taken from the 'hdlmake/_version.py'
;; source.

It's a small thing though.  I personally wouldn't bother.
  

Patch

diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm
index 2298dde595..e2a0b19a7d 100644
--- a/gnu/packages/fpga.scm
+++ b/gnu/packages/fpga.scm
@@ -776,26 +776,26 @@  (define-public openfpgaloader
     (license license:asl2.0)))
 
 (define-public python-hdlmake
-  (let ((commit "3cb248fdad601c579b59fd7c194402871209bc54")
+  (let ((commit "9338e3e7a8784e63d16496a3fa8234d9e5aa7621")
         (revision "0"))
     (package
       (name "python-hdlmake")
-      (version (git-version "3.3" revision commit))
+      (version (git-version "3.4dev1" revision commit))
       (source
        (origin
          (method git-fetch)
          (uri (git-reference
-               (url "https://ohwr.org/project/hdl-make")
+               (url "https://gitlab.com/ohwr/project/hdl-make/")
                (commit commit)))
          (file-name (git-file-name name version))
          (sha256
-          (base32 "08ivnhxyp44agmifqb4pjbxj23p43qqcg73s2y2z1hqk2six3fdx"))))
+          (base32 "13d0zvpch0k758r2c2vq3vhd9nbydy01jnv2ddfvb6d3xpb4wzrj"))))
       (build-system pyproject-build-system)
       (arguments
        `(#:tests? #f))
       (native-inputs (list python-setuptools python-wheel))
       (propagated-inputs (list python-six))
-      (home-page "https://ohwr.org/projects/hdl-make")
+      (home-page "https://gitlab.com/ohwr/project/hdl-make/")
       (synopsis "Generate multi-purpose makefiles for HDL projects")
       (description
        "Hdlmake helps manage and share @acronym{HDL, hardware description