gnu: crypto++: Update to 8.0.0.

* gnu/packages/crypto.scm (crypto++): Update to 8.0.0.
[arguments]: Build shared library.
[arguments]: Generate .pc file.
This commit is contained in:
Pierre Neidhardt 2019-01-09 21:11:41 +01:00
parent 8b0c174415
commit 35ac66eec1
No known key found for this signature in database
GPG Key ID: 9BDCF497A4BBCC7F
1 changed files with 28 additions and 4 deletions

View File

@ -632,7 +632,7 @@ data on your platform, so the seed itself will be as random as possible.
(define-public crypto++ (define-public crypto++
(package (package
(name "crypto++") (name "crypto++")
(version "6.0.0") (version "8.0.0")
(source (origin (source (origin
(method url-fetch/zipbomb) (method url-fetch/zipbomb)
(uri (string-append "https://cryptopp.com/cryptopp" (uri (string-append "https://cryptopp.com/cryptopp"
@ -640,11 +640,14 @@ data on your platform, so the seed itself will be as random as possible.
".zip")) ".zip"))
(sha256 (sha256
(base32 (base32
"1nidm6xbdza5cbgf5md2zznmaq692rfyjasycwipl6rzdfwjvb34")))) "0b5qrsm4jhy4nzxgrm13nixhvbswr242plx1jw6r4sw492rqkzdv"))))
(build-system gnu-build-system) (build-system gnu-build-system)
(arguments (arguments
`(#:make-flags `(#:make-flags
(list (string-append "PREFIX=" (assoc-ref %outputs "out"))) (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
;; Override "/sbin/ldconfig" with simply "echo" since
;; we don't need ldconfig(8).
"LDCONF=echo")
#:phases #:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(add-after 'unpack 'disable-native-optimisation (add-after 'unpack 'disable-native-optimisation
@ -654,7 +657,28 @@ data on your platform, so the seed itself will be as random as possible.
(substitute* "GNUmakefile" (substitute* "GNUmakefile"
((" -march=native") "")) ((" -march=native") ""))
#t)) #t))
(delete 'configure)))) (delete 'configure)
(add-after 'build 'build-shared
(lambda _
;; By default, only the static library is built.
(invoke "make" "shared")))
(add-after 'install 'install-pkg-config
(lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))
(pkg-dir (string-append out "/lib/pkgconfig")))
(mkdir-p pkg-dir)
(with-output-to-file (string-append pkg-dir "/libcrypto++.pc")
(lambda _
(display
(string-append
"prefix=" out "\n"
"libdir=" out "/lib\n"
"includedir=" out "/include\n\n"
"Name: libcrypto++-" ,version "\n"
"Description: Class library of cryptographic schemes"
"Version: " ,version "\n"
"Libs: -L${libdir} -lcryptopp\n"
"Cflags: -I${includedir}\n"))))))))))
(native-inputs (native-inputs
`(("unzip" ,unzip))) `(("unzip" ,unzip)))
(home-page "https://cryptopp.com/") (home-page "https://cryptopp.com/")