From fbb422c1afa4c6d49f528222b226f602fc38950a Mon Sep 17 00:00:00 2001 From: Johan Euphrosine Date: Tue, 13 Dec 2022 22:33:58 +0900 Subject: [PATCH 1/5] sim: add xyce --- sim/xyce/build.sh | 38 +++++++++++++++++++++++++++ sim/xyce/meta.yaml | 65 ++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 103 insertions(+) create mode 100644 sim/xyce/build.sh create mode 100644 sim/xyce/meta.yaml diff --git a/sim/xyce/build.sh b/sim/xyce/build.sh new file mode 100644 index 00000000..84351ff4 --- /dev/null +++ b/sim/xyce/build.sh @@ -0,0 +1,38 @@ +#!/bin/bash + + +# Copyright 2022 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +set -ex + +cd $SRC_DIR/blas +cmake -B build -DCMAKE_INSTALL_PREFIX=$PREFIX . +cmake --build build -j $CPU_COUNT --target install + +cd $SRC_DIR/lapack +cmake -B build -DCMAKE_INSTALL_PREFIX=$PREFIX . +cmake --build build -j $CPU_COUNT --target install + +cd $SRC_DIR/amd +cmake -B build -DSuiteSparsePath=. -DCMAKE_INSTALL_PREFIX=$PREFIX $SRC_DIR/cmake/trilinos/AMD +cmake --build build -j $CPU_COUNT --target install + +cd $SRC_DIR/Trilinos +cmake -B build -DCMAKE_INSTALL_PREFIX=$PREFIX -C $SRC_DIR/cmake/trilinos/trilinos-config.cmake . +cmake --build build -j $CPU_COUNT --target install + +cd $SRC_DIR +cmake -B build -DCMAKE_INSTALL_PREFIX=$PREFIX . +cmake --build build -j $CPU_COUNT --target install diff --git a/sim/xyce/meta.yaml b/sim/xyce/meta.yaml new file mode 100644 index 00000000..348616be --- /dev/null +++ b/sim/xyce/meta.yaml @@ -0,0 +1,65 @@ +# Use `conda-build-prepare` before building for a better version string. +{% set version = '%s_%04i_%s'|format(GIT_DESCRIBE_TAG|replace('v', '')|replace('-', '')|default('0.X'), GIT_DESCRIBE_NUMBER|int, GIT_DESCRIBE_HASH|default('gUNKNOWN')) %} +{% set blas_version = '3.11.0' %} +{% set blas_md5 = '92418c9bc598e589d73044ec39518616' %} +{% set lapack_version = '3.11.0' %} +{% set lapack_md5 = '595b064fd448b161cd711fe346f498a7' %} +{% set amd_version = '6.0.2' %} +{% set amd_md5 = '628214a2d18ee4d3996fdc50b7fc9aef' %} +package: + name: xyce + version: {{ version }} + +source: + - git_url: /~https://github.com/Xyce/Xyce.git + git_rev: master + - git_url: /~https://github.com/trilinos/Trilinos.git + git_rev: master + folder: Trilinos + - url: http://www.netlib.org/blas/blas-{{ blas_version }}.tgz + md5: {{ blas_md5 }} + folder: blas + - url: /~https://github.com/Reference-LAPACK/lapack/archive/refs/tags/v{{ lapack_version }}.tar.gz + md5: {{ lapack_md5 }} + folder: lapack + - url: /~https://github.com/DrTimothyAldenDavis/SuiteSparse/archive/refs/tags/v{{ amd_version }}.tar.gz + md5: {{ amd_md5 }} + folder: amd + +build: + # number: 202202031935 + number: {{ environ.get('DATE_NUM') }} + # string: 20220203_1935 + string: {{ environ.get('DATE_STR') }} + script_env: + - CI + +requirements: + build: + - autoconf + - automake + - make + - cmake + - bison + - flex + - {{ compiler('cxx') }} + - {{ compiler('fortran') }} + +test: + commands: + - xyce --version + +about: + home: https://xyce.sandia.gov/ + license: GPL + license_family: GPL + license_file: LICENSE + summary: 'The Xyce™ Parallel Electronic Simulator' + description: | + Xyce (zīs, rhymes with “spice”) is an open source, SPICE-compatible, high-performance analog circuit simulator, capable of solving extremely large circuit problems by supporting large-scale parallel computing platforms. It also supports serial execution on all common desktop platforms, and small-scale parallel runs on Unix-like systems. In addition to analog electronic simulation, Xyce has also been used to investigate more general network systems, such as neural networks and power grids. + doc_url: https://xyce.sandia.gov/documentation/ + dev_url: /~https://github.com/Xyce/Xyce + +extra: + recipe-maintainers: + - proppy From d37df922c2574646086733c8b996ebfeb13ee479 Mon Sep 17 00:00:00 2001 From: Johan Euphrosine Date: Tue, 13 Dec 2022 22:38:05 +0900 Subject: [PATCH 2/5] github/workflows/Build: add xyce --- .github/workflows/Build.yml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/.github/workflows/Build.yml b/.github/workflows/Build.yml index 116acd29..213496e6 100644 --- a/.github/workflows/Build.yml +++ b/.github/workflows/Build.yml @@ -730,3 +730,13 @@ jobs: steps: - uses: actions/checkout@v3 - uses: ./ci + + #65 + xyce-linux: + runs-on: "ubuntu-20.04" + env: + PACKAGE: "sim/xyce" + OS_NAME: "linux" + steps: + - uses: actions/checkout@v3 + - uses: ./ci From f002f1edf59904a2bb3380a291387fffc0ac0cdd Mon Sep 17 00:00:00 2001 From: Johan Euphrosine Date: Tue, 13 Dec 2022 23:13:48 +0900 Subject: [PATCH 3/5] sim/xyce: add build prefix to search path --- sim/xyce/build.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sim/xyce/build.sh b/sim/xyce/build.sh index 84351ff4..eb219e1e 100644 --- a/sim/xyce/build.sh +++ b/sim/xyce/build.sh @@ -34,5 +34,5 @@ cmake -B build -DCMAKE_INSTALL_PREFIX=$PREFIX -C $SRC_DIR/cmake/trilinos/trilino cmake --build build -j $CPU_COUNT --target install cd $SRC_DIR -cmake -B build -DCMAKE_INSTALL_PREFIX=$PREFIX . +cmake -B build -DCMAKE_FIND_ROOT_PATH="$BUILD_PREFIX;$PREFIX" -DCMAKE_FIND_ROOT_PATH_MODE_INCLUDE=ONLY -DCMAKE_FIND_ROOT_PATH_MODE_LIBRARY=ONLY -DCMAKE_FIND_ROOT_PATH_MODE_PROGRAM=ONLY -DCMAKE_INSTALL_PREFIX=$PREFIX . cmake --build build -j $CPU_COUNT --target install From 9202bfa5ef43d88cfa0c58cee41343e1f7ef8fa7 Mon Sep 17 00:00:00 2001 From: Johan Euphrosine Date: Wed, 21 Dec 2022 14:32:11 +0900 Subject: [PATCH 4/5] sim/xyce: add libgfortran --- sim/xyce/meta.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sim/xyce/meta.yaml b/sim/xyce/meta.yaml index 348616be..275e581f 100644 --- a/sim/xyce/meta.yaml +++ b/sim/xyce/meta.yaml @@ -44,6 +44,9 @@ requirements: - flex - {{ compiler('cxx') }} - {{ compiler('fortran') }} + host: + - libgfortran5 + - libgfortran-ng test: commands: From d263f734c45b647d981b2c85ec5cac4560a0086a Mon Sep 17 00:00:00 2001 From: Johan Euphrosine Date: Wed, 21 Dec 2022 22:02:53 +0900 Subject: [PATCH 5/5] sim/xyce: switch trilinos to tarball --- sim/xyce/meta.yaml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sim/xyce/meta.yaml b/sim/xyce/meta.yaml index 275e581f..de8d495c 100644 --- a/sim/xyce/meta.yaml +++ b/sim/xyce/meta.yaml @@ -1,5 +1,7 @@ # Use `conda-build-prepare` before building for a better version string. {% set version = '%s_%04i_%s'|format(GIT_DESCRIBE_TAG|replace('v', '')|replace('-', '')|default('0.X'), GIT_DESCRIBE_NUMBER|int, GIT_DESCRIBE_HASH|default('gUNKNOWN')) %} +{% set trilinos_version = '13-4-1' %} +{% set trilinos_md5 = '8f26e97d92a9d91affadc54896a0ec77' %} {% set blas_version = '3.11.0' %} {% set blas_md5 = '92418c9bc598e589d73044ec39518616' %} {% set lapack_version = '3.11.0' %} @@ -13,8 +15,8 @@ package: source: - git_url: /~https://github.com/Xyce/Xyce.git git_rev: master - - git_url: /~https://github.com/trilinos/Trilinos.git - git_rev: master + - url: /~https://github.com/trilinos/Trilinos/archive/refs/tags/trilinos-release-{{ trilinos_version }}.tar.gz + md5: {{ trilinos_md5 }} folder: Trilinos - url: http://www.netlib.org/blas/blas-{{ blas_version }}.tgz md5: {{ blas_md5 }}