diff --git a/.github/workflows/spack.yml b/.github/workflows/spack.yml new file mode 100644 index 00000000..6127630d --- /dev/null +++ b/.github/workflows/spack.yml @@ -0,0 +1,30 @@ +name: spack-ci + +on: + pull_request: + push: + branches: [main] + +jobs: + spack-build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Checkout Spack + uses: actions/checkout@v4 + with: + repository: spack/spack + path: spack-tool + + - name: Set up Spack + run: | + . spack-tool/share/spack/setup-env.sh + spack compiler find + spack repo add $GITHUB_WORKSPACE/./spack + spack env create ci + spack env activate ci + spack add py-moocore + spack concretize -f + spack install --fail-fast + shell: bash \ No newline at end of file diff --git a/spack/packages/py-moocore/package.py b/spack/packages/py-moocore/package.py new file mode 100644 index 00000000..a4e5aaaa --- /dev/null +++ b/spack/packages/py-moocore/package.py @@ -0,0 +1,24 @@ +# ruff: noqa: F403, F405 +from spack.package import * + + +class PyMoocore(PythonPackage): + """Core Algorithms for Multi-Objective Optimization.""" + + homepage = "https://multi-objective.github.io/moocore/python/" + pypi = "moocore/moocore-0.2.0.tar.gz" + + version( + "0.2.0", + sha256="3dc601f85f9a4743ed50ddd027dca30e3bb55c899916a092c2ece495b1b2de08", + ) + + depends_on("c", type="build") + depends_on("gmake@4.4:", type="build") + + depends_on("python@3.10:", type=("build", "run")) + depends_on("py-setuptools@77.0.3:", type="build") + depends_on("py-wheel", type="build") + depends_on("py-cffi@1.16:", type=("build", "run")) + depends_on("py-numpy@1.24:", type=("build", "run")) + depends_on("py-platformdirs", type=("build", "run")) diff --git a/spack/repo.yaml b/spack/repo.yaml new file mode 100644 index 00000000..174fff33 --- /dev/null +++ b/spack/repo.yaml @@ -0,0 +1,2 @@ +repo: + namespace: 'moocore'