summaryrefslogtreecommitdiffstats
path: root/src/intel/vulkan/intel_icd.json.in
Commit message (Collapse)AuthorAgeFilesLines
* anv: Replace "abi_versions" with correct "api_version".Matt Turner2016-10-271-1/+1
| | | | | | | | | git history shows "abi_versions" was used from the outset. Cc: <mesa-stable@lists.freedesktop.org> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=98415 Reviewed-by: Dave Airlie <airlied@redhat.com> (cherry picked from commit 07755237d36754cb44c32e17e32cf1bc551d2373)
* anv: Suffix the intel_icd file with the host CPUJason Ekstrand2016-10-241-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Vulkan has a multi-arch problem... The idea behind the Vulkan loader is that you have a little json file on your disk that tells the loader where to find drivers. The loader looks for these json files in standard locations, and then goes and loads the my_driver.so's that they specify. This allows you as a driver implementer to put their driver wherever on the disk they want so long as the ICD points in the right place. For a multi-arch system, however, you may have multiple libvulkan_intel.so files installed that the loader needs to pick depending on architecture. Since the ICD file format does not specify any architecture information, you can't tell the loader where to find the 32-bit version vs. the 64-bit version. The way that packagers have been dealing with this is to place libvulkan_intel.so in the top level lib directory and provide just a name (and no path) to the loader. It will then use the regular system search paths and find the correct driver. While this solution works fine for distro-installed Vulkan drivers, it doesn't work so well for user-installed drivers because they may put it in /opt or $HOME/.local or some other more exotic location. In this case, you can't use an ICD json file with just a library name because it doesn't know where to find it; you also have to add that to your library lookup path via LD_LIBRARY_PATH or similar. This patch handles both use-cases by taking advantage of the fact that the loader dlopen()s each of the drivers and, if one dlopen() calls fails, it silently continues on to open other drivers. By suffixing the icd file, we can provide two different json files: intel_icd.x86_64.json and intel_icd.i686.json with different paths. Since dlopen() will only succeed on the libvulkan_intel.so of the right arch, the loader will happily ignore the others and load that one. This allows us to properly handle multi-arch while still providing a full path so user installs will work fine. I tested this on my Fedora 25 machine with 32 and 64-bit builds of our Vulkan driver installed and 32 and 64-bit builds of crucible. It seems to work just fine. Signed-off-by: Jason Ekstrand <jason@jlekstrand.net> Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Cc: "13.0" <mesa-stable@lists.freedesktop.org> (cherry picked from commit d96345de989c8f9a0328cdc3588bfe186154c8ea) Squashed with commit: anv: Always use the full driver path in the intel_icd.*.json Signed-off-by: Jason Ekstrand <jason@jlekstrand.net> Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Cc: "13.0" <mesa-stable@lists.freedesktop.org> (cherry picked from commit 7ea4ef8849c5cc158adbdff1187b91f591552196) Squashed with commit: configure: Get rid of the --disable-vulkan-icd-full-driver-path flag Signed-off-by: Jason Ekstrand <jason@jlekstrand.net> Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Cc: "13.0" <mesa-stable@lists.freedesktop.org> (cherry picked from commit 3f05fc62f924c051bdb883482452fb37650d5768)
* Revert Use absolute path in intel_icd.json and related patches.Emil Velikov2016-10-191-7/+0
| | | | | | | | | | | | | | | | | This commit effectively reverts the following commits: This reverts commit 0b6837a643bbbf3c57c5cc5030279fb4389b23b7. This reverts commit 05f36435ef117e48f457b44877d04dd6249b3bb7. This reverts commit a2ae67aa47df6dd41802462105dac7ce5ab676a2. While the feature introduced is convinient for development it is not as useful for distributions. Furthermore it even breaks things as one wishes to have both 32 and 64 bit package installed on the same system. Keep the functionality in development branch(es) and drop it from distribution packages to avoid confusion and misuse. Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
* anv: Add a --disable-vulkan-icd-full-driver-path optionJason Ekstrand2016-08-251-1/+1
| | | | | | | | This option makes installed Vulkan ICD files contain only a driver library name and not a path. This is intended for distros to help them work around multi-arch issues. Reviewed-by: Dave Airlie <airlied@redhat.com>
* anv: Give the installed intel_icd.json file an absolute pathJason Ekstrand2016-08-201-0/+7
Not providing a path allows the ICD to work on multi-arch systems but breaks it if you install anywhere other than /usr/lib. Given that users may be installing locally in .local or similar, we probably do want to provide a filename. Distros can carry a revert of this commit if they want an intel_icd.json file without the path. Signed-off-by: Jason Ekstrand <jason@jlekstrand.net> Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com> Reviewed-by: Chad Versace <chad@kiwitree.net>