2022-01-13 03:21:41 +08:00
|
|
|
# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other
|
2020-09-28 23:26:20 +08:00
|
|
|
# Spack Project Developers. See the top-level COPYRIGHT file for details.
|
|
|
|
#
|
|
|
|
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
|
|
|
|
|
2022-05-29 00:55:44 +08:00
|
|
|
from spack.package import *
|
2020-09-28 23:26:20 +08:00
|
|
|
|
|
|
|
|
|
|
|
class Hipfort(CMakePackage):
|
|
|
|
"""Radeon Open Compute Parallel Primitives Library"""
|
|
|
|
|
|
|
|
homepage = "https://github.com/ROCmSoftwarePlatform/hipfort"
|
2021-04-01 08:30:56 +08:00
|
|
|
git = "https://github.com/ROCmSoftwarePlatform/hipfort.git"
|
2022-08-12 15:20:47 +08:00
|
|
|
url = "https://github.com/ROCmSoftwarePlatform/hipfort/archive/rocm-5.2.0.tar.gz"
|
2022-06-24 00:10:01 +08:00
|
|
|
tags = ["rocm"]
|
2022-07-31 06:19:18 +08:00
|
|
|
|
2022-08-12 15:20:47 +08:00
|
|
|
maintainers = ["cgmb", "srekolam", "renjithravindrankannath"]
|
2022-07-31 06:19:18 +08:00
|
|
|
|
2022-08-12 15:20:47 +08:00
|
|
|
version("5.2.0", sha256="a0af1fe62757993600a41af6bb6c4b8c6cfdfba650389645ac1f995f7623785c")
|
2022-06-02 01:57:10 +08:00
|
|
|
version("5.1.3", sha256="8f8849d8d0972366bafa41be35cf6a7a59480ed584d1ddff39768cb14247e9d4")
|
2022-05-10 23:42:22 +08:00
|
|
|
version("5.1.0", sha256="1ddd46c00bb6bcd539a921d6a94d858f4e4408a35cb6910186c7517f375ae8ab")
|
2022-03-26 01:56:52 +08:00
|
|
|
version("5.0.2", sha256="fcee6e62482ab15f365681dbc12bd9ae26b0fab2f2848a3c14de8ec63004a7aa")
|
|
|
|
version("5.0.0", sha256="af0f332fec082a03ca0403618ab20d31baadf3103e3371db9edc39dc9474ef4c")
|
2022-01-15 23:59:15 +08:00
|
|
|
version("4.5.2", sha256="14599d027b57189c6734b04ace7792d2ae5c409cf7983c0970b086fb4e634dd8")
|
2022-01-07 05:24:00 +08:00
|
|
|
version("4.5.0", sha256="48626dfb15bb5dcb044c9e1d4dc4b0654a2cd0abfc69485aa285dc20d7f40d51")
|
2022-05-18 05:11:32 +08:00
|
|
|
version(
|
|
|
|
"4.3.1",
|
|
|
|
sha256="279a35edbc0c22fa930a4355e663a86adf4d0316c5b1b6b9ccc6ee5c19c8c2e4",
|
|
|
|
deprecated=True,
|
|
|
|
)
|
|
|
|
version(
|
|
|
|
"4.3.0",
|
|
|
|
sha256="fd0ffdafdc17ac42c7dae3f89991651f15affdef9b2354da05c7493d09d8974e",
|
|
|
|
deprecated=True,
|
|
|
|
)
|
|
|
|
version(
|
|
|
|
"4.2.0",
|
|
|
|
sha256="b411cb32bf87927eba4c5573b412c56d75d15165e2f1c8ac5ac18e624ed3a4b4",
|
2022-01-17 20:08:24 +08:00
|
|
|
deprecated=True,
|
|
|
|
)
|
|
|
|
version(
|
|
|
|
"4.1.0",
|
|
|
|
sha256="2d335ae068d0cbb480575de7d3ea4868362af32cb195f911ee1aeced499f3974",
|
|
|
|
deprecated=True,
|
|
|
|
)
|
|
|
|
version(
|
|
|
|
"4.0.0",
|
|
|
|
sha256="a497645c33e0eff39abd5344756de63424733cde2837b7376c924b44ed5ae9c9",
|
|
|
|
deprecated=True,
|
|
|
|
)
|
|
|
|
version(
|
|
|
|
"3.10.0",
|
|
|
|
sha256="44173522d9eb2a18ec1cea2d9b00b237fe70501f0849bd6be3decbb73389487a",
|
|
|
|
deprecated=True,
|
|
|
|
)
|
|
|
|
version(
|
|
|
|
"3.9.0",
|
|
|
|
sha256="a3c4e125a9b56820446a65bd76b8caa196fddb0e0723eb513f0bcde9abd6a0c0",
|
|
|
|
deprecated=True,
|
|
|
|
)
|
|
|
|
version(
|
|
|
|
"3.8.0",
|
|
|
|
sha256="0132e9949f758dd8b8a462d133b3316101440cd503aa6c53bea9e34e61bbb3cc",
|
2021-10-27 03:18:38 +08:00
|
|
|
deprecated=True,
|
|
|
|
)
|
2022-07-31 06:19:18 +08:00
|
|
|
|
2021-10-27 03:18:38 +08:00
|
|
|
variant(
|
|
|
|
"build_type",
|
|
|
|
default="Release",
|
|
|
|
values=("Release", "Debug", "RelWithDebInfo"),
|
|
|
|
description="CMake build type",
|
2022-07-31 06:19:18 +08:00
|
|
|
)
|
|
|
|
|
rocmlibs: relax rocm-cmake version requirements (#29857)
* rocmlibs: relax rocm-cmake version requirements
The rocm-cmake modules tend to be backwards-compatible, to the extent
that most ROCm math libraries were built using rocm-cmake@master
for a long while without anybody noticing. (That was fixed in
97f0c3ccd9f0a40896998a7580150a514ec3bc37.)
Some packages, like comgr, barely use rocm-cmake for anything, and
we can easily set a very minimal version requirement. For most
packages, however, it would be a lot of effort to determine the
minimum rocm-cmake version required for each release. For those
packages, I just turned the exact version requirement into a
minimum version requirement.
Since I was looking through the CMakeLists.txt for a large number of
libraries, I also took note of the cmake_minimum_required and adjusted
the cmake minimum requirements to match.
* Add rocblas build dependency to hipblas
The rocblas library is required both for both building and linking
hipblas.
* Remove rocm-cmake from vtk-m dependency list
The rocm-cmake package provides CMake scripts that facilitate common
build configuration tasks in the ROCm libraries. It is never needed at
link-time. Also, there are no calls to find_package(ROCM) or
include(ROCM.*)in vtk-m, so this dependency will never be used.
2022-04-19 21:26:40 +08:00
|
|
|
depends_on("cmake@3.0.2:", type="build")
|
2022-07-31 06:19:18 +08:00
|
|
|
|
rocmlibs: relax rocm-cmake version requirements (#29857)
* rocmlibs: relax rocm-cmake version requirements
The rocm-cmake modules tend to be backwards-compatible, to the extent
that most ROCm math libraries were built using rocm-cmake@master
for a long while without anybody noticing. (That was fixed in
97f0c3ccd9f0a40896998a7580150a514ec3bc37.)
Some packages, like comgr, barely use rocm-cmake for anything, and
we can easily set a very minimal version requirement. For most
packages, however, it would be a lot of effort to determine the
minimum rocm-cmake version required for each release. For those
packages, I just turned the exact version requirement into a
minimum version requirement.
Since I was looking through the CMakeLists.txt for a large number of
libraries, I also took note of the cmake_minimum_required and adjusted
the cmake minimum requirements to match.
* Add rocblas build dependency to hipblas
The rocblas library is required both for both building and linking
hipblas.
* Remove rocm-cmake from vtk-m dependency list
The rocm-cmake package provides CMake scripts that facilitate common
build configuration tasks in the ROCm libraries. It is never needed at
link-time. Also, there are no calls to find_package(ROCM) or
include(ROCM.*)in vtk-m, so this dependency will never be used.
2022-04-19 21:26:40 +08:00
|
|
|
depends_on("rocm-cmake@3.8.0:", type="build")
|
2022-07-31 06:19:18 +08:00
|
|
|
|
2021-08-11 15:52:22 +08:00
|
|
|
for ver in [
|
|
|
|
"3.8.0",
|
|
|
|
"3.9.0",
|
|
|
|
"3.10.0",
|
|
|
|
"4.0.0",
|
|
|
|
"4.1.0",
|
|
|
|
"4.2.0",
|
2022-03-26 01:56:52 +08:00
|
|
|
"4.3.0",
|
|
|
|
"4.3.1",
|
|
|
|
"4.5.0",
|
|
|
|
"4.5.2",
|
|
|
|
"5.0.0",
|
2022-06-02 01:57:10 +08:00
|
|
|
"5.0.2",
|
|
|
|
"5.1.0",
|
|
|
|
"5.1.3",
|
2022-08-12 15:20:47 +08:00
|
|
|
"5.2.0",
|
2022-06-02 01:57:10 +08:00
|
|
|
]:
|
2020-09-28 23:26:20 +08:00
|
|
|
depends_on("hip@" + ver, type="build", when="@" + ver)
|
|
|
|
|
|
|
|
def setup_build_environment(self, env):
|
|
|
|
env.set("CXX", self.spec["hip"].hipcc)
|
2021-08-11 14:21:17 +08:00
|
|
|
|
|
|
|
def cmake_args(self):
|
|
|
|
args = []
|
|
|
|
|
2021-09-30 22:01:17 +08:00
|
|
|
if self.spec.satisfies("^cmake@3.21.0:3.21.2"):
|
2021-08-11 14:21:17 +08:00
|
|
|
args.append(self.define("__skip_rocmclang", "ON"))
|
|
|
|
|
|
|
|
return args
|