Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Volk present but not detected #1021

Open
juanitotc opened this issue Aug 18, 2024 · 5 comments
Open

Volk present but not detected #1021

juanitotc opened this issue Aug 18, 2024 · 5 comments

Comments

@juanitotc
Copy link

Building vulkan-tools-1.3.292, volk is not detected even though present in /usr/local.

-Dvolk_dir=/usr/local/lib/cmake/volk does not help.

-DUPDATES=ON downloads volk, but it is still not detected.

@charles-lunarg
Copy link
Contributor

It's -DUPDATE_DEPS=ON and you need to delete your cache to make sure it is getting populated. I'm not sure off the top of my head where volk_dir points to - it might be the root of the install directory, so setting it to /usr/local may work, or it may need /usr/local/lib.

@juanitotc
Copy link
Author

Thanks - yes, it’s DUPDATE_DEPS=ON, I checked volk, vulkan-headers, etc were downloaded - vulkan-headers, etc are detected, but not volk.

I’ve set -Dvolk_DIR to /usr/local, /usr/local/lib, /usr/local/lib/cmake as well, but none work.

@juanitotc
Copy link
Author

Using volk-3.1.2 and Vulkan-Tools-1.3.292, If find_package(volk QUIET REQUIRED CONFIG) is changed to find_package(Volk QUIET REQUIRED CONFIG) then volk is found.

Configuring still fails with errors of the form:

CMake Error at cube/CMakeLists.txt:246 (target_link_libraries):
  Target "vkcube" links to:

    volk::volk_headers

It looks like the target should be Volk::volk - this allows configuring to finish, but then there are many "make" errors of the form:

/usr/local/bin/cc -march=armv6zk -mtune=arm1176jzf-s -mfpu=vfp -Os -pipe CMakeFiles/vkcube.dir/cube.c.o -o vkcube  -Wl,-rpath,/usr/local/lib: -lm -lrt /usr/local/lib/libvolk.so.3.1.2 /usr/local/lib/libxcb.so -ldl -lm 
/usr/local/bin/ld: CMakeFiles/vkcube.dir/cube.c.o: in function `demo_name_object':
cube.c:(.text+0xa50): undefined reference to `vkSetDebugUtilsObjectNameEXT'

@charles-lunarg
Copy link
Contributor

So looking at my own build, I see that

VOLK_INSTALL_DIR:STRING=/home/cdgiessen/lunarg/Vulkan-Tools/external/Release/64/volk/build/install
volk_DIR:PATH=/home/cdgiessen/lunarg/Vulkan-Tools/external/Release/64/volk/build/install/lib/cmake/volk

Looking at the CMake code, you should be setting VOLK_INSTALL_DIR, not volk_DIR. I'm not sure who/what volk_DIR is or comes from, but it seems to be an internal variable, not the one that the user should set.

@juanitotc
Copy link
Author

IT looks like the problem is small "v" versus capital "V".

If I use VOLK_INSTALL_DIR=/usr/local/lib, I get the error:

CMake Error at CMakeLists.txt:59 (find_package):
  Could not find a package configuration file provided by "volk" with any of
  the following names:

    volkConfig.cmake
    volk-config.cmake

  Add the installation prefix of "volk" to CMAKE_PREFIX_PATH or set
  "volk_DIR" to a directory containing one of the above files.  If "volk"
  provides a separate development package or SDK, be sure it has been
  installed.

..but I have:

ls /usr/local/lib/cmake/volk
VolkConfig.cmake           VolkTargets-release.cmake
VolkConfigVersion.cmake    VolkTargets.cmake

As mentioned above, if I change the search from volk to Volk, volk is found, but the are still problems of volk versus Volk.

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

No branches or pull requests

2 participants