37 Commits

Author SHA1 Message Date
arvindcheru 21afa807a9 Enable Lintian Support for ROCM-SMI, ROCMINFO (#1650)
* Enable Lintian Support for ROCM-SMI

* Enable Lintian Support for ROCMINFO

* Updated Lintian Override File Processing

* Update UT Fix for Lintian rocmsmi,rocminfo

* Update UT Fixes, Review Comments

* Update Review Comments - removed extra white spaces, added error check for gzip, date commands

* Update Review Comments - Correcting License Type

* Sync Lintian ChangeLog

* Changelog data sync enhanced

* Update Review Comments, UT fix

* white space cleanup - precommit check
2025-12-15 14:35:28 -06:00
David Yat Sin b192a84396 build: update CMake file (#1015)
Co-authored-by: Eisuke Kawashima <e-kwsm@users.noreply.github.com>
2025-09-18 09:27:11 -04:00
David Yat Sin 6f09eb3418 rocminfo: unset executable flag (#314)
Co-authored-by: Eisuke Kawashima <e-kwsm@users.noreply.github.com>
2025-08-12 21:13:45 -04:00
Khatri, Shweta 043657e70f Use idomatic approach to extending CMAKE_MODULE_PATH. (#7)
There are many reasons why there may already be a CMAKE_MODULE_PATH defined.
The idiomatic way to extend it in a project is via list(APPEND).

https://github.com/ROCm/rocminfo/pull/97 submitted by @stellaraccident

Co-authored-by: Stella Laurenzo <Stella.Laurenzo@amd.com>

[ROCm/rocminfo commit: 8503ec36ca]
2025-03-14 08:16:56 -07:00
benrichard-amd 838e46af4d Obey CMAKE_BUILD_TYPE
Obey CMAKE_BUILD_TYPE when it is passed on the command line. Previous
behavior remains:

Debug by default
ROCRTST_BLD_TYPE can set build type


[ROCm/rocminfo commit: 0607268260]
2025-02-08 13:33:12 -05:00
Chris Freehill 44522c86f0 rocminfo: Update Debian depends to use libgcc1
Change-Id: I49e8f534393abe6b93f52a545e4baec720b6edde


[ROCm/rocminfo commit: e07320467c]
2025-01-21 12:08:37 -06:00
Ranjith Ramakrishnan 8df83d6dd6 Removed kmod dependency from rocminfo
kmod dependency is not at all required for rocminfo. Removing the same from the package dependency list

Change-Id: I58f9c4305585c5dd770ea3c6a6298c30c89c31b5


[ROCm/rocminfo commit: 63ff6a4b30]
2024-08-19 16:12:31 +00:00
Ranjith Ramakrishnan 6072326740 Prevent the modification of interpreter directives
CPACK is converting /usr/bin/env python3 to /usr/libexec/platform-python in RHEL8.
Undefining __brp_mangle_shebangs will prevent the same

Change-Id: I0803d0a6cc1ddc991e8e9a8e6617436930ef013a


[ROCm/rocminfo commit: aa8a83815e]
2024-08-06 10:54:27 -04:00
Ranjith Ramakrishnan 3d124359f1 SWDEV-451078 - Update rocminfo package dependency list
python3, glibc, libgcc/libgcc_s1, libstdc++/libstdc++6 added to the RPM package dependency list
python3, libc6, libgcc-s1, libstdc++6 added to the DEB package dependency list

Change-Id: I4843b1431c0d0edf1b0df1e12c82adb4ff53c8cd


[ROCm/rocminfo commit: 1f4752295e]
2024-05-13 15:40:26 -07:00
Ranjith Ramakrishnan 9bd58252fe SWDEV-442738 - Static package generation for rocminfo
Package name will have suffix static-dev/devel
rocminfo static package will depend on hsa static package

Change-Id: I3e72b19403c10e74199067f2c725ed4a007ab150


[ROCm/rocminfo commit: 5e4f64e786]
2024-05-13 13:50:54 -04:00
David Yat Sin 0412fdba60 Set -m64 flag only on x86-64 hosts
-m64 only applies to x86-64, it's more reasonable to enable it only on x86_64 host.
It fixes build on some other platforms as well.

Provided by user r-value on github

https: //github.com/RadeonOpenCompute/rocminfo/pull/63
Change-Id: I9c1c40d3fa39b0a61d28041fe4998b5e1ad0cdcd


[ROCm/rocminfo commit: 17de0f9097]
2024-01-09 09:49:04 -05:00
Ranjith Ramakrishnan c3457852af Correct the permission of rocminfo and rocm_agent_enumerator
Both will have a permission of 755

Change-Id: I428c6419358a578595969b4bf0918e6384180dbc


[ROCm/rocminfo commit: c9905a8ba1]
2023-12-17 20:55:42 -08:00
Mark Searles be0e6048cf Removing __linux__ definition in CMake
Removing this definition as this should already be defined by compiler.
This is causing compile errors on newer versions of llvm because the
macro is being redefined.

Change-Id: I3bf03617970d4b76dabce36ed980523673afadc5


[ROCm/rocminfo commit: c8db38ede2]
2023-06-02 16:39:42 -07:00
Ranjith Ramakrishnan 324e7b83e9 SWDEV-321112: Use GNUInstallDir variable DOCDIR
Replaced install path 'share/doc/project_name' with gnuinstalldir variable CMAKE_INSTALL_DOCDIR

Change-Id: Id9fc7599e6893a604f9d965b952ab27413e1c0d6


[ROCm/rocminfo commit: 0b270afafc]
2022-05-24 23:29:54 -07:00
Nirmal Unnikrishnan a4c14fb921 Adding license file to rocminfo package
Change-Id: Ibc3b53922c366944a404982ed977ede50c6f36c7


[ROCm/rocminfo commit: 31e6575e9f]
2022-01-15 06:32:38 -06:00
Joseph Greathouse 3d4449f0c8 Update cmake to include pciutils dependencies
When building packages, add in pciutils as a dependency because
rocm_agent_enumerator uses this as a mechanism for looking up
what GPUs exist on the system.

Change-Id: I10ac088c461c6d0bca435b61fbc90b685556fdf4


[ROCm/rocminfo commit: 0e1807c72d]
2021-10-29 18:45:32 -05:00
Sean Keely b289416285 Add dependency on kmod.
rocminfo uses lsmod to check for loaded drivers.  Use of sysfs is
possible but sysfs' stable interface does not allow for easy parsing.
Use of lsmod avoids needing to walk the sysfs tree and avoids issues
of permissions to examine sysfs.

Both Debian and Fedora list lsmod under kmod.  Presumption is that
CentOS and RHEL also follow this.

Change-Id: Ic5033e0b780100c54d2fe0b4f501c40acbc237fb


[ROCm/rocminfo commit: 2b4b0c8862]
2021-10-29 16:23:01 -05:00
Sean Keely a665dc415f Correct and simplify package dependencies.
Package should depend on hsa-rocr, not hsa-rocr-dev.  Also
Remove negative path for dependency rocm-core (unconditional add +
conditional remove simplified to conditional add).

Change-Id: I6ead202f4f3f2f77b1da2ffed77feee956caf2e9


[ROCm/rocminfo commit: 86560046de]
2021-10-29 16:23:01 -05:00
Sean Keely 029c8a02aa Don't touch CMAKE_CXX_FLAGS.
Cmake manages CMAKE_CXX_FLAGS in standard ways from user inputs,
env vars, and target properties.  Use target properties for our
options and let cmake handle the rest.

Change-Id: I20ef738e4df7880258d770f4ec13c09d8b323fba


[ROCm/rocminfo commit: e32a4d9bed]
2021-10-29 16:23:01 -05:00
Ashutosh Misra 633405914f Adding package dependency
SWDEV-260294:Rocminfo shall explicitly depend on hsa-rocr for package installation

Signed-off-by: Ashutosh Mishra <ashutosh.mishra@amd.com>
Change-Id: I9a6d1691cd5a821f135a1d1cff599e9a2c40d06f


[ROCm/rocminfo commit: 2bd7657503]
2021-10-29 16:23:01 -05:00
Chris Freehill 18be0dc298 Append CXXFLAGS env. variable to CMAKE_CXX_FLAGS
This facilitates address sanitizer builds via env. variable.

Change-Id: I69fc9a5782ca80d7bdbf2b1ec0c89cccc4a5ca11


[ROCm/rocminfo commit: 102f22f974]
2021-10-29 16:23:01 -05:00
Icarus Sparry cad2d9733e Add dependency on rocm-core
Signed-off-by: Icarus Sparry <icarus.sparry@amd.com>
Change-Id: I2b0e330698ed19a2474734e33a1215644ec6f1cc


[ROCm/rocminfo commit: 1452f8fa24]
2021-07-19 21:25:55 +00:00
Ashutosh Mishra d89689c978 Standardizing Package name
Enables standards compliant package naming for debian and rpm

Signed-off-by: Ashutosh Mishra <ashutosh.mishra@amd.com>
Change-Id: I38af7b31f0c17d0c38ea7c2eb143770e7f1d74b2


[ROCm/rocminfo commit: e7b43b970f]
2020-10-24 10:08:00 +05:30
Ashutosh Mishra 59b2c3308d Adapting to latest HSA changes
JIRA : SWDEV-234471
With this change rocminfo exe shall be created using using hsa-runtime64::hsa-runtime64 which
internally decides whether static or shared libs based on its cmake build options

S. Keely:
Update patch to use find_package for rocr dependency.

Removed deadcode now supported by find_package.

Removed "hsa/" prefix from include statements since find_package
points to the target (ie rocr) include directory.

Removed typedef on structs due to new clang-11 warning.

Adapting to the comments : Removed PATHS for hsa find_package

Change-Id: I1ec65cdbce3085e44f1839da196eb4ae5c9ff30d


[ROCm/rocminfo commit: 605b3a5105]
2020-07-09 18:38:46 +05:30
Chris Freehill 8eeb8d3e5f Fix for running rocminfo on wider variety of CPUs
Change-Id: I7acc46d2fec97ae1026643f79e59dd632444ce2e


[ROCm/rocminfo commit: 9b0cd9e428]
2019-12-09 14:59:57 -06:00
Chris Freehill 7be9165a61 Require >= CMake3.5 instead of 2.8
Change-Id: I5e0045fad2ecc028c2dcb9fd78805dfb42a9e2ed


[ROCm/rocminfo commit: 2afaae2fbe]
2019-12-09 11:57:09 -06:00
Craig Andrews 7b18eda121 Install to standard locations using GNUInstallDirs
Change-Id: I6bafae15d2a0dfb70389673e03b6f72737786501


[ROCm/rocminfo commit: f1181e0569]
2019-08-22 23:02:30 -05:00
Chris Freehill 48e4985f5b Update versioning to new uniform standards
Change-Id: I93eb3170fedeee98caf7b3fd8f63a8c0fef5fd78


[ROCm/rocminfo commit: 9842beb770]
2019-08-22 12:01:49 -05:00
Craig Andrews 96fdd37b2c Use CACHE variables, allow overriding ROCR_LIB_DIR/ROCR_INC_DIR
CACHE variables allow for variables to be documented, and
ROCR_LIB_DIR/ROCR_INC_DIR should be overridable as they'll
have different values on different Linux distributions.

Change-Id: I0bba633c184df2da55bdbe6aabbd53346d098b83


[ROCm/rocminfo commit: 04dc08664e]
2019-08-22 08:02:31 -05:00
Craig Andrews a013e37c8f Messages indicating fatal errors should be fatal
Change-Id: Ib071d3f6ed216c817daa637fc784680ef9d123f8


[ROCm/rocminfo commit: 9f5349806a]
2019-08-21 22:28:54 -05:00
Chris Freehill 4e9009867d Undo previous commit of github CMakeLists.txt file
Change-Id: Ic650b913377112bff6c25176d9446311f33f6c78


[ROCm/rocminfo commit: 43f664436d]
2019-06-22 16:29:42 -05:00
Anthony Cowley 2eaa5dcc5d cmake: fix typo in ROCR_LIB_DIR detection
[ROCm/rocminfo commit: ca841958af]
2019-06-19 13:44:12 -05:00
James Edwards d01a68b591 Update CMakeLists.txt
[ROCm/rocminfo commit: 26378662db]
2019-06-19 13:44:12 -05:00
James Adrian Edwards a9efd9a64a Add dependencies and support for rocm-cmake style packaging.
[ROCm/rocminfo commit: a8dc4b3e37]
2019-06-19 13:44:12 -05:00
James Edwards 26958f006f Add install and packaging to CMakeList.txt file.
[ROCm/rocminfo commit: f99ef9da4f]
2018-02-28 16:57:14 -06:00
Wen-Heng (Jack) Chung ec9e027988 Initial commit to introduce rocm_agent_enumerator into rocminfo
This is a python port of rocm_agent_enumerator, which is used by HIP/HCC to
determine available AMDGPU targets on a system.

Its previous implementation was written in C++ which makes it somewhat hard to
deploy onto different distros / architectures. A python port should remove such
issue.


[ROCm/rocminfo commit: 8b018900f6]
2017-11-09 12:33:53 -06:00
Chris Freehill 1b86c30dfa Rename to rocminfo
Change-Id: Ifd0ba9aaa4078dc2771e15bb254ba1c4ec2acf1e


[ROCm/rocminfo commit: 5c6e06c80f]
2017-11-03 14:04:51 -05:00