Can't get SDL_image to support JPEG
Installed libjpeg-turbo, still didn't get it.
Made USE_JPEG to ON by default
set(USE_JPEG ON) <-- on by default
message("FEATURES: ${FEATURES}") <-- print features
if("libjpeg-turbo" IN_LIST FEATURES)
set(USE_JPEG ON)
endif()
then got it working. This was the output btw
-- Using source at C:/gits/vcpkg/buildtrees/sdl2-image/src/2.0.5-633f4ae965
FEATURES: core
-- Configuring x86-windows
So how does the FEATURES list work?
Features is a very simple thing. You need specify comma separated list inside square brackets
vcpkg install sdl2-image[libjpeg-turbo] or vcpkg install sdl2-image[libjpeg-turbo,libwebp]
By default it setted to core. So you need to reinstall sdl2-image with libjpeg-turbo feature
Yeah, it's not documented well
It worked thanks.
I cannot run these commands in Ubuntu 18.04.4 LTS with vcpkg version 2020.02.04-unknownhash However when I search for sdl2-image, I can see the sdl2-image[libjpeg-turbo]. Only way to use it changing portfile.cmake
./vcpkg search sdl2-image[libjpeg-turbo]
zsh: no matches found: sdl2-image[libjpeg-turbo]
./vcpkg install sdl2-image[libjpeg-turbo]
zsh: no matches found: sdl2-image[libjpeg-turbo]
I cannot run these commands in Ubuntu 18.04.4 LTS with vcpkg version 2020.02.04-unknownhash However when I search for sdl2-image, I can see the sdl2-image[libjpeg-turbo]. Only way to use it changing portfile.cmake
./vcpkg search sdl2-image[libjpeg-turbo] zsh: no matches found: sdl2-image[libjpeg-turbo] ./vcpkg install sdl2-image[libjpeg-turbo] zsh: no matches found: sdl2-image[libjpeg-turbo]
Always quote the names of packages with features on macOS or Linux like this, vcpkg install 'sdl2-image[libjpeg-turbo]'. Square brackets are part of Z shell's syntax. For example:
arr=(0 1 2);
echo $arr[1]
# Output 0