Device API Vulkan not enabled when only building libtvm_runtime.so

Why is the vulkan device not recognised when I build the tvm runtime library? I have enable Vulkan SDK in the TVM runtime build config and given the right paths. The runtime builds without any errors but when I try to run a python program to access the vulkan device by

import tvm
tvm.vulkan(0).device_name

I get the error saying Device API Vulkan not found.

I did not face this error when I built the full tvm library. TVM was able to detect the Vulkan API. Is there any dependency for the full libtvm.so to execute on vulkan device. I am not generating any code hence my assumption was that only libtvm_runtime.so was sufficient for this purpose.

How do I enable Vulkan API when I build only the libtvm_runtime.so?

Thank you

likely you did not turn USE_VULKAN ON, remember to remove old cmake cache

I have enabled USE_VULKAN ON

This is part of the cmake command output. Looks like its able to find the vulkan Libraries.

But the issue still persists.

maybe you can try ldd the so file to see if the library indeed links libvulkan

Looks like it is linked to the correct libvulkan.so.

This is happening on an aarch64 device. When I tried the same on my x86_64 desktop, I was able to build only the libtvm_runtime.so which works. Is there any way to see where the loader is registered when building the runtime on the aarch64 machine. Its not a problem with the libvulkan.so as it works with libtvm.so. Any ideas on how I could further check?

interesting, you want to make sure https://github.com/apache/tvm/blob/main/src/runtime/vulkan/vulkan_device_api.cc#L449 get included in the so. maybe try to use verbose mode in build and check the linking step