Compare commits

3 Commits

Author SHA1 Message Date
8604d1720c Add Fedora copyright
Signed-off-by: Tom Rix <Tom.Rix@amd.com>
2025-08-27 12:09:43 -07:00
7b3e17bed2 Simplify file removal
Signed-off-by: Tom Rix <Tom.Rix@amd.com>
2025-08-25 12:53:03 -07:00
2af41a8bda Remove changelog
Signed-off-by: Tom Rix <Tom.Rix@amd.com>
2025-08-25 08:25:57 -07:00
3 changed files with 29 additions and 123 deletions

View File

@@ -1,65 +0,0 @@
From: Egbert Eich <eich@suse.com>
Date: Thu Aug 14 15:28:19 2025 +0200
Subject: Make use of system-provided gtest USE_SYSTEM_GTEST is set
Patch-mainline: Not yet
Git-commit: f695634372d6d262fb495529f12c32ea97c4a6f2
References:
Signed-off-by: Egbert Eich <eich@suse.com>
Signed-off-by: Egbert Eich <eich@suse.de>
---
tests/rocm_smi_test/CMakeLists.txt | 30 +++++++++++++++++++-----------
1 file changed, 19 insertions(+), 11 deletions(-)
diff --git a/tests/rocm_smi_test/CMakeLists.txt b/tests/rocm_smi_test/CMakeLists.txt
index 2253327..bc565cb 100755
--- a/tests/rocm_smi_test/CMakeLists.txt
+++ b/tests/rocm_smi_test/CMakeLists.txt
@@ -10,6 +10,8 @@ endif()
# Required Defines first:
option(INSTALL_GTEST "Install GTest (only useful if GTest is not already installed)" OFF)
+option(USE_SYSTEM_GTEST "Use system GTest" OFF)
+
message("")
message("Build Configuration:")
message("-----------BuildType: " ${BUILD_TYPE})
@@ -36,13 +38,17 @@ set(CMAKE_INSTALL_RPATH
${CMAKE_INSTALL_RPATH}
${RSMITST_RPATH})
-# Download and compile googletest
-include(FetchContent)
-FetchContent_Declare(
- googletest
- GIT_REPOSITORY https://github.com/google/googletest.git
- GIT_TAG v1.14.0)
-FetchContent_MakeAvailable(googletest)
+if(USE_SYSTEM_GTEST)
+ find_package( GTest REQUIRED )
+else()
+ # Download and compile googletest
+ include(FetchContent)
+ FetchContent_Declare(
+ googletest
+ GIT_REPOSITORY https://github.com/google/googletest.git
+ GIT_TAG v1.14.0)
+ FetchContent_MakeAvailable(googletest)
+endif()
# Other source directories
aux_source_directory(${SRC_DIR}/functional functionalSources)
@@ -74,8 +80,10 @@ install(FILES rsmitst.exclude
DESTINATION ${SHARE_INSTALL_PREFIX}/rsmitst_tests
COMPONENT ${TESTS_COMPONENT})
-# install googletest libraries with tests
-install(TARGETS gtest gtest_main
- DESTINATION ${SHARE_INSTALL_PREFIX}/rsmitst_tests
- COMPONENT ${TESTS_COMPONENT})
+if(NOT USE_SYSTEM_GTEST)
+ # install googletest libraries with tests
+ install(TARGETS gtest gtest_main
+ DESTINATION ${SHARE_INSTALL_PREFIX}/rsmitst_tests
+ COMPONENT ${TESTS_COMPONENT})
+endif()

View File

@@ -1,38 +0,0 @@
* Tue Feb 20 2024 Zhengyu He <hezhy472013@gmail.com> - 6.0.0-5
- Add support for riscv64
* Thu Oct 19 2023 Jeremy Newton <alexjnewt at hotmail dot com> - 5.7.1-1
- Update to 5.7.1
* Sun Sep 17 2023 Jeremy Newton <alexjnewt at hotmail dot com> - 5.7.0-1
- Update to 5.7
* Fri Jul 21 2023 Fedora Release Engineering <releng@fedoraproject.org> - 5.6.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Thu Jun 29 2023 Jeremy Newton <alexjnewt at hotmail dot com> - 5.6.0-1
- Update to 5.6.0
- Replace fixes with upstream patches
* Sun Jun 25 2023 Jeremy Newton <alexjnewt at hotmail dot com> - 5.5.1-2
- Rename to rocm-smi to replace existing retired package
- Add patches to fix soversion
* Fri Jun 23 2023 Jeremy Newton <alexjnewt at hotmail dot com> - 5.5.1-1
- Complete rewrite of spec file (start from scratch)
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 4.0.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
* Tue Dec 22 2020 Benjamin A. Beasley <code@musicinmybrain.net> - 4.0.0-1
- Upstream version 4.0.0 (no changes whatsoever, still deprecated)
* Fri Dec 11 2020 Benjamin A. Beasley <code@musicinmybrain.net> - 3.10.0-1
- Upstream version 3.10.0 (no changes whatsoever, still deprecated)
* Thu Nov 19 2020 Benjamin A. Beasley <code@musicinmybrain.net> - 3.9.0-1
- Upstream version 3.9.0 (no changes except deprecation)
- Deprecate package
* Thu Oct 15 2020 Benjamin A. Beasley <code@musicinmybrain.net> - 3.8.0-1
- Initial import (#1885684)

View File

@@ -1,3 +1,24 @@
#
# Copyright Fedora Project Authors.
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to
# deal in the Software without restriction, including without limitation the
# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
# sell copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in
# all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
# THE SOFTWARE.
#
%global rocm_release 6.4
%global rocm_patch 3
%global rocm_version %{rocm_release}.%{rocm_patch}
@@ -14,14 +35,13 @@
Name: rocm-smi
Version: %{rocm_version}
Release: 2%{?dist}
Release: 3%{?dist}
Summary: ROCm System Management Interface Library
License: MIT AND NCSA
URL: https://github.com/ROCm/%{upstreamname}
Source0: %{url}/archive/rocm-%{version}.tar.gz#/%{upstreamname}-%{version}.tar.gz
Patch0: 0001-rocm-smi-fix-empty-return.patch
Patch1: Make-use-of-system-provided-gtest-USE_SYSTEM_GTEST-is-set.patch
%if 0%{?rhel} || 0%{?suse_version}
ExclusiveArch: x86_64
@@ -40,13 +60,6 @@ BuildRequires: doxygen-latex >= 1.9.7
%endif
BuildRequires: gcc-c++
BuildRequires: libdrm-devel
%if %{with test}
%if 0%{?suse_version}
BuildRequires: gtest = 1.14.0
%else
BuildRequires: gtest-devel
%endif
%endif
%description
The ROCm System Management Interface Library, or ROCm SMI library, is part of
@@ -85,8 +98,7 @@ sed -i -e 's@env python3@python3@' python_smi_tools/rsmiBindingsInit.py.in
%build
%cmake -DFILE_REORG_BACKWARD_COMPATIBILITY=OFF -DCMAKE_INSTALL_LIBDIR=%{_lib} \
-DCMAKE_SKIP_INSTALL_RPATH=TRUE \
-DBUILD_TESTS=%build_test \
-DUSE_SYSTEM_GTEST=On
-DBUILD_TESTS=%build_test
%cmake_build
@@ -96,10 +108,7 @@ sed -i -e 's@env python3@python3@' python_smi_tools/rsmiBindingsInit.py.in
# For Fedora < 38, the README is not installed if doxygen is disabled:
install -D -m 644 README.md %{buildroot}%{_docdir}/rocm_smi/README.md
F=%{buildroot}%{_datadir}/doc/rocm_smi/LICENSE.txt
if [ -f $F ]; then
rm $F
fi
rm -f %{buildroot}%{_datadir}/doc/rocm_smi/LICENSE.txt
%if 0%{?suse_version}
%post -p /sbin/ldconfig
@@ -127,11 +136,11 @@ fi
%endif
%changelog
* Thu Aug 14 2025 Egbert Eich <eich@suse.com> - 6.4.3-2
- Require googletest package when building with test.
- Fix build to not attempt to download googletest sources.
Add: Make-use-of-system-provided-gtest-USE_SYSTEM_GTEST-is-set.patch
- On SUSE limit gtest to version 1.14.0.
* Wed Aug 27 2025 Tom Rix <Tom.Rix@amd.com> - 6.4.3-3
- Add Fedora copyright
* Mon Aug 25 2025 Tom Rix <Tom.Rix@amd.com> - 6.4.3-2
- Simplify file removal
* Thu Aug 7 2025 Tom Rix <Tom.Rix@amd.com> - 6.4.3-1
- Update to 6.4.3