From 71107f9aae89f4ce78894271e6d5ed689d64e45e Mon Sep 17 00:00:00 2001 From: Joshua Goins Date: Thu, 25 Apr 2024 20:31:26 -0400 Subject: [PATCH] Switch to my personal fork of libcotp, add gpg-error and gcrypt --- .github/workflows/main.yml | 6 ++++++ .gitmodules | 2 +- external/CMakeLists.txt | 12 +++++++----- external/libcotp | 2 +- scripts/windows-setup.ps1 | 6 ++++++ 5 files changed, 21 insertions(+), 7 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index b4047e3..b55b539 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -80,6 +80,12 @@ jobs: Invoke-WebRequest https://xiv.zone/distrib/dependencies/iconv.zip -OutFile iconv.zip unzip iconv.zip -d ${{ steps.strings.outputs.prefix-dir }} + Invoke-WebRequest https://xiv.zone/distrib/dependencies/gcrypt.zip -OutFile gcrypt.zip + unzip gcrypt.zip -d ${{ steps.strings.outputs.prefix-dir }} + + Invoke-WebRequest https://xiv.zone/distrib/dependencies/gpg-error.zip -OutFile gpg-error.zip + unzip gpg-error.zip -d ${{ steps.strings.outputs.prefix-dir }} + Invoke-WebRequest https://xiv.zone/distrib/dependencies/icoutils.zip -OutFile icoutils.zip unzip icoutils.zip -d ${{ steps.strings.outputs.prefix-dir }} diff --git a/.gitmodules b/.gitmodules index 05dc619..d9ed198 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,6 +1,6 @@ [submodule "external/libcotp"] path = external/libcotp - url = https://github.com/paolostivanin/libcotp.git + url = https://github.com/redstrate/libcotp.git [submodule "external/libphysis"] path = external/libphysis url = ../libphysis diff --git a/external/CMakeLists.txt b/external/CMakeLists.txt index bcb8793..43611c9 100644 --- a/external/CMakeLists.txt +++ b/external/CMakeLists.txt @@ -16,12 +16,14 @@ corrosion_import_crate(MANIFEST_PATH ${CMAKE_CURRENT_SOURCE_DIR}/libphysis/Cargo FEATURES game_install visual_data) # FIXME: split visual_data? we only need texture decompression add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/libphysis/logger EXCLUDE_FROM_ALL) -find_package(PkgConfig REQUIRED) -pkg_check_modules(UNSHIELD REQUIRED IMPORTED_TARGET libunshield) - target_include_directories(physis INTERFACE ${CMAKE_CURRENT_SOURCE_DIR}/libphysis/target/public) -target_link_libraries(physis INTERFACE ${UNSHIELD_LIBRARIES} z) -target_link_directories(physis INTERFACE ${UNSHIELD_LIBRARY_DIRS}) + +# TODO: enable unshield on Windows +if (NOT WIN32) + find_package(PkgConfig REQUIRED) + pkg_check_modules(UNSHIELD REQUIRED IMPORTED_TARGET libunshield) + target_link_directories(physis INTERFACE ${UNSHIELD_LIBRARY_DIRS}) +endif() set(KDSingleApplication_QT6 ON) set(KDSingleApplication_STATIC ON) diff --git a/external/libcotp b/external/libcotp index 60461cd..9136e0a 160000 --- a/external/libcotp +++ b/external/libcotp @@ -1 +1 @@ -Subproject commit 60461cd28c297eed476ff93d9b1123c3855c7053 +Subproject commit 9136e0a94f1b4d9afe2d8aa79bfdaf1d1699f265 diff --git a/scripts/windows-setup.ps1 b/scripts/windows-setup.ps1 index 03c21cd..74b3805 100644 --- a/scripts/windows-setup.ps1 +++ b/scripts/windows-setup.ps1 @@ -51,6 +51,12 @@ Expand-Archive -Path "$LocalDir/iconv.zip" -DestinationPath $PrefixDir -Force Invoke-WebRequest https://xiv.zone/distrib/dependencies/icoutils.zip -OutFile "$LocalDir/icoutils.zip" Expand-Archive -Path "$LocalDir/icoutils.zip" -DestinationPath $PrefixDir -Force +Invoke-WebRequest https://xiv.zone/distrib/dependencies/gcrypt.zip -OutFile "$LocalDir/gcrypt.zip" +Expand-Archive -Path "$LocalDir/gcrypt.zip" -DestinationPath $PrefixDir -Force + +Invoke-WebRequest https://xiv.zone/distrib/dependencies/gpg-error.zip -OutFile "$LocalDir/gpg-error.zip" +Expand-Archive -Path "$LocalDir/gpg-error.zip" -DestinationPath $PrefixDir -Force + # Build zlib Clone "zlib" "https://github.com/madler/zlib.git" Configure "zlib" "-DBUILD_TESTING=OFF"