me
/
guix
Archived
1
0
Fork 0

gnu: libffi: Inline all patches.

* gnu/packages/libffi.scm (libffi)[source]: Add patch.
[arguments]: Remove custom patch phases.
[inputs]: Remove field.
master
Efraim Flashner 2021-03-15 11:40:45 +02:00
parent 0ca7e19093
commit 9562d50d8e
No known key found for this signature in database
GPG Key ID: 41AAE7DCCA3D8351
1 changed files with 5 additions and 36 deletions

View File

@ -2,7 +2,7 @@
;;; Copyright © 2012, 2013, 2014, 2020 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2014 Federico Beffa <beffa@fbengineering.ch>
;;; Copyright © 2015, 2019 Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
;;; Copyright © 2016, 2017, 2020 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2016, 2017, 2020, 2021 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2016, 2017 Ben Woodcroft <donttrustben@gmail.com>
;;; Copyright © 2017, 2019, 2020 Marius Bakke <marius@gnu.org>
;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
@ -52,45 +52,14 @@
(sha256
(base32
"0mi0cpf8aa40ljjmzxb7im6dbj45bb0kllcd09xgmp834y9agyvj"))
(patches (search-patches "libffi-3.3-powerpc-fixes.patch"))))
(patches (search-patches "libffi-3.3-powerpc-fixes.patch"
"libffi-float128-powerpc64le.patch"))))
(build-system gnu-build-system)
(arguments
`(;; Prevent the build system from passing -march and -mtune to the
;; compiler. See "ax_cc_maxopt.m4" and "ax_gcc_archflag.m4".
#:configure-flags '("--enable-portable-binary" "--without-gcc-arch")
;; TODO: Inline patches on next rebuild cycle.
,@(if (string-prefix? "powerpc-" (or (%current-target-system)
(%current-system)))
'(#:phases (modify-phases %standard-phases
(add-after 'unpack 'apply-patch
(lambda* (#:key inputs #:allow-other-keys)
(let ((patch (assoc-ref inputs
"powerpc-patch")))
(invoke "patch" "--force" "-p1"
"-i" patch))))))
'())
,@(if (string-prefix? "powerpc64le-" (or (%current-target-system)
(%current-system)))
'(#:phases (modify-phases %standard-phases
(add-after 'unpack 'apply-patch2
(lambda* (#:key inputs #:allow-other-keys)
(let ((patch (assoc-ref inputs
"powerpc64le-patch")))
(invoke "patch" "--force" "-p1"
"-i" patch))))))
'())))
(inputs
(cond
((string-prefix? "powerpc-" (or (%current-target-system)
(%current-system)))
`(("powerpc-patch" ,@(search-patches
"libffi-3.3-powerpc-fixes.patch"))))
((string-prefix? "powerpc64le-" (or (%current-target-system)
(%current-system)))
`(("powerpc64le-patch" ,@(search-patches
"libffi-float128-powerpc64le.patch"))))
(else '())))
#:configure-flags '("--enable-portable-binary"
"--without-gcc-arch")))
(outputs '("out" "debug"))
(synopsis "Foreign function call interface library")
(description