diff options
| author | Efraim Flashner <efraim@flashner.co.il> | 2020-08-30 14:15:07 +0300 |
|---|---|---|
| committer | Efraim Flashner <efraim@flashner.co.il> | 2020-08-30 14:15:07 +0300 |
| commit | ab15bbea60413c8a2e7900a98b22c46adade34fb (patch) | |
| tree | adf7e36b33d687c9ef50e7216b7f75e79b3fa2f6 /gnu/packages/datastructures.scm | |
| parent | d9bba529fca41dcb36735121c2dc3d68dd4ffacb (diff) | |
gnu: sdsl-lite: Install pkgconfig file.
* gnu/packages/datastructures.scm (sdsl-lite)[arguments]: Add custom
'install-pkgconfig-file phase to install sdsl-lite.pc.
Diffstat (limited to 'gnu/packages/datastructures.scm')
| -rw-r--r-- | gnu/packages/datastructures.scm | 26 |
1 files changed, 23 insertions, 3 deletions
diff --git a/gnu/packages/datastructures.scm b/gnu/packages/datastructures.scm index a9f30831ecf..6121d633252 100644 --- a/gnu/packages/datastructures.scm +++ b/gnu/packages/datastructures.scm | |||
| @@ -2,7 +2,7 @@ | |||
| 2 | ;;; Copyright © 2015, 2016, 2018, 2019 Ricardo Wurmus <rekado@elephly.net> | 2 | ;;; Copyright © 2015, 2016, 2018, 2019 Ricardo Wurmus <rekado@elephly.net> |
| 3 | ;;; Copyright © 2016, 2017, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr> | 3 | ;;; Copyright © 2016, 2017, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr> |
| 4 | ;;; Copyright © 2018 Meiyo Peng <meiyo.peng@gmail.com> | 4 | ;;; Copyright © 2018 Meiyo Peng <meiyo.peng@gmail.com> |
| 5 | ;;; Copyright © 2019 Efraim Flashner <efraim@flashner.co.il> | 5 | ;;; Copyright © 2019, 2020 Efraim Flashner <efraim@flashner.co.il> |
| 6 | ;;; Copyright © 2020 Mark H Weaver <mhw@netris.org> | 6 | ;;; Copyright © 2020 Mark H Weaver <mhw@netris.org> |
| 7 | ;;; | 7 | ;;; |
| 8 | ;;; This file is part of GNU Guix. | 8 | ;;; This file is part of GNU Guix. |
| @@ -236,14 +236,34 @@ to the structure and choosing one or more fields to act as the key.") | |||
| 236 | "0m542xpys54bni29zibgrfpgpd0zgyny4h131virxsanixsbz52z"))))))) | 236 | "0m542xpys54bni29zibgrfpgpd0zgyny4h131virxsanixsbz52z"))))))) |
| 237 | (build-system cmake-build-system) | 237 | (build-system cmake-build-system) |
| 238 | (arguments | 238 | (arguments |
| 239 | '(#:phases | 239 | `(#:phases |
| 240 | (modify-phases %standard-phases | 240 | (modify-phases %standard-phases |
| 241 | (add-after 'install 'install-static-library | 241 | (add-after 'install 'install-static-library |
| 242 | (lambda* (#:key outputs #:allow-other-keys) | 242 | (lambda* (#:key outputs #:allow-other-keys) |
| 243 | (let ((out (assoc-ref outputs "out"))) | 243 | (let ((out (assoc-ref outputs "out"))) |
| 244 | (copy-file "lib/libsdsl_static.a" | 244 | (copy-file "lib/libsdsl_static.a" |
| 245 | (string-append out "/lib/libsdsl.a"))) | 245 | (string-append out "/lib/libsdsl.a"))) |
| 246 | #t))))) | 246 | #t)) |
| 247 | (add-after 'install 'install-pkgconfig-file | ||
| 248 | (lambda* (#:key outputs #:allow-other-keys) | ||
| 249 | (let ((out (assoc-ref outputs "out")) | ||
| 250 | (lib (string-append out "/lib"))) | ||
| 251 | (mkdir-p (string-append lib "/pkgconfig")) | ||
| 252 | (with-output-to-file (string-append lib "/pkgconfig/sdsl-lite.pc") | ||
| 253 | (lambda _ | ||
| 254 | (format #t "prefix=~a~@ | ||
| 255 | exec_prefix=${prefix}~@ | ||
| 256 | libdir=${exec_prefix}/lib~@ | ||
| 257 | includedir=${prefix}/include~@ | ||
| 258 | ~@ | ||
| 259 | ~@ | ||
| 260 | Name: sdsl~@ | ||
| 261 | Version: ~a~@ | ||
| 262 | Description: SDSL: Succinct Data Structure Library~@ | ||
| 263 | Libs: -L${libdir} -lsdsl -ldivsufsort -ldivsufsort64~@ | ||
| 264 | Cflags: -I${includedir}~%" | ||
| 265 | out ,version))) | ||
| 266 | #t)))))) | ||
| 247 | (native-inputs | 267 | (native-inputs |
| 248 | `(("libdivsufsort" ,libdivsufsort))) | 268 | `(("libdivsufsort" ,libdivsufsort))) |
| 249 | (home-page "https://github.com/simongog/sdsl-lite") | 269 | (home-page "https://github.com/simongog/sdsl-lite") |
