Open gggh000 opened 2 years ago
You might find this script useful. Not everything in it will install to the right directory with DCMAKE_INSTALL_PREFIX specified, but it builds most of the components in ROCm 4.5 from source.
(That doesn't fix the issue if the INSTALL.md instructions are wrong, but I hope you at least find it useful as an additional reference.)
hi i looked at it however not sure if this resolves the fundamental build problem. INSTALL.md refers to instruction for HIP build. However i found that cmake command mistakes the case sensitives.
It expects hipconfig in
There is another path issue that readlinks must be read from
If it helps, to get HIP building on Fedora I needed to do:
export HIP_CLANG_PATH=/usr/bin mkdir build cd build cmake -S.. -B. \ -DHIP_COMMON_DIR=/path/to/hip \ -DAMD_OPENCL_PATH=/path/to/ocl \ -DROCCLR_PATH=/path/to/rocclr \ -DHIP_COMPILER=clang make
But I only tried 5.0 and 5.1, not 4.5. Note that I did notice that HIP seems to assume cmake is run within the build directory, not the source directory, so you must use something like "cmake -S.. -B." (I not sure if that's the same as what you did). As well, exporting HIP_CLANG_PATH is needed to find clang, as it doesn't appear to fall back to PATH to find it.
It appears the instruction in INSTALL.md misled in such a way build expects the hipconfig in wrong place.
DCMAKE_INSTALL_PREFIX=$PWD/install .. -- HIP_COMMON_DIR found at /root/ROCm-4.5/hipamd/hip Can't open perl script "/root/ROCm-4.5/hipamd/hip/bin/hipconfig": No such file or directory
root@nonroot-SYS-7049GP-TRT:~/ROCm-4.5/hipamd/build# find ~/ROCm-4.5/ -name hipconfig /root/ROCm-4.5/HIP/bin/hipconfig