aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/benchmark.scm
diff options
context:
space:
mode:
authorMaxim Cournoyer <maxim.cournoyer@gmail.com>2022-06-19 01:32:11 -0400
committerMaxim Cournoyer <maxim.cournoyer@gmail.com>2022-06-22 10:48:37 -0400
commit92121b8e9db9541b0fdf0e6e0b17e28e03a01277 (patch)
tree86203d8e5ecbdf242c33419bbd520c1ad3a00960 /gnu/packages/benchmark.scm
parente74fa406e1043547242a8b67ab9907fea7aae6b9 (diff)
downloadguix-92121b8e9db9541b0fdf0e6e0b17e28e03a01277.tar
guix-92121b8e9db9541b0fdf0e6e0b17e28e03a01277.tar.gz
gnu: Add phoronix-test-suite.
* gnu/packages/patches/phoronix-test-suite-fsdg.patch: New file. * gnu/local.mk (dist_patch_DATA): Register it. * gnu/packages/benchmark.scm (phoronix-test-suite): New variable. (gcc-toolchain*): Likewise.
Diffstat (limited to 'gnu/packages/benchmark.scm')
-rw-r--r--gnu/packages/benchmark.scm62
1 files changed, 61 insertions, 1 deletions
diff --git a/gnu/packages/benchmark.scm b/gnu/packages/benchmark.scm
index b167c6de6e..b718a65f7c 100644
--- a/gnu/packages/benchmark.scm
+++ b/gnu/packages/benchmark.scm
@@ -39,18 +39,20 @@
#:use-module (gnu packages)
#:use-module (gnu packages autotools)
#:use-module (gnu packages base)
+ #:use-module (gnu packages bash)
#:use-module (gnu packages c)
#:use-module (gnu packages check)
#:use-module (gnu packages compression)
- #:use-module (gnu packages kde-frameworks)
#:use-module (gnu packages databases)
#:use-module (gnu packages docbook)
+ #:use-module (gnu packages kde-frameworks)
#:use-module (gnu packages linux)
#:use-module (gnu packages lua)
#:use-module (gnu packages maths)
#:use-module (gnu packages mpi)
#:use-module (gnu packages opencl)
#:use-module (gnu packages perl)
+ #:use-module (gnu packages php)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages python)
#:use-module (gnu packages python-science)
@@ -60,6 +62,11 @@
#:use-module (gnu packages xml)
#:use-module (ice-9 match))
+;; Lazily resolve the gcc-toolchain to avoid a circular dependency.
+(define gcc-toolchain*
+ (delay (module-ref (resolve-interface '(gnu packages commencement))
+ 'gcc-toolchain)))
+
(define-public fio
(package
(name "fio")
@@ -263,6 +270,59 @@ speed, the number of seeks that can be performed per second, and the number of
file metadata operations that can be performed per second.")
(license license:gpl2))) ;GPL 2 only, see copyright.txt
+(define-public phoronix-test-suite
+ (package
+ (name "phoronix-test-suite")
+ (version "10.8.3")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append "https://phoronix-test-suite.com/releases/"
+ name "-" version ".tar.gz"))
+ (sha256
+ (base32
+ "105shk78jy46nwj6vnlmgp3y3lv9klar3dmcgasy4bslm4l2wx2b"))
+ (patches (search-patches "phoronix-test-suite-fsdg.patch"))))
+ (arguments
+ (list
+ #:tests? #f ;no test suite
+ #:phases
+ #~(modify-phases %standard-phases
+ (delete 'configure)
+ (delete 'build)
+ (replace 'install
+ (lambda _
+ (invoke "./install-sh" #$output "--free-software-only")))
+ (add-after 'install 'wrap-binary
+ (lambda* (#:key inputs #:allow-other-keys)
+ (let ((pts (string-append #$output "/bin/phoronix-test-suite")))
+ (wrap-program pts
+ (list "PATH" 'prefix
+ (map (lambda (binary)
+ (dirname (search-input-file
+ inputs (string-append "bin/" binary))))
+ '("bash" "cat" ;coreutils
+ "gzip" "make" "php" "sed" "tar" "which"))))))))))
+ (build-system gnu-build-system)
+ (native-inputs (list python which))
+ ;; Wrap the most basic build tools needed by Phoronix Test Suite to build
+ ;; simple tests such as 'fio'.
+ (inputs (list bash coreutils gnu-make gzip php sed tar which))
+ ;; Phoronix Test Suite builds and caches the benchmarking tools itself;
+ ;; the user is required to manually install extra libraries depending on
+ ;; the selected test; but at least a working C/C++ toolchain is assumed to
+ ;; be available.
+ (propagated-inputs (list (force gcc-toolchain*)))
+ (home-page "https://www.phoronix-test-suite.com/")
+ (synopsis "Automated testing/benchmarking software")
+ (description
+ "The Phoronix Test Suite is a comprehensive testing and benchmarking platform
+that provides an extensible framework for which new tests can be easily added.
+It can carry out both qualitative and quantitative benchmarks in a clean,
+reproducible, and easy-to-use manner, making it easy to compare one particular
+setup against another one.")
+ (license license:gpl3+)))
+
(define-public python-locust
(package
(name "python-locust")