File bandwidth.spec of Package bandwidth

# spec file for package bandwidth
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via

Name:           bandwidth
Version:        1.9.3
Release:        0
Summary:        Memory and network benchmark program
License:        GPL-2.0-only
Group:          System/Benchmark
BuildRequires:  nasm
ExclusiveArch:  %{ix86} x86_64

bandwidth is an artificial benchmark primarily for measuring memory bandwidth
on x86 and x86_64 based computers, useful for identifying weaknesses in a
computer's memory subsystem, in the bus architecture, in the cache architecture
and in the processor itself.

%setup -q

# currently fails with No rule to make target 'routines-arm-32bit.asm', needed by 'bandwidth-arm32'
%ifarch %arm
make %{?_smp_mflags} bandwidth-arm32

%ifarch %{ix86}
make %{?_smp_mflags} bandwidth32 CFLAGS="%{optflags}"
mv bandwidth32 %{name}

%ifarch x86_64
make %{?_smp_mflags} bandwidth64 CFLAGS="%{optflags}"
mv bandwidth64 %{name}

install -Dsm 755 %{name} %{buildroot}/%{_bindir}/%{name}

%license GPL.txt
%doc README.txt

openSUSE Build Service is sponsored by