felixdoerre / primus_vk

Vulkan GPU-offloading layer
BSD 2-Clause "Simplified" License
230 stars 17 forks source link

it does not build. #60

Closed lemmy04 closed 4 years ago

lemmy04 commented 4 years ago

I'm trying to build on openSUSE 15.1, all I get is a TON of errors like this one:

mathias@kirika:~/work/nv_vulkan/primus-vk-rpm/work/BUILD/primus_vk-master> make libprimus_vk.so libnv_vulkan_wrapper.so
g++ --std=gnu++11 -g3 -DNV_DRIVER_PATH=\"libGLX_nvidia.so.0\" -I/usr/include/vulkan -I/usr/include/wayland -shared -fPIC primus_vk.cpp -o libprimus_vk.so -Wl,-soname,libprimus_vk.so.1 -ldl -lpthread primus_vk.cpp:69:3: error: ‘PFN_vkLayerCreateDevice’ does not name a type; did you mean ‘PFN_vkCreateDevice’? PFN_vkLayerCreateDevice layerCreateDevice;

felixdoerre commented 4 years ago

It seems to me, that your vulkan loader is too old: From the package dictionaries it looks like you have 1.0.65.0 (from 24 Oct 2017), however for primus_vk >= 1.2 you need at least 1.1.108. This requirement is also documented in the Readme:

Due to a bug/missing feature in the Vulkan Loader you will need Vulkan/libvulkan >= 1.1.108. If you have an older system you can try primus_vk version 1.1 which contains an ugly workaround for that issue and is therefore compatible with older Vulkan versions.

So you can try version 1.1, or look if you can upgrade your vulkan loader (for example by building it from source here: https://github.com/KhronosGroup/Vulkan-Loader)

lemmy04 commented 4 years ago

now I have the latest vulkan (1.2.134), now it fails differently:

primus_vk.cpp:7:10: fatal error: vk_layer_dispatch_table.h: Datei oder Verzeichnis nicht gefunden
 #include "vk_layer_dispatch_table.h"
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~
felixdoerre commented 4 years ago

Ths file should come with the Validation Layer Development files. Upstream it is here: https://github.com/KhronosGroup/Vulkan-ValidationLayers/tree/master/layers/generated On Fedora they seem to be in a package called vulkan-validation-layers-devel

felixdoerre commented 4 years ago

Hi @lemmy04 did the suggestion work?

lemmy04 commented 4 years ago

...haven't tried that yet...

felixdoerre commented 4 years ago

As there is not reaction since two months I assume that primus_vk either builds or you have lost interest. I close the issue now, please feel free to reopen or to start a new issue if the problem persists.