summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordarmac <darmac@163.com>2019-12-18 04:29:56 +0800
committerAdam J. Stewart <ajstewart426@gmail.com>2019-12-17 14:29:56 -0600
commit6a0d15a5c9148065fd6460306c5483d99177ff9b (patch)
treec4ee7d29d7c9d824903c1a3bfb4fb2a37516c58c
parentdc69256a5981c2d3ed65084580bef105c57361fd (diff)
downloadspack-6a0d15a5c9148065fd6460306c5483d99177ff9b.tar.gz
spack-6a0d15a5c9148065fd6460306c5483d99177ff9b.tar.bz2
spack-6a0d15a5c9148065fd6460306c5483d99177ff9b.tar.xz
spack-6a0d15a5c9148065fd6460306c5483d99177ff9b.zip
add new package : nicstat (#14173)
* add new package : nicstat * refine nicstat edit operation * refine CMODEL regex expression
-rw-r--r--var/spack/repos/builtin/packages/nicstat/package.py27
1 files changed, 27 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/nicstat/package.py b/var/spack/repos/builtin/packages/nicstat/package.py
new file mode 100644
index 0000000000..57bb609856
--- /dev/null
+++ b/var/spack/repos/builtin/packages/nicstat/package.py
@@ -0,0 +1,27 @@
+# Copyright 2013-2019 Lawrence Livermore National Security, LLC and other
+# Spack Project Developers. See the top-level COPYRIGHT file for details.
+#
+# SPDX-License-Identifier: (Apache-2.0 OR MIT)
+
+from spack import *
+
+
+class Nicstat(MakefilePackage):
+ """
+ Nicstat is a Solaris and Linux command-line that prints out network
+ statistics for all network interface cards (NICs), including packets,
+ kilobytes per second, average packet sizes and more.
+ """
+
+ homepage = "https://github.com/scotte/nicstat"
+ url = "https://jaist.dl.sourceforge.net/project/nicstat/nicstat-1.95.tar.gz"
+
+ version('1.95', sha256='c4cc33f8838f4523f27c3d7584eedbe59f4c587f0821612f5ac2201adc18b367')
+
+ def edit(self, spec, prefix):
+ copy('Makefile.Linux', 'makefile')
+ filter_file(r'CMODEL =\s+-m32', '', 'makefile')
+ filter_file('sudo', '', 'makefile', string=True)
+
+ def install(self, spec, prefix):
+ install_tree(".", prefix)