Files
haikuports/app-benchmarks/stress-ng/stress_ng-0.18.06.recipe
2024-11-07 11:52:31 +01:00

97 lines
3.0 KiB
Bash

SUMMARY="Stress test a computer system in various selectable ways"
DESCRIPTION="stress-ng will stress test a computer system in various \
selectable ways. It was designed to exercise various physical subsystems of a \
computer as well as the various operating system kernel interfaces.
Stress-ng features:
* Over 240 stress tests
* 78 CPU specific stress tests that exercise floating point, integer, bit \
manipulation and control flow
* Over 20 virtual memory stress tests
stress-ng was originally intended to make a machine work hard and trip \
hardware issues such as thermal overruns as well as operating system bugs \
that only occur when a system is being thrashed hard. Use stress-ng with \
caution as some of the tests can make a system run hot on poorly designed \
hardware and also can cause excessive system thrashing which may be difficult \
to stop.
stress-ng can also measure test throughput rates; this can be useful to \
observe performance changes across different operating system releases or \
types of hardware. However, it has never been intended to be used as a \
precise benchmark test suite, so do NOT use it in this manner.
Running stress-ng with root privileges will adjust out of memory settings on \
Linux systems to make the stressors unkillable in low memory situations, so \
use this judiciously. With the apropriate privilege, stress-ng can allow the \
ionice class and ionice levels to be adjusted, again, this should be used \
with care.
One can specify the number of processes to invoke per type of stress test; \
specifying a negative or zero value will select the number of online \
processors as defined by sysconf(_SC_NPROCESSORS_ONLN)."
HOMEPAGE="https://kernel.ubuntu.com/~cking/stress-ng/"
COPYRIGHT="2013-2021 Colin Ian King"
LICENSE="GNU GPL v2"
REVISION="1"
SOURCE_URI="https://github.com/ColinIanKing/stress-ng/archive/V$portVersion.zip"
CHECKSUM_SHA256="0f8c60a4d988fc23c3982c9d60753a92d7e16115aac7a5122688446f4aa83e4f"
SOURCE_DIR="stress-ng-$portVersion"
if [ $effectiveTargetArchitecture = x86 ]; then
PATCHES+="
stress_ng_x86-$portVersion.patchset
"
fi
ARCHITECTURES="all !x86_gcc2"
SECONDARY_ARCHITECTURES="x86"
PROVIDES="
stress_ng$secondaryArchSuffix = $portVersion
cmd:stress_ng = $portVersion
"
REQUIRES="
haiku$secondaryArchSuffix
lib:libatomic$secondaryArchSuffix
lib:libz$secondaryArchSuffix
"
BUILD_REQUIRES="
haiku${secondaryArchSuffix}_devel
devel:libssp_nonshared$secondaryArchSuffix
devel:libz$secondaryArchSuffix
"
BUILD_PREREQUIRES="
cmd:awk
cmd:gcc$secondaryArchSuffix
cmd:make
cmd:which
"
BUILD()
{
touch config
make -f Makefile.config
make $jobArgs
}
INSTALL()
{
mkdir -p $prefix/bin
cp stress-ng $prefix/bin/
install -m 755 -d $dataDir/bash-completion/completions
install -m 644 bash-completion/stress-ng $dataDir/bash-completion/completions/stress-ng
}
TEST()
{
# use lite-test for quick test, the others take up a long time to finish
# slow-test-all
# verify-test-all
# chmod +x debian/tests/fast-test-all
chmod +x debian/tests/lite-test
# make fast-test-all
make lite-test
}