Open jasvinderkhurana opened 1 year ago
The root cause seems to be ROS_VITIS macro is somehow not getting enabled and then it is not installing the vitis_common headers in install directory. using below command it succeeds the doublevadd_publisher, but fails in another package:
colcon build --cmake-args -D ROS_VITIS=1 --merge-install
Here is the error:
But then I am currently skipping that package to proceed the build
colcon build --cmake-args -D ROS_VITIS=1 --merge-install --packages-skip ros2_kria_power
@jasvinderkhurana I'm traveling and can't have a look at your issues right now in detail. My quick feedback is that KRS is known to build. See CI pipeline https://gitlab.com/accelerationrobotics/customers/amd/krs-pipeline/-/pipelines/660158697. Inspect the corresponding files at that point if you need further help.
My suggestion is for you to hold until the CI stabilizes (still in development) and build on top of that (which is reproducible) once ready to avoid uncertainty. It'll take some weeks still.
I'm trying to build using Docker via the Ubuntu 22.04 instructions listed here and am running into this same issue. Here's the error that I see:
--- stderr: accelerated_vadd
/krs_ws/src/acceleration/acceleration_examples/nodes/accelerated_vadd/src/host.cpp:24:10: fatal error: vitis_common/common/ros_opencl_120.hpp: No such file or directory
24 | #include <vitis_common/common/ros_opencl_120.hpp>
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
gmake[2]: *** [CMakeFiles/accelerated_vadd.dir/build.make:76: CMakeFiles/accelerated_vadd.dir/src/host.cpp.o] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:137: CMakeFiles/accelerated_vadd.dir/all] Error 2
gmake: *** [Makefile:146: all] Error 2
---
Failed <<< accelerated_vadd [5.04s, exited with code 2]
I just got my KR260 dev kit last week and this is the first time I've tried to build the KRS.
Further, I'm getting a 404 when I try to follow the CI pipeline link @vmayoral has referenced in https://github.com/Xilinx/KRS/issues/74#issuecomment-1278999392. So, I can't compare how that's working versus how my build is not.
FYI--
By adding the ROS_VITIS macro identified by @jasvinderkhurana and modifying src/acceleration/ros2_kria/ros2_kria_power/CMakeLists.txt
, I was able to build. I added find_package(std_msgs REQUIRED)
to CMakeLists.txt
and added a reference to std_msgs
in the ament_target_dependencies(power_component
declaration.
@verderog , thanks for confirming, we are working towards making KRS more stable. So please stay tuned
I've been able to progress through much of the Ubuntu 22.04 Install Instructions. However, when I hit step 7.A, I encounter several colcon
build errors. Here's the first one:
CMake Error at CMakeLists.txt:12 (find_package):
By not providing "Findament_cmake_core.cmake" in CMAKE_MODULE_PATH this
project has asked CMake to find a package configuration file provided by
"ament_cmake_core", but CMake did not find one.
Could not find a package configuration file provided by "ament_cmake_core"
with any of the following names:
ament_cmake_coreConfig.cmake
ament_cmake_core-config.cmake
Add the installation prefix of "ament_cmake_core" to CMAKE_PREFIX_PATH or
set "ament_cmake_core_DIR" to a directory containing one of the above
files. If "ament_cmake_core" provides a separate development package or
SDK, be sure it has been installed.
The others are similar, but reference different packages such as ament_cmake
, ament_cmake_ros
and ament_cmake_auto
.
I'm executing the instructions from the Xilinx page linked above in order. I've googled potential causes for the ament_cmake_core
problem and they mention that my ROS2 Humble setup.bash
could be the culprit, but I've made sure to source
that as well as the install/setup.bash
from the build.
I do see /opt/ros/humble/share/ament_cmake_core/cmake/ament_cmake_coreConfig.cmake
, so I don't know why cmake is not finding it correctly. I've tried specifying -DCMAKE_PREFIX_PATH=/opt/ros/humble/share
but still see the same failure.
If I explicitly define the location of ament_cmake_core via -Dament_cmake_core_DIR="/opt/ros/humble/share/ament_cmake_core/cmake"
, then I can get ament_accleration
to build. This seems like overkill and something else is fundamentally wrong with my environment or the build configuration.
Any ideas or suggestions on what may be causing the problem?
EDIT: For future reference, there is already an open issue that seems to relate to this: https://github.com/Xilinx/KRS/issues/59. I'll follow-up there.
I edited krs_humble.repos and changed vitis_common version from humble to master. After that I was able to build successfully. Is this related to this error?
@vmayoral, I am also facing similar issue, and after updating the vitis_common package to master branch. That also did not resolved my problem.
Can you please check, if there is any latest change that broke the build?
@jasvinderkhurana I think you can try to delete the previous build folder and build again. I also encountered the same problem, and after about three rebuilds, the problem was solved.
Hi,
I have tried to setup a fresh on new ubuntu machine and install KRS, but it is failing to compile at accelerated_doublevadd_publisher. I have used below steps:
Below is the error occured:
@vmayoral, can you please have a quick look at it..
PS: The KRS used to build earlier may be 1 month back, but is failing now.