summaryrefslogtreecommitdiff
path: root/var/spack/repos/builtin/packages/xxd-standalone/package.py
diff options
context:
space:
mode:
Diffstat (limited to 'var/spack/repos/builtin/packages/xxd-standalone/package.py')
-rw-r--r--var/spack/repos/builtin/packages/xxd-standalone/package.py27
1 files changed, 27 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/xxd-standalone/package.py b/var/spack/repos/builtin/packages/xxd-standalone/package.py
new file mode 100644
index 0000000000..bce886a193
--- /dev/null
+++ b/var/spack/repos/builtin/packages/xxd-standalone/package.py
@@ -0,0 +1,27 @@
+# Copyright 2013-2021 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 *
+import os
+
+
+class XxdStandalone(MakefilePackage):
+ """xxd creates a hex dump of a given file or standard input.
+ It is bundled with vim, but as xxd is used in build scripts,
+ it makes sense to have it available as a standalone package."""
+
+ homepage = "https://www.vim.org/"
+ url = "https://github.com/vim/vim/archive/v8.2.1201.tar.gz"
+
+ maintainers = ['haampie']
+ build_targets = ['-C', os.path.join('src', 'xxd')]
+
+ provides('xxd')
+
+ version('8.2.1201', sha256='39032fe866f44724b104468038dc9ac4ff2c00a4b18c9a1e2c27064ab1f1143d')
+
+ def install(self, spec, prefix):
+ mkdirp(prefix.bin)
+ install(os.path.join(self.build_directory, 'src', 'xxd', 'xxd'), prefix.bin)