diff mbox series

[bug#39599,4/4] gnu: net-base: Use copy build system.

Message ID 20200217111228.23716-4-mail@ambrevar.xyz
State Accepted
Headers show
Series New build system: copy-build-system | expand

Checks

Context Check Description
cbaines/comparison success View comparision
cbaines/git branch success View Git branch
cbaines/applying patch success View Laminar job

Commit Message

Pierre Neidhardt Feb. 17, 2020, 11:12 a.m. UTC
* gnu/packages/admin.scm (net-base)[build-system]: Use copy-build-system.
---
 gnu/packages/admin.scm | 29 ++++++-----------------------
 1 file changed, 6 insertions(+), 23 deletions(-)
diff mbox series

Patch

diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm
index 4780fe124e..1f384edb2c 100644
--- a/gnu/packages/admin.scm
+++ b/gnu/packages/admin.scm
@@ -54,6 +54,7 @@ 
   #:use-module (guix download)
   #:use-module (guix git-download)
   #:use-module (guix build-system cmake)
+  #:use-module (guix build-system copy)
   #:use-module (guix build-system emacs)
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system meson)
@@ -566,30 +567,12 @@  to allow automatic login and starting any app.")
              (sha256
               (base32
                "12xqjwg3p4rzmmh2iib6sigm9l29y3dgk74mmnw64k84jnbwdxl1"))))
-    (build-system trivial-build-system)
+    (build-system copy-build-system)
     (arguments
-     `(#:modules ((guix build utils))
-       #:builder (begin
-                   (use-modules (guix build utils)
-                                (srfi srfi-26))
-
-                   (let* ((source (assoc-ref %build-inputs "source"))
-                          (tar    (assoc-ref %build-inputs "tar"))
-                          (xz     (assoc-ref %build-inputs "xz"))
-                          (output (assoc-ref %outputs "out"))
-                          (etc    (string-append output "/etc")))
-                     (setenv "PATH" (string-append xz "/bin"))
-                     (invoke (string-append tar "/bin/tar") "xvf"
-                             source)
-                     (chdir ,(string-append "netbase-" version))
-                     (mkdir-p etc)
-                     (for-each copy-file
-                               '("etc-services" "etc-protocols" "etc-rpc")
-                               (map (cut string-append etc "/" <>)
-                                    '("services" "protocols" "rpc")))
-                     #t))))
-    (native-inputs `(("tar" ,tar)
-                     ("xz" ,xz)))
+     `(#:install-plan
+       `(("etc-services" "etc/services")
+         ("etc-protocols" "etc/protocols")
+         ("etc-rpc" "etc/rpc"))))
     (synopsis "IANA protocol, port, and RPC number assignments")
     (description
      "This package provides the /etc/services, /etc/protocols, and /etc/rpc