diff options
| author | Efraim Flashner <efraim@flashner.co.il> | 2020-11-16 11:05:21 +0200 |
|---|---|---|
| committer | Efraim Flashner <efraim@flashner.co.il> | 2020-11-16 11:16:11 +0200 |
| commit | cbd104bf6fe9c66db6173952f42db8efe48cf39f (patch) | |
| tree | 2d786364f9415acbde0e1d8f86acdf7d50cea787 /gnu | |
| parent | d4560e0b7b518e749ea2089b3a76e8d033b45784 (diff) | |
gnu: nnn: Cross compile.
* gnu/packages/admin.scm (nnn)[arguments]: Use cc-for-target in
make-flags. Add custom phase to use correct pkg-config for target.
Diffstat (limited to 'gnu')
| -rw-r--r-- | gnu/packages/admin.scm | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm index e5f990f7ab9..e6223681997 100644 --- a/gnu/packages/admin.scm +++ b/gnu/packages/admin.scm | |||
| @@ -3382,15 +3382,23 @@ information tool.") | |||
| 3382 | (native-inputs | 3382 | (native-inputs |
| 3383 | `(("pkg-config" ,pkg-config))) | 3383 | `(("pkg-config" ,pkg-config))) |
| 3384 | (arguments | 3384 | (arguments |
| 3385 | '(#:tests? #f ; no tests | 3385 | `(#:tests? #f ; no tests |
| 3386 | #:phases | 3386 | #:phases |
| 3387 | (modify-phases %standard-phases | 3387 | (modify-phases %standard-phases |
| 3388 | (delete 'configure)) ; no configure script | 3388 | (delete 'configure) ; no configure script |
| 3389 | (add-after 'unpack 'patch-pkg-config | ||
| 3390 | (lambda _ | ||
| 3391 | (substitute* "Makefile" | ||
| 3392 | (("pkg-config") | ||
| 3393 | (or (which "pkg-config") | ||
| 3394 | (string-append ,(%current-target-system) | ||
| 3395 | "-pkg-config")))) | ||
| 3396 | #t))) | ||
| 3389 | #:make-flags | 3397 | #:make-flags |
| 3390 | (list | 3398 | (list |
| 3391 | (string-append "PREFIX=" | 3399 | (string-append "PREFIX=" |
| 3392 | (assoc-ref %outputs "out")) | 3400 | (assoc-ref %outputs "out")) |
| 3393 | "CC=gcc"))) | 3401 | (string-append "CC=" ,(cc-for-target))))) |
| 3394 | (home-page "https://github.com/jarun/nnn") | 3402 | (home-page "https://github.com/jarun/nnn") |
| 3395 | (synopsis "Terminal file browser") | 3403 | (synopsis "Terminal file browser") |
| 3396 | (description "@command{nnn} is a fork of @command{noice}, a blazing-fast | 3404 | (description "@command{nnn} is a fork of @command{noice}, a blazing-fast |
