From 8da6dfb0bbb00c330bfa053741f5a58b66219463 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Tue, 14 Dec 2021 20:10:48 +0100 Subject: gnu: libgit2: Allow cross-compilation. With commit 8394619baceb118df92e355377fd543bb1aa501a, the label for 'pkg-config' when cross-compiling changed to "TRIPLET-pkg-config", thereby breaking the 'assoc-ref' call. This commit fixes it by avoiding referring to the label. * gnu/packages/version-control.scm (libgit2)[arguments]: Adjust "-DPKG_CONFIG_EXECUTABLE=" option. --- gnu/packages/version-control.scm | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm index d7ea61e5fb..bc999bf3dc 100644 --- a/gnu/packages/version-control.scm +++ b/gnu/packages/version-control.scm @@ -811,8 +811,10 @@ (define-public libgit2 ,@(if (%current-target-system) `((string-append "-DPKG_CONFIG_EXECUTABLE=" - (assoc-ref %build-inputs "pkg-config") - "/bin/" ,(%current-target-system) "-pkg-config")) + (search-input-file + %build-inputs + (string-append "/bin/" ,(%current-target-system) + "-pkg-config")))) '())) #:phases (modify-phases %standard-phases -- cgit v1.2.3