libplacebo
libplacebo copied to clipboard
Is it possible to port this library to vcpkg?
vcpkg is a C++ library manager for Windows, Linux and macOS written by Microsoft. It supports CMake, meson and many other build systems.
Seems reasonable, but I don't know anything about vcpkg and I don't intend to research this. If you want to contribute a package (for any platform), I'd be happy to ACK or link to it.
I'm trying to port this library to Windows, but I found that your meson scripts do not take Windows platform into account. You are using Linux-specific parameters. I'm not familiar with meson so could you please adjust your meson scripts to make them portable to Windows? GNU FriBidi is a good example, it also uses meson and can be ported to Windows easily.
Using MinGW is impossible because vcpkg doesn't support it. It uses MSVC on Windows.
Maybe GCC only flags -> MSVC compatible flags. I don't know how fribidi does it, but it can be compiled by MSVC on Windows.
Does clang work with vcpkg?
That aside, I could see if compilation with MSVC can be made possible, but my hopes are not high. (We use e.g. preprocessor features that are only supported by GCC/clang afaict). MSVC support has never been in scope for libplacebo, mostly due to lack of interest.
In any case, I'd need some sort of compilation log or list of errors, so I can know which of the options are even causing problems.
For now, the most critical problem is meson can't find vulkan and shaderc although I have already installed them. I'm trying to find out why. I'll show you the compilation log once I got it.
However, it may take some time because I don't have much free time in my real life. Sorry for it.
I'm interested in this aswell. @wangwenx190 is there anything how i could help you with this?
For now, the most critical problem is meson can't find vulkan and shaderc although I have already installed them. I'm trying to find out why. I'll show you the compilation log once I got it.
However, it may take some time because I don't have much free time in my real life. Sorry for it.
The only way I could get meson to find shaderc on windows was by hardcoding its location here like this:
shaderc = cc.find_library(n, required: get_option('shaderc'), dirs: '<location of shaderc_shared.lib>')
This is probably extremely dumb, but hey, it compiles. ¯\_(ツ)_/¯
As for Vulkan, make sure you have an environment variable VULKAN_SDK
set to the installation directory.
Edit: Alternatively you can manually add shaderc_shared.lib to your build environment’s lib directory, e.g. *tdm-gcc\lib
for tdm gcc.
You can add the shaderc lib path to the user or computer LIB (setx LIB %LIB%;C:\Path\To\ShaderRC\lib from a regular command prompt without all the MSVS paths in place to make it stick without polluting future VS dev prompts) and the visual studio command prompts will preserve them at the end of their own lists... Then meson should be able to find them with just find_library, assuming it works roughly like CMake, although at that point you really only need the lib name for either CL / LINK or clang-cl.