Skip to content

Enable build of 06_dcmac example#81

Merged
hpc-aulmamei merged 3 commits into
Xilinx:devfrom
papeg:dev-enable-06_dcmac-build
May 11, 2026
Merged

Enable build of 06_dcmac example#81
hpc-aulmamei merged 3 commits into
Xilinx:devfrom
papeg:dev-enable-06_dcmac-build

Conversation

@papeg
Copy link
Copy Markdown

@papeg papeg commented May 7, 2026

Current version fails in finding SlashTools:

CMake Error at CMakeLists.txt:31 (find_package):
  By not providing "FindSlashTools.cmake" in CMAKE_MODULE_PATH this project
  has asked CMake to find a package configuration file provided by
  "SlashTools", but CMake did not find one.

  Could not find a package configuration file provided by "SlashTools" with
  any of the following names:

    SlashToolsConfig.cmake
    slashtools-config.cmake

This commit adapts the CMakeLists.txt based on the 00_axilite example to reenable the build.

Also the provided host code is added as build target.

@papeg papeg mentioned this pull request May 7, 2026
@mariodruiz
Copy link
Copy Markdown
Collaborator

@amd-vserbu, can you please review as well?

@amd-vserbu
Copy link
Copy Markdown

Others example have:

if(SLASH_USE_REPO)
  get_filename_component(REPO_ROOT "${CMAKE_CURRENT_LIST_DIR}/../.." REALPATH)
  list(APPEND CMAKE_MODULE_PATH "${REPO_ROOT}/cmake")
  include(SlashTools)
  add_subdirectory(${REPO_ROOT}/vrt ${CMAKE_CURRENT_BINARY_DIR}/vrt)
  set(_VRT_INCLUDES /usr/include/ami)
  set(_VRT_LIBS vrt ami)
else()
  find_package(vrt REQUIRED CONFIG)
  find_package(SlashTools REQUIRED)
  set(_VRT_INCLUDES "")
  set(_VRT_LIBS vrt::vrt ami)
endif()

We would want that

  add_subdirectory(${REPO_ROOT}/vrt ${CMAKE_CURRENT_BINARY_DIR}/vrt)
  set(_VRT_INCLUDES /usr/include/ami)
  set(_VRT_LIBS vrt ami)

section included as well the if branch so the example can be built using the SLASH_USE_REPO as well.

Otherwise looks good.

@papeg
Copy link
Copy Markdown
Author

papeg commented May 8, 2026

Oh right, i didnt checked the ON path - i will update it as well

@papeg
Copy link
Copy Markdown
Author

papeg commented May 8, 2026

I added the changes, to enable USE_REPO=ON.

I also set the CXX standard to 20, now its completely equivalent to the current state of the other examples.

@amd-vserbu
Copy link
Copy Markdown

Looks good to me!

@mariodruiz
Copy link
Copy Markdown
Collaborator

@hpc-aulmamei can you merge?

@hpc-aulmamei
Copy link
Copy Markdown
Collaborator

sure

@hpc-aulmamei hpc-aulmamei merged commit 2ade25c into Xilinx:dev May 11, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants