Skip to content

Commit

Permalink
Update to latest vcpkg (2023.12.12)
Browse files Browse the repository at this point in the history
  • Loading branch information
GPSnoopy committed Dec 24, 2023
1 parent 6826682 commit c4f67f0
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 7 deletions.
8 changes: 5 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,11 @@ find_package(SDL2 CONFIG REQUIRED)

if (VCPKG_TARGET_TRIPLET)
# On Windows and MacOS we can use vcpkg to build all the dependencies.
find_path(SDL2_INCLUDE_DIR SDL2/SDL.h NO_SYSTEM_ENVIRONMENT_PATH)
find_package(SDL2-mixer CONFIG REQUIRED)
set(SDL2_ALL_LIBRARIES SDL2::SDL2main SDL2::SDL2-static SDL2::SDL2_mixer)
find_package(SDL2_mixer CONFIG REQUIRED)
set(SDL2_ALL_LIBRARIES
$<TARGET_NAME_IF_EXISTS:SDL2::SDL2main>
$<IF:$<TARGET_EXISTS:SDL2::SDL2>,SDL2::SDL2,SDL2::SDL2-static>
$<IF:$<TARGET_EXISTS:SDL2_mixer::SDL2_mixer>,SDL2_mixer::SDL2_mixer,SDL2_mixer::SDL2_mixer-static>)
else()
# On Linux we have to rely on the package system (e.g. apt-get).
# Otherwise we are likely to be missing some SDL-mixer components (e.g. proper MIDI sound support).
Expand Down
2 changes: 1 addition & 1 deletion Engine/src/sdl_util.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
#pragma once

#include <assert.h>
#include <SDL2/SDL.h>
#include <SDL.h>
#include "build.h"

// This will output the proper SDL error strings in the event that a SDL call returns an error
Expand Down
2 changes: 1 addition & 1 deletion vcpkg_macosx.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ mkdir -p build
cd build
git clone https://github.com/Microsoft/vcpkg.git vcpkg.macosx
cd vcpkg.macosx
git checkout 2022.05.10
git checkout 2023.12.12
./bootstrap-vcpkg.sh

./vcpkg install \
Expand Down
2 changes: 1 addition & 1 deletion vcpkg_windows_x64.bat
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ mkdir build
cd build || goto :error
git clone https://github.com/Microsoft/vcpkg.git vcpkg.windows.x64 || goto :error
cd vcpkg.windows.x64 || goto :error
git checkout 2022.05.10 || goto :error
git checkout 2023.12.12 || goto :error
call bootstrap-vcpkg.bat || goto :error

vcpkg.exe install ^
Expand Down
2 changes: 1 addition & 1 deletion vcpkg_windows_x86.bat
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ mkdir build
cd build || goto :error
git clone https://github.com/Microsoft/vcpkg.git vcpkg.windows.x86 || goto :error
cd vcpkg.windows.x86 || goto :error
git checkout 2022.05.10 || goto :error
git checkout 2023.12.12 || goto :error
call bootstrap-vcpkg.bat || goto :error

vcpkg.exe install ^
Expand Down

0 comments on commit c4f67f0

Please sign in to comment.