Subject: [bug#78404] [PATCH 3/4] gnu: Build go-ulid with go-module-build system

From: Jørgen Kvalsvik <[email-masked]>
Date: Thu, 15 May 2025 10:16:34 +0200

* gnu/packages/golang-xyz.scm (go-ulid): Use go-module-build-system.

Change-Id: I4ee3ae8cdb5a17df1478aeef555ad8d6fcdbf437
---
 gnu/packages/golang-xyz.scm | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/golang-xyz.scm b/gnu/packages/golang-xyz.scm
index 21d2b05abc..bcf758e8fe 100644
--- a/gnu/packages/golang-xyz.scm
+++ b/gnu/packages/golang-xyz.scm
@@ -79,9 +79,11 @@
 (define-module (gnu packages golang-xyz)
   #:use-module ((guix licenses) #:prefix license:)
   #:use-module (guix build-system go)
+  #:use-module (guix build-system go-module)
   #:use-module (guix build-system copy)
   #:use-module (guix gexp)
   #:use-module (guix git-download)
+  #:use-module (guix go-mod-download)
   #:use-module (guix packages)
   #:use-module (guix utils)
   #:use-module (gnu packages)
@@ -18217,11 +18219,13 @@ (define-public go-tomlv
 (define-public go-ulid
   (package/inherit go-github-com-oklog-ulid-v2
     (name "go-ulid")
+    (build-system go-module-build-system)
     (arguments
      (list
       #:install-source? #f
-      #:import-path "github.com/oklog/ulid/v2/cmd/ulid"
-      #:unpack-path "github.com/oklog/ulid/v2"))
+      #:install-cache? #f
+      #:build-targets '()
+      #:install-targets '("./cmd/ulid")))
     (description
      (string-append (package-description go-github-com-oklog-ulid-v2)
                     "\nThis package provides a command line interface (CLI)
-- 
2.39.5