summaryrefslogtreecommitdiff
path: root/var
diff options
context:
space:
mode:
authorBitllion <39736583+Bitllion@users.noreply.github.com>2022-06-08 01:11:14 +0800
committerGitHub <noreply@github.com>2022-06-07 10:11:14 -0700
commitadf073b53ccd9d1c49ef2ab034f3c38e3c751334 (patch)
tree916bc5da22700ad71b086eb226d196ade25b5094 /var
parent449e885d4cb616de0118262709b03c1c59d3d887 (diff)
downloadspack-adf073b53ccd9d1c49ef2ab034f3c38e3c751334.tar.gz
spack-adf073b53ccd9d1c49ef2ab034f3c38e3c751334.tar.bz2
spack-adf073b53ccd9d1c49ef2ab034f3c38e3c751334.tar.xz
spack-adf073b53ccd9d1c49ef2ab034f3c38e3c751334.zip
Add New Package:PSCMC (#30944)
* add some new version of abacus and fix bug on mkl * Add Package:PSCMC * update maintainer * rebase * update maintainers * Update var/spack/repos/builtin/packages/pscmc/package.py Co-authored-by: Tamara Dahlgren <35777542+tldahlgren@users.noreply.github.com> Co-authored-by: Tamara Dahlgren <35777542+tldahlgren@users.noreply.github.com>
Diffstat (limited to 'var')
-rw-r--r--var/spack/repos/builtin/packages/pscmc/package.py42
1 files changed, 42 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/pscmc/package.py b/var/spack/repos/builtin/packages/pscmc/package.py
new file mode 100644
index 0000000000..9de06aa89c
--- /dev/null
+++ b/var/spack/repos/builtin/packages/pscmc/package.py
@@ -0,0 +1,42 @@
+# Copyright 2013-2022 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)
+
+
+import os
+
+from spack.package import *
+
+
+class Pscmc(MakefilePackage):
+ """The SCMC and PSCMC programming language
+ is designed for multi-platform
+ parallel programming."""
+
+ maintainers = ['Bitllion']
+
+ homepage = "https://github.com/JianyuanXiao/PSCMC"
+ git = "https://github.com/JianyuanXiao/PSCMC.git"
+
+ version("master", branch="master")
+
+ def setup_run_environment(self, env):
+ env.set("SCMC_COMPILE_ROOT", self.prefix.source)
+ env.set("SCMC_ROOT", join_path(self.prefix.source, "runtime_passes"))
+ env.set("STDLIB", join_path(self.prefix.source, "stdlib.scm"))
+
+ def build(self, spec, prefix):
+ with working_dir("source"):
+ make()
+ with working_dir("source/scompiler"):
+ makefile = FileFilter("Makefile")
+ makefile.filter("CC=clang", "CC=gcc")
+ make()
+ os.system("./gen_pscmc_compiler")
+
+ def install(self, spec, prefix):
+ mkdir(prefix.source)
+ ln = which("ln")
+ ln("-s", prefix.source, prefix.bin)
+ install_tree("./", prefix)