From 058d0251bd14fdbb06ce223bbecc8eb1a0d74382 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= <ludo@gnu.org>
Date: Tue, 7 Jan 2020 11:45:56 +0100
Subject: [PATCH] download, git: Refer to the right module in 'module-use!'
 call.

This fixes a regression introduced in
6a7c4636d4dec47eefa03c95da5a1315bd0e0413.

* guix/build/download.scm (load-gnutls): Call 'resolve-module' instead
of 'current-module'.
* guix/git.scm (load-git-submodules): Likewise.
---
 guix/build/download.scm | 3 ++-
 guix/git.scm            | 2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/guix/build/download.scm b/guix/build/download.scm
index 641dacefa1f..0f2d5f402af 100644
--- a/guix/build/download.scm
+++ b/guix/build/download.scm
@@ -158,7 +158,8 @@ (define* (ftp-fetch uri file #:key timeout print-build-trace?)
 (define (load-gnutls)
   ;; XXX: Use this hack instead of #:autoload to avoid compilation errors.
   ;; See <http://bugs.gnu.org/12202>.
-  (module-use! (current-module) (resolve-interface '(gnutls)))
+  (module-use! (resolve-module '(guix build download))
+               (resolve-interface '(gnutls)))
   (set! load-gnutls (const #t)))
 
 (define %x509-certificate-directory
diff --git a/guix/git.scm b/guix/git.scm
index 15a0a6f9e5c..a12f1eec8ea 100644
--- a/guix/git.scm
+++ b/guix/git.scm
@@ -203,7 +203,7 @@ (define (load-git-submodules)
      (set! load-git-submodules (const #f))
      #f)
     (iface
-     (module-use! (current-module) iface)
+     (module-use! (resolve-module '(guix git)) iface)
      (set! load-git-submodules (const #t))
      #t)))
 
-- 
GitLab