Compare commits

..

1 Commits

Author SHA1 Message Date
Elad 06dcea4f41 Deny PKG installation without RAP 2025-12-06 17:55:07 +02:00
841 changed files with 25317 additions and 132307 deletions
+1 -1
View File
@@ -35,7 +35,7 @@ cmake .. \
-DUSE_SYSTEM_CURL=ON \ -DUSE_SYSTEM_CURL=ON \
-DUSE_SDL=ON \ -DUSE_SDL=ON \
-DUSE_SYSTEM_SDL=ON \ -DUSE_SYSTEM_SDL=ON \
-DUSE_SYSTEM_FFMPEG=ON \ -DUSE_SYSTEM_FFMPEG=OFF \
-DUSE_SYSTEM_OPENCV=ON \ -DUSE_SYSTEM_OPENCV=ON \
-DUSE_DISCORD_RPC=ON \ -DUSE_DISCORD_RPC=ON \
-DOpenGL_GL_PREFERENCE=LEGACY \ -DOpenGL_GL_PREFERENCE=LEGACY \
+1 -1
View File
@@ -46,7 +46,7 @@ cmake .. \
-DUSE_SYSTEM_CURL=ON \ -DUSE_SYSTEM_CURL=ON \
-DUSE_SDL=ON \ -DUSE_SDL=ON \
-DUSE_SYSTEM_SDL=ON \ -DUSE_SYSTEM_SDL=ON \
-DUSE_SYSTEM_FFMPEG=ON \ -DUSE_SYSTEM_FFMPEG=OFF \
-DUSE_SYSTEM_OPENCV=ON \ -DUSE_SYSTEM_OPENCV=ON \
-DUSE_DISCORD_RPC=ON \ -DUSE_DISCORD_RPC=ON \
-DOpenGL_GL_PREFERENCE=LEGACY \ -DOpenGL_GL_PREFERENCE=LEGACY \
+125
View File
@@ -0,0 +1,125 @@
#!/bin/sh -ex
# shellcheck disable=SC2086
export HOMEBREW_NO_AUTO_UPDATE=1
export HOMEBREW_NO_INSTALLED_DEPENDENTS_CHECK=1
export HOMEBREW_NO_ENV_HINTS=1
export HOMEBREW_NO_INSTALL_CLEANUP=1
brew install -f --overwrite --quiet pipenv googletest opencv@4 ffmpeg@5 "llvm@$LLVM_COMPILER_VER" glew sdl3 vulkan-headers
brew unlink --quiet ffmpeg qtbase qtsvg qtdeclarative
brew link -f --quiet "llvm@$LLVM_COMPILER_VER" ffmpeg@5
# moltenvk based on commit for 1.4.0 release
export HOMEBREW_DEVELOPER=1 # Prevents blocking of local formulae
wget https://raw.githubusercontent.com/Homebrew/homebrew-core/ea2bec5f1f4384e188d7fc0702ab21a20a2ced08/Formula/m/molten-vk.rb
/opt/homebrew/bin/brew install -f --overwrite --formula --quiet ./molten-vk.rb
export HOMEBREW_DEVELOPER=0
export CXX=clang++
export CC=clang
export BREW_PATH;
BREW_PATH="$(brew --prefix)"
export BREW_BIN="/opt/homebrew/bin"
export BREW_SBIN="/opt/homebrew/sbin"
export CMAKE_EXTRA_OPTS='-DLLVM_TARGETS_TO_BUILD=arm64'
export WORKDIR;
WORKDIR="$(pwd)"
# Setup ccache
if [ ! -d "$CCACHE_DIR" ]; then
mkdir -p "$CCACHE_DIR"
fi
# Get Qt
if [ ! -d "/tmp/Qt/$QT_VER" ]; then
mkdir -p "/tmp/Qt"
git clone https://github.com/engnr/qt-downloader.git
cd qt-downloader
git checkout f52efee0f18668c6d6de2dec0234b8c4bc54c597
sed -i '' "s/'qt{0}_{0}{1}{2}'.format(major, minor, patch)]))/'qt{0}_{0}{1}{2}'.format(major, minor, patch), 'qt{0}_{0}{1}{2}'.format(major, minor, patch)]))/g" qt-downloader
sed -i '' "s/'{}\/{}\/qt{}_{}\/'/'{0}\/{1}\/qt{2}_{3}\/qt{2}_{3}\/'/g" qt-downloader
cd "/tmp/Qt"
"$BREW_PATH/bin/pipenv" run pip3 uninstall py7zr requests semantic_version lxml
"$BREW_PATH/bin/pipenv" run pip3 install py7zr requests semantic_version lxml --no-cache
mkdir -p "$QT_VER/macos" ; ln -s "macos" "$QT_VER/clang_64"
sed -i '' 's/args\.version \/ derive_toolchain_dir(args) \/ //g' "$WORKDIR/qt-downloader/qt-downloader"
"$BREW_PATH/bin/pipenv" run "$WORKDIR/qt-downloader/qt-downloader" macos desktop "$QT_VER" clang_64 --opensource --addons qtmultimedia qtimageformats -o "$QT_VER/clang_64"
fi
cd "$WORKDIR"
ditto "/tmp/Qt/$QT_VER" "qt-downloader/$QT_VER"
export Qt6_DIR="$WORKDIR/qt-downloader/$QT_VER/clang_64/lib/cmake/Qt$QT_VER_MAIN"
export SDL3_DIR="$BREW_PATH/opt/sdl3/lib/cmake/SDL3"
export PATH="$BREW_PATH/opt/llvm@$LLVM_COMPILER_VER/bin:$WORKDIR/qt-downloader/$QT_VER/clang_64/bin:$BREW_BIN:$BREW_SBIN:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/Library/Apple/usr/bin:$PATH"
export LDFLAGS="-L$BREW_PATH/lib $BREW_PATH/opt/ffmpeg@5/lib/libavcodec.dylib $BREW_PATH/opt/ffmpeg@5/lib/libavformat.dylib $BREW_PATH/opt/ffmpeg@5/lib/libavutil.dylib $BREW_PATH/opt/ffmpeg@5/lib/libswscale.dylib $BREW_PATH/opt/ffmpeg@5/lib/libswresample.dylib $BREW_PATH/opt/llvm@$LLVM_COMPILER_VER/lib/c++/libc++.1.dylib $BREW_PATH/lib/libSDL3.dylib $BREW_PATH/lib/libGLEW.dylib $BREW_PATH/opt/llvm@$LLVM_COMPILER_VER/lib/unwind/libunwind.1.dylib -Wl,-rpath,$BREW_PATH/lib"
export CPPFLAGS="-I$BREW_PATH/include -I$BREW_PATH/include -no-pie -D__MAC_OS_X_VERSION_MIN_REQUIRED=140000"
export CFLAGS="-D__MAC_OS_X_VERSION_MIN_REQUIRED=140000"
export LIBRARY_PATH="$BREW_PATH/lib"
export LD_LIBRARY_PATH="$BREW_PATH/lib"
export VULKAN_SDK
VULKAN_SDK="$BREW_PATH/opt/molten-vk"
ln -s "$VULKAN_SDK/lib/libMoltenVK.dylib" "$VULKAN_SDK/lib/libvulkan.dylib" || true
export VK_ICD_FILENAMES="$VULKAN_SDK/share/vulkan/icd.d/MoltenVK_icd.json"
export LLVM_DIR
LLVM_DIR="$BREW_PATH/opt/llvm@$LLVM_COMPILER_VER"
# exclude ffmpeg, LLVM, opencv, and sdl from submodule update
# shellcheck disable=SC2046
git submodule -q update --init --depth=1 --jobs=8 $(awk '/path/ && !/ffmpeg/ && !/llvm/ && !/opencv/ && !/SDL/ && !/feralinteractive/ { print $3 }' .gitmodules)
# 3rdparty fixes
sed -i '' "s/extern const double NSAppKitVersionNumber;/const double NSAppKitVersionNumber = 1343;/g" 3rdparty/hidapi/hidapi/mac/hid.c
mkdir build && cd build || exit 1
export MACOSX_DEPLOYMENT_TARGET=14.0
"$BREW_PATH/bin/cmake" .. \
-DBUILD_RPCS3_TESTS="${RUN_UNIT_TESTS}" \
-DRUN_RPCS3_TESTS="${RUN_UNIT_TESTS}" \
-DUSE_SDL=ON \
-DUSE_DISCORD_RPC=ON \
-DUSE_VULKAN=ON \
-DUSE_ALSA=OFF \
-DUSE_PULSE=OFF \
-DUSE_AUDIOUNIT=ON \
-DUSE_SYSTEM_FFMPEG=ON \
-DLLVM_CCACHE_BUILD=OFF \
-DLLVM_BUILD_RUNTIME=OFF \
-DLLVM_BUILD_TOOLS=OFF \
-DLLVM_INCLUDE_DOCS=OFF \
-DLLVM_INCLUDE_EXAMPLES=OFF \
-DLLVM_INCLUDE_TESTS=OFF \
-DLLVM_INCLUDE_TOOLS=OFF \
-DLLVM_INCLUDE_UTILS=OFF \
-DLLVM_USE_PERF=OFF \
-DLLVM_ENABLE_Z3_SOLVER=OFF \
-DUSE_NATIVE_INSTRUCTIONS=OFF \
-DUSE_SYSTEM_MVK=ON \
-DUSE_SYSTEM_FAUDIO=OFF \
-DUSE_SYSTEM_SDL=ON \
-DUSE_SYSTEM_OPENCV=ON \
"$CMAKE_EXTRA_OPTS" \
-DLLVM_TARGET_ARCH=arm64 \
-DCMAKE_OSX_ARCHITECTURES=arm64 \
-DCMAKE_IGNORE_PATH="$BREW_PATH/lib" \
-DCMAKE_IGNORE_PREFIX_PATH=/opt/homebrew/opt \
-DCMAKE_CXX_FLAGS="-D__MAC_OS_X_VERSION_MIN_REQUIRED=140000" \
-DCMAKE_POLICY_VERSION_MINIMUM=3.5 \
-DCMAKE_OSX_SYSROOT="$(xcrun --sdk macosx --show-sdk-path)" \
-G Ninja
"$BREW_PATH/bin/ninja"; build_status=$?;
cd ..
# If it compiled succesfully let's deploy.
if [ "$build_status" -eq 0 ]; then
.ci/deploy-mac-arm64.sh
fi
+72 -81
View File
@@ -1,52 +1,38 @@
#!/bin/sh -ex #!/bin/sh -ex
# Gather explicit version number and number of commits
COMM_TAG=$(awk '/version{.*}/ { printf("%d.%d.%d", $5, $6, $7) }' rpcs3/rpcs3_version.cpp)
COMM_COUNT=$(git rev-list --count HEAD)
COMM_HASH=$(git rev-parse --short=8 HEAD)
# AVVER is used for GitHub releases, it is the version number. LVER is used for release naming.
AVVER="${COMM_TAG}-${COMM_COUNT}"
export LVER="${COMM_TAG}-${COMM_COUNT}-${COMM_HASH}"
echo "AVVER=$AVVER" >> .ci/ci-vars.env
# shellcheck disable=SC2086
export HOMEBREW_NO_AUTO_UPDATE=1 export HOMEBREW_NO_AUTO_UPDATE=1
export HOMEBREW_NO_INSTALLED_DEPENDENTS_CHECK=1 export HOMEBREW_NO_INSTALLED_DEPENDENTS_CHECK=1
export HOMEBREW_NO_ENV_HINTS=1 export HOMEBREW_NO_ENV_HINTS=1
export HOMEBREW_NO_INSTALL_CLEANUP=1 export HOMEBREW_NO_INSTALL_CLEANUP=1
brew update
brew install -f --overwrite --quiet ccache "llvm@$LLVM_COMPILER_VER"
brew link -f --overwrite --quiet "llvm@$LLVM_COMPILER_VER"
if [ "$AARCH64" -eq 1 ]; then
brew install -f --overwrite --quiet googletest opencv@4 sdl3 vulkan-headers vulkan-loader molten-vk
brew unlink --quiet ffmpeg fmt qtbase qtsvg qtdeclarative protobuf || true
else
arch -x86_64 /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
arch -x86_64 /usr/local/bin/brew install -f --overwrite --quiet python@3.14 opencv@4 "llvm@$LLVM_COMPILER_VER" sdl3 vulkan-headers vulkan-loader molten-vk
arch -x86_64 /usr/local/bin/brew unlink --quiet ffmpeg qtbase qtsvg qtdeclarative protobuf || true
fi
brew install -f --overwrite --quiet ccache pipenv "llvm@$LLVM_COMPILER_VER"
brew link -f --overwrite --quiet "llvm@$LLVM_COMPILER_VER"
# shellcheck disable=SC3009
rm /usr/local/bin/{idle3.14,pip3.14,pydoc3.14,python3.14,python3.14-config} && \
rm /usr/local/bin/{idle3,pip3,pydoc3,python3,python3-config}
arch -x86_64 /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
arch -x86_64 /usr/local/bin/brew install -f --overwrite --quiet opencv@4 ffmpeg@5 "llvm@$LLVM_COMPILER_VER" glew sdl3 vulkan-headers
arch -x86_64 /usr/local/bin/brew unlink --quiet ffmpeg qtbase qtsvg qtdeclarative
arch -x86_64 /usr/local/bin/brew link -f --overwrite --quiet "llvm@$LLVM_COMPILER_VER" ffmpeg@5
# moltenvk based on commit for 1.4.0 release
export HOMEBREW_DEVELOPER=1 # Prevents blocking of local formulae
wget https://raw.githubusercontent.com/Homebrew/homebrew-core/ea2bec5f1f4384e188d7fc0702ab21a20a2ced08/Formula/m/molten-vk.rb
arch -x86_64 /usr/local/bin/brew install -f --overwrite --formula --quiet ./molten-vk.rb
export HOMEBREW_DEVELOPER=0
export CXX=clang++ export CXX=clang++
export CC=clang export CC=clang
export BREW_PATH; export BREW_X64_PATH;
if [ "$AARCH64" -eq 1 ]; then BREW_X64_PATH="$("/usr/local/bin/brew" --prefix)"
BREW_PATH="$(brew --prefix)" export BREW_BIN="/usr/local/bin"
export BREW_BIN="/opt/homebrew/bin" export BREW_SBIN="/usr/local/sbin"
export BREW_SBIN="/opt/homebrew/sbin" export CMAKE_EXTRA_OPTS='-DLLVM_TARGETS_TO_BUILD=X86'
else
BREW_PATH="$("/usr/local/bin/brew" --prefix)"
export BREW_BIN="/usr/local/bin"
export BREW_SBIN="/usr/local/sbin"
fi
export WORKDIR; export WORKDIR;
WORKDIR="$(pwd)" WORKDIR="$(pwd)"
# Setup ccache
if [ ! -d "$CCACHE_DIR" ]; then
mkdir -p "$CCACHE_DIR"
fi
# Get Qt # Get Qt
if [ ! -d "/tmp/Qt/$QT_VER" ]; then if [ ! -d "/tmp/Qt/$QT_VER" ]; then
mkdir -p "/tmp/Qt" mkdir -p "/tmp/Qt"
@@ -56,77 +42,82 @@ if [ ! -d "/tmp/Qt/$QT_VER" ]; then
sed -i '' "s/'qt{0}_{0}{1}{2}'.format(major, minor, patch)]))/'qt{0}_{0}{1}{2}'.format(major, minor, patch), 'qt{0}_{0}{1}{2}'.format(major, minor, patch)]))/g" qt-downloader sed -i '' "s/'qt{0}_{0}{1}{2}'.format(major, minor, patch)]))/'qt{0}_{0}{1}{2}'.format(major, minor, patch), 'qt{0}_{0}{1}{2}'.format(major, minor, patch)]))/g" qt-downloader
sed -i '' "s/'{}\/{}\/qt{}_{}\/'/'{0}\/{1}\/qt{2}_{3}\/qt{2}_{3}\/'/g" qt-downloader sed -i '' "s/'{}\/{}\/qt{}_{}\/'/'{0}\/{1}\/qt{2}_{3}\/qt{2}_{3}\/'/g" qt-downloader
cd "/tmp/Qt" cd "/tmp/Qt"
pip3 install py7zr requests semantic_version lxml --no-cache --break-system-packages "/opt/homebrew/bin/pipenv" --python "/opt/homebrew/bin/python3" run pip3 install py7zr requests semantic_version lxml
mkdir -p "$QT_VER/macos" ; ln -s "macos" "$QT_VER/clang_64" mkdir -p "$QT_VER/macos" ; ln -s "macos" "$QT_VER/clang_64"
sed -i '' 's/args\.version \/ derive_toolchain_dir(args) \/ //g' "$WORKDIR/qt-downloader/qt-downloader" sed -i '' 's/args\.version \/ derive_toolchain_dir(args) \/ //g' "$WORKDIR/qt-downloader/qt-downloader"
python3 "$WORKDIR/qt-downloader/qt-downloader" macos desktop "$QT_VER" clang_64 --opensource --addons qtmultimedia qtimageformats -o "$QT_VER/clang_64" "/opt/homebrew/bin/pipenv" --python "/opt/homebrew/bin/python3" run "$WORKDIR/qt-downloader/qt-downloader" macos desktop "$QT_VER" clang_64 --opensource --addons qtmultimedia qtimageformats -o "$QT_VER/clang_64"
fi fi
cd "$WORKDIR" cd "$WORKDIR"
ditto "/tmp/Qt/$QT_VER" "qt-downloader/$QT_VER" ditto "/tmp/Qt/$QT_VER" "qt-downloader/$QT_VER"
export Qt6_DIR="$WORKDIR/qt-downloader/$QT_VER/clang_64/lib/cmake/Qt$QT_VER_MAIN" export Qt6_DIR="$WORKDIR/qt-downloader/$QT_VER/clang_64/lib/cmake/Qt$QT_VER_MAIN"
export SDL3_DIR="$BREW_PATH/opt/sdl3/lib/cmake/SDL3" export SDL3_DIR="$BREW_X64_PATH/opt/sdl3/lib/cmake/SDL3"
export PATH="/opt/homebrew/opt/llvm@$LLVM_COMPILER_VER/bin:$PATH" export PATH="/opt/homebrew/opt/llvm@$LLVM_COMPILER_VER/bin:$WORKDIR/qt-downloader/$QT_VER/clang_64/bin:$BREW_BIN:$BREW_SBIN:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/Library/Apple/usr/bin:$PATH"
export LDFLAGS="-L$BREW_PATH/opt/llvm@$LLVM_COMPILER_VER/lib/c++ -L$BREW_PATH/opt/llvm@$LLVM_COMPILER_VER/lib/unwind -lunwind" # shellcheck disable=SC2155
export LDFLAGS="-L$BREW_X64_PATH/lib -Wl,-rpath,$BREW_X64_PATH/lib,-L$(brew --prefix llvm)/lib/c++"
export CPPFLAGS="-I$BREW_X64_PATH/include -msse -msse2 -mcx16 -no-pie -D__MAC_OS_X_VERSION_MIN_REQUIRED=140000"
export CFLAGS="-D__MAC_OS_X_VERSION_MIN_REQUIRED=140000"
export LIBRARY_PATH="$BREW_X64_PATH/opt/llvm@$LLVM_COMPILER_VER/lib:$BREW_X64_PATH/lib"
export LD_LIBRARY_PATH="$BREW_X64_PATH/opt/llvm@$LLVM_COMPILER_VER/lib:$BREW_X64_PATH/lib"
export VULKAN_SDK export VULKAN_SDK
VULKAN_SDK="$BREW_PATH/opt/molten-vk" VULKAN_SDK="$BREW_X64_PATH/opt/molten-vk"
ln -s "$BREW_PATH/opt/vulkan-loader/lib/libvulkan.dylib" "$VULKAN_SDK/lib/libvulkan.dylib" ln -s "$VULKAN_SDK/lib/libMoltenVK.dylib" "$VULKAN_SDK/lib/libvulkan.dylib"
export VK_ICD_FILENAMES="$VULKAN_SDK/share/vulkan/icd.d/MoltenVK_icd.json"
export LLVM_DIR export LLVM_DIR
LLVM_DIR="$BREW_PATH/opt/llvm@$LLVM_COMPILER_VER" LLVM_DIR="$BREW_X64_PATH/opt/llvm@$LLVM_COMPILER_VER"
# Pull all the submodules except some # exclude ffmpeg, LLVM, opencv, and sdl from submodule update
# shellcheck disable=SC2046 # shellcheck disable=SC2046
git submodule -q update --init --depth=1 --jobs=8 $(awk '/path/ && !/llvm/ && !/opencv/ && !/SDL/ && !/feralinteractive/ { print $3 }' .gitmodules) git submodule -q update --init --depth=1 --jobs=8 $(awk '/path/ && !/ffmpeg/ && !/llvm/ && !/opencv/ && !/SDL/ && !/feralinteractive/ { print $3 }' .gitmodules)
# 3rdparty fixes
sed -i '' "s/extern const double NSAppKitVersionNumber;/const double NSAppKitVersionNumber = 1343;/g" 3rdparty/hidapi/hidapi/mac/hid.c
mkdir build && cd build || exit 1 mkdir build && cd build || exit 1
if [ "$AARCH64" -eq 1 ]; then export MACOSX_DEPLOYMENT_TARGET=14.0
cmake .. \
-DBUILD_RPCS3_TESTS="${RUN_UNIT_TESTS}" \ "/opt/homebrew/bin/cmake" .. \
-DRUN_RPCS3_TESTS="${RUN_UNIT_TESTS}" \
-DCMAKE_OSX_DEPLOYMENT_TARGET=14.4 \
-DCMAKE_OSX_SYSROOT="$(xcrun --sdk macosx --show-sdk-path)" \
-DMACOSX_BUNDLE_SHORT_VERSION_STRING="${COMM_TAG}" \
-DMACOSX_BUNDLE_BUNDLE_VERSION="${COMM_COUNT}" \
-DSTATIC_LINK_LLVM=ON \
-DUSE_SDL=ON \
-DUSE_DISCORD_RPC=ON \
-DUSE_AUDIOUNIT=ON \
-DUSE_SYSTEM_FFMPEG=OFF \
-DUSE_NATIVE_INSTRUCTIONS=OFF \
-DUSE_PRECOMPILED_HEADERS=OFF \
-DUSE_SYSTEM_MVK=ON \
-DUSE_SYSTEM_SDL=ON \
-DUSE_SYSTEM_OPENCV=ON \
-G Ninja
else
cmake .. \
-DBUILD_RPCS3_TESTS=OFF \ -DBUILD_RPCS3_TESTS=OFF \
-DRUN_RPCS3_TESTS=OFF \ -DRUN_RPCS3_TESTS=OFF \
-DUSE_SDL=ON \
-DUSE_DISCORD_RPC=ON \
-DUSE_VULKAN=ON \
-DUSE_ALSA=OFF \
-DUSE_PULSE=OFF \
-DUSE_AUDIOUNIT=ON \
-DUSE_SYSTEM_FFMPEG=ON \
-DLLVM_CCACHE_BUILD=OFF \
-DLLVM_BUILD_RUNTIME=OFF \
-DLLVM_BUILD_TOOLS=OFF \
-DLLVM_INCLUDE_DOCS=OFF \
-DLLVM_INCLUDE_EXAMPLES=OFF \
-DLLVM_INCLUDE_TESTS=OFF \
-DLLVM_INCLUDE_TOOLS=OFF \
-DLLVM_INCLUDE_UTILS=OFF \
-DLLVM_USE_PERF=OFF \
-DLLVM_ENABLE_Z3_SOLVER=OFF \
-DUSE_NATIVE_INSTRUCTIONS=OFF \
-DUSE_SYSTEM_MVK=ON \
-DUSE_SYSTEM_FAUDIO=OFF \
-DUSE_SYSTEM_SDL=ON \
-DUSE_SYSTEM_OPENCV=ON \
"$CMAKE_EXTRA_OPTS" \
-DLLVM_TARGET_ARCH=X86_64 \
-DCMAKE_OSX_ARCHITECTURES=x86_64 \ -DCMAKE_OSX_ARCHITECTURES=x86_64 \
-DCMAKE_SYSTEM_PROCESSOR=x86_64 \ -DCMAKE_SYSTEM_PROCESSOR=x86_64 \
-DCMAKE_TOOLCHAIN_FILE=buildfiles/cmake/TCDarwinX86_64.cmake \ -DCMAKE_TOOLCHAIN_FILE=buildfiles/cmake/TCDarwinX86_64.cmake \
-DCMAKE_OSX_DEPLOYMENT_TARGET=14.4 \ -DCMAKE_IGNORE_PATH="$BREW_X64_PATH/lib" \
-DCMAKE_IGNORE_PREFIX_PATH=/usr/local/opt \
-DCMAKE_CXX_FLAGS="-D__MAC_OS_X_VERSION_MIN_REQUIRED=140000" \
-DCMAKE_POLICY_VERSION_MINIMUM=3.5 \
-DCMAKE_OSX_SYSROOT="$(xcrun --sdk macosx --show-sdk-path)" \ -DCMAKE_OSX_SYSROOT="$(xcrun --sdk macosx --show-sdk-path)" \
-DMACOSX_BUNDLE_SHORT_VERSION_STRING="${COMM_TAG}" \
-DMACOSX_BUNDLE_BUNDLE_VERSION="${COMM_COUNT}"\
-DSTATIC_LINK_LLVM=ON \
-DUSE_SDL=ON \
-DUSE_DISCORD_RPC=ON \
-DUSE_AUDIOUNIT=ON \
-DUSE_SYSTEM_FFMPEG=OFF \
-DUSE_NATIVE_INSTRUCTIONS=OFF \
-DUSE_PRECOMPILED_HEADERS=OFF \
-DUSE_SYSTEM_MVK=ON \
-DUSE_SYSTEM_SDL=ON \
-DUSE_SYSTEM_OPENCV=ON \
-G Ninja -G Ninja
fi
ninja; build_status=$?; "/opt/homebrew/bin/ninja"; build_status=$?;
cd .. cd ..
+4 -7
View File
@@ -2,9 +2,6 @@
git config --global --add safe.directory '*' git config --global --add safe.directory '*'
CPU_ARCH="${1:-x86_64}"
MSYS2="${2:-clang64}"
# Pull all the submodules except some # Pull all the submodules except some
# Note: Tried to use git submodule status, but it takes over 20 seconds # Note: Tried to use git submodule status, but it takes over 20 seconds
# shellcheck disable=SC2046 # shellcheck disable=SC2046
@@ -26,7 +23,7 @@ else
fi fi
cmake .. \ cmake .. \
-DCMAKE_PREFIX_PATH=/"${MSYS2}" \ -DCMAKE_PREFIX_PATH=/clang64 \
-DCMAKE_INSTALL_PREFIX=/usr \ -DCMAKE_INSTALL_PREFIX=/usr \
-DUSE_NATIVE_INSTRUCTIONS=OFF \ -DUSE_NATIVE_INSTRUCTIONS=OFF \
-DUSE_PRECOMPILED_HEADERS=OFF \ -DUSE_PRECOMPILED_HEADERS=OFF \
@@ -47,8 +44,8 @@ cmake .. \
-DUSE_DISCORD_RPC=ON \ -DUSE_DISCORD_RPC=ON \
-DOpenGL_GL_PREFERENCE=LEGACY \ -DOpenGL_GL_PREFERENCE=LEGACY \
-DWITH_LLVM=ON \ -DWITH_LLVM=ON \
-DLLVM_DIR=/"${MSYS2}"/lib/cmake/llvm \ -DLLVM_DIR=/clang64/lib/cmake/llvm \
-DVulkan_LIBRARY=/"${MSYS2}"/lib/libvulkan-1.dll.a \ -DVulkan_LIBRARY=/clang64/lib/libvulkan-1.dll.a \
-DSTATIC_LINK_LLVM=ON \ -DSTATIC_LINK_LLVM=ON \
-DBUILD_RPCS3_TESTS=OFF \ -DBUILD_RPCS3_TESTS=OFF \
-DRUN_RPCS3_TESTS=OFF \ -DRUN_RPCS3_TESTS=OFF \
@@ -60,5 +57,5 @@ cd ..
# If it compiled succesfully let's deploy. # If it compiled succesfully let's deploy.
if [ "$build_status" -eq 0 ]; then if [ "$build_status" -eq 0 ]; then
.ci/deploy-windows-clang.sh "${CPU_ARCH}" "${MSYS2}" .ci/deploy-windows-clang.sh "x86_64"
fi fi
-3
View File
@@ -19,9 +19,6 @@ if [ "$DEPLOY_APPIMAGE" = "true" ]; then
APPIMAGE_EXTRACT_AND_RUN=1 linuxdeploy --appdir AppDir --plugin qt --plugin checkrt APPIMAGE_EXTRACT_AND_RUN=1 linuxdeploy --appdir AppDir --plugin qt --plugin checkrt
# Restore App Icon
ln -sr ./AppDir/rpcs3.svg ./AppDir/.DirIcon
# Remove libwayland-client because it has platform-dependent exports and breaks other OSes # Remove libwayland-client because it has platform-dependent exports and breaks other OSes
rm -f ./AppDir/usr/lib/libwayland-client.so* rm -f ./AppDir/usr/lib/libwayland-client.so*
+76
View File
@@ -0,0 +1,76 @@
#!/bin/sh -ex
# shellcheck disable=SC2086
cd build || exit 1
# Gather explicit version number and number of commits
COMM_TAG=$(awk '/version{.*}/ { printf("%d.%d.%d", $5, $6, $7) }' ../rpcs3/rpcs3_version.cpp)
COMM_COUNT=$(git rev-list --count HEAD)
COMM_HASH=$(git rev-parse --short=8 HEAD)
AVVER="${COMM_TAG}-${COMM_COUNT}"
# AVVER is used for GitHub releases, it is the version number.
echo "AVVER=$AVVER" >> ../.ci/ci-vars.env
cd bin
mkdir "rpcs3.app/Contents/lib/" || true
cp "$(realpath /opt/homebrew/opt/llvm@$LLVM_COMPILER_VER/lib/c++/libc++abi.1.0.dylib)" "rpcs3.app/Contents/Frameworks/libc++abi.1.dylib"
cp "$(realpath /opt/homebrew/opt/gcc/lib/gcc/current/libgcc_s.1.1.dylib)" "rpcs3.app/Contents/Frameworks/libgcc_s.1.1.dylib"
cp "$(realpath /opt/homebrew/lib/libsharpyuv.0.dylib)" "rpcs3.app/Contents/lib/libsharpyuv.0.dylib"
cp "$(realpath /opt/homebrew/lib/libintl.8.dylib)" "rpcs3.app/Contents/lib/libintl.8.dylib"
rm -rf "rpcs3.app/Contents/Frameworks/QtPdf.framework" \
"rpcs3.app/Contents/Frameworks/QtQml.framework" \
"rpcs3.app/Contents/Frameworks/QtQmlModels.framework" \
"rpcs3.app/Contents/Frameworks/QtQuick.framework" \
"rpcs3.app/Contents/Frameworks/QtVirtualKeyboard.framework" \
"rpcs3.app/Contents/Plugins/platforminputcontexts" \
"rpcs3.app/Contents/Plugins/virtualkeyboard" \
"rpcs3.app/Contents/Resources/git"
../../.ci/optimize-mac.sh rpcs3.app
# Download translations
mkdir -p "rpcs3.app/Contents/translations"
ZIP_URL=$(curl -fsSL "https://api.github.com/repos/RPCS3/rpcs3_translations/releases/latest" \
| grep "browser_download_url" \
| grep "RPCS3-languages.zip" \
| cut -d '"' -f 4)
if [ -z "$ZIP_URL" ]; then
echo "Failed to find RPCS3-languages.zip in the latest release. Continuing without translations."
else
echo "Downloading translations from: $ZIP_URL"
curl -L -o translations.zip "$ZIP_URL" || {
echo "Failed to download translations.zip. Continuing without translations."
exit 0
}
unzip -o translations.zip -d "rpcs3.app/Contents/translations" >/dev/null 2>&1 || \
echo "Failed to extract translations.zip. Continuing without translations."
rm -f translations.zip
fi
# Hack
install_name_tool -delete_rpath /opt/homebrew/lib RPCS3.app/Contents/MacOS/rpcs3 || echo "Hack for deleting rpath /opt/homebrew/lib not needed"
install_name_tool -delete_rpath /opt/homebrew/opt/llvm@$LLVM_COMPILER_VER/lib RPCS3.app/Contents/MacOS/rpcs3 || echo "Hack for deleting rpath /opt/homebrew/opt/llvm@$LLVM_COMPILER_VER/lib not needed"
# Need to do this rename hack due to case insensitive filesystem
mv rpcs3.app RPCS3_.app
mv RPCS3_.app RPCS3.app
# NOTE: "--deep" is deprecated
codesign --deep -fs - RPCS3.app
echo "[InternetShortcut]" > Quickstart.url
echo "URL=https://rpcs3.net/quickstart" >> Quickstart.url
echo "IconIndex=0" >> Quickstart.url
ARCHIVE_FILEPATH="$BUILD_ARTIFACTSTAGINGDIRECTORY/rpcs3-v${COMM_TAG}-${COMM_COUNT}-${COMM_HASH}_macos_arm64.7z"
"/opt/homebrew/bin/7z" a -mx9 "$ARCHIVE_FILEPATH" RPCS3.app Quickstart.url
FILESIZE=$(stat -f %z "$ARCHIVE_FILEPATH")
SHA256SUM=$(shasum -a 256 "$ARCHIVE_FILEPATH" | awk '{ print $1 }')
cd ..
echo "${SHA256SUM};${FILESIZE}B" > "$RELEASE_MESSAGE"
cd bin
+36 -57
View File
@@ -3,21 +3,24 @@
# shellcheck disable=SC2086 # shellcheck disable=SC2086
cd build || exit 1 cd build || exit 1
# Gather explicit version number and number of commits
COMM_TAG=$(awk '/version{.*}/ { printf("%d.%d.%d", $5, $6, $7) }' ../rpcs3/rpcs3_version.cpp)
COMM_COUNT=$(git rev-list --count HEAD)
COMM_HASH=$(git rev-parse --short=8 HEAD)
AVVER="${COMM_TAG}-${COMM_COUNT}"
# AVVER is used for GitHub releases, it is the version number.
echo "AVVER=$AVVER" >> ../.ci/ci-vars.env
cd bin cd bin
git clone --revision=a075e5e417f87675ea3137b7365f3e5a99608d72 https://github.com/KhronosGroup/MoltenVK.git mkdir "rpcs3.app/Contents/lib/"
cd MoltenVK
./fetchDependencies --macos
sudo xcode-select -switch /Applications/Xcode_16.2.app/Contents/Developer
make macos MVK_USE_METAL_PRIVATE_API=1
cd ../
mkdir -p "rpcs3.app/Contents/Resources/vulkan/icd.d" || true cp "$(realpath /usr/local/opt/llvm@$LLVM_COMPILER_VER/lib/c++/libc++abi.1.0.dylib)" "rpcs3.app/Contents/Frameworks/libc++abi.1.dylib"
cp "MoltenVK/Package/Release/MoltenVK/dynamic/dylib/macOS/libMoltenVK.dylib" "rpcs3.app/Contents/Frameworks/libMoltenVK.dylib" cp "$(realpath /usr/local/opt/llvm@$LLVM_COMPILER_VER/lib/unwind/libunwind.1.dylib)" "rpcs3.app/Contents/Frameworks/libunwind.1.dylib"
cp "MoltenVK/Package/Release/MoltenVK/dynamic/dylib/macOS/MoltenVK_icd.json" "rpcs3.app/Contents/Resources/vulkan/icd.d/MoltenVK_icd.json" cp "$(realpath /usr/local/opt/gcc/lib/gcc/current/libgcc_s.1.1.dylib)" "rpcs3.app/Contents/Frameworks/libgcc_s.1.1.dylib"
sed -i '' "s/.\//..\/..\/..\/Frameworks\//g" "rpcs3.app/Contents/Resources/vulkan/icd.d/MoltenVK_icd.json" cp "$(realpath /usr/local/lib/libsharpyuv.0.dylib)" "rpcs3.app/Contents/lib/libsharpyuv.0.dylib"
cp "$(realpath /usr/local/lib/libintl.8.dylib)" "rpcs3.app/Contents/lib/libintl.8.dylib"
cp "$(realpath $BREW_PATH/opt/llvm@$LLVM_COMPILER_VER/lib/c++/libc++abi.1.0.dylib)" "rpcs3.app/Contents/Frameworks/libc++abi.1.dylib"
cp "$(realpath $BREW_PATH/opt/gcc/lib/gcc/current/libgcc_s.1.1.dylib)" "rpcs3.app/Contents/Frameworks/libgcc_s.1.1.dylib"
rm -rf "rpcs3.app/Contents/Frameworks/QtPdf.framework" \ rm -rf "rpcs3.app/Contents/Frameworks/QtPdf.framework" \
"rpcs3.app/Contents/Frameworks/QtQml.framework" \ "rpcs3.app/Contents/Frameworks/QtQml.framework" \
@@ -26,56 +29,36 @@ rm -rf "rpcs3.app/Contents/Frameworks/QtPdf.framework" \
"rpcs3.app/Contents/Frameworks/QtVirtualKeyboard.framework" \ "rpcs3.app/Contents/Frameworks/QtVirtualKeyboard.framework" \
"rpcs3.app/Contents/Plugins/platforminputcontexts" \ "rpcs3.app/Contents/Plugins/platforminputcontexts" \
"rpcs3.app/Contents/Plugins/virtualkeyboard" \ "rpcs3.app/Contents/Plugins/virtualkeyboard" \
"rpcs3.app/Contents/Resources/git" || true "rpcs3.app/Contents/Resources/git"
../../.ci/optimize-mac.sh rpcs3.app ../../.ci/optimize-mac.sh rpcs3.app
# Download translations # Download translations
mkdir -p "rpcs3.app/Contents/translations" mkdir -p "rpcs3.app/Contents/translations"
ZIP_URL="https://github.com/RPCS3/rpcs3_translations/releases/latest/download/RPCS3-languages.zip" ZIP_URL=$(curl -fsSL "https://api.github.com/repos/RPCS3/rpcs3_translations/releases/latest" \
echo "Downloading translations from: $ZIP_URL" | grep "browser_download_url" \
if curl -fsSL "$ZIP_URL" -o "translations.zip"; then | grep "RPCS3-languages.zip" \
echo "Successfully downloaded translations." | cut -d '"' -f 4)
if unzip -o translations.zip -d "rpcs3.app/Contents/translations" >/dev/null 2>&1; then if [ -z "$ZIP_URL" ]; then
rm -f translations.zip echo "Failed to find RPCS3-languages.zip in the latest release. Continuing without translations."
else
echo "Failed to extract translations.zip. Continuing without translations."
rm -f translations.zip
fi
else else
echo "Warning: Failed to download translations. Skipping..." echo "Downloading translations from: $ZIP_URL"
curl -L -o translations.zip "$ZIP_URL" || {
echo "Failed to download translations.zip. Continuing without translations."
exit 0
}
unzip -o translations.zip -d "rpcs3.app/Contents/translations" >/dev/null 2>&1 || \
echo "Failed to extract translations.zip. Continuing without translations."
rm -f translations.zip
fi fi
# Copy Qt translations manually
QT_TRANS="$WORKDIR/qt-downloader/$QT_VER/clang_64/translations"
cp $QT_TRANS/qt_*.qm rpcs3.app/Contents/translations
cp $QT_TRANS/qtbase_*.qm rpcs3.app/Contents/translations
cp $QT_TRANS/qtmultimedia_*.qm rpcs3.app/Contents/translations
rm -f rpcs3.app/Contents/translations/qt_help_*.qm || true
# Need to do this rename hack due to case insensitive filesystem # Need to do this rename hack due to case insensitive filesystem
mv rpcs3.app RPCS3_.app mv rpcs3.app RPCS3_.app
mv RPCS3_.app RPCS3.app mv RPCS3_.app RPCS3.app
# Hack to fix rpath issues # Hack
BIN="RPCS3.app/Contents/MacOS/rpcs3" install_name_tool -delete_rpath /usr/local/lib RPCS3.app/Contents/MacOS/rpcs3
install_name_tool -delete_rpath /opt/homebrew/lib $BIN || true #-delete_rpath /usr/local/Cellar/sdl3/3.2.8/lib
install_name_tool -delete_rpath /usr/local/lib $BIN || true
# Fix dylib IDs
for lib in RPCS3.app/Contents/Frameworks/*.dylib; do
name=$(basename "$lib")
install_name_tool -id "@rpath/$name" "$lib"
done
# Rewrite any hardcoded Homebrew paths to use @rpath
find "RPCS3.app/Contents/" -type f \( -perm +111 -o -name "*.dylib" \) | while read -r bin; do
otool -L "$bin" | grep -E "/opt/homebrew|/usr/local" | awk '{print $1}' | while read -r dep; do
base=$(basename "$dep")
echo "Fixing $dep -> @rpath/$base in $bin"
install_name_tool -change "$dep" "@rpath/$base" "$bin"
done
done
# NOTE: "--deep" is deprecated # NOTE: "--deep" is deprecated
codesign --deep -fs - RPCS3.app codesign --deep -fs - RPCS3.app
@@ -84,12 +67,8 @@ echo "[InternetShortcut]" > Quickstart.url
echo "URL=https://rpcs3.net/quickstart" >> Quickstart.url echo "URL=https://rpcs3.net/quickstart" >> Quickstart.url
echo "IconIndex=0" >> Quickstart.url echo "IconIndex=0" >> Quickstart.url
if [ "$AARCH64" -eq 1 ]; then ARCHIVE_FILEPATH="$BUILD_ARTIFACTSTAGINGDIRECTORY/rpcs3-v${COMM_TAG}-${COMM_COUNT}-${COMM_HASH}_macos.7z"
ARCHIVE_FILEPATH="$BUILD_ARTIFACTSTAGINGDIRECTORY/rpcs3-v${LVER}_macos_aarch64.7z" "/opt/homebrew/bin/7z" a -mx9 "$ARCHIVE_FILEPATH" RPCS3.app Quickstart.url
else
ARCHIVE_FILEPATH="$BUILD_ARTIFACTSTAGINGDIRECTORY/rpcs3-v${LVER}_macos.7z"
fi
7z a -mx9 "$ARCHIVE_FILEPATH" RPCS3.app Quickstart.url
FILESIZE=$(stat -f %z "$ARCHIVE_FILEPATH") FILESIZE=$(stat -f %z "$ARCHIVE_FILEPATH")
SHA256SUM=$(shasum -a 256 "$ARCHIVE_FILEPATH" | awk '{ print $1 }') SHA256SUM=$(shasum -a 256 "$ARCHIVE_FILEPATH" | awk '{ print $1 }')
+4 -6
View File
@@ -7,13 +7,12 @@
cd build || exit 1 cd build || exit 1
CPU_ARCH="${1:-x86_64}" CPU_ARCH="${1:-x86_64}"
MSYS2="${2:-clang64}"
echo "Deploying rpcs3 windows clang $CPU_ARCH" echo "Deploying rpcs3 windows clang $CPU_ARCH"
# BUILD_blablabla is CI specific, so we wrap it for portability # BUILD_blablabla is CI specific, so we wrap it for portability
ARTIFACT_DIR=$(cygpath -u "$BUILD_ARTIFACTSTAGINGDIRECTORY") ARTIFACT_DIR=$(cygpath -u "$BUILD_ARTIFACTSTAGINGDIRECTORY")
MSYS2_CLANG_BIN=$(cygpath -w /"${MSYS2}"/bin) MSYS2_CLANG_BIN=$(cygpath -w /clang64/bin)
MSYS2_USR_BIN=$(cygpath -w /usr/bin) MSYS2_USR_BIN=$(cygpath -w /usr/bin)
echo "Installing dependencies of: ./bin/rpcs3.exe (MSYS2 dir is '$MSYS2_CLANG_BIN', usr dir is '$MSYS2_USR_BIN')" echo "Installing dependencies of: ./bin/rpcs3.exe (MSYS2 dir is '$MSYS2_CLANG_BIN', usr dir is '$MSYS2_USR_BIN')"
@@ -23,8 +22,7 @@ cmake -DMSYS2_CLANG_BIN="$MSYS2_CLANG_BIN" -DMSYS2_USR_BIN="$MSYS2_USR_BIN" -Dex
mkdir ./bin/config mkdir ./bin/config
mkdir ./bin/config/input_configs mkdir ./bin/config/input_configs
curl -fsSL 'https://raw.githubusercontent.com/gabomdq/SDL_GameControllerDB/master/gamecontrollerdb.txt' 1> ./bin/config/input_configs/gamecontrollerdb.txt curl -fsSL 'https://raw.githubusercontent.com/gabomdq/SDL_GameControllerDB/master/gamecontrollerdb.txt' 1> ./bin/config/input_configs/gamecontrollerdb.txt
curl -fsSL 'https://rpcs3.net/compatibility?api=v1&export' | iconv -f ISO-8859-1 -t UTF-8 1> ./bin/GuiConfigs/compat_database.dat curl -fsSL 'https://rpcs3.net/compatibility?api=v1&export' | iconv -t UTF-8 1> ./bin/GuiConfigs/compat_database.dat
curl -fsSL 'https://api.rpcs3.net/config/?api=v1' | iconv -f ISO-8859-1 -t UTF-8 1> ./bin/GuiConfigs/config_database.dat
# Download translations # Download translations
mkdir -p ./bin/share/qt6/translations mkdir -p ./bin/share/qt6/translations
@@ -40,7 +38,7 @@ else
echo "Failed to download translations.zip. Continuing without translations." echo "Failed to download translations.zip. Continuing without translations."
exit 0 exit 0
} }
7z x translations.zip -o"./bin/share/qt6/translations" >/dev/null 2>&1 || \ unzip -o translations.zip -d "./bin/share/qt6/translations" >/dev/null 2>&1 || \
echo "Failed to extract translations.zip. Continuing without translations." echo "Failed to extract translations.zip. Continuing without translations."
rm -f translations.zip rm -f translations.zip
fi fi
@@ -51,7 +49,7 @@ fi
# Generate sha256 hashes # Generate sha256 hashes
# Write to file for GitHub releases # Write to file for GitHub releases
sha256sum "$BUILD" | awk '{ print $1 }' | tee "$BUILD.sha256" sha256sum "$BUILD" | awk '{ print $1 }' | tee "$BUILD.sha256"
echo "$(cat "$BUILD.sha256");$(stat -c %s "$BUILD")B" > "$RELEASE_MESSAGE" echo "$(cat "$BUILD.sha256");$(stat -c %s "$BUILD")B" > GitHubReleaseMessage.txt
# Move files to publishing directory # Move files to publishing directory
mkdir -p "$ARTIFACT_DIR" mkdir -p "$ARTIFACT_DIR"
-1
View File
@@ -14,7 +14,6 @@ mkdir ./bin/config
mkdir ./bin/config/input_configs mkdir ./bin/config/input_configs
curl -fsSL 'https://raw.githubusercontent.com/gabomdq/SDL_GameControllerDB/master/gamecontrollerdb.txt' 1> ./bin/config/input_configs/gamecontrollerdb.txt curl -fsSL 'https://raw.githubusercontent.com/gabomdq/SDL_GameControllerDB/master/gamecontrollerdb.txt' 1> ./bin/config/input_configs/gamecontrollerdb.txt
curl -fsSL 'https://rpcs3.net/compatibility?api=v1&export' | iconv -t UTF-8 1> ./bin/GuiConfigs/compat_database.dat curl -fsSL 'https://rpcs3.net/compatibility?api=v1&export' | iconv -t UTF-8 1> ./bin/GuiConfigs/compat_database.dat
curl -fsSL 'https://api.rpcs3.net/config/?api=v1' | iconv -t UTF-8 1> ./bin/GuiConfigs/config_database.dat
# Download translations # Download translations
mkdir -p ./bin/qt6/translations mkdir -p ./bin/qt6/translations
+4 -16
View File
@@ -1,7 +1,7 @@
#!/bin/sh -ex #!/bin/sh -ex
# Resource/dependency URLs # Resource/dependency URLs
CCACHE_URL="https://github.com/ccache/ccache/releases/download/v4.12.3/ccache-4.12.3-windows-x86_64.zip" CCACHE_URL="https://github.com/ccache/ccache/releases/download/v4.11.2/ccache-4.11.2-windows-x86_64.zip"
DEP_URLS=" \ DEP_URLS=" \
$CCACHE_URL" $CCACHE_URL"
@@ -28,23 +28,11 @@ download_and_verify()
correctChecksum="$2" correctChecksum="$2"
algo="$3" algo="$3"
fileName="$4" fileName="$4"
path="$DEPS_CACHE_DIR/$fileName"
for _ in 1 2 3; do for _ in 1 2 3; do
# Check if the file exists and the checksum is correct [ -e "$DEPS_CACHE_DIR/$fileName" ] || curl -fLo "$DEPS_CACHE_DIR/$fileName" "$url"
if [ -e "$path" ]; then fileChecksum=$("${algo}sum" "$DEPS_CACHE_DIR/$fileName" | awk '{ print $1 }')
fileChecksum=$("${algo}sum" "$path" | awk '{ print $1 }') [ "$fileChecksum" = "$correctChecksum" ] && return 0
[ "$fileChecksum" = "$correctChecksum" ] && return 0
fi
# Otherwise download the file
curl -fLo "$path" "$url"
# Check again if the file exists and the checksum is correct
if [ -e "$path" ]; then
fileChecksum=$("${algo}sum" "$path" | awk '{ print $1 }')
[ "$fileChecksum" = "$correctChecksum" ] && return 0
fi
done done
return 1; return 1;
+2 -9
View File
@@ -13,21 +13,14 @@ COMM_TAG=$(awk '/version{.*}/ { printf("%d.%d.%d", $5, $6, $7) }' ./rpcs3/rpcs3_
COMM_COUNT=$(git rev-list --count HEAD) COMM_COUNT=$(git rev-list --count HEAD)
COMM_HASH=$(git rev-parse --short=8 HEAD) COMM_HASH=$(git rev-parse --short=8 HEAD)
# Differentiate Windows builds
if [ "$COMPILER" = 'clang' ];then
BUILD_SUFFIX="win64_${CPU_ARCH}_${COMPILER}"
else
BUILD_SUFFIX="${CPU_ARCH}_${COMPILER}"
fi
# Format the above into filenames # Format the above into filenames
if [ -n "$PR_NUMBER" ]; then if [ -n "$PR_NUMBER" ]; then
AVVER="${COMM_TAG}-${COMM_HASH}" AVVER="${COMM_TAG}-${COMM_HASH}"
BUILD_RAW="rpcs3-v${AVVER}_${BUILD_SUFFIX}" BUILD_RAW="rpcs3-v${AVVER}_${CPU_ARCH}_${COMPILER}"
BUILD="${BUILD_RAW}.7z" BUILD="${BUILD_RAW}.7z"
else else
AVVER="${COMM_TAG}-${COMM_COUNT}" AVVER="${COMM_TAG}-${COMM_COUNT}"
BUILD_RAW="rpcs3-v${AVVER}-${COMM_HASH}_${BUILD_SUFFIX}" BUILD_RAW="rpcs3-v${AVVER}-${COMM_HASH}_${CPU_ARCH}_${COMPILER}"
BUILD="${BUILD_RAW}.7z" BUILD="${BUILD_RAW}.7z"
fi fi
+7 -21
View File
@@ -6,7 +6,7 @@
QT_HOST="http://qt.mirror.constant.com/" QT_HOST="http://qt.mirror.constant.com/"
QT_URL_VER=$(echo "$QT_VER" | sed "s/\.//g") QT_URL_VER=$(echo "$QT_VER" | sed "s/\.//g")
QT_VER_MSVC_UP=$(echo "${QT_VER_MSVC}" | tr '[:lower:]' '[:upper:]') QT_VER_MSVC_UP=$(echo "${QT_VER_MSVC}" | tr '[:lower:]' '[:upper:]')
QT_PREFIX="online/qtsdkrepository/windows_x86/desktop/qt${QT_VER_MAIN}_${QT_URL_VER}/qt${QT_VER_MAIN}_${QT_URL_VER}_${QT_VER_MSVC}_64/qt.qt${QT_VER_MAIN}.${QT_URL_VER}." QT_PREFIX="online/qtsdkrepository/windows_x86/desktop/qt${QT_VER_MAIN}_${QT_URL_VER}/qt${QT_VER_MAIN}_${QT_URL_VER}/qt.qt${QT_VER_MAIN}.${QT_URL_VER}."
QT_PREFIX_2="win64_${QT_VER_MSVC}_64/${QT_VER}-0-${QT_DATE}" QT_PREFIX_2="win64_${QT_VER_MSVC}_64/${QT_VER}-0-${QT_DATE}"
QT_SUFFIX="-Windows-Windows_11_24H2-${QT_VER_MSVC_UP}-Windows-Windows_11_24H2-X86_64.7z" QT_SUFFIX="-Windows-Windows_11_24H2-${QT_VER_MSVC_UP}-Windows-Windows_11_24H2-X86_64.7z"
QT_BASE_URL="${QT_HOST}${QT_PREFIX}${QT_PREFIX_2}qtbase${QT_SUFFIX}" QT_BASE_URL="${QT_HOST}${QT_PREFIX}${QT_PREFIX_2}qtbase${QT_SUFFIX}"
@@ -14,10 +14,9 @@ QT_DECL_URL="${QT_HOST}${QT_PREFIX}${QT_PREFIX_2}qtdeclarative${QT_SUFFIX}"
QT_TOOL_URL="${QT_HOST}${QT_PREFIX}${QT_PREFIX_2}qttools${QT_SUFFIX}" QT_TOOL_URL="${QT_HOST}${QT_PREFIX}${QT_PREFIX_2}qttools${QT_SUFFIX}"
QT_MM_URL="${QT_HOST}${QT_PREFIX}addons.qtmultimedia.${QT_PREFIX_2}qtmultimedia${QT_SUFFIX}" QT_MM_URL="${QT_HOST}${QT_PREFIX}addons.qtmultimedia.${QT_PREFIX_2}qtmultimedia${QT_SUFFIX}"
QT_SVG_URL="${QT_HOST}${QT_PREFIX}${QT_PREFIX_2}qtsvg${QT_SUFFIX}" QT_SVG_URL="${QT_HOST}${QT_PREFIX}${QT_PREFIX_2}qtsvg${QT_SUFFIX}"
QT_TRANSLATIONS_URL="${QT_HOST}${QT_PREFIX}${QT_PREFIX_2}qttranslations${QT_SUFFIX}"
LLVMLIBS_URL="https://github.com/RPCS3/llvm-mirror/releases/download/custom-build-win-${LLVM_VER}/llvmlibs_mt.7z" LLVMLIBS_URL="https://github.com/RPCS3/llvm-mirror/releases/download/custom-build-win-${LLVM_VER}/llvmlibs_mt.7z"
VULKAN_SDK_URL="https://www.dropbox.com/scl/fi/olpvqk4346ig7i8btadk5/vulkansdk-windows-X64-${VULKAN_VER}.exe?rlkey=huvssch6sy904qkg8ti9p65br&st=pztptdin&dl=1" VULKAN_SDK_URL="https://www.dropbox.com/scl/fi/sjjh0fc4ld281pjbl2xzu/VulkanSDK-${VULKAN_VER}-Installer.exe?rlkey=f6wzc0lvms5vwkt2z3qabfv9d&dl=1"
CCACHE_URL="https://github.com/ccache/ccache/releases/download/v4.12.3/ccache-4.12.3-windows-x86_64.zip" CCACHE_URL="https://github.com/ccache/ccache/releases/download/v4.11.2/ccache-4.11.2-windows-x86_64.zip"
DEP_URLS=" \ DEP_URLS=" \
$QT_BASE_URL \ $QT_BASE_URL \
@@ -25,7 +24,6 @@ DEP_URLS=" \
$QT_TOOL_URL \ $QT_TOOL_URL \
$QT_MM_URL \ $QT_MM_URL \
$QT_SVG_URL \ $QT_SVG_URL \
$QT_TRANSLATIONS_URL \
$LLVMLIBS_URL \ $LLVMLIBS_URL \
$VULKAN_SDK_URL\ $VULKAN_SDK_URL\
$CCACHE_URL" $CCACHE_URL"
@@ -53,23 +51,11 @@ download_and_verify()
correctChecksum="$2" correctChecksum="$2"
algo="$3" algo="$3"
fileName="$4" fileName="$4"
path="$DEPS_CACHE_DIR/$fileName"
for _ in 1 2 3; do for _ in 1 2 3; do
# Check if the file exists and the checksum is correct [ -e "$DEPS_CACHE_DIR/$fileName" ] || curl -fLo "$DEPS_CACHE_DIR/$fileName" "$url"
if [ -e "$path" ]; then fileChecksum=$("${algo}sum" "$DEPS_CACHE_DIR/$fileName" | awk '{ print $1 }')
fileChecksum=$("${algo}sum" "$path" | awk '{ print $1 }') [ "$fileChecksum" = "$correctChecksum" ] && return 0
[ "$fileChecksum" = "$correctChecksum" ] && return 0
fi
# Otherwise download the file
curl -fLo "$path" "$url"
# Check again if the file exists and the checksum is correct
if [ -e "$path" ]; then
fileChecksum=$("${algo}sum" "$path" | awk '{ print $1 }')
[ "$fileChecksum" = "$correctChecksum" ] && return 0
fi
done done
return 1; return 1;
@@ -88,7 +74,7 @@ for url in $DEP_URLS; do
*qt*) checksum=$(curl -fL "${url}.sha1"); algo="sha1"; outDir="$QTDIR/" ;; *qt*) checksum=$(curl -fL "${url}.sha1"); algo="sha1"; outDir="$QTDIR/" ;;
*llvm*) checksum=$(curl -fL "${url}.sha256"); algo="sha256"; outDir="./build/lib_ext/Release-x64" ;; *llvm*) checksum=$(curl -fL "${url}.sha256"); algo="sha256"; outDir="./build/lib_ext/Release-x64" ;;
*ccache*) checksum=$CCACHE_SHA; algo="sha256"; outDir="$CCACHE_BIN_DIR" ;; *ccache*) checksum=$CCACHE_SHA; algo="sha256"; outDir="$CCACHE_BIN_DIR" ;;
*vulkansdk*) *Vulkan*)
# Vulkan setup needs to be run in batch environment # Vulkan setup needs to be run in batch environment
# Need to subshell this or else it doesn't wait # Need to subshell this or else it doesn't wait
download_and_verify "$url" "$VULKAN_SDK_SHA" "sha256" "$fileName" download_and_verify "$url" "$VULKAN_SDK_SHA" "sha256" "$fileName"
+2 -2
View File
@@ -17,10 +17,10 @@ jobs:
Windows_Build: Windows_Build:
if: github.event_name == 'workflow_dispatch' if: github.event_name == 'workflow_dispatch'
name: LLVM Windows (MSVC) name: LLVM Windows (MSVC)
runs-on: windows-2025-vs2026 runs-on: windows-2025
env: env:
COMPILER: msvc COMPILER: msvc
CCACHE_SHA: '859141059ac950e1e8cd042c66f842f26b9e3a62a1669a69fe6ba180cb58bbdf' CCACHE_SHA: '1f39f3ad5aae3fe915e99ad1302633bc8f6718e58fa7c0de2b0ba7e080f0f08c'
CCACHE_BIN_DIR: 'C:\ccache_bin' CCACHE_BIN_DIR: 'C:\ccache_bin'
CCACHE_DIR: 'C:\ccache' CCACHE_DIR: 'C:\ccache'
CCACHE_INODECACHE: 'true' CCACHE_INODECACHE: 'true'
+41 -78
View File
@@ -30,23 +30,23 @@ jobs:
matrix: matrix:
include: include:
- os: ubuntu-24.04 - os: ubuntu-24.04
docker_img: "rpcs3/rpcs3-ci-jammy:1.13" docker_img: "rpcs3/rpcs3-ci-jammy:1.7"
build_sh: "/rpcs3/.ci/build-linux.sh" build_sh: "/rpcs3/.ci/build-linux.sh"
compiler: clang compiler: clang
UPLOAD_COMMIT_HASH: d812f1254a1157c80fd402f94446310560f54e5f UPLOAD_COMMIT_HASH: d812f1254a1157c80fd402f94446310560f54e5f
UPLOAD_REPO_FULL_NAME: "rpcs3/rpcs3-binaries-linux" UPLOAD_REPO_FULL_NAME: "rpcs3/rpcs3-binaries-linux"
- os: ubuntu-24.04 - os: ubuntu-24.04
docker_img: "rpcs3/rpcs3-ci-jammy:1.13" docker_img: "rpcs3/rpcs3-ci-jammy:1.7"
build_sh: "/rpcs3/.ci/build-linux.sh" build_sh: "/rpcs3/.ci/build-linux.sh"
compiler: gcc compiler: gcc
- os: ubuntu-24.04-arm - os: ubuntu-24.04-arm
docker_img: "rpcs3/rpcs3-ci-jammy-aarch64:1.13" docker_img: "rpcs3/rpcs3-ci-jammy-aarch64:1.7"
build_sh: "/rpcs3/.ci/build-linux-aarch64.sh" build_sh: "/rpcs3/.ci/build-linux-aarch64.sh"
compiler: clang compiler: clang
UPLOAD_COMMIT_HASH: a1d35836e8d45bfc6f63c26f0a3e5d46ef622fe1 UPLOAD_COMMIT_HASH: a1d35836e8d45bfc6f63c26f0a3e5d46ef622fe1
UPLOAD_REPO_FULL_NAME: "rpcs3/rpcs3-binaries-linux-arm64" UPLOAD_REPO_FULL_NAME: "rpcs3/rpcs3-binaries-linux-arm64"
- os: ubuntu-24.04-arm - os: ubuntu-24.04-arm
docker_img: "rpcs3/rpcs3-ci-jammy-aarch64:1.13" docker_img: "rpcs3/rpcs3-ci-jammy-aarch64:1.7"
build_sh: "/rpcs3/.ci/build-linux-aarch64.sh" build_sh: "/rpcs3/.ci/build-linux-aarch64.sh"
compiler: gcc compiler: gcc
name: RPCS3 Linux ${{ matrix.os }} ${{ matrix.compiler }} name: RPCS3 Linux ${{ matrix.os }} ${{ matrix.compiler }}
@@ -123,24 +123,23 @@ jobs:
matrix: matrix:
include: include:
- name: Intel - name: Intel
AARCH64: 0 build_sh: .ci/build-mac.sh
UPLOAD_COMMIT_HASH: 51ae32f468089a8169aaf1567de355ff4a3e0842 UPLOAD_COMMIT_HASH: 51ae32f468089a8169aaf1567de355ff4a3e0842
UPLOAD_REPO_FULL_NAME: rpcs3/rpcs3-binaries-mac UPLOAD_REPO_FULL_NAME: rpcs3/rpcs3-binaries-mac
- name: Apple Silicon - name: Apple Silicon
AARCH64: 1 build_sh: .ci/build-mac-arm64.sh
UPLOAD_COMMIT_HASH: 8e21bdbc40711a3fccd18fbf17b742348b0f4281 UPLOAD_COMMIT_HASH: 8e21bdbc40711a3fccd18fbf17b742348b0f4281
UPLOAD_REPO_FULL_NAME: rpcs3/rpcs3-binaries-mac-arm64 UPLOAD_REPO_FULL_NAME: rpcs3/rpcs3-binaries-mac-arm64
name: RPCS3 Mac ${{ matrix.name }} name: RPCS3 Mac ${{ matrix.name }}
runs-on: macos-14 runs-on: macos-14
env: env:
CCACHE_DIR: /tmp/ccache_dir CCACHE_DIR: /tmp/ccache_dir
QT_VER: '6.11.1' QT_VER: '6.10.1'
QT_VER_MAIN: '6' QT_VER_MAIN: '6'
LLVM_COMPILER_VER: '21' LLVM_COMPILER_VER: '21'
RELEASE_MESSAGE: ../GitHubReleaseMessage.txt RELEASE_MESSAGE: ../GitHubReleaseMessage.txt
UPLOAD_COMMIT_HASH: ${{ matrix.UPLOAD_COMMIT_HASH }} UPLOAD_COMMIT_HASH: ${{ matrix.UPLOAD_COMMIT_HASH }}
UPLOAD_REPO_FULL_NAME: ${{ matrix.UPLOAD_REPO_FULL_NAME }} UPLOAD_REPO_FULL_NAME: ${{ matrix.UPLOAD_REPO_FULL_NAME }}
AARCH64: ${{ matrix.AARCH64 }}
RUN_UNIT_TESTS: github.event_name == 'pull_request' && 'ON' || 'OFF' RUN_UNIT_TESTS: github.event_name == 'pull_request' && 'ON' || 'OFF'
steps: steps:
- name: Checkout repository - name: Checkout repository
@@ -165,7 +164,7 @@ jobs:
restore-keys: ${{ runner.os }}-qt-${{ matrix.name }}-${{ env.QT_VER }} restore-keys: ${{ runner.os }}-qt-${{ matrix.name }}-${{ env.QT_VER }}
- name: Build - name: Build
run: .ci/build-mac.sh run: ${{ matrix.build_sh }}
- name: Upload artifacts - name: Upload artifacts
uses: actions/upload-artifact@main uses: actions/upload-artifact@main
@@ -209,17 +208,17 @@ jobs:
# Only run push event on master branch of main repo, but run all PRs # Only run push event on master branch of main repo, but run all PRs
if: github.event_name != 'push' || (github.repository == 'RPCS3/rpcs3' && github.ref_name == 'master') if: github.event_name != 'push' || (github.repository == 'RPCS3/rpcs3' && github.ref_name == 'master')
name: RPCS3 Windows name: RPCS3 Windows
runs-on: windows-2025-vs2026 runs-on: windows-2025
env: env:
COMPILER: msvc COMPILER: msvc
QT_VER_MAIN: '6' QT_VER_MAIN: '6'
QT_VER: '6.11.1' QT_VER: '6.10.1'
QT_VER_MSVC: 'msvc2022' QT_VER_MSVC: 'msvc2022'
QT_DATE: '202605090529' QT_DATE: '202511161843'
LLVM_VER: '19.1.7' LLVM_VER: '19.1.7'
VULKAN_VER: '1.4.341.1' VULKAN_VER: '1.3.268.0'
VULKAN_SDK_SHA: 'bcf2d75aa9556889ab974858666e20b3655b6055a0db704ccb47279ff33b5bfe' VULKAN_SDK_SHA: '8459ef49bd06b697115ddd3d97c9aec729e849cd775f5be70897718a9b3b9db5'
CCACHE_SHA: '859141059ac950e1e8cd042c66f842f26b9e3a62a1669a69fe6ba180cb58bbdf' CCACHE_SHA: '1f39f3ad5aae3fe915e99ad1302633bc8f6718e58fa7c0de2b0ba7e080f0f08c'
CCACHE_BIN_DIR: 'C:\ccache_bin' CCACHE_BIN_DIR: 'C:\ccache_bin'
CCACHE_DIR: 'C:\ccache' CCACHE_DIR: 'C:\ccache'
CCACHE_INODECACHE: 'true' CCACHE_INODECACHE: 'true'
@@ -235,7 +234,7 @@ jobs:
fetch-depth: 0 fetch-depth: 0
- name: Setup NuGet - name: Setup NuGet
uses: nuget/setup-nuget@v4 uses: nuget/setup-nuget@v2
- name: Restore NuGet packages - name: Restore NuGet packages
run: nuget restore rpcs3.sln run: nuget restore rpcs3.sln
@@ -329,25 +328,16 @@ jobs:
Windows_Build_Clang: Windows_Build_Clang:
# Only run push event on master branch of main repo, but run all PRs # Only run push event on master branch of main repo, but run all PRs
if: github.event_name != 'push' || (github.repository == 'RPCS3/rpcs3' && github.ref_name == 'master') if: github.event_name != 'push' || (github.repository == 'RPCS3/rpcs3' && github.ref_name == 'master')
name: RPCS3 Windows Clang
runs-on: windows-2025
strategy: strategy:
fail-fast: false
matrix: matrix:
include: include:
- msys2: clang64 - msys2: clang64
compiler: clang compiler: clang
arch: x86_64 arch: win64
os: windows-2025
name: X64
- msys2: clangarm64
compiler: clang
arch: aarch64
os: windows-11-arm
name: ARM64
env: env:
CCACHE_DIR: 'C:\ccache' CCACHE_DIR: 'C:\ccache'
RELEASE_MESSAGE: ../GitHubReleaseMessage.txt
name: RPCS3 Windows Clang ${{ matrix.arch }}
runs-on: ${{ matrix.os }}
steps: steps:
- name: Checkout repository - name: Checkout repository
uses: actions/checkout@main uses: actions/checkout@main
@@ -361,26 +351,23 @@ jobs:
update: true update: true
cache: true cache: true
install: | install: |
mingw-w64-clang-${{ matrix.arch }}-clang mingw-w64-clang-x86_64-clang
mingw-w64-clang-${{ matrix.arch }}-ccache mingw-w64-clang-x86_64-ccache
mingw-w64-clang-${{ matrix.arch }}-cmake mingw-w64-clang-x86_64-cmake
mingw-w64-clang-${{ matrix.arch }}-lld mingw-w64-clang-x86_64-lld
mingw-w64-clang-${{ matrix.arch }}-ninja mingw-w64-clang-x86_64-ninja
mingw-w64-clang-${{ matrix.arch }}-llvm mingw-w64-clang-x86_64-llvm
mingw-w64-clang-${{ matrix.arch }}-ffmpeg mingw-w64-clang-x86_64-ffmpeg
mingw-w64-clang-${{ matrix.arch }}-opencv mingw-w64-clang-x86_64-opencv
mingw-w64-clang-${{ matrix.arch }}-iconv mingw-w64-clang-x86_64-glew
mingw-w64-clang-${{ matrix.arch }}-glew mingw-w64-clang-x86_64-vulkan
mingw-w64-clang-${{ matrix.arch }}-vulkan mingw-w64-clang-x86_64-vulkan-headers
mingw-w64-clang-${{ matrix.arch }}-vulkan-headers mingw-w64-clang-x86_64-vulkan-loader
mingw-w64-clang-${{ matrix.arch }}-vulkan-loader mingw-w64-clang-x86_64-gtest
mingw-w64-clang-${{ matrix.arch }}-gtest mingw-w64-clang-x86_64-qt6-base
mingw-w64-clang-${{ matrix.arch }}-qt6-base mingw-w64-clang-x86_64-qt6-declarative
mingw-w64-clang-${{ matrix.arch }}-qt6-declarative mingw-w64-clang-x86_64-qt6-multimedia
mingw-w64-clang-${{ matrix.arch }}-qt6-multimedia mingw-w64-clang-x86_64-qt6-svg
mingw-w64-clang-${{ matrix.arch }}-qt6-svg
mingw-w64-clang-${{ matrix.arch }}-qt6-tools
mingw-w64-clang-${{ matrix.arch }}-qt6-translations
base-devel base-devel
curl curl
git git
@@ -391,8 +378,8 @@ jobs:
id: restore-build-ccache id: restore-build-ccache
with: with:
path: ${{ env.CCACHE_DIR }} path: ${{ env.CCACHE_DIR }}
key: ${{ runner.os }}-ccache-${{ matrix.compiler }}-${{ matrix.arch }}-${{ github.run_id }} key: ${{ runner.os }}-ccache-${{ matrix.compiler }}-${{ runner.arch }}-${{ github.run_id }}
restore-keys: ${{ runner.os }}-ccache-${{ matrix.compiler }}-${{ matrix.arch }}- restore-keys: ${{ runner.os }}-ccache-${{ matrix.compiler }}-${{ runner.arch }}-
- name: Build RPCS3 - name: Build RPCS3
shell: msys2 {0} shell: msys2 {0}
@@ -400,25 +387,7 @@ jobs:
export CCACHE_DIR=$(cygpath -u "$CCACHE_DIR") export CCACHE_DIR=$(cygpath -u "$CCACHE_DIR")
echo "CCACHE_DIR=$CCACHE_DIR" echo "CCACHE_DIR=$CCACHE_DIR"
.ci/setup-windows-ci-vars.sh ${{ matrix.arch }} ${{ matrix.compiler }} .ci/setup-windows-ci-vars.sh ${{ matrix.arch }} ${{ matrix.compiler }}
.ci/build-windows-clang.sh ${{ matrix.arch }} ${{ matrix.msys2 }} .ci/build-windows-clang.sh
- name: Deploy master build to GitHub Releases (only aarch64)
if: |
matrix.arch == 'aarch64' &&
github.event_name != 'pull_request' &&
github.repository == 'RPCS3/rpcs3' &&
github.ref == 'refs/heads/master'
env:
RPCS3_TOKEN: ${{ secrets.RPCS3_TOKEN }}
# We specify it here since this upload is specific to arm64
UPLOAD_COMMIT_HASH: ee05050fd1d8488148a771b526702656a10dacf0
UPLOAD_REPO_FULL_NAME: "RPCS3/rpcs3-binaries-win-arm64"
run: |
COMM_TAG=$(awk '/version{.*}/ { printf("%d.%d.%d", $5, $6, $7) }' ./rpcs3/rpcs3_version.cpp)
COMM_COUNT=$(git rev-list --count HEAD)
COMM_HASH=$(git rev-parse --short=8 HEAD)
export AVVER="${COMM_TAG}-${COMM_COUNT}"
.ci/github-upload.sh
- name: Save build Ccache - name: Save build Ccache
if: github.ref == 'refs/heads/master' if: github.ref == 'refs/heads/master'
@@ -430,7 +399,7 @@ jobs:
- name: Upload artifacts - name: Upload artifacts
uses: actions/upload-artifact@main uses: actions/upload-artifact@main
with: with:
name: RPCS3 for Windows (${{ matrix.name }}, clang) name: RPCS3 for Windows (${{ runner.arch }}, ${{ matrix.compiler }})
path: ${{ env.BUILD_ARTIFACTSTAGINGDIRECTORY }} path: ${{ env.BUILD_ARTIFACTSTAGINGDIRECTORY }}
compression-level: 0 compression-level: 0
if-no-files-found: error if-no-files-found: error
@@ -444,11 +413,7 @@ jobs:
env: env:
CCACHE_DIR: ${{ github.workspace }}/ccache CCACHE_DIR: ${{ github.workspace }}/ccache
QT_VER_MAIN: '6' QT_VER_MAIN: '6'
LLVM_COMPILER_VER: '-devel' LLVM_COMPILER_VER: '19'
CC: 'clang-devel'
CXX: 'clang++-devel'
LLVM_CONFIG: 'llvm-config-devel'
steps: steps:
- name: Checkout repository - name: Checkout repository
uses: actions/checkout@main uses: actions/checkout@main
@@ -467,10 +432,8 @@ jobs:
id: root id: root
uses: vmactions/freebsd-vm@v1 uses: vmactions/freebsd-vm@v1
with: with:
envs: 'QT_VER_MAIN LLVM_COMPILER_VER CCACHE_DIR CC CXX LLVM_CONFIG' envs: 'QT_VER_MAIN LLVM_COMPILER_VER CCACHE_DIR'
usesh: true usesh: true
copyback: false
release: "14.3"
run: .ci/install-freebsd.sh && .ci/build-freebsd.sh run: .ci/install-freebsd.sh && .ci/build-freebsd.sh
- name: Save Build Ccache - name: Save Build Ccache
-3
View File
@@ -69,9 +69,6 @@ CMakeSettings.json
*PVS-Studio* *PVS-Studio*
PVS/* PVS/*
# Zed Editor files
.zed/*
# Ignore other system generated files # Ignore other system generated files
x64/* x64/*
rpcs3/x64/* rpcs3/x64/*
+4 -4
View File
@@ -52,6 +52,10 @@
path = 3rdparty/wolfssl/wolfssl path = 3rdparty/wolfssl/wolfssl
url = ../../wolfSSL/wolfssl.git url = ../../wolfSSL/wolfssl.git
ignore = dirty ignore = dirty
[submodule "3rdparty/flatbuffers"]
path = 3rdparty/flatbuffers
url = ../../google/flatbuffers.git
ignore = dirty
[submodule "3rdparty/cubeb/cubeb"] [submodule "3rdparty/cubeb/cubeb"]
path = 3rdparty/cubeb/cubeb path = 3rdparty/cubeb/cubeb
url = ../../mozilla/cubeb.git url = ../../mozilla/cubeb.git
@@ -108,7 +112,3 @@
path = 3rdparty/feralinteractive/feralinteractive path = 3rdparty/feralinteractive/feralinteractive
url = ../../FeralInteractive/gamemode.git url = ../../FeralInteractive/gamemode.git
ignore = dirty ignore = dirty
[submodule "3rdparty/protobuf/protobuf"]
path = 3rdparty/protobuf/protobuf
url = ../../protocolbuffers/protobuf.git
ignore = dirty
+2 -2
View File
@@ -59,11 +59,11 @@ if(WIN32 OR APPLE)
7zip/C/XzEnc.c 7zip/C/XzEnc.c
7zip/C/XzIn.c 7zip/C/XzIn.c
7zip/C/ZstdDec.c) 7zip/C/ZstdDec.c)
target_include_directories(3rdparty_7zip SYSTEM INTERFACE target_include_directories(3rdparty_7zip INTERFACE
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/7zip/C> $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/7zip/C>
$<INSTALL_INTERFACE:/7zip/C>) $<INSTALL_INTERFACE:/7zip/C>)
target_include_directories(3rdparty_7zip SYSTEM INTERFACE 7zip) target_include_directories(3rdparty_7zip INTERFACE 7zip)
set_property(TARGET 3rdparty_7zip PROPERTY FOLDER "3rdparty/") set_property(TARGET 3rdparty_7zip PROPERTY FOLDER "3rdparty/")
+22 -10
View File
@@ -25,8 +25,18 @@ add_subdirectory(zstd EXCLUDE_FROM_ALL)
# 7zip sdk # 7zip sdk
add_subdirectory(7zip EXCLUDE_FROM_ALL) add_subdirectory(7zip EXCLUDE_FROM_ALL)
# Protobuf add_library(3rdparty_flatbuffers INTERFACE)
add_subdirectory(protobuf EXCLUDE_FROM_ALL) if (USE_SYSTEM_FLATBUFFERS)
pkg_check_modules(FLATBUFFERS REQUIRED IMPORTED_TARGET flatbuffers>=2.0.0)
target_link_libraries(3rdparty_flatbuffers INTERFACE PkgConfig::FLATBUFFERS)
set(FBS_DIR "${CMAKE_CURRENT_SOURCE_DIR}/../rpcs3/Emu/NP/generated/")
execute_process(COMMAND flatc --cpp -o "${FBS_DIR}" "${FBS_DIR}/np2_structs.fbs" RESULT_VARIABLE FBS_CMD_ERROR)
if(FBS_CMD_ERROR AND NOT FBS_CMD_ERROR EQUAL 0)
message(FATAL_ERROR "flatc failed to regenerate flatbuffers headers.")
endif()
else()
target_include_directories(3rdparty_flatbuffers INTERFACE flatbuffers/include)
endif()
# libPNG # libPNG
add_subdirectory(libpng EXCLUDE_FROM_ALL) add_subdirectory(libpng EXCLUDE_FROM_ALL)
@@ -46,7 +56,7 @@ if (USE_SYSTEM_VULKAN_MEMORY_ALLOCATOR)
add_library(3rdparty::vulkanmemoryallocator ALIAS GPUOpen::VulkanMemoryAllocator) add_library(3rdparty::vulkanmemoryallocator ALIAS GPUOpen::VulkanMemoryAllocator)
else() else()
add_library(3rdparty_vulkanmemoryallocator INTERFACE) add_library(3rdparty_vulkanmemoryallocator INTERFACE)
target_include_directories(3rdparty_vulkanmemoryallocator SYSTEM INTERFACE GPUOpen/VulkanMemoryAllocator/include) target_include_directories(3rdparty_vulkanmemoryallocator INTERFACE GPUOpen/VulkanMemoryAllocator/include)
add_library(3rdparty::vulkanmemoryallocator ALIAS 3rdparty_vulkanmemoryallocator) add_library(3rdparty::vulkanmemoryallocator ALIAS 3rdparty_vulkanmemoryallocator)
endif() endif()
@@ -97,11 +107,11 @@ add_subdirectory(yaml-cpp)
# OpenGL # OpenGL
if (NOT ANDROID AND NOT APPLE) if (NOT ANDROID)
find_package(OpenGL REQUIRED OPTIONAL_COMPONENTS EGL) find_package(OpenGL REQUIRED OPTIONAL_COMPONENTS EGL)
add_library(3rdparty_opengl INTERFACE) add_library(3rdparty_opengl INTERFACE)
target_include_directories(3rdparty_opengl SYSTEM INTERFACE GL) target_include_directories(3rdparty_opengl INTERFACE GL)
if (WIN32) if (WIN32)
if(NOT MSVC) if(NOT MSVC)
@@ -109,6 +119,8 @@ if (NOT ANDROID AND NOT APPLE)
else() else()
target_link_libraries(3rdparty_opengl INTERFACE dxgi.lib d2d1.lib dwrite.lib) target_link_libraries(3rdparty_opengl INTERFACE dxgi.lib d2d1.lib dwrite.lib)
endif() endif()
elseif(APPLE)
target_link_libraries(3rdparty_opengl INTERFACE OpenGL::GL OpenGL::GLU)
else() else()
target_link_libraries(3rdparty_opengl INTERFACE OpenGL::GL OpenGL::GLU OpenGL::GLX) target_link_libraries(3rdparty_opengl INTERFACE OpenGL::GL OpenGL::GLU OpenGL::GLX)
endif() endif()
@@ -192,7 +204,7 @@ if(USE_VULKAN)
find_package(Wayland) find_package(Wayland)
if (WAYLAND_FOUND) if (WAYLAND_FOUND)
target_include_directories(3rdparty_vulkan target_include_directories(3rdparty_vulkan
SYSTEM INTERFACE ${WAYLAND_INCLUDE_DIR}) INTERFACE ${WAYLAND_INCLUDE_DIR})
endif() endif()
endif() endif()
@@ -286,7 +298,7 @@ if(NOT ANDROID)
message(STATUS "RPCS3: using shared ffmpeg") message(STATUS "RPCS3: using shared ffmpeg")
find_package(FFMPEG REQUIRED) find_package(FFMPEG REQUIRED)
target_include_directories(3rdparty_ffmpeg SYSTEM INTERFACE ${FFMPEG_INCLUDE_DIR}) target_include_directories(3rdparty_ffmpeg INTERFACE ${FFMPEG_INCLUDE_DIR})
target_link_libraries(3rdparty_ffmpeg INTERFACE ${FFMPEG_LIBRARIES}) target_link_libraries(3rdparty_ffmpeg INTERFACE ${FFMPEG_LIBRARIES})
else() else()
message(STATUS "RPCS3: using builtin ffmpeg") message(STATUS "RPCS3: using builtin ffmpeg")
@@ -316,14 +328,14 @@ if(NOT ANDROID)
${FFMPEG_LIB_SWSCALE} ${FFMPEG_LIB_SWSCALE}
${FFMPEG_LIB_SWRESAMPLE} ${FFMPEG_LIB_SWRESAMPLE}
) )
target_include_directories(3rdparty_ffmpeg SYSTEM INTERFACE "ffmpeg/include") target_include_directories(3rdparty_ffmpeg INTERFACE "ffmpeg/include")
endif() endif()
endif() endif()
# GLEW # GLEW
add_library(3rdparty_glew INTERFACE) add_library(3rdparty_glew INTERFACE)
if(NOT MSVC AND NOT ANDROID AND NOT APPLE) if(NOT MSVC AND NOT ANDROID)
find_package(GLEW REQUIRED) find_package(GLEW REQUIRED)
target_link_libraries(3rdparty_glew INTERFACE GLEW::GLEW) target_link_libraries(3rdparty_glew INTERFACE GLEW::GLEW)
endif() endif()
@@ -362,7 +374,7 @@ endif()
add_library(3rdparty::zlib ALIAS 3rdparty_zlib) add_library(3rdparty::zlib ALIAS 3rdparty_zlib)
add_library(3rdparty::zstd ALIAS 3rdparty_zstd) add_library(3rdparty::zstd ALIAS 3rdparty_zstd)
add_library(3rdparty::7zip ALIAS 3rdparty_7zip) add_library(3rdparty::7zip ALIAS 3rdparty_7zip)
add_library(3rdparty::protobuf ALIAS 3rdparty_protobuf) add_library(3rdparty::flatbuffers ALIAS 3rdparty_flatbuffers)
add_library(3rdparty::pugixml ALIAS pugixml) add_library(3rdparty::pugixml ALIAS pugixml)
add_library(3rdparty::glslang ALIAS 3rdparty_glslang) add_library(3rdparty::glslang ALIAS 3rdparty_glslang)
add_library(3rdparty::yaml-cpp ALIAS yaml-cpp) add_library(3rdparty::yaml-cpp ALIAS yaml-cpp)
+2 -123
View File
@@ -6,7 +6,7 @@ extern "C" {
#endif #endif
/* /*
** Copyright 2013-2026 The Khronos Group Inc. ** Copyright 2013-2020 The Khronos Group Inc.
** SPDX-License-Identifier: MIT ** SPDX-License-Identifier: MIT
** **
** This header is generated from the Khronos OpenGL / OpenGL ES XML ** This header is generated from the Khronos OpenGL / OpenGL ES XML
@@ -32,7 +32,7 @@ extern "C" {
#define GLAPI extern #define GLAPI extern
#endif #endif
#define GL_GLEXT_VERSION 20260126 #define GL_GLEXT_VERSION 20250203
#include <KHR/khrplatform.h> #include <KHR/khrplatform.h>
@@ -7358,47 +7358,6 @@ GLAPI void APIENTRY glFogCoordPointerEXT (GLenum type, GLsizei stride, const voi
#endif #endif
#endif /* GL_EXT_fog_coord */ #endif /* GL_EXT_fog_coord */
#ifndef GL_EXT_fragment_shading_rate
#define GL_EXT_fragment_shading_rate 1
#define GL_SHADING_RATE_1X1_PIXELS_EXT 0x96A6
#define GL_SHADING_RATE_1X2_PIXELS_EXT 0x96A7
#define GL_SHADING_RATE_2X1_PIXELS_EXT 0x96A8
#define GL_SHADING_RATE_2X2_PIXELS_EXT 0x96A9
#define GL_SHADING_RATE_1X4_PIXELS_EXT 0x96AA
#define GL_SHADING_RATE_4X1_PIXELS_EXT 0x96AB
#define GL_SHADING_RATE_4X2_PIXELS_EXT 0x96AC
#define GL_SHADING_RATE_2X4_PIXELS_EXT 0x96AD
#define GL_SHADING_RATE_4X4_PIXELS_EXT 0x96AE
#define GL_SHADING_RATE_EXT 0x96D0
#define GL_SHADING_RATE_ATTACHMENT_EXT 0x96D1
#define GL_FRAGMENT_SHADING_RATE_COMBINER_OP_KEEP_EXT 0x96D2
#define GL_FRAGMENT_SHADING_RATE_COMBINER_OP_REPLACE_EXT 0x96D3
#define GL_FRAGMENT_SHADING_RATE_COMBINER_OP_MIN_EXT 0x96D4
#define GL_FRAGMENT_SHADING_RATE_COMBINER_OP_MAX_EXT 0x96D5
#define GL_FRAGMENT_SHADING_RATE_COMBINER_OP_MUL_EXT 0x96D6
#define GL_MIN_FRAGMENT_SHADING_RATE_ATTACHMENT_TEXEL_WIDTH_EXT 0x96D7
#define GL_MAX_FRAGMENT_SHADING_RATE_ATTACHMENT_TEXEL_WIDTH_EXT 0x96D8
#define GL_MIN_FRAGMENT_SHADING_RATE_ATTACHMENT_TEXEL_HEIGHT_EXT 0x96D9
#define GL_MAX_FRAGMENT_SHADING_RATE_ATTACHMENT_TEXEL_HEIGHT_EXT 0x96DA
#define GL_MAX_FRAGMENT_SHADING_RATE_ATTACHMENT_TEXEL_ASPECT_RATIO_EXT 0x96DB
#define GL_MAX_FRAGMENT_SHADING_RATE_ATTACHMENT_LAYERS_EXT 0x96DC
#define GL_FRAGMENT_SHADING_RATE_WITH_SHADER_DEPTH_STENCIL_WRITES_SUPPORTED_EXT 0x96DD
#define GL_FRAGMENT_SHADING_RATE_WITH_SAMPLE_MASK_SUPPORTED_EXT 0x96DE
#define GL_FRAGMENT_SHADING_RATE_ATTACHMENT_WITH_DEFAULT_FRAMEBUFFER_SUPPORTED_EXT 0x96DF
#define GL_FRAGMENT_SHADING_RATE_NON_TRIVIAL_COMBINERS_SUPPORTED_EXT 0x8F6F
#define GL_FRAGMENT_SHADING_RATE_PRIMITIVE_RATE_WITH_MULTI_VIEWPORT_SUPPORTED_EXT 0x9780
typedef void (APIENTRYP PFNGLGETFRAGMENTSHADINGRATESEXTPROC) (GLsizei samples, GLsizei maxCount, GLsizei *count, GLenum *shadingRates);
typedef void (APIENTRYP PFNGLSHADINGRATEEXTPROC) (GLenum rate);
typedef void (APIENTRYP PFNGLSHADINGRATECOMBINEROPSEXTPROC) (GLenum combinerOp0, GLenum combinerOp1);
typedef void (APIENTRYP PFNGLFRAMEBUFFERSHADINGRATEEXTPROC) (GLenum target, GLenum attachment, GLuint texture, GLint baseLayer, GLsizei numLayers, GLsizei texelWidth, GLsizei texelHeight);
#ifdef GL_GLEXT_PROTOTYPES
GLAPI void APIENTRY glGetFragmentShadingRatesEXT (GLsizei samples, GLsizei maxCount, GLsizei *count, GLenum *shadingRates);
GLAPI void APIENTRY glShadingRateEXT (GLenum rate);
GLAPI void APIENTRY glShadingRateCombinerOpsEXT (GLenum combinerOp0, GLenum combinerOp1);
GLAPI void APIENTRY glFramebufferShadingRateEXT (GLenum target, GLenum attachment, GLuint texture, GLint baseLayer, GLsizei numLayers, GLsizei texelWidth, GLsizei texelHeight);
#endif
#endif /* GL_EXT_fragment_shading_rate */
#ifndef GL_EXT_framebuffer_blit #ifndef GL_EXT_framebuffer_blit
#define GL_EXT_framebuffer_blit 1 #define GL_EXT_framebuffer_blit 1
#define GL_READ_FRAMEBUFFER_EXT 0x8CA8 #define GL_READ_FRAMEBUFFER_EXT 0x8CA8
@@ -7857,86 +7816,6 @@ GLAPI void APIENTRY glImportMemoryWin32NameEXT (GLuint memory, GLuint64 size, GL
#endif #endif
#endif /* GL_EXT_memory_object_win32 */ #endif /* GL_EXT_memory_object_win32 */
#ifndef GL_EXT_mesh_shader
#define GL_EXT_mesh_shader 1
#define GL_MESH_SHADER_EXT 0x9559
#define GL_TASK_SHADER_EXT 0x955A
#define GL_MAX_MESH_UNIFORM_BLOCKS_EXT 0x8E60
#define GL_MAX_MESH_TEXTURE_IMAGE_UNITS_EXT 0x8E61
#define GL_MAX_MESH_IMAGE_UNIFORMS_EXT 0x8E62
#define GL_MAX_MESH_UNIFORM_COMPONENTS_EXT 0x8E63
#define GL_MAX_MESH_ATOMIC_COUNTER_BUFFERS_EXT 0x8E64
#define GL_MAX_MESH_ATOMIC_COUNTERS_EXT 0x8E65
#define GL_MAX_MESH_SHADER_STORAGE_BLOCKS_EXT 0x8E66
#define GL_MAX_COMBINED_MESH_UNIFORM_COMPONENTS_EXT 0x8E67
#define GL_MAX_TASK_UNIFORM_BLOCKS_EXT 0x8E68
#define GL_MAX_TASK_TEXTURE_IMAGE_UNITS_EXT 0x8E69
#define GL_MAX_TASK_IMAGE_UNIFORMS_EXT 0x8E6A
#define GL_MAX_TASK_UNIFORM_COMPONENTS_EXT 0x8E6B
#define GL_MAX_TASK_ATOMIC_COUNTER_BUFFERS_EXT 0x8E6C
#define GL_MAX_TASK_ATOMIC_COUNTERS_EXT 0x8E6D
#define GL_MAX_TASK_SHADER_STORAGE_BLOCKS_EXT 0x8E6E
#define GL_MAX_COMBINED_TASK_UNIFORM_COMPONENTS_EXT 0x8E6F
#define GL_MAX_TASK_WORK_GROUP_TOTAL_COUNT_EXT 0x9740
#define GL_MAX_MESH_WORK_GROUP_TOTAL_COUNT_EXT 0x9741
#define GL_MAX_MESH_WORK_GROUP_INVOCATIONS_EXT 0x9757
#define GL_MAX_TASK_WORK_GROUP_INVOCATIONS_EXT 0x9759
#define GL_MAX_TASK_PAYLOAD_SIZE_EXT 0x9742
#define GL_MAX_TASK_SHARED_MEMORY_SIZE_EXT 0x9743
#define GL_MAX_MESH_SHARED_MEMORY_SIZE_EXT 0x9744
#define GL_MAX_TASK_PAYLOAD_AND_SHARED_MEMORY_SIZE_EXT 0x9745
#define GL_MAX_MESH_PAYLOAD_AND_SHARED_MEMORY_SIZE_EXT 0x9746
#define GL_MAX_MESH_OUTPUT_MEMORY_SIZE_EXT 0x9747
#define GL_MAX_MESH_PAYLOAD_AND_OUTPUT_MEMORY_SIZE_EXT 0x9748
#define GL_MAX_MESH_OUTPUT_VERTICES_EXT 0x9538
#define GL_MAX_MESH_OUTPUT_PRIMITIVES_EXT 0x9756
#define GL_MAX_MESH_OUTPUT_COMPONENTS_EXT 0x9749
#define GL_MAX_MESH_OUTPUT_LAYERS_EXT 0x974A
#define GL_MAX_MESH_MULTIVIEW_VIEW_COUNT_EXT 0x9557
#define GL_MESH_OUTPUT_PER_VERTEX_GRANULARITY_EXT 0x92DF
#define GL_MESH_OUTPUT_PER_PRIMITIVE_GRANULARITY_EXT 0x9543
#define GL_MAX_PREFERRED_TASK_WORK_GROUP_INVOCATIONS_EXT 0x974B
#define GL_MAX_PREFERRED_MESH_WORK_GROUP_INVOCATIONS_EXT 0x974C
#define GL_MESH_PREFERS_LOCAL_INVOCATION_VERTEX_OUTPUT_EXT 0x974D
#define GL_MESH_PREFERS_LOCAL_INVOCATION_PRIMITIVE_OUTPUT_EXT 0x974E
#define GL_MESH_PREFERS_COMPACT_VERTEX_OUTPUT_EXT 0x974F
#define GL_MESH_PREFERS_COMPACT_PRIMITIVE_OUTPUT_EXT 0x9750
#define GL_MAX_TASK_WORK_GROUP_COUNT_EXT 0x9751
#define GL_MAX_MESH_WORK_GROUP_COUNT_EXT 0x9752
#define GL_MAX_MESH_WORK_GROUP_SIZE_EXT 0x9758
#define GL_MAX_TASK_WORK_GROUP_SIZE_EXT 0x975A
#define GL_MESH_WORK_GROUP_SIZE_EXT 0x953E
#define GL_TASK_WORK_GROUP_SIZE_EXT 0x953F
#define GL_MESH_VERTICES_OUT_EXT 0x9579
#define GL_MESH_PRIMITIVES_OUT_EXT 0x957A
#define GL_MESH_OUTPUT_TYPE_EXT 0x957B
#define GL_UNIFORM_BLOCK_REFERENCED_BY_MESH_SHADER_EXT 0x959C
#define GL_UNIFORM_BLOCK_REFERENCED_BY_TASK_SHADER_EXT 0x959D
#define GL_REFERENCED_BY_MESH_SHADER_EXT 0x95A0
#define GL_REFERENCED_BY_TASK_SHADER_EXT 0x95A1
#define GL_TASK_SHADER_INVOCATIONS_EXT 0x9753
#define GL_MESH_SHADER_INVOCATIONS_EXT 0x9754
#define GL_MESH_PRIMITIVES_GENERATED_EXT 0x9755
#define GL_MESH_SHADER_BIT_EXT 0x00000040
#define GL_TASK_SHADER_BIT_EXT 0x00000080
#define GL_MESH_SUBROUTINE_EXT 0x957C
#define GL_TASK_SUBROUTINE_EXT 0x957D
#define GL_MESH_SUBROUTINE_UNIFORM_EXT 0x957E
#define GL_TASK_SUBROUTINE_UNIFORM_EXT 0x957F
#define GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_MESH_SHADER_EXT 0x959E
#define GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TASK_SHADER_EXT 0x959F
typedef void (APIENTRYP PFNGLDRAWMESHTASKSEXTPROC) (GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z);
typedef void (APIENTRYP PFNGLDRAWMESHTASKSINDIRECTEXTPROC) (GLintptr indirect);
typedef void (APIENTRYP PFNGLMULTIDRAWMESHTASKSINDIRECTEXTPROC) (GLintptr indirect, GLsizei drawcount, GLsizei stride);
typedef void (APIENTRYP PFNGLMULTIDRAWMESHTASKSINDIRECTCOUNTEXTPROC) (GLintptr indirect, GLintptr drawcount, GLsizei maxdrawcount, GLsizei stride);
#ifdef GL_GLEXT_PROTOTYPES
GLAPI void APIENTRY glDrawMeshTasksEXT (GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z);
GLAPI void APIENTRY glDrawMeshTasksIndirectEXT (GLintptr indirect);
GLAPI void APIENTRY glMultiDrawMeshTasksIndirectEXT (GLintptr indirect, GLsizei drawcount, GLsizei stride);
GLAPI void APIENTRY glMultiDrawMeshTasksIndirectCountEXT (GLintptr indirect, GLintptr drawcount, GLsizei maxdrawcount, GLsizei stride);
#endif
#endif /* GL_EXT_mesh_shader */
#ifndef GL_EXT_misc_attribute #ifndef GL_EXT_misc_attribute
#define GL_EXT_misc_attribute 1 #define GL_EXT_misc_attribute 1
#endif /* GL_EXT_misc_attribute */ #endif /* GL_EXT_misc_attribute */
+2 -2
View File
@@ -11,11 +11,11 @@ add_library(soundtouch STATIC EXCLUDE_FROM_ALL
soundtouch/source/SoundTouch/TDStretch.cpp soundtouch/source/SoundTouch/TDStretch.cpp
) )
target_include_directories(soundtouch SYSTEM PRIVATE target_include_directories(soundtouch PRIVATE
soundtouch/source/SoundTouch soundtouch/source/SoundTouch
soundtouch/include) soundtouch/include)
target_include_directories(soundtouch SYSTEM INTERFACE target_include_directories(soundtouch INTERFACE
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/soundtouch/include> $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/soundtouch/include>
$<INSTALL_INTERFACE:/soundtouch/include>) $<INSTALL_INTERFACE:/soundtouch/include>)
+1 -1
View File
@@ -9,7 +9,7 @@ set(ASMJIT_DIR "${CMAKE_CURRENT_SOURCE_DIR}/asmjit" CACHE PATH "Location of 'asm
include("${ASMJIT_DIR}/CMakeLists.txt") include("${ASMJIT_DIR}/CMakeLists.txt")
add_library(asmjit ${ASMJIT_SRC}) add_library(asmjit ${ASMJIT_SRC})
target_include_directories(asmjit SYSTEM PUBLIC ${ASMJIT_DIR}/src) target_include_directories(asmjit PUBLIC ${ASMJIT_DIR}/src)
target_link_libraries(asmjit PRIVATE ${ASMJIT_DEPS}) target_link_libraries(asmjit PRIVATE ${ASMJIT_DEPS})
# ASMJIT should have a option for disabling installing and this wouldnt # ASMJIT should have a option for disabling installing and this wouldnt
+19 -16
View File
@@ -7,24 +7,27 @@ if(USE_SYSTEM_CURL)
target_link_libraries(3rdparty_libcurl INTERFACE CURL::libcurl) target_link_libraries(3rdparty_libcurl INTERFACE CURL::libcurl)
else() else()
message(STATUS "RPCS3: building libcurl + wolfssl submodules") message(STATUS "RPCS3: building libcurl + wolfssl submodules")
set(BUILD_CURL_EXE OFF CACHE INTERNAL "") set(BUILD_CURL_EXE OFF CACHE BOOL "Set to ON to build curl executable.")
set(BUILD_STATIC_CURL OFF CACHE INTERNAL "") set(BUILD_STATIC_CURL OFF CACHE BOOL "Set to ON to build curl executable with static libcurl.")
set(BUILD_STATIC_LIBS ON CACHE INTERNAL "") set(BUILD_STATIC_LIBS ON CACHE BOOL "Set to ON to build static libcurl.")
set(BUILD_SHARED_LIBS OFF CACHE INTERNAL "") set(BUILD_SHARED_LIBS OFF CACHE BOOL "Set to ON to build shared libcurl.")
find_package(WolfSSL REQUIRED) find_package(WolfSSL REQUIRED)
set(CURL_USE_WOLFSSL ON CACHE INTERNAL "") set(CURL_USE_WOLFSSL ON CACHE BOOL "enable wolfSSL for SSL/TLS")
set(CURL_USE_OPENSSL OFF CACHE INTERNAL "") set(CURL_USE_OPENSSL OFF CACHE BOOL "Use OpenSSL code. Experimental")
set(HTTP_ONLY ON CACHE INTERNAL "") set(HTTP_ONLY ON CACHE BOOL "disables all protocols except HTTP (This overrides all CURL_DISABLE_* options)")
set(USE_LIBIDN2 OFF CACHE INTERNAL "") # Disabled because MacOS CI doesn't work otherwise set(USE_LIBIDN2 OFF CACHE BOOL "Use libidn2 for IDN support") # Disabled because MacOS CI doesn't work otherwise
set(CURL_CA_PATH "none" CACHE INTERNAL "") set(CURL_CA_PATH "none" CACHE STRING "Location of default CA path. Set 'none' to disable or 'auto' for auto-detection. Defaults to 'auto'.")
set(CURL_DISABLE_INSTALL ON CACHE INTERNAL "") option(CURL_DISABLE_INSTALL "Disable installation targets" ON)
if(WIN32) if(USE_MSVC_STATIC_CRT)
set(ENABLE_UNICODE ON CACHE INTERNAL "") set(CURL_STATIC_CRT ON CACHE BOOL "Use static crt to build curl")
endif() endif()
set(CURL_USE_LIBSSH2 OFF CACHE INTERNAL "") if(WIN32)
set(CURL_USE_LIBPSL OFF CACHE INTERNAL "") set(ENABLE_UNICODE ON CACHE BOOL "enable Unicode")
set(BUILD_TESTING OFF CACHE INTERNAL "") endif()
set(BUILD_EXAMPLES OFF CACHE INTERNAL "") set(CURL_USE_LIBSSH2 OFF CACHE BOOL "Use libSSH2")
set(CURL_USE_LIBPSL OFF CACHE BOOL "Use libPSL")
option(BUILD_TESTING "Build tests" OFF)
option(BUILD_EXAMPLES "Build libcurl examples" OFF)
add_subdirectory(curl EXCLUDE_FROM_ALL) add_subdirectory(curl EXCLUDE_FROM_ALL)
+17 -25
View File
@@ -66,7 +66,6 @@
<ClCompile Include="curl\lib\asyn-thrdd.c" /> <ClCompile Include="curl\lib\asyn-thrdd.c" />
<ClCompile Include="curl\lib\bufq.c" /> <ClCompile Include="curl\lib\bufq.c" />
<ClCompile Include="curl\lib\bufref.c" /> <ClCompile Include="curl\lib\bufref.c" />
<ClCompile Include="curl\lib\cf-dns.c" />
<ClCompile Include="curl\lib\cf-h1-proxy.c" /> <ClCompile Include="curl\lib\cf-h1-proxy.c" />
<ClCompile Include="curl\lib\cf-h2-proxy.c" /> <ClCompile Include="curl\lib\cf-h2-proxy.c" />
<ClCompile Include="curl\lib\cf-haproxy.c" /> <ClCompile Include="curl\lib\cf-haproxy.c" />
@@ -80,16 +79,12 @@
<ClCompile Include="curl\lib\cookie.c" /> <ClCompile Include="curl\lib\cookie.c" />
<ClCompile Include="curl\lib\cshutdn.c" /> <ClCompile Include="curl\lib\cshutdn.c" />
<ClCompile Include="curl\lib\curlx\base64.c" /> <ClCompile Include="curl\lib\curlx\base64.c" />
<ClCompile Include="curl\lib\curlx\basename.c" />
<ClCompile Include="curl\lib\curlx\dynbuf.c" /> <ClCompile Include="curl\lib\curlx\dynbuf.c" />
<ClCompile Include="curl\lib\curlx\fopen.c" /> <ClCompile Include="curl\lib\curlx\fopen.c" />
<ClCompile Include="curl\lib\curlx\inet_ntop.c" /> <ClCompile Include="curl\lib\curlx\inet_ntop.c" />
<ClCompile Include="curl\lib\curlx\inet_pton.c" /> <ClCompile Include="curl\lib\curlx\inet_pton.c" />
<ClCompile Include="curl\lib\curlx\multibyte.c" /> <ClCompile Include="curl\lib\curlx\multibyte.c" />
<ClCompile Include="curl\lib\curlx\nonblock.c" /> <ClCompile Include="curl\lib\curlx\nonblock.c" />
<ClCompile Include="curl\lib\curlx\snprintf.c" />
<ClCompile Include="curl\lib\curlx\strcopy.c" />
<ClCompile Include="curl\lib\curlx\strdup.c" />
<ClCompile Include="curl\lib\curlx\strerr.c" /> <ClCompile Include="curl\lib\curlx\strerr.c" />
<ClCompile Include="curl\lib\curlx\strparse.c" /> <ClCompile Include="curl\lib\curlx\strparse.c" />
<ClCompile Include="curl\lib\curlx\timediff.c" /> <ClCompile Include="curl\lib\curlx\timediff.c" />
@@ -108,9 +103,9 @@
<ClCompile Include="curl\lib\curl_memrchr.c" /> <ClCompile Include="curl\lib\curl_memrchr.c" />
<ClCompile Include="curl\lib\curl_ntlm_core.c" /> <ClCompile Include="curl\lib\curl_ntlm_core.c" />
<ClCompile Include="curl\lib\curl_range.c" /> <ClCompile Include="curl\lib\curl_range.c" />
<ClCompile Include="curl\lib\curl_rtmp.c" />
<ClCompile Include="curl\lib\curl_sasl.c" /> <ClCompile Include="curl\lib\curl_sasl.c" />
<ClCompile Include="curl\lib\curl_sha512_256.c" /> <ClCompile Include="curl\lib\curl_sha512_256.c" />
<ClCompile Include="curl\lib\curl_share.c" />
<ClCompile Include="curl\lib\curl_sspi.c" /> <ClCompile Include="curl\lib\curl_sspi.c" />
<ClCompile Include="curl\lib\curl_threads.c" /> <ClCompile Include="curl\lib\curl_threads.c" />
<ClCompile Include="curl\lib\curl_trc.c" /> <ClCompile Include="curl\lib\curl_trc.c" />
@@ -118,7 +113,6 @@
<ClCompile Include="curl\lib\cw-pause.c" /> <ClCompile Include="curl\lib\cw-pause.c" />
<ClCompile Include="curl\lib\dict.c" /> <ClCompile Include="curl\lib\dict.c" />
<ClCompile Include="curl\lib\dllmain.c" /> <ClCompile Include="curl\lib\dllmain.c" />
<ClCompile Include="curl\lib\dnscache.c" />
<ClCompile Include="curl\lib\doh.c" /> <ClCompile Include="curl\lib\doh.c" />
<ClCompile Include="curl\lib\dynhds.c" /> <ClCompile Include="curl\lib\dynhds.c" />
<ClCompile Include="curl\lib\easy.c" /> <ClCompile Include="curl\lib\easy.c" />
@@ -173,16 +167,16 @@
<ClCompile Include="curl\lib\pingpong.c" /> <ClCompile Include="curl\lib\pingpong.c" />
<ClCompile Include="curl\lib\pop3.c" /> <ClCompile Include="curl\lib\pop3.c" />
<ClCompile Include="curl\lib\progress.c" /> <ClCompile Include="curl\lib\progress.c" />
<ClCompile Include="curl\lib\protocol.c" />
<ClCompile Include="curl\lib\psl.c" /> <ClCompile Include="curl\lib\psl.c" />
<ClCompile Include="curl\lib\rand.c" /> <ClCompile Include="curl\lib\rand.c" />
<ClCompile Include="curl\lib\ratelimit.c" /> <ClCompile Include="curl\lib\rename.c" />
<ClCompile Include="curl\lib\request.c" /> <ClCompile Include="curl\lib\request.c" />
<ClCompile Include="curl\lib\rtsp.c" /> <ClCompile Include="curl\lib\rtsp.c" />
<ClCompile Include="curl\lib\select.c" /> <ClCompile Include="curl\lib\select.c" />
<ClCompile Include="curl\lib\sendf.c" /> <ClCompile Include="curl\lib\sendf.c" />
<ClCompile Include="curl\lib\setopt.c" /> <ClCompile Include="curl\lib\setopt.c" />
<ClCompile Include="curl\lib\sha256.c" /> <ClCompile Include="curl\lib\sha256.c" />
<ClCompile Include="curl\lib\share.c" />
<ClCompile Include="curl\lib\slist.c" /> <ClCompile Include="curl\lib\slist.c" />
<ClCompile Include="curl\lib\smb.c" /> <ClCompile Include="curl\lib\smb.c" />
<ClCompile Include="curl\lib\smtp.c" /> <ClCompile Include="curl\lib\smtp.c" />
@@ -190,15 +184,15 @@
<ClCompile Include="curl\lib\socks.c" /> <ClCompile Include="curl\lib\socks.c" />
<ClCompile Include="curl\lib\socks_gssapi.c" /> <ClCompile Include="curl\lib\socks_gssapi.c" />
<ClCompile Include="curl\lib\socks_sspi.c" /> <ClCompile Include="curl\lib\socks_sspi.c" />
<ClCompile Include="curl\lib\speedcheck.c" />
<ClCompile Include="curl\lib\splay.c" /> <ClCompile Include="curl\lib\splay.c" />
<ClCompile Include="curl\lib\strcase.c" /> <ClCompile Include="curl\lib\strcase.c" />
<ClCompile Include="curl\lib\strdup.c" />
<ClCompile Include="curl\lib\strequal.c" /> <ClCompile Include="curl\lib\strequal.c" />
<ClCompile Include="curl\lib\strerror.c" /> <ClCompile Include="curl\lib\strerror.c" />
<ClCompile Include="curl\lib\system_win32.c" /> <ClCompile Include="curl\lib\system_win32.c" />
<ClCompile Include="curl\lib\telnet.c" /> <ClCompile Include="curl\lib\telnet.c" />
<ClCompile Include="curl\lib\tftp.c" /> <ClCompile Include="curl\lib\tftp.c" />
<ClCompile Include="curl\lib\thrdpool.c" />
<ClCompile Include="curl\lib\thrdqueue.c" />
<ClCompile Include="curl\lib\transfer.c" /> <ClCompile Include="curl\lib\transfer.c" />
<ClCompile Include="curl\lib\uint-bset.c" /> <ClCompile Include="curl\lib\uint-bset.c" />
<ClCompile Include="curl\lib\uint-hash.c" /> <ClCompile Include="curl\lib\uint-hash.c" />
@@ -210,7 +204,6 @@
<ClCompile Include="curl\lib\version.c" /> <ClCompile Include="curl\lib\version.c" />
<ClCompile Include="curl\lib\vquic\curl_ngtcp2.c" /> <ClCompile Include="curl\lib\vquic\curl_ngtcp2.c" />
<ClCompile Include="curl\lib\vquic\curl_quiche.c" /> <ClCompile Include="curl\lib\vquic\curl_quiche.c" />
<ClCompile Include="curl\lib\vssh\vssh.c" />
<ClCompile Include="curl\lib\vtls\apple.c" /> <ClCompile Include="curl\lib\vtls\apple.c" />
<ClCompile Include="curl\lib\vtls\cipher_suite.c" /> <ClCompile Include="curl\lib\vtls\cipher_suite.c" />
<ClCompile Include="curl\lib\vtls\hostcheck.c" /> <ClCompile Include="curl\lib\vtls\hostcheck.c" />
@@ -231,11 +224,13 @@
<ClCompile Include="curl\lib\vauth\spnego_sspi.c" /> <ClCompile Include="curl\lib\vauth\spnego_sspi.c" />
<ClCompile Include="curl\lib\vauth\vauth.c" /> <ClCompile Include="curl\lib\vauth\vauth.c" />
<ClCompile Include="curl\lib\vquic\vquic.c" /> <ClCompile Include="curl\lib\vquic\vquic.c" />
<ClCompile Include="curl\lib\vssh\curl_path.c" />
<ClCompile Include="curl\lib\vssh\libssh.c" /> <ClCompile Include="curl\lib\vssh\libssh.c" />
<ClCompile Include="curl\lib\vssh\libssh2.c" /> <ClCompile Include="curl\lib\vssh\libssh2.c" />
<ClCompile Include="curl\lib\vtls\gtls.c" /> <ClCompile Include="curl\lib\vtls\gtls.c" />
<ClCompile Include="curl\lib\vtls\keylog.c" /> <ClCompile Include="curl\lib\vtls\keylog.c" />
<ClCompile Include="curl\lib\vtls\mbedtls.c" /> <ClCompile Include="curl\lib\vtls\mbedtls.c" />
<ClCompile Include="curl\lib\vtls\mbedtls_threadlock.c" />
<ClCompile Include="curl\lib\vtls\openssl.c" /> <ClCompile Include="curl\lib\vtls\openssl.c" />
<ClCompile Include="curl\lib\vtls\schannel.c" /> <ClCompile Include="curl\lib\vtls\schannel.c" />
<ClCompile Include="curl\lib\vtls\schannel_verify.c" /> <ClCompile Include="curl\lib\vtls\schannel_verify.c" />
@@ -259,7 +254,6 @@
<ClInclude Include="curl\lib\asyn.h" /> <ClInclude Include="curl\lib\asyn.h" />
<ClInclude Include="curl\lib\bufq.h" /> <ClInclude Include="curl\lib\bufq.h" />
<ClInclude Include="curl\lib\bufref.h" /> <ClInclude Include="curl\lib\bufref.h" />
<ClInclude Include="curl\lib\cf-dns.h" />
<ClInclude Include="curl\lib\cf-h1-proxy.h" /> <ClInclude Include="curl\lib\cf-h1-proxy.h" />
<ClInclude Include="curl\lib\cf-h2-proxy.h" /> <ClInclude Include="curl\lib\cf-h2-proxy.h" />
<ClInclude Include="curl\lib\cf-haproxy.h" /> <ClInclude Include="curl\lib\cf-haproxy.h" />
@@ -278,17 +272,14 @@
<ClInclude Include="curl\lib\cookie.h" /> <ClInclude Include="curl\lib\cookie.h" />
<ClInclude Include="curl\lib\cshutdn.h" /> <ClInclude Include="curl\lib\cshutdn.h" />
<ClInclude Include="curl\lib\curlx\base64.h" /> <ClInclude Include="curl\lib\curlx\base64.h" />
<ClInclude Include="curl\lib\curlx\basename.h" />
<ClInclude Include="curl\lib\curlx\binmode.h" /> <ClInclude Include="curl\lib\curlx\binmode.h" />
<ClInclude Include="curl\lib\curlx\curlx.h" />
<ClInclude Include="curl\lib\curlx\dynbuf.h" /> <ClInclude Include="curl\lib\curlx\dynbuf.h" />
<ClInclude Include="curl\lib\curlx\fopen.h" /> <ClInclude Include="curl\lib\curlx\fopen.h" />
<ClInclude Include="curl\lib\curlx\inet_ntop.h" /> <ClInclude Include="curl\lib\curlx\inet_ntop.h" />
<ClInclude Include="curl\lib\curlx\inet_pton.h" /> <ClInclude Include="curl\lib\curlx\inet_pton.h" />
<ClInclude Include="curl\lib\curlx\multibyte.h" /> <ClInclude Include="curl\lib\curlx\multibyte.h" />
<ClInclude Include="curl\lib\curlx\nonblock.h" /> <ClInclude Include="curl\lib\curlx\nonblock.h" />
<ClInclude Include="curl\lib\curlx\snprintf.h" />
<ClInclude Include="curl\lib\curlx\strcopy.h" />
<ClInclude Include="curl\lib\curlx\strdup.h" />
<ClInclude Include="curl\lib\curlx\strerr.h" /> <ClInclude Include="curl\lib\curlx\strerr.h" />
<ClInclude Include="curl\lib\curlx\strparse.h" /> <ClInclude Include="curl\lib\curlx\strparse.h" />
<ClInclude Include="curl\lib\curlx\timediff.h" /> <ClInclude Include="curl\lib\curlx\timediff.h" />
@@ -309,23 +300,24 @@
<ClInclude Include="curl\lib\curl_ldap.h" /> <ClInclude Include="curl\lib\curl_ldap.h" />
<ClInclude Include="curl\lib\curl_md4.h" /> <ClInclude Include="curl\lib\curl_md4.h" />
<ClInclude Include="curl\lib\curl_md5.h" /> <ClInclude Include="curl\lib\curl_md5.h" />
<ClInclude Include="curl\lib\curl_memory.h" />
<ClInclude Include="curl\lib\curl_memrchr.h" /> <ClInclude Include="curl\lib\curl_memrchr.h" />
<ClInclude Include="curl\lib\curl_mem_undef.h" />
<ClInclude Include="curl\lib\curl_ntlm_core.h" /> <ClInclude Include="curl\lib\curl_ntlm_core.h" />
<ClInclude Include="curl\lib\curl_printf.h" /> <ClInclude Include="curl\lib\curl_printf.h" />
<ClInclude Include="curl\lib\curl_range.h" /> <ClInclude Include="curl\lib\curl_range.h" />
<ClInclude Include="curl\lib\curl_rtmp.h" />
<ClInclude Include="curl\lib\curl_sasl.h" /> <ClInclude Include="curl\lib\curl_sasl.h" />
<ClInclude Include="curl\lib\curl_setup.h" /> <ClInclude Include="curl\lib\curl_setup.h" />
<ClInclude Include="curl\lib\curl_setup_once.h" /> <ClInclude Include="curl\lib\curl_setup_once.h" />
<ClInclude Include="curl\lib\curl_sha256.h" /> <ClInclude Include="curl\lib\curl_sha256.h" />
<ClInclude Include="curl\lib\curl_sha512_256.h" /> <ClInclude Include="curl\lib\curl_sha512_256.h" />
<ClInclude Include="curl\lib\curl_share.h" />
<ClInclude Include="curl\lib\curl_sspi.h" /> <ClInclude Include="curl\lib\curl_sspi.h" />
<ClInclude Include="curl\lib\curl_threads.h" /> <ClInclude Include="curl\lib\curl_threads.h" />
<ClInclude Include="curl\lib\curl_trc.h" /> <ClInclude Include="curl\lib\curl_trc.h" />
<ClInclude Include="curl\lib\cw-out.h" /> <ClInclude Include="curl\lib\cw-out.h" />
<ClInclude Include="curl\lib\cw-pause.h" /> <ClInclude Include="curl\lib\cw-pause.h" />
<ClInclude Include="curl\lib\dict.h" /> <ClInclude Include="curl\lib\dict.h" />
<ClInclude Include="curl\lib\dnscache.h" />
<ClInclude Include="curl\lib\doh.h" /> <ClInclude Include="curl\lib\doh.h" />
<ClInclude Include="curl\lib\dynhds.h" /> <ClInclude Include="curl\lib\dynhds.h" />
<ClInclude Include="curl\lib\easyif.h" /> <ClInclude Include="curl\lib\easyif.h" />
@@ -336,7 +328,6 @@
<ClInclude Include="curl\lib\file.h" /> <ClInclude Include="curl\lib\file.h" />
<ClInclude Include="curl\lib\fileinfo.h" /> <ClInclude Include="curl\lib\fileinfo.h" />
<ClInclude Include="curl\lib\formdata.h" /> <ClInclude Include="curl\lib\formdata.h" />
<ClInclude Include="curl\lib\ftp-int.h" />
<ClInclude Include="curl\lib\ftp.h" /> <ClInclude Include="curl\lib\ftp.h" />
<ClInclude Include="curl\lib\ftplistparser.h" /> <ClInclude Include="curl\lib\ftplistparser.h" />
<ClInclude Include="curl\lib\functypes.h" /> <ClInclude Include="curl\lib\functypes.h" />
@@ -361,6 +352,7 @@
<ClInclude Include="curl\lib\imap.h" /> <ClInclude Include="curl\lib\imap.h" />
<ClInclude Include="curl\lib\llist.h" /> <ClInclude Include="curl\lib\llist.h" />
<ClInclude Include="curl\lib\macos.h" /> <ClInclude Include="curl\lib\macos.h" />
<ClInclude Include="curl\lib\memdebug.h" />
<ClInclude Include="curl\lib\mime.h" /> <ClInclude Include="curl\lib\mime.h" />
<ClInclude Include="curl\lib\mqtt.h" /> <ClInclude Include="curl\lib\mqtt.h" />
<ClInclude Include="curl\lib\multihandle.h" /> <ClInclude Include="curl\lib\multihandle.h" />
@@ -373,10 +365,9 @@
<ClInclude Include="curl\lib\pingpong.h" /> <ClInclude Include="curl\lib\pingpong.h" />
<ClInclude Include="curl\lib\pop3.h" /> <ClInclude Include="curl\lib\pop3.h" />
<ClInclude Include="curl\lib\progress.h" /> <ClInclude Include="curl\lib\progress.h" />
<ClInclude Include="curl\lib\protocol.h" />
<ClInclude Include="curl\lib\psl.h" /> <ClInclude Include="curl\lib\psl.h" />
<ClInclude Include="curl\lib\rand.h" /> <ClInclude Include="curl\lib\rand.h" />
<ClInclude Include="curl\lib\ratelimit.h" /> <ClInclude Include="curl\lib\rename.h" />
<ClInclude Include="curl\lib\request.h" /> <ClInclude Include="curl\lib\request.h" />
<ClInclude Include="curl\lib\rtsp.h" /> <ClInclude Include="curl\lib\rtsp.h" />
<ClInclude Include="curl\lib\select.h" /> <ClInclude Include="curl\lib\select.h" />
@@ -385,6 +376,7 @@
<ClInclude Include="curl\lib\setup-os400.h" /> <ClInclude Include="curl\lib\setup-os400.h" />
<ClInclude Include="curl\lib\setup-vms.h" /> <ClInclude Include="curl\lib\setup-vms.h" />
<ClInclude Include="curl\lib\setup-win32.h" /> <ClInclude Include="curl\lib\setup-win32.h" />
<ClInclude Include="curl\lib\share.h" />
<ClInclude Include="curl\lib\sigpipe.h" /> <ClInclude Include="curl\lib\sigpipe.h" />
<ClInclude Include="curl\lib\slist.h" /> <ClInclude Include="curl\lib\slist.h" />
<ClInclude Include="curl\lib\smb.h" /> <ClInclude Include="curl\lib\smb.h" />
@@ -392,6 +384,7 @@
<ClInclude Include="curl\lib\sockaddr.h" /> <ClInclude Include="curl\lib\sockaddr.h" />
<ClInclude Include="curl\lib\socketpair.h" /> <ClInclude Include="curl\lib\socketpair.h" />
<ClInclude Include="curl\lib\socks.h" /> <ClInclude Include="curl\lib\socks.h" />
<ClInclude Include="curl\lib\speedcheck.h" />
<ClInclude Include="curl\lib\splay.h" /> <ClInclude Include="curl\lib\splay.h" />
<ClInclude Include="curl\lib\strcase.h" /> <ClInclude Include="curl\lib\strcase.h" />
<ClInclude Include="curl\lib\strdup.h" /> <ClInclude Include="curl\lib\strdup.h" />
@@ -401,8 +394,6 @@
<ClInclude Include="curl\lib\system_win32.h" /> <ClInclude Include="curl\lib\system_win32.h" />
<ClInclude Include="curl\lib\telnet.h" /> <ClInclude Include="curl\lib\telnet.h" />
<ClInclude Include="curl\lib\tftp.h" /> <ClInclude Include="curl\lib\tftp.h" />
<ClInclude Include="curl\lib\thrdpool.h" />
<ClInclude Include="curl\lib\thrdqueue.h" />
<ClInclude Include="curl\lib\transfer.h" /> <ClInclude Include="curl\lib\transfer.h" />
<ClInclude Include="curl\lib\uint-bset.h" /> <ClInclude Include="curl\lib\uint-bset.h" />
<ClInclude Include="curl\lib\uint-hash.h" /> <ClInclude Include="curl\lib\uint-hash.h" />
@@ -414,7 +405,6 @@
<ClInclude Include="curl\lib\vquic\curl_ngtcp2.h" /> <ClInclude Include="curl\lib\vquic\curl_ngtcp2.h" />
<ClInclude Include="curl\lib\vquic\curl_quiche.h" /> <ClInclude Include="curl\lib\vquic\curl_quiche.h" />
<ClInclude Include="curl\lib\vquic\vquic_int.h" /> <ClInclude Include="curl\lib\vquic\vquic_int.h" />
<ClInclude Include="curl\lib\vssh\vssh.h" />
<ClInclude Include="curl\lib\vtls\apple.h" /> <ClInclude Include="curl\lib\vtls\apple.h" />
<ClInclude Include="curl\lib\vtls\cipher_suite.h" /> <ClInclude Include="curl\lib\vtls\cipher_suite.h" />
<ClInclude Include="curl\lib\vtls\hostcheck.h" /> <ClInclude Include="curl\lib\vtls\hostcheck.h" />
@@ -428,10 +418,12 @@
<ClInclude Include="curl\lib\vauth\ntlm.h" /> <ClInclude Include="curl\lib\vauth\ntlm.h" />
<ClInclude Include="curl\lib\vauth\vauth.h" /> <ClInclude Include="curl\lib\vauth\vauth.h" />
<ClInclude Include="curl\lib\vquic\vquic.h" /> <ClInclude Include="curl\lib\vquic\vquic.h" />
<ClInclude Include="curl\lib\vssh\curl_path.h" />
<ClInclude Include="curl\lib\vssh\ssh.h" /> <ClInclude Include="curl\lib\vssh\ssh.h" />
<ClInclude Include="curl\lib\vtls\gtls.h" /> <ClInclude Include="curl\lib\vtls\gtls.h" />
<ClInclude Include="curl\lib\vtls\keylog.h" /> <ClInclude Include="curl\lib\vtls\keylog.h" />
<ClInclude Include="curl\lib\vtls\mbedtls.h" /> <ClInclude Include="curl\lib\vtls\mbedtls.h" />
<ClInclude Include="curl\lib\vtls\mbedtls_threadlock.h" />
<ClInclude Include="curl\lib\vtls\openssl.h" /> <ClInclude Include="curl\lib\vtls\openssl.h" />
<ClInclude Include="curl\lib\vtls\schannel.h" /> <ClInclude Include="curl\lib\vtls\schannel.h" />
<ClInclude Include="curl\lib\vtls\vtls.h" /> <ClInclude Include="curl\lib\vtls\vtls.h" />
+51 -75
View File
@@ -66,6 +66,9 @@
<ClCompile Include="curl\lib\curl_range.c"> <ClCompile Include="curl\lib\curl_range.c">
<Filter>Source Files</Filter> <Filter>Source Files</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="curl\lib\curl_rtmp.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\curl_sasl.c"> <ClCompile Include="curl\lib\curl_sasl.c">
<Filter>Source Files</Filter> <Filter>Source Files</Filter>
</ClCompile> </ClCompile>
@@ -201,6 +204,9 @@
<ClCompile Include="curl\lib\rand.c"> <ClCompile Include="curl\lib\rand.c">
<Filter>Source Files</Filter> <Filter>Source Files</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="curl\lib\rename.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\rtsp.c"> <ClCompile Include="curl\lib\rtsp.c">
<Filter>Source Files</Filter> <Filter>Source Files</Filter>
</ClCompile> </ClCompile>
@@ -216,6 +222,9 @@
<ClCompile Include="curl\lib\sha256.c"> <ClCompile Include="curl\lib\sha256.c">
<Filter>Source Files</Filter> <Filter>Source Files</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="curl\lib\share.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\slist.c"> <ClCompile Include="curl\lib\slist.c">
<Filter>Source Files</Filter> <Filter>Source Files</Filter>
</ClCompile> </ClCompile>
@@ -237,12 +246,18 @@
<ClCompile Include="curl\lib\socks_sspi.c"> <ClCompile Include="curl\lib\socks_sspi.c">
<Filter>Source Files</Filter> <Filter>Source Files</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="curl\lib\speedcheck.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\splay.c"> <ClCompile Include="curl\lib\splay.c">
<Filter>Source Files</Filter> <Filter>Source Files</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="curl\lib\strcase.c"> <ClCompile Include="curl\lib\strcase.c">
<Filter>Source Files</Filter> <Filter>Source Files</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="curl\lib\strdup.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\strerror.c"> <ClCompile Include="curl\lib\strerror.c">
<Filter>Source Files</Filter> <Filter>Source Files</Filter>
</ClCompile> </ClCompile>
@@ -303,6 +318,9 @@
<ClCompile Include="curl\lib\vauth\vauth.c"> <ClCompile Include="curl\lib\vauth\vauth.c">
<Filter>Source Files</Filter> <Filter>Source Files</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="curl\lib\vssh\curl_path.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\vssh\libssh.c"> <ClCompile Include="curl\lib\vssh\libssh.c">
<Filter>Source Files</Filter> <Filter>Source Files</Filter>
</ClCompile> </ClCompile>
@@ -315,6 +333,9 @@
<ClCompile Include="curl\lib\vtls\mbedtls.c"> <ClCompile Include="curl\lib\vtls\mbedtls.c">
<Filter>Source Files</Filter> <Filter>Source Files</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="curl\lib\vtls\mbedtls_threadlock.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\vtls\openssl.c"> <ClCompile Include="curl\lib\vtls\openssl.c">
<Filter>Source Files</Filter> <Filter>Source Files</Filter>
</ClCompile> </ClCompile>
@@ -528,42 +549,6 @@
<ClCompile Include="curl\lib\curlx\strerr.c"> <ClCompile Include="curl\lib\curlx\strerr.c">
<Filter>Source Files</Filter> <Filter>Source Files</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="curl\lib\curlx\strcopy.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\vssh\vssh.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\curl_share.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\ratelimit.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\curlx\basename.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\curlx\snprintf.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\curlx\strdup.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\cf-dns.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\dnscache.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\protocol.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\thrdpool.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="curl\lib\thrdqueue.c">
<Filter>Source Files</Filter>
</ClCompile>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClInclude Include="curl\include\curl\curl.h"> <ClInclude Include="curl\include\curl\curl.h">
@@ -668,6 +653,9 @@
<ClInclude Include="curl\lib\curl_md5.h"> <ClInclude Include="curl\lib\curl_md5.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="curl\lib\curl_memory.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\curl_memrchr.h"> <ClInclude Include="curl\lib\curl_memrchr.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
@@ -680,6 +668,9 @@
<ClInclude Include="curl\lib\curl_range.h"> <ClInclude Include="curl\lib\curl_range.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="curl\lib\curl_rtmp.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\curl_sasl.h"> <ClInclude Include="curl\lib\curl_sasl.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
@@ -767,6 +758,9 @@
<ClInclude Include="curl\lib\llist.h"> <ClInclude Include="curl\lib\llist.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="curl\lib\memdebug.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\mime.h"> <ClInclude Include="curl\lib\mime.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
@@ -797,6 +791,9 @@
<ClInclude Include="curl\lib\rand.h"> <ClInclude Include="curl\lib\rand.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="curl\lib\rename.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\rtsp.h"> <ClInclude Include="curl\lib\rtsp.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
@@ -815,6 +812,9 @@
<ClInclude Include="curl\lib\setup-vms.h"> <ClInclude Include="curl\lib\setup-vms.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="curl\lib\share.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\sigpipe.h"> <ClInclude Include="curl\lib\sigpipe.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
@@ -836,6 +836,9 @@
<ClInclude Include="curl\lib\socks.h"> <ClInclude Include="curl\lib\socks.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="curl\lib\speedcheck.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\splay.h"> <ClInclude Include="curl\lib\splay.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
@@ -884,6 +887,9 @@
<ClInclude Include="curl\lib\vauth\vauth.h"> <ClInclude Include="curl\lib\vauth\vauth.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="curl\lib\vssh\curl_path.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\vssh\ssh.h"> <ClInclude Include="curl\lib\vssh\ssh.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
@@ -893,6 +899,9 @@
<ClInclude Include="curl\lib\vtls\mbedtls.h"> <ClInclude Include="curl\lib\vtls\mbedtls.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="curl\lib\vtls\mbedtls_threadlock.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\vtls\openssl.h"> <ClInclude Include="curl\lib\vtls\openssl.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
@@ -1049,6 +1058,9 @@
<ClInclude Include="curl\lib\curlx\base64.h"> <ClInclude Include="curl\lib\curlx\base64.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="curl\lib\curlx\curlx.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\curlx\dynbuf.h"> <ClInclude Include="curl\lib\curlx\dynbuf.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
@@ -1091,6 +1103,9 @@
<ClInclude Include="curl\lib\cf-ip-happy.h"> <ClInclude Include="curl\lib\cf-ip-happy.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="curl\lib\curl_mem_undef.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\curl_fopen.h"> <ClInclude Include="curl\lib\curl_fopen.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
@@ -1106,45 +1121,6 @@
<ClInclude Include="curl\lib\curlx\strerr.h"> <ClInclude Include="curl\lib\curlx\strerr.h">
<Filter>Header Files</Filter> <Filter>Header Files</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="curl\lib\curlx\snprintf.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\curlx\strcopy.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\vssh\vssh.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\curl_share.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\ratelimit.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\curlx\basename.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\curlx\strdup.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\cf-dns.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\dnscache.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\ftp-int.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\protocol.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\thrdpool.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="curl\lib\thrdqueue.h">
<Filter>Header Files</Filter>
</ClInclude>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ResourceCompile Include="curl\lib\libcurl.rc"> <ResourceCompile Include="curl\lib\libcurl.rc">
+1 -1
View File
@@ -9,7 +9,7 @@ if (USE_DISCORD_RPC AND (WIN32 OR CMAKE_SYSTEM MATCHES "Linux" OR APPLE))
set(WARNINGS_AS_ERRORS FALSE CACHE BOOL "When enabled, compiles with `-Werror` (on *nix platforms).") set(WARNINGS_AS_ERRORS FALSE CACHE BOOL "When enabled, compiles with `-Werror` (on *nix platforms).")
add_subdirectory(discord-rpc EXCLUDE_FROM_ALL) add_subdirectory(discord-rpc EXCLUDE_FROM_ALL)
target_include_directories(3rdparty_discordRPC SYSTEM INTERFACE discord-rpc/include) target_include_directories(3rdparty_discordRPC INTERFACE discord-rpc/include)
target_compile_definitions(3rdparty_discordRPC INTERFACE -DWITH_DISCORD_RPC) target_compile_definitions(3rdparty_discordRPC INTERFACE -DWITH_DISCORD_RPC)
target_link_libraries(3rdparty_discordRPC INTERFACE discord-rpc) target_link_libraries(3rdparty_discordRPC INTERFACE discord-rpc)
endif() endif()
+1 -1
View File
@@ -3,7 +3,7 @@
add_library(3rdparty_feralinteractive INTERFACE) add_library(3rdparty_feralinteractive INTERFACE)
if (CMAKE_SYSTEM MATCHES "Linux") if (CMAKE_SYSTEM MATCHES "Linux")
target_include_directories(3rdparty_feralinteractive SYSTEM INTERFACE feralinteractive/lib) target_include_directories(3rdparty_feralinteractive INTERFACE feralinteractive/lib)
target_compile_definitions(3rdparty_feralinteractive INTERFACE -DGAMEMODE_AVAILABLE) target_compile_definitions(3rdparty_feralinteractive INTERFACE -DGAMEMODE_AVAILABLE)
target_link_libraries(3rdparty_feralinteractive INTERFACE feralinteractive) target_link_libraries(3rdparty_feralinteractive INTERFACE feralinteractive)
endif() endif()
Vendored Submodule
+1
Submodule 3rdparty/flatbuffers added at 595bf0007a
+1 -1
View File
@@ -7,7 +7,7 @@ if(USE_SYSTEM_GLSLANG)
target_link_libraries(3rdparty_glslang INTERFACE glslang::SPIRV) target_link_libraries(3rdparty_glslang INTERFACE glslang::SPIRV)
get_target_property(SPIRV_INCLUDE_DIRS glslang::SPIRV INTERFACE_INCLUDE_DIRECTORIES) get_target_property(SPIRV_INCLUDE_DIRS glslang::SPIRV INTERFACE_INCLUDE_DIRECTORIES)
list(TRANSFORM SPIRV_INCLUDE_DIRS APPEND "/glslang") list(TRANSFORM SPIRV_INCLUDE_DIRS APPEND "/glslang")
target_include_directories(3rdparty_glslang SYSTEM INTERFACE ${SPIRV_INCLUDE_DIRS}) target_include_directories(3rdparty_glslang INTERFACE ${SPIRV_INCLUDE_DIRS})
else() else()
set(ENABLE_PCH OFF CACHE BOOL "Enables Precompiled header" FORCE) set(ENABLE_PCH OFF CACHE BOOL "Enables Precompiled header" FORCE)
set(BUILD_EXTERNAL OFF CACHE BOOL "Build external dependencies in /External" FORCE) set(BUILD_EXTERNAL OFF CACHE BOOL "Build external dependencies in /External" FORCE)
+1 -1
View File
@@ -4,7 +4,7 @@ if(USE_SYSTEM_HIDAPI)
pkg_check_modules(hidapi-hidraw REQUIRED IMPORTED_TARGET hidapi-hidraw) pkg_check_modules(hidapi-hidraw REQUIRED IMPORTED_TARGET hidapi-hidraw)
add_library(3rdparty_hidapi INTERFACE) add_library(3rdparty_hidapi INTERFACE)
target_link_libraries(3rdparty_hidapi INTERFACE PkgConfig::hidapi-hidraw) target_link_libraries(3rdparty_hidapi INTERFACE PkgConfig::hidapi-hidraw)
target_include_directories(3rdparty_hidapi SYSTEM INTERFACE PkgConfig::hidapi-hidraw) target_include_directories(3rdparty_hidapi INTERFACE PkgConfig::hidapi-hidraw)
else() else()
set(BUILD_SHARED_LIBS FALSE CACHE BOOL "Don't build shared libs") set(BUILD_SHARED_LIBS FALSE CACHE BOOL "Don't build shared libs")
set(HIDAPI_INSTALL_TARGETS FALSE CACHE BOOL "Don't install anything") set(HIDAPI_INSTALL_TARGETS FALSE CACHE BOOL "Don't install anything")
+2 -2
View File
@@ -6,14 +6,14 @@ if (NOT USE_SYSTEM_LIBPNG)
set(PNG_TESTS OFF CACHE BOOL "Build libpng tests") set(PNG_TESTS OFF CACHE BOOL "Build libpng tests")
set(SKIP_INSTALL_ALL ON) set(SKIP_INSTALL_ALL ON)
add_subdirectory(libpng EXCLUDE_FROM_ALL) add_subdirectory(libpng EXCLUDE_FROM_ALL)
target_include_directories(png_static SYSTEM INTERFACE "${libpng_BINARY_DIR}" "${libpng_SOURCE_DIR}") target_include_directories(png_static INTERFACE "${libpng_BINARY_DIR}" "${libpng_SOURCE_DIR}")
set(LIBPNG_TARGET png_static PARENT_SCOPE) set(LIBPNG_TARGET png_static PARENT_SCOPE)
else() else()
find_package(PNG REQUIRED) find_package(PNG REQUIRED)
add_library(3rdparty_system_libpng INTERFACE) add_library(3rdparty_system_libpng INTERFACE)
target_include_directories(3rdparty_system_libpng SYSTEM INTERFACE ${PNG_INCLUDE_DIR}) target_include_directories(3rdparty_system_libpng INTERFACE ${PNG_INCLUDE_DIR})
target_link_libraries(3rdparty_system_libpng INTERFACE ${PNG_LIBRARY}) target_link_libraries(3rdparty_system_libpng INTERFACE ${PNG_LIBRARY})
target_compile_definitions(3rdparty_system_libpng INTERFACE ${PNG_DEFINITIONS}) target_compile_definitions(3rdparty_system_libpng INTERFACE ${PNG_DEFINITIONS})
+7 -29
View File
@@ -23,7 +23,6 @@
<ClInclude Include="SDL\include\SDL3\SDL_clipboard.h" /> <ClInclude Include="SDL\include\SDL3\SDL_clipboard.h" />
<ClInclude Include="SDL\include\SDL3\SDL_copying.h" /> <ClInclude Include="SDL\include\SDL3\SDL_copying.h" />
<ClInclude Include="SDL\include\SDL3\SDL_cpuinfo.h" /> <ClInclude Include="SDL\include\SDL3\SDL_cpuinfo.h" />
<ClInclude Include="SDL\include\SDL3\SDL_dlopennote.h" />
<ClInclude Include="SDL\include\SDL3\SDL_egl.h" /> <ClInclude Include="SDL\include\SDL3\SDL_egl.h" />
<ClInclude Include="SDL\include\SDL3\SDL_endian.h" /> <ClInclude Include="SDL\include\SDL3\SDL_endian.h" />
<ClInclude Include="SDL\include\SDL3\SDL_error.h" /> <ClInclude Include="SDL\include\SDL3\SDL_error.h" />
@@ -103,7 +102,6 @@
<ClInclude Include="SDL\src\audio\wasapi\SDL_wasapi.h" /> <ClInclude Include="SDL\src\audio\wasapi\SDL_wasapi.h" />
<ClInclude Include="SDL\src\camera\SDL_camera_c.h" /> <ClInclude Include="SDL\src\camera\SDL_camera_c.h" />
<ClInclude Include="SDL\src\camera\SDL_syscamera.h" /> <ClInclude Include="SDL\src\camera\SDL_syscamera.h" />
<ClInclude Include="SDL\src\core\SDL_core_unsupported.h" />
<ClInclude Include="SDL\src\core\windows\SDL_directx.h" /> <ClInclude Include="SDL\src\core\windows\SDL_directx.h" />
<ClInclude Include="SDL\src\core\windows\SDL_gameinput.h" /> <ClInclude Include="SDL\src\core\windows\SDL_gameinput.h" />
<ClInclude Include="SDL\src\core\windows\SDL_hid.h" /> <ClInclude Include="SDL\src\core\windows\SDL_hid.h" />
@@ -132,8 +130,6 @@
<ClInclude Include="SDL\src\filesystem\SDL_sysfilesystem.h" /> <ClInclude Include="SDL\src\filesystem\SDL_sysfilesystem.h" />
<ClInclude Include="SDL\src\gpu\SDL_sysgpu.h" /> <ClInclude Include="SDL\src\gpu\SDL_sysgpu.h" />
<ClInclude Include="SDL\src\gpu\vulkan\SDL_gpu_vulkan_vkfuncs.h" /> <ClInclude Include="SDL\src\gpu\vulkan\SDL_gpu_vulkan_vkfuncs.h" />
<ClInclude Include="SDL\src\haptic\hidapi\SDL_hidapihaptic.h" />
<ClInclude Include="SDL\src\haptic\hidapi\SDL_hidapihaptic_c.h" />
<ClInclude Include="SDL\src\io\SDL_asyncio_c.h" /> <ClInclude Include="SDL\src\io\SDL_asyncio_c.h" />
<ClInclude Include="SDL\src\io\SDL_sysasyncio.h" /> <ClInclude Include="SDL\src\io\SDL_sysasyncio.h" />
<ClInclude Include="SDL\src\haptic\SDL_haptic_c.h" /> <ClInclude Include="SDL\src\haptic\SDL_haptic_c.h" />
@@ -144,11 +140,7 @@
<ClInclude Include="SDL\src\hidapi\SDL_hidapi_c.h" /> <ClInclude Include="SDL\src\hidapi\SDL_hidapi_c.h" />
<ClInclude Include="SDL\src\joystick\controller_type.h" /> <ClInclude Include="SDL\src\joystick\controller_type.h" />
<ClInclude Include="SDL\src\joystick\hidapi\SDL_hidapijoystick_c.h" /> <ClInclude Include="SDL\src\joystick\hidapi\SDL_hidapijoystick_c.h" />
<ClInclude Include="SDL\src\joystick\hidapi\SDL_hidapi_flydigi.h" />
<ClInclude Include="SDL\src\joystick\hidapi\SDL_hidapi_nintendo.h" />
<ClInclude Include="SDL\src\joystick\hidapi\SDL_hidapi_rumble.h" /> <ClInclude Include="SDL\src\joystick\hidapi\SDL_hidapi_rumble.h" />
<ClInclude Include="SDL\src\joystick\hidapi\SDL_hidapi_sinput.h" />
<ClInclude Include="SDL\src\joystick\hidapi\SDL_report_descriptor.h" />
<ClInclude Include="SDL\src\joystick\SDL_gamepad_c.h" /> <ClInclude Include="SDL\src\joystick\SDL_gamepad_c.h" />
<ClInclude Include="SDL\src\joystick\SDL_gamepad_db.h" /> <ClInclude Include="SDL\src\joystick\SDL_gamepad_db.h" />
<ClInclude Include="SDL\src\joystick\SDL_joystick_c.h" /> <ClInclude Include="SDL\src\joystick\SDL_joystick_c.h" />
@@ -164,7 +156,6 @@
<ClInclude Include="SDL\src\libm\math_private.h" /> <ClInclude Include="SDL\src\libm\math_private.h" />
<ClInclude Include="SDL\src\locale\SDL_syslocale.h" /> <ClInclude Include="SDL\src\locale\SDL_syslocale.h" />
<ClInclude Include="SDL\src\main\SDL_main_callbacks.h" /> <ClInclude Include="SDL\src\main\SDL_main_callbacks.h" />
<ClInclude Include="SDL\src\misc\SDL_libusb.h" />
<ClInclude Include="SDL\src\misc\SDL_sysurl.h" /> <ClInclude Include="SDL\src\misc\SDL_sysurl.h" />
<ClInclude Include="SDL\src\power\SDL_syspower.h" /> <ClInclude Include="SDL\src\power\SDL_syspower.h" />
<ClInclude Include="SDL\src\render\direct3d11\SDL_shaders_d3d11.h" /> <ClInclude Include="SDL\src\render\direct3d11\SDL_shaders_d3d11.h" />
@@ -184,6 +175,7 @@
<ClInclude Include="SDL\src\render\software\SDL_drawline.h" /> <ClInclude Include="SDL\src\render\software\SDL_drawline.h" />
<ClInclude Include="SDL\src\render\software\SDL_drawpoint.h" /> <ClInclude Include="SDL\src\render\software\SDL_drawpoint.h" />
<ClInclude Include="SDL\src\render\software\SDL_render_sw_c.h" /> <ClInclude Include="SDL\src\render\software\SDL_render_sw_c.h" />
<ClInclude Include="SDL\src\render\software\SDL_rotate.h" />
<ClInclude Include="SDL\src\render\software\SDL_triangle.h" /> <ClInclude Include="SDL\src\render\software\SDL_triangle.h" />
<ClInclude Include="SDL\src\render\vulkan\SDL_shaders_vulkan.h" /> <ClInclude Include="SDL\src\render\vulkan\SDL_shaders_vulkan.h" />
<ClInclude Include="SDL\src\SDL_assert_c.h" /> <ClInclude Include="SDL\src\SDL_assert_c.h" />
@@ -192,35 +184,20 @@
<ClCompile Include="SDL\src\camera\dummy\SDL_camera_dummy.c" /> <ClCompile Include="SDL\src\camera\dummy\SDL_camera_dummy.c" />
<ClCompile Include="SDL\src\camera\mediafoundation\SDL_camera_mediafoundation.c" /> <ClCompile Include="SDL\src\camera\mediafoundation\SDL_camera_mediafoundation.c" />
<ClCompile Include="SDL\src\camera\SDL_camera.c" /> <ClCompile Include="SDL\src\camera\SDL_camera.c" />
<ClCompile Include="SDL\src\core\windows\pch_cpp.cpp" />
<ClCompile Include="SDL\src\core\windows\SDL_gameinput.cpp" />
<ClCompile Include="SDL\src\dialog\SDL_dialog.c" /> <ClCompile Include="SDL\src\dialog\SDL_dialog.c" />
<ClCompile Include="SDL\src\dialog\SDL_dialog_utils.c" /> <ClCompile Include="SDL\src\dialog\SDL_dialog_utils.c" />
<ClCompile Include="SDL\src\filesystem\SDL_filesystem.c" /> <ClCompile Include="SDL\src\filesystem\SDL_filesystem.c" />
<ClCompile Include="SDL\src\filesystem\windows\SDL_sysfsops.c" /> <ClCompile Include="SDL\src\filesystem\windows\SDL_sysfsops.c" />
<ClCompile Include="SDL\src\haptic\hidapi\SDL_hidapihaptic.c" />
<ClCompile Include="SDL\src\haptic\hidapi\SDL_hidapihaptic_lg4ff.c" />
<ClCompile Include="SDL\src\io\windows\SDL_asyncio_windows_ioring.c" /> <ClCompile Include="SDL\src\io\windows\SDL_asyncio_windows_ioring.c" />
<ClCompile Include="SDL\src\gpu\SDL_gpu.c" /> <ClCompile Include="SDL\src\gpu\SDL_gpu.c" />
<ClCompile Include="SDL\src\gpu\d3d12\SDL_gpu_d3d12.c" /> <ClCompile Include="SDL\src\gpu\d3d12\SDL_gpu_d3d12.c" />
<ClCompile Include="SDL\src\gpu\vulkan\SDL_gpu_vulkan.c" /> <ClCompile Include="SDL\src\gpu\vulkan\SDL_gpu_vulkan.c" />
<ClCompile Include="SDL\src\io\generic\SDL_asyncio_generic.c" /> <ClCompile Include="SDL\src\io\generic\SDL_asyncio_generic.c" />
<ClCompile Include="SDL\src\io\SDL_asyncio.c" /> <ClCompile Include="SDL\src\io\SDL_asyncio.c" />
<ClCompile Include="SDL\src\joystick\gdk\SDL_gameinputjoystick.cpp" />
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_8bitdo.c" />
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_flydigi.c" />
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_gip.c" />
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_lg4ff.c" />
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_sinput.c" />
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_steam_triton.c" />
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_switch2.c" />
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_zuiki.c" />
<ClCompile Include="SDL\src\joystick\hidapi\SDL_report_descriptor.c" />
<ClCompile Include="SDL\src\main\generic\SDL_sysmain_callbacks.c" /> <ClCompile Include="SDL\src\main\generic\SDL_sysmain_callbacks.c" />
<ClCompile Include="SDL\src\main\SDL_main_callbacks.c" /> <ClCompile Include="SDL\src\main\SDL_main_callbacks.c" />
<ClCompile Include="SDL\src\main\SDL_runapp.c" /> <ClCompile Include="SDL\src\main\SDL_runapp.c" />
<ClCompile Include="SDL\src\main\windows\SDL_sysmain_runapp.c" /> <ClCompile Include="SDL\src\main\windows\SDL_sysmain_runapp.c" />
<ClCompile Include="SDL\src\misc\SDL_libusb.c" />
<ClCompile Include="SDL\src\render\vulkan\SDL_render_vulkan.c" /> <ClCompile Include="SDL\src\render\vulkan\SDL_render_vulkan.c" />
<ClCompile Include="SDL\src\render\vulkan\SDL_shaders_vulkan.c" /> <ClCompile Include="SDL\src\render\vulkan\SDL_shaders_vulkan.c" />
<ClCompile Include="SDL\src\SDL_guid.c" /> <ClCompile Include="SDL\src\SDL_guid.c" />
@@ -264,7 +241,6 @@
<ClInclude Include="SDL\src\video\khronos\vulkan\vulkan_xcb.h" /> <ClInclude Include="SDL\src\video\khronos\vulkan\vulkan_xcb.h" />
<ClInclude Include="SDL\src\video\khronos\vulkan\vulkan_xlib.h" /> <ClInclude Include="SDL\src\video\khronos\vulkan\vulkan_xlib.h" />
<ClInclude Include="SDL\src\video\khronos\vulkan\vulkan_xlib_xrandr.h" /> <ClInclude Include="SDL\src\video\khronos\vulkan\vulkan_xlib_xrandr.h" />
<ClInclude Include="SDL\src\video\miniz.h" />
<ClInclude Include="SDL\src\video\offscreen\SDL_offscreenevents_c.h" /> <ClInclude Include="SDL\src\video\offscreen\SDL_offscreenevents_c.h" />
<ClInclude Include="SDL\src\video\offscreen\SDL_offscreenframebuffer_c.h" /> <ClInclude Include="SDL\src\video\offscreen\SDL_offscreenframebuffer_c.h" />
<ClInclude Include="SDL\src\video\offscreen\SDL_offscreenopengles.h" /> <ClInclude Include="SDL\src\video\offscreen\SDL_offscreenopengles.h" />
@@ -280,14 +256,13 @@
<ClInclude Include="SDL\src\video\SDL_pixels_c.h" /> <ClInclude Include="SDL\src\video\SDL_pixels_c.h" />
<ClInclude Include="SDL\src\video\SDL_rect_c.h" /> <ClInclude Include="SDL\src\video\SDL_rect_c.h" />
<ClInclude Include="SDL\src\video\SDL_RLEaccel_c.h" /> <ClInclude Include="SDL\src\video\SDL_RLEaccel_c.h" />
<ClInclude Include="SDL\src\video\SDL_rotate.h" />
<ClInclude Include="SDL\src\video\SDL_stb_c.h" /> <ClInclude Include="SDL\src\video\SDL_stb_c.h" />
<ClInclude Include="SDL\src\video\SDL_surface_c.h" /> <ClInclude Include="SDL\src\video\SDL_surface_c.h" />
<ClInclude Include="SDL\src\video\SDL_sysvideo.h" /> <ClInclude Include="SDL\src\video\SDL_sysvideo.h" />
<ClInclude Include="SDL\src\video\SDL_video_unsupported.h" />
<ClInclude Include="SDL\src\video\SDL_vulkan_internal.h" /> <ClInclude Include="SDL\src\video\SDL_vulkan_internal.h" />
<ClInclude Include="SDL\src\video\SDL_yuv_c.h" /> <ClInclude Include="SDL\src\video\SDL_yuv_c.h" />
<ClInclude Include="SDL\src\video\windows\SDL_msctf.h" /> <ClInclude Include="SDL\src\video\windows\SDL_msctf.h" />
<ClInclude Include="SDL\src\video\windows\SDL_surface_utils.h" />
<ClInclude Include="SDL\src\video\windows\SDL_windowsclipboard.h" /> <ClInclude Include="SDL\src\video\windows\SDL_windowsclipboard.h" />
<ClInclude Include="SDL\src\video\windows\SDL_windowsevents.h" /> <ClInclude Include="SDL\src\video\windows\SDL_windowsevents.h" />
<ClInclude Include="SDL\src\video\windows\SDL_windowsframebuffer.h" /> <ClInclude Include="SDL\src\video\windows\SDL_windowsframebuffer.h" />
@@ -328,6 +303,7 @@
<ClCompile Include="SDL\src\audio\SDL_wave.c" /> <ClCompile Include="SDL\src\audio\SDL_wave.c" />
<ClCompile Include="SDL\src\audio\wasapi\SDL_wasapi.c" /> <ClCompile Include="SDL\src\audio\wasapi\SDL_wasapi.c" />
<ClCompile Include="SDL\src\core\SDL_core_unsupported.c" /> <ClCompile Include="SDL\src\core\SDL_core_unsupported.c" />
<ClCompile Include="SDL\src\core\windows\SDL_gameinput.c" />
<ClCompile Include="SDL\src\core\windows\SDL_hid.c" /> <ClCompile Include="SDL\src\core\windows\SDL_hid.c" />
<ClCompile Include="SDL\src\core\windows\SDL_immdevice.c" /> <ClCompile Include="SDL\src\core\windows\SDL_immdevice.c" />
<ClCompile Include="SDL\src\core\windows\SDL_windows.c" /> <ClCompile Include="SDL\src\core\windows\SDL_windows.c" />
@@ -357,6 +333,7 @@
<ClCompile Include="SDL\src\hidapi\SDL_hidapi.c" /> <ClCompile Include="SDL\src\hidapi\SDL_hidapi.c" />
<ClCompile Include="SDL\src\joystick\controller_type.c" /> <ClCompile Include="SDL\src\joystick\controller_type.c" />
<ClCompile Include="SDL\src\joystick\dummy\SDL_sysjoystick.c" /> <ClCompile Include="SDL\src\joystick\dummy\SDL_sysjoystick.c" />
<ClCompile Include="SDL\src\joystick\gdk\SDL_gameinputjoystick.c" />
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapijoystick.c" /> <ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapijoystick.c" />
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_combined.c" /> <ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_combined.c" />
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_gamecube.c" /> <ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_gamecube.c" />
@@ -416,6 +393,7 @@
<ClCompile Include="SDL\src\render\software\SDL_drawline.c" /> <ClCompile Include="SDL\src\render\software\SDL_drawline.c" />
<ClCompile Include="SDL\src\render\software\SDL_drawpoint.c" /> <ClCompile Include="SDL\src\render\software\SDL_drawpoint.c" />
<ClCompile Include="SDL\src\render\software\SDL_render_sw.c" /> <ClCompile Include="SDL\src\render\software\SDL_render_sw.c" />
<ClCompile Include="SDL\src\render\software\SDL_rotate.c" />
<ClCompile Include="SDL\src\render\software\SDL_triangle.c" /> <ClCompile Include="SDL\src\render\software\SDL_triangle.c" />
<ClCompile Include="SDL\src\SDL.c" /> <ClCompile Include="SDL\src\SDL.c" />
<ClCompile Include="SDL\src\SDL_assert.c" /> <ClCompile Include="SDL\src\SDL_assert.c" />
@@ -486,7 +464,6 @@
<ClCompile Include="SDL\src\video\SDL_pixels.c" /> <ClCompile Include="SDL\src\video\SDL_pixels.c" />
<ClCompile Include="SDL\src\video\SDL_rect.c" /> <ClCompile Include="SDL\src\video\SDL_rect.c" />
<ClCompile Include="SDL\src\video\SDL_RLEaccel.c" /> <ClCompile Include="SDL\src\video\SDL_RLEaccel.c" />
<ClCompile Include="SDL\src\video\SDL_rotate.c" />
<ClCompile Include="SDL\src\video\SDL_stb.c" /> <ClCompile Include="SDL\src\video\SDL_stb.c" />
<ClCompile Include="SDL\src\video\SDL_stretch.c" /> <ClCompile Include="SDL\src\video\SDL_stretch.c" />
<ClCompile Include="SDL\src\video\SDL_surface.c" /> <ClCompile Include="SDL\src\video\SDL_surface.c" />
@@ -494,11 +471,12 @@
<ClCompile Include="SDL\src\video\SDL_video_unsupported.c" /> <ClCompile Include="SDL\src\video\SDL_video_unsupported.c" />
<ClCompile Include="SDL\src\video\SDL_vulkan_utils.c" /> <ClCompile Include="SDL\src\video\SDL_vulkan_utils.c" />
<ClCompile Include="SDL\src\video\SDL_yuv.c" /> <ClCompile Include="SDL\src\video\SDL_yuv.c" />
<ClCompile Include="SDL\src\video\windows\SDL_surface_utils.c" />
<ClCompile Include="SDL\src\video\windows\SDL_windowsclipboard.c" /> <ClCompile Include="SDL\src\video\windows\SDL_windowsclipboard.c" />
<ClCompile Include="SDL\src\video\windows\SDL_windowsevents.c" /> <ClCompile Include="SDL\src\video\windows\SDL_windowsevents.c" />
<ClCompile Include="SDL\src\video\windows\SDL_windowsframebuffer.c" /> <ClCompile Include="SDL\src\video\windows\SDL_windowsframebuffer.c" />
<ClCompile Include="SDL\src\video\windows\SDL_windowsgameinput.cpp" />
<ClCompile Include="SDL\src\video\windows\SDL_windowskeyboard.c" /> <ClCompile Include="SDL\src\video\windows\SDL_windowskeyboard.c" />
<ClCompile Include="SDL\src\video\windows\SDL_windowsgameinput.c" />
<ClCompile Include="SDL\src\video\windows\SDL_windowsmessagebox.c" /> <ClCompile Include="SDL\src\video\windows\SDL_windowsmessagebox.c" />
<ClCompile Include="SDL\src\video\windows\SDL_windowsmodes.c" /> <ClCompile Include="SDL\src\video\windows\SDL_windowsmodes.c" />
<ClCompile Include="SDL\src\video\windows\SDL_windowsmouse.c" /> <ClCompile Include="SDL\src\video\windows\SDL_windowsmouse.c" />
+30 -117
View File
@@ -214,9 +214,6 @@
<Filter Include="io\windows"> <Filter Include="io\windows">
<UniqueIdentifier>{000028b2ea36d7190d13777a4dc70000}</UniqueIdentifier> <UniqueIdentifier>{000028b2ea36d7190d13777a4dc70000}</UniqueIdentifier>
</Filter> </Filter>
<Filter Include="haptic\hidapi">
<UniqueIdentifier>{695ffc61-5497-4227-b415-15e9bdd5b6bf}</UniqueIdentifier>
</Filter>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClInclude Include="SDL\include\SDL3\SDL_begin_code.h"> <ClInclude Include="SDL\include\SDL3\SDL_begin_code.h">
@@ -702,6 +699,9 @@
<ClInclude Include="SDL\src\video\yuv2rgb\yuv_rgb_std_func.h"> <ClInclude Include="SDL\src\video\yuv2rgb\yuv_rgb_std_func.h">
<Filter>video\yuv2rgb</Filter> <Filter>video\yuv2rgb</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="SDL\src\video\windows\SDL_surface_utils.h">
<Filter>video\windows</Filter>
</ClInclude>
<ClInclude Include="SDL\src\video\windows\SDL_windowsclipboard.h"> <ClInclude Include="SDL\src\video\windows\SDL_windowsclipboard.h">
<Filter>video\windows</Filter> <Filter>video\windows</Filter>
</ClInclude> </ClInclude>
@@ -831,6 +831,9 @@
<ClInclude Include="SDL\src\render\software\SDL_render_sw_c.h"> <ClInclude Include="SDL\src\render\software\SDL_render_sw_c.h">
<Filter>render\software</Filter> <Filter>render\software</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="SDL\src\render\software\SDL_rotate.h">
<Filter>render\software</Filter>
</ClInclude>
<ClInclude Include="SDL\src\render\software\SDL_triangle.h"> <ClInclude Include="SDL\src\render\software\SDL_triangle.h">
<Filter>render\software</Filter> <Filter>render\software</Filter>
</ClInclude> </ClInclude>
@@ -908,6 +911,12 @@
<ClInclude Include="SDL\src\hidapi\SDL_hidapi_c.h" /> <ClInclude Include="SDL\src\hidapi\SDL_hidapi_c.h" />
<ClInclude Include="SDL\src\thread\generic\SDL_sysrwlock_c.h" /> <ClInclude Include="SDL\src\thread\generic\SDL_sysrwlock_c.h" />
<ClInclude Include="SDL\src\thread\generic\SDL_sysrwlock_c.h" /> <ClInclude Include="SDL\src\thread\generic\SDL_sysrwlock_c.h" />
<ClInclude Include="SDL\src\video\yuv2rgb\yuv_rgb_common.h" />
<ClInclude Include="SDL\src\video\yuv2rgb\yuv_rgb_internal.h" />
<ClInclude Include="SDL\src\video\yuv2rgb\yuv_rgb_lsx.h" />
<ClInclude Include="SDL\src\video\yuv2rgb\yuv_rgb_lsx_func.h" />
<ClInclude Include="SDL\src\video\yuv2rgb\yuv_rgb_sse.h" />
<ClInclude Include="SDL\src\video\yuv2rgb\yuv_rgb_std.h" />
<ClInclude Include="SDL\src\render\vulkan\SDL_shaders_vulkan.h"> <ClInclude Include="SDL\src\render\vulkan\SDL_shaders_vulkan.h">
<Filter>render\vulkan</Filter> <Filter>render\vulkan</Filter>
</ClInclude> </ClInclude>
@@ -941,60 +950,6 @@
<ClInclude Include="SDL\include\SDL3\SDL_storage.h" /> <ClInclude Include="SDL\include\SDL3\SDL_storage.h" />
<ClInclude Include="SDL\include\SDL3\SDL_time.h" /> <ClInclude Include="SDL\include\SDL3\SDL_time.h" />
<ClInclude Include="SDL\src\events\SDL_categories_c.h" /> <ClInclude Include="SDL\src\events\SDL_categories_c.h" />
<ClInclude Include="SDL\src\video\yuv2rgb\yuv_rgb_std.h">
<Filter>video\yuv2rgb</Filter>
</ClInclude>
<ClInclude Include="SDL\src\video\yuv2rgb\yuv_rgb_common.h">
<Filter>video\yuv2rgb</Filter>
</ClInclude>
<ClInclude Include="SDL\src\video\yuv2rgb\yuv_rgb_internal.h">
<Filter>video\yuv2rgb</Filter>
</ClInclude>
<ClInclude Include="SDL\src\video\yuv2rgb\yuv_rgb_lsx.h">
<Filter>video\yuv2rgb</Filter>
</ClInclude>
<ClInclude Include="SDL\src\video\yuv2rgb\yuv_rgb_lsx_func.h">
<Filter>video\yuv2rgb</Filter>
</ClInclude>
<ClInclude Include="SDL\src\video\yuv2rgb\yuv_rgb_sse.h">
<Filter>video\yuv2rgb</Filter>
</ClInclude>
<ClInclude Include="SDL\src\video\miniz.h">
<Filter>video</Filter>
</ClInclude>
<ClInclude Include="SDL\src\video\SDL_rotate.h">
<Filter>video</Filter>
</ClInclude>
<ClInclude Include="SDL\src\video\SDL_video_unsupported.h">
<Filter>video</Filter>
</ClInclude>
<ClInclude Include="SDL\src\misc\SDL_libusb.h">
<Filter>misc</Filter>
</ClInclude>
<ClInclude Include="SDL\src\haptic\hidapi\SDL_hidapihaptic.h">
<Filter>haptic\hidapi</Filter>
</ClInclude>
<ClInclude Include="SDL\src\haptic\hidapi\SDL_hidapihaptic_c.h">
<Filter>haptic\hidapi</Filter>
</ClInclude>
<ClInclude Include="SDL\src\core\SDL_core_unsupported.h">
<Filter>core</Filter>
</ClInclude>
<ClInclude Include="SDL\src\joystick\hidapi\SDL_hidapi_flydigi.h">
<Filter>joystick\hidapi</Filter>
</ClInclude>
<ClInclude Include="SDL\src\joystick\hidapi\SDL_hidapi_nintendo.h">
<Filter>joystick\hidapi</Filter>
</ClInclude>
<ClInclude Include="SDL\src\joystick\hidapi\SDL_hidapi_sinput.h">
<Filter>joystick\hidapi</Filter>
</ClInclude>
<ClInclude Include="SDL\src\joystick\hidapi\SDL_report_descriptor.h">
<Filter>joystick\hidapi</Filter>
</ClInclude>
<ClInclude Include="SDL\include\SDL3\SDL_dlopennote.h">
<Filter>API Headers</Filter>
</ClInclude>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClCompile Include="SDL\src\audio\wasapi\SDL_wasapi.c" /> <ClCompile Include="SDL\src\audio\wasapi\SDL_wasapi.c" />
@@ -1082,6 +1037,9 @@
<ClCompile Include="SDL\src\core\SDL_core_unsupported.c"> <ClCompile Include="SDL\src\core\SDL_core_unsupported.c">
<Filter>core</Filter> <Filter>core</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="SDL\src\core\windows\SDL_gameinput.c">
<Filter>core\windows</Filter>
</ClCompile>
<ClCompile Include="SDL\src\core\windows\SDL_hid.c"> <ClCompile Include="SDL\src\core\windows\SDL_hid.c">
<Filter>core\windows</Filter> <Filter>core\windows</Filter>
</ClCompile> </ClCompile>
@@ -1208,6 +1166,9 @@
<ClCompile Include="SDL\src\joystick\dummy\SDL_sysjoystick.c"> <ClCompile Include="SDL\src\joystick\dummy\SDL_sysjoystick.c">
<Filter>joystick\dummy</Filter> <Filter>joystick\dummy</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="SDL\src\joystick\gdk\SDL_gameinputjoystick.c">
<Filter>joystick\gdk</Filter>
</ClCompile>
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_combined.c"> <ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_combined.c">
<Filter>joystick\hidapi</Filter> <Filter>joystick\hidapi</Filter>
</ClCompile> </ClCompile>
@@ -1367,6 +1328,9 @@
<ClCompile Include="SDL\src\video\dummy\SDL_nullvideo.c"> <ClCompile Include="SDL\src\video\dummy\SDL_nullvideo.c">
<Filter>video\dummy</Filter> <Filter>video\dummy</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="SDL\src\video\windows\SDL_surface_utils.c">
<Filter>video\windows</Filter>
</ClCompile>
<ClCompile Include="SDL\src\video\windows\SDL_windowsclipboard.c"> <ClCompile Include="SDL\src\video\windows\SDL_windowsclipboard.c">
<Filter>video\windows</Filter> <Filter>video\windows</Filter>
</ClCompile> </ClCompile>
@@ -1379,6 +1343,9 @@
<ClCompile Include="SDL\src\video\windows\SDL_windowskeyboard.c"> <ClCompile Include="SDL\src\video\windows\SDL_windowskeyboard.c">
<Filter>video\windows</Filter> <Filter>video\windows</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="SDL\src\video\windows\SDL_windowsgameinput.c">
<Filter>video\windows</Filter>
</ClCompile>
<ClCompile Include="SDL\src\video\windows\SDL_windowsmessagebox.c"> <ClCompile Include="SDL\src\video\windows\SDL_windowsmessagebox.c">
<Filter>video\windows</Filter> <Filter>video\windows</Filter>
</ClCompile> </ClCompile>
@@ -1541,6 +1508,9 @@
<ClCompile Include="SDL\src\render\software\SDL_render_sw.c"> <ClCompile Include="SDL\src\render\software\SDL_render_sw.c">
<Filter>render\software</Filter> <Filter>render\software</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="SDL\src\render\software\SDL_rotate.c">
<Filter>render\software</Filter>
</ClCompile>
<ClCompile Include="SDL\src\render\software\SDL_triangle.c"> <ClCompile Include="SDL\src\render\software\SDL_triangle.c">
<Filter>render\software</Filter> <Filter>render\software</Filter>
</ClCompile> </ClCompile>
@@ -1565,6 +1535,9 @@
</ClCompile> </ClCompile>
<ClCompile Include="SDL\src\thread\generic\SDL_sysrwlock.c" /> <ClCompile Include="SDL\src\thread\generic\SDL_sysrwlock.c" />
<ClCompile Include="SDL\src\thread\generic\SDL_sysrwlock.c" /> <ClCompile Include="SDL\src\thread\generic\SDL_sysrwlock.c" />
<ClCompile Include="SDL\src\video\yuv2rgb\yuv_rgb_lsx.c" />
<ClCompile Include="SDL\src\video\yuv2rgb\yuv_rgb_sse.c" />
<ClCompile Include="SDL\src\video\yuv2rgb\yuv_rgb_std.c" />
<ClCompile Include="SDL\src\render\vulkan\SDL_render_vulkan.c"> <ClCompile Include="SDL\src\render\vulkan\SDL_render_vulkan.c">
<Filter>render\vulkan</Filter> <Filter>render\vulkan</Filter>
</ClCompile> </ClCompile>
@@ -1606,66 +1579,6 @@
<ClCompile Include="SDL\src\storage\generic\SDL_genericstorage.c" /> <ClCompile Include="SDL\src\storage\generic\SDL_genericstorage.c" />
<ClCompile Include="SDL\src\storage\steam\SDL_steamstorage.c" /> <ClCompile Include="SDL\src\storage\steam\SDL_steamstorage.c" />
<ClCompile Include="SDL\src\storage\SDL_storage.c" /> <ClCompile Include="SDL\src\storage\SDL_storage.c" />
<ClCompile Include="SDL\src\video\windows\SDL_windowsgameinput.cpp">
<Filter>video\windows</Filter>
</ClCompile>
<ClCompile Include="SDL\src\video\yuv2rgb\yuv_rgb_lsx.c">
<Filter>video\yuv2rgb</Filter>
</ClCompile>
<ClCompile Include="SDL\src\video\yuv2rgb\yuv_rgb_sse.c">
<Filter>video\yuv2rgb</Filter>
</ClCompile>
<ClCompile Include="SDL\src\video\yuv2rgb\yuv_rgb_std.c">
<Filter>video\yuv2rgb</Filter>
</ClCompile>
<ClCompile Include="SDL\src\video\SDL_rotate.c">
<Filter>video</Filter>
</ClCompile>
<ClCompile Include="SDL\src\misc\SDL_libusb.c">
<Filter>misc</Filter>
</ClCompile>
<ClCompile Include="SDL\src\haptic\hidapi\SDL_hidapihaptic.c">
<Filter>haptic\hidapi</Filter>
</ClCompile>
<ClCompile Include="SDL\src\haptic\hidapi\SDL_hidapihaptic_lg4ff.c">
<Filter>haptic\hidapi</Filter>
</ClCompile>
<ClCompile Include="SDL\src\core\windows\pch_cpp.cpp">
<Filter>core\windows</Filter>
</ClCompile>
<ClCompile Include="SDL\src\core\windows\SDL_gameinput.cpp">
<Filter>core\windows</Filter>
</ClCompile>
<ClCompile Include="SDL\src\joystick\gdk\SDL_gameinputjoystick.cpp">
<Filter>joystick\gdk</Filter>
</ClCompile>
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_8bitdo.c">
<Filter>joystick\hidapi</Filter>
</ClCompile>
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_flydigi.c">
<Filter>joystick\hidapi</Filter>
</ClCompile>
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_gip.c">
<Filter>joystick\hidapi</Filter>
</ClCompile>
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_lg4ff.c">
<Filter>joystick\hidapi</Filter>
</ClCompile>
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_sinput.c">
<Filter>joystick\hidapi</Filter>
</ClCompile>
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_steam_triton.c">
<Filter>joystick\hidapi</Filter>
</ClCompile>
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_switch2.c">
<Filter>joystick\hidapi</Filter>
</ClCompile>
<ClCompile Include="SDL\src\joystick\hidapi\SDL_hidapi_zuiki.c">
<Filter>joystick\hidapi</Filter>
</ClCompile>
<ClCompile Include="SDL\src\joystick\hidapi\SDL_report_descriptor.c">
<Filter>joystick\hidapi</Filter>
</ClCompile>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ResourceCompile Include="SDL\src\core\windows\version.rc" /> <ResourceCompile Include="SDL\src\core\windows\version.rc" />
-5
View File
@@ -54,9 +54,6 @@
<ClCompile Condition="'$(Configuration)'=='Release'"> <ClCompile Condition="'$(Configuration)'=='Release'">
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions> <PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ClCompile> </ClCompile>
<ClCompile Condition="'$(EnableLibUsbWindowsHotplug)' == 'true'">
<PreprocessorDefinitions>LIBUSB_WINDOWS_HOTPLUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ClCompile>
<Lib> <Lib>
<OutputFile>$(OutDir)libusb-1.0.lib</OutputFile> <OutputFile>$(OutDir)libusb-1.0.lib</OutputFile>
</Lib> </Lib>
@@ -67,7 +64,6 @@
<ClCompile Include="libusb\libusb\hotplug.c" /> <ClCompile Include="libusb\libusb\hotplug.c" />
<ClCompile Include="libusb\libusb\io.c" /> <ClCompile Include="libusb\libusb\io.c" />
<ClCompile Include="libusb\libusb\os\events_windows.c" /> <ClCompile Include="libusb\libusb\os\events_windows.c" />
<ClCompile Condition="'$(EnableLibUsbWindowsHotplug)' == 'true'" Include="libusb\libusb\os\windows_hotplug.c" />
<ClCompile Include="libusb\libusb\strerror.c" /> <ClCompile Include="libusb\libusb\strerror.c" />
<ClCompile Include="libusb\libusb\sync.c" /> <ClCompile Include="libusb\libusb\sync.c" />
<ClCompile Include="libusb\libusb\os\threads_windows.c" /> <ClCompile Include="libusb\libusb\os\threads_windows.c" />
@@ -76,7 +72,6 @@
<ClCompile Include="libusb\libusb\os\windows_winusb.c" /> <ClCompile Include="libusb\libusb\os\windows_winusb.c" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClInclude Condition="'$(EnableLibUsbWindowsHotplug)' == 'true'" Include="libusb\libusb\os\windows_hotplug.h" />
<ClInclude Include="libusb\msvc\config.h" /> <ClInclude Include="libusb\msvc\config.h" />
<ClInclude Include="libusb\libusb\hotplug.h" /> <ClInclude Include="libusb\libusb\hotplug.h" />
<ClInclude Include="libusb\libusb\libusb.h" /> <ClInclude Include="libusb\libusb\libusb.h" />
+1 -1
View File
@@ -107,7 +107,7 @@ if(WITH_LLVM)
add_library(3rdparty_llvm INTERFACE) add_library(3rdparty_llvm INTERFACE)
target_link_libraries(3rdparty_llvm INTERFACE ${LLVM_LIBS}) target_link_libraries(3rdparty_llvm INTERFACE ${LLVM_LIBS})
target_include_directories(3rdparty_llvm SYSTEM INTERFACE ${LLVM_INCLUDE_DIRS}) target_include_directories(3rdparty_llvm INTERFACE ${LLVM_INCLUDE_DIRS})
separate_arguments(LLVM_DEFINITIONS_LIST NATIVE_COMMAND ${LLVM_DEFINITIONS}) separate_arguments(LLVM_DEFINITIONS_LIST NATIVE_COMMAND ${LLVM_DEFINITIONS})
target_compile_definitions(3rdparty_llvm INTERFACE ${LLVM_DEFINITIONS_LIST} LLVM_AVAILABLE) target_compile_definitions(3rdparty_llvm INTERFACE ${LLVM_DEFINITIONS_LIST} LLVM_AVAILABLE)
+3 -3
View File
@@ -3,9 +3,9 @@ if(USE_SYSTEM_MINIUPNPC)
pkg_check_modules(MiniUPnPc REQUIRED IMPORTED_TARGET miniupnpc>=2.3.3) pkg_check_modules(MiniUPnPc REQUIRED IMPORTED_TARGET miniupnpc>=2.3.3)
add_library(3rdparty_miniupnpc INTERFACE) add_library(3rdparty_miniupnpc INTERFACE)
target_link_libraries(3rdparty_miniupnpc INTERFACE PkgConfig::MiniUPnPc) target_link_libraries(3rdparty_miniupnpc INTERFACE PkgConfig::MiniUPnPc)
target_include_directories(3rdparty_miniupnpc SYSTEM INTERFACE PkgConfig::MiniUPnPc) target_include_directories(3rdparty_miniupnpc INTERFACE PkgConfig::MiniUPnPc)
list(TRANSFORM MiniUPnPc_INCLUDE_DIRS APPEND "/miniupnpc") list(TRANSFORM MiniUPnPc_INCLUDE_DIRS APPEND "/miniupnpc")
target_include_directories(3rdparty_miniupnpc SYSTEM INTERFACE ${MiniUPnPc_INCLUDE_DIRS}) target_include_directories(3rdparty_miniupnpc INTERFACE ${MiniUPnPc_INCLUDE_DIRS})
else() else()
option (UPNPC_BUILD_STATIC "Build static library" TRUE) option (UPNPC_BUILD_STATIC "Build static library" TRUE)
option (UPNPC_BUILD_SHARED "Build shared library" FALSE) option (UPNPC_BUILD_SHARED "Build shared library" FALSE)
@@ -17,5 +17,5 @@ else()
add_subdirectory(miniupnp/miniupnpc EXCLUDE_FROM_ALL) add_subdirectory(miniupnp/miniupnpc EXCLUDE_FROM_ALL)
add_library(3rdparty_miniupnpc INTERFACE) add_library(3rdparty_miniupnpc INTERFACE)
target_link_libraries(3rdparty_miniupnpc INTERFACE libminiupnpc-static) target_link_libraries(3rdparty_miniupnpc INTERFACE libminiupnpc-static)
target_include_directories(3rdparty_miniupnpc SYSTEM INTERFACE libminiupnpc-static) target_include_directories(3rdparty_miniupnpc INTERFACE libminiupnpc-static)
endif() endif()
-29
View File
@@ -1,29 +0,0 @@
add_library(3rdparty_protobuf INTERFACE)
if (USE_SYSTEM_PROTOBUF)
pkg_check_modules(PROTOBUF REQUIRED IMPORTED_TARGET protobuf>=33.0.0)
target_link_libraries(3rdparty_protobuf INTERFACE PkgConfig::PROTOBUF)
set(PROTOBUF_DIR "${CMAKE_SOURCE_DIR}/rpcs3/Emu/NP/generated")
execute_process(COMMAND protoc --cpp_out=${PROTOBUF_DIR} --proto_path=${PROTOBUF_DIR} np2_structs.proto RESULT_VARIABLE PROTOBUF_CMD_ERROR)
if(PROTOBUF_CMD_ERROR AND NOT PROTOBUF_CMD_ERROR EQUAL 0)
message(FATAL_ERROR "protoc failed to regenerate protobuf files.")
endif()
else()
option(protobuf_INSTALL "Install protobuf binaries and files" OFF)
option(protobuf_BUILD_TESTS "Build tests" OFF)
option(protobuf_BUILD_CONFORMANCE "Build conformance tests" OFF)
option(protobuf_BUILD_EXAMPLES "Build examples" OFF)
option(protobuf_BUILD_PROTOBUF_BINARIES "Build protobuf libraries and protoc compiler" ON)
option(protobuf_BUILD_PROTOC_BINARIES "Build libprotoc and protoc compiler" OFF)
option(protobuf_BUILD_LIBPROTOC "Build libprotoc" OFF)
option(protobuf_BUILD_LIBUPB "Build libupb" OFF)
option(protobuf_ALLOW_CCACHE "Adjust build flags to allow for ccache support." ON)
option(protobuf_DISABLE_RTTI "Remove runtime type information in the binaries" OFF)
option(protobuf_FORCE_FETCH_DEPENDENCIES "Force all dependencies to be downloaded from GitHub. Local installations will be ignored." OFF)
option(protobuf_LOCAL_DEPENDENCIES_ONLY "Prevent downloading any dependencies from GitHub. If this option is set, the dependency must be available locally as an installed package." OFF)
option(protobuf_BUILD_SHARED_LIBS "Build Shared Libraries" OFF)
option(protobuf_MSVC_STATIC_RUNTIME "Link static runtime libraries" OFF)
add_subdirectory(protobuf EXCLUDE_FROM_ALL)
target_include_directories(3rdparty_protobuf SYSTEM INTERFACE protobuf/src)
target_link_libraries(3rdparty_protobuf INTERFACE libprotobuf)
endif()
-111
View File
@@ -1,111 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup Label="Globals">
<ProjectGuid>{7B3B4C5D-6E7F-8A9B-0C1D-2E3F4A5B6C7D}</ProjectGuid>
<Keyword>MakeFileProj</Keyword>
</PropertyGroup>
<Import Project="$(SolutionDir)\buildfiles\msvc\common_default.props" />
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<Import Project="$(SolutionDir)\buildfiles\msvc\common_default_macros.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>Makefile</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>Makefile</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<PropertyGroup>
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
</PropertyGroup>
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros">
<CmakeReleaseCLI>call vsdevcmd.bat -arch=amd64
if not exist "$(SolutionDir)build\tmp\protobuf_build-$(Configuration)-$(Platform)" mkdir "$(SolutionDir)build\tmp\protobuf_build-$(Configuration)-$(Platform)"
cd "$(SolutionDir)build\tmp\protobuf_build-$(Configuration)-$(Platform)"
cmake -G Ninja -DCMAKE_CXX_COMPILER="cl.exe" -DCMAKE_C_COMPILER="cl.exe" -DCMAKE_CXX_STANDARD=20 -DCMAKE_BUILD_TYPE="Release" -DCMAKE_INSTALL_PREFIX="$(SolutionDir)build\lib\$(Configuration)-$(Platform)\protobuf_build" -DCMAKE_SYSTEM_VERSION=10.0 -DCMAKE_VS_WINDOWS_TARGET_PLATFORM_VERSION=$(WindowsTargetPlatformVersion) -DCMAKE_MSVC_RUNTIME_LIBRARY=MultiThreaded -Dprotobuf_INSTALL=ON -Dprotobuf_BUILD_TESTS=OFF -Dprotobuf_BUILD_CONFORMANCE=OFF -Dprotobuf_BUILD_EXAMPLES=OFF -Dprotobuf_BUILD_PROTOBUF_BINARIES=ON -Dprotobuf_BUILD_PROTOC_BINARIES=OFF -Dprotobuf_BUILD_LIBPROTOC=OFF -Dprotobuf_BUILD_LIBUPB=OFF -Dprotobuf_ALLOW_CCACHE=ON -Dprotobuf_FORCE_FETCH_DEPENDENCIES=ON -Dprotobuf_WITH_ZLIB=OFF -Dprotobuf_MSVC_STATIC_RUNTIME=ON "$(SolutionDir)3rdparty\protobuf\protobuf"
</CmakeReleaseCLI>
<CmakeDebugCLI>call vsdevcmd.bat -arch=amd64
if not exist "$(SolutionDir)build\tmp\protobuf_build-$(Configuration)-$(Platform)" mkdir "$(SolutionDir)build\tmp\protobuf_build-$(Configuration)-$(Platform)"
cd "$(SolutionDir)build\tmp\protobuf_build-$(Configuration)-$(Platform)"
cmake -G Ninja -DCMAKE_CXX_COMPILER="cl.exe" -DCMAKE_C_COMPILER="cl.exe" -DCMAKE_CXX_STANDARD=20 -DCMAKE_BUILD_TYPE="Debug" -DCMAKE_INSTALL_PREFIX="$(SolutionDir)build\lib\$(Configuration)-$(Platform)\protobuf_build" -DCMAKE_SYSTEM_VERSION=10.0 -DCMAKE_VS_WINDOWS_TARGET_PLATFORM_VERSION=$(WindowsTargetPlatformVersion) -DCMAKE_MSVC_RUNTIME_LIBRARY=MultiThreadedDebugDLL -Dprotobuf_INSTALL=ON -Dprotobuf_BUILD_TESTS=OFF -Dprotobuf_BUILD_CONFORMANCE=OFF -Dprotobuf_BUILD_EXAMPLES=OFF -Dprotobuf_BUILD_PROTOBUF_BINARIES=ON -Dprotobuf_BUILD_PROTOC_BINARIES=OFF -Dprotobuf_BUILD_LIBPROTOC=OFF -Dprotobuf_BUILD_LIBUPB=OFF -Dprotobuf_ALLOW_CCACHE=ON -Dprotobuf_FORCE_FETCH_DEPENDENCIES=ON -Dprotobuf_WITH_ZLIB=OFF -Dprotobuf_MSVC_STATIC_RUNTIME=OFF "$(SolutionDir)3rdparty\protobuf\protobuf"
</CmakeDebugCLI>
<CmakeCleanCLI>
echo Cleaning..
rmdir /s /q "$(SolutionDir)build\lib\$(Configuration)-$(Platform)\protobuf_build"
cd "$(SolutionDir)build\tmp\protobuf_build-$(Configuration)-$(Platform)"
for /F "delims= eol=|" %%f in ('
dir /b ^| findstr /V "[^.]*\build[^.]*\.vcxproj"') do (
echo Deleting .\%%f
if exist %%f\nul (
rmdir .\%%f /s /q
) else (
del .\%%f /q
)
)
</CmakeCleanCLI>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<NMakePreprocessorDefinitions>
</NMakePreprocessorDefinitions>
<OutDir>$(SolutionDir)build\lib\$(Configuration)-$(Platform)\</OutDir>
<IntDir>$(SolutionDir)build\tmp\$(ProjectName)-$(Configuration)-$(Platform)\</IntDir>
<NMakeBuildCommandLine>
$(CmakeDebugCLI)
ninja
ninja install
</NMakeBuildCommandLine>
<NMakeReBuildCommandLine>
$(CmakeCleanCLI)
$(CmakeDebugCLI)
ninja
ninja install
</NMakeReBuildCommandLine>
<NMakeCleanCommandLine>
$(CmakeCleanCLI)
</NMakeCleanCommandLine>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<NMakePreprocessorDefinitions>
</NMakePreprocessorDefinitions>
<OutDir>$(SolutionDir)build\lib\$(Configuration)-$(Platform)\</OutDir>
<IntDir>$(SolutionDir)build\tmp\$(ProjectName)-$(Configuration)-$(Platform)\</IntDir>
<NMakeBuildCommandLine>
$(CmakeReleaseCLI)
ninja
ninja install
</NMakeBuildCommandLine>
<NMakeReBuildCommandLine>
$(CmakeCleanCLI)
$(CmakeReleaseCLI)
ninja
ninja install
</NMakeReBuildCommandLine>
<NMakeCleanCommandLine>
$(CmakeCleanCLI)
</NMakeCleanCommandLine>
</PropertyGroup>
<ItemDefinitionGroup>
</ItemDefinitionGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
+3 -10
View File
@@ -6,22 +6,15 @@ find_package(Qt6 ${QT_MIN_VER} CONFIG COMPONENTS Widgets Concurrent Multimedia M
if(WIN32) if(WIN32)
target_link_libraries(3rdparty_qt6 INTERFACE Qt6::Widgets Qt6::Concurrent Qt6::Multimedia Qt6::MultimediaWidgets Qt6::Svg Qt6::SvgWidgets) target_link_libraries(3rdparty_qt6 INTERFACE Qt6::Widgets Qt6::Concurrent Qt6::Multimedia Qt6::MultimediaWidgets Qt6::Svg Qt6::SvgWidgets)
else() else()
find_package(Qt6 ${QT_MIN_VER} COMPONENTS DBus Gui) set(QT_NO_PRIVATE_MODULE_WARNING ON)
if(Qt6_VERSION VERSION_GREATER_EQUAL "6.10.0") find_package(Qt6 ${QT_MIN_VER} COMPONENTS DBus Gui GuiPrivate)
set(QT_NO_PRIVATE_MODULE_WARNING ON)
find_package(Qt6 ${QT_MIN_VER} COMPONENTS GuiPrivate)
endif()
if(Qt6DBus_FOUND) if(Qt6DBus_FOUND)
target_link_libraries(3rdparty_qt6 INTERFACE Qt6::Widgets Qt6::DBus Qt6::Concurrent Qt6::Multimedia Qt6::MultimediaWidgets Qt6::Svg Qt6::SvgWidgets) target_link_libraries(3rdparty_qt6 INTERFACE Qt6::Widgets Qt6::DBus Qt6::Concurrent Qt6::Multimedia Qt6::MultimediaWidgets Qt6::Svg Qt6::SvgWidgets)
target_compile_definitions(3rdparty_qt6 INTERFACE -DHAVE_QTDBUS) target_compile_definitions(3rdparty_qt6 INTERFACE -DHAVE_QTDBUS)
else() else()
target_link_libraries(3rdparty_qt6 INTERFACE Qt6::Widgets Qt6::Concurrent Qt6::Multimedia Qt6::MultimediaWidgets Qt6::Svg Qt6::SvgWidgets) target_link_libraries(3rdparty_qt6 INTERFACE Qt6::Widgets Qt6::Concurrent Qt6::Multimedia Qt6::MultimediaWidgets Qt6::Svg Qt6::SvgWidgets)
endif() endif()
if(Qt6_VERSION VERSION_GREATER_EQUAL "6.10.0") target_link_libraries(3rdparty_qt6 INTERFACE Qt6::GuiPrivate)
target_link_libraries(3rdparty_qt6 INTERFACE Qt6::GuiPrivate)
else()
target_include_directories(3rdparty_qt6 INTERFACE ${Qt6Gui_PRIVATE_INCLUDE_DIRS})
endif()
endif() endif()
if(Qt6Widgets_FOUND) if(Qt6Widgets_FOUND)
+1 -1
View File
@@ -3,7 +3,7 @@ if(USE_SYSTEM_RTMIDI)
pkg_check_modules(RtMidi REQUIRED IMPORTED_TARGET rtmidi>=6.0.0) pkg_check_modules(RtMidi REQUIRED IMPORTED_TARGET rtmidi>=6.0.0)
add_library(rtmidi INTERFACE) add_library(rtmidi INTERFACE)
target_link_libraries(rtmidi INTERFACE PkgConfig::RtMidi) target_link_libraries(rtmidi INTERFACE PkgConfig::RtMidi)
target_include_directories(rtmidi SYSTEM INTERFACE PkgConfig::RtMidi) target_include_directories(rtmidi INTERFACE PkgConfig::RtMidi)
else() else()
option(RTMIDI_API_JACK "Compile with JACK support." OFF) option(RTMIDI_API_JACK "Compile with JACK support." OFF)
option(RTMIDI_BUILD_TESTING "Build test programs" OFF) option(RTMIDI_BUILD_TESTING "Build test programs" OFF)
+1 -1
View File
@@ -1,2 +1,2 @@
add_library(3rdparty_stblib INTERFACE) add_library(3rdparty_stblib INTERFACE)
target_include_directories(3rdparty_stblib SYSTEM INTERFACE stb) target_include_directories(3rdparty_stblib INTERFACE stb)
+3 -6
View File
@@ -119,8 +119,7 @@ echo -e "\n\nResult:\n"
# Find the max length of the paths (before '->') # Find the max length of the paths (before '->')
max_len=0 max_len=0
while read -r line; do while IFS='->' read -r left _; do
left="${line%%->*}"
len=$(echo -n "$left" | wc -c) len=$(echo -n "$left" | wc -c)
if (( len > max_len )); then if (( len > max_len )); then
max_len=$len max_len=$len
@@ -128,10 +127,8 @@ while read -r line; do
done < "$resultfile" done < "$resultfile"
# Print with padding so '->' lines up # Print with padding so '->' lines up
while read -r line; do while IFS='->' read -r left right; do
left="${line%%->*}" right=$(echo "$right" | sed 's/^[[:space:]]*>*[[:space:]]*//')
right="${line#*->}"
right=$(echo "$right" | sed 's/^[[:space:]]*//')
printf "%-${max_len}s -> %s\n" "$left" "$right" printf "%-${max_len}s -> %s\n" "$left" "$right"
done < "$resultfile" done < "$resultfile"
+16 -15
View File
@@ -4,22 +4,23 @@ if(USE_SYSTEM_WOLFSSL)
add_library(wolfssl INTERFACE) add_library(wolfssl INTERFACE)
target_link_libraries(wolfssl INTERFACE PkgConfig::WolfSSL) target_link_libraries(wolfssl INTERFACE PkgConfig::WolfSSL)
else() else()
set(WOLFSSL_TLS13 OFF CACHE INTERNAL "") option(WOLFSSL_TLS13 "Enable wolfSSL TLS v1.3 (default: enabled)" OFF)
set(WOLFSSL_SHA3 ON CACHE INTERNAL "") set(WOLFSSL_SHA3 ON CACHE STRING "Enable wolfSSL SHA-3 support (default: enabled on x86_64/aarch64)")
set(WOLFSSL_SHAKE256 ON CACHE INTERNAL "") set(WOLFSSL_SHAKE256 ON CACHE STRING "Enable wolfSSL SHAKE256 support (default: enabled on x86_64/aarch64)")
set(WOLFSSL_BASE64_ENCODE OFF CACHE INTERNAL "") option(WOLFSSL_BASE64_ENCODE "Enable Base64 encoding (default: enabled on x86_64)" OFF)
set(WOLFSSL_DES3 ON CACHE INTERNAL "") option(WOLFSSL_DES3 "Enable DES3 (default: disabled)" ON)
set(WOLFSSL_PWDBASED ON CACHE INTERNAL "") option(WOLFSSL_PWDBASED "Enable PWDBASED (default: disabled)" ON)
set(WOLFSSL_FAST_MATH ON CACHE INTERNAL "") option(WOLFSSL_FAST_MATH "Enable fast math ops (default: disabled)" ON)
set(WOLFSSL_EXAMPLES OFF CACHE INTERNAL "") option(WOLFSSL_EXAMPLES "Enable examples (default: enabled)" OFF)
set(WOLFSSL_CRYPT_TESTS OFF CACHE INTERNAL "") option(WOLFSSL_CRYPT_TESTS "Enable Crypt Bench/Test (default: enabled)" OFF)
set(WOLFSSL_ASYNC_THREADS OFF CACHE INTERNAL "") option(WOLFSSL_ASYNC_THREADS "Enable Asynchronous Threading (default: enabled)" OFF)
set(WOLFSSL_BUILD_OUT_OF_TREE ON CACHE INTERNAL "") option(WOLFSSL_BUILD_OUT_OF_TREE "Don't generate files in the source tree (default: yes)" ON)
set(WOLFSSL_SNI ON CACHE INTERNAL "") option(WOLFSSL_SNI "Enable SNI (default: disabled)" ON)
set(WOLFSSL_OPENSSLEXTRA ON CACHE INTERNAL "") option(WOLFSSL_OPENSSLEXTRA "Enable extra OpenSSL API, size+ (default: disabled)" ON)
set(WOLFSSL_ALT_CERT_CHAINS ON CACHE INTERNAL "") option(WOLFSSL_HARDEN "Enable Hardened build, Enables Timing Resistance and Blinding (default: enabled)" OFF)
option(WOLFSSL_ALT_CERT_CHAINS "Enable support for Alternate certification chains (default: disabled)" ON)
add_subdirectory(wolfssl EXCLUDE_FROM_ALL) add_subdirectory(wolfssl EXCLUDE_FROM_ALL)
target_compile_definitions(wolfssl PUBLIC WOLFSSL_DES_ECB HAVE_WRITE_DUP FP_MAX_BITS=8192 WOLFSSL_USE_OPTIONS_H) target_compile_definitions(wolfssl PUBLIC WOLFSSL_DES_ECB HAVE_WRITE_DUP FP_MAX_BITS=8192 WOLFSSL_NO_OPTIONS_H)
endif() endif()
-1
View File
@@ -76,7 +76,6 @@
<ClCompile Include="yaml-cpp\src\exceptions.cpp" /> <ClCompile Include="yaml-cpp\src\exceptions.cpp" />
<ClCompile Include="yaml-cpp\src\exp.cpp"> <ClCompile Include="yaml-cpp\src\exp.cpp">
</ClCompile> </ClCompile>
<ClCompile Include="yaml-cpp\src\fptostring.cpp" />
<ClCompile Include="yaml-cpp\src\memory.cpp"> <ClCompile Include="yaml-cpp\src\memory.cpp">
</ClCompile> </ClCompile>
<ClCompile Include="yaml-cpp\src\node.cpp"> <ClCompile Include="yaml-cpp\src\node.cpp">
-3
View File
@@ -94,8 +94,5 @@
<ClCompile Include="yaml-cpp\src\depthguard.cpp"> <ClCompile Include="yaml-cpp\src\depthguard.cpp">
<Filter>Source Files</Filter> <Filter>Source Files</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="yaml-cpp\src\fptostring.cpp">
<Filter>Source Files</Filter>
</ClCompile>
</ItemGroup> </ItemGroup>
</Project> </Project>
+2 -3
View File
@@ -6,14 +6,13 @@ if (USE_SYSTEM_ZLIB)
target_link_libraries(3rdparty_zlib INTERFACE ZLIB::ZLIB) target_link_libraries(3rdparty_zlib INTERFACE ZLIB::ZLIB)
target_compile_definitions(3rdparty_zlib INTERFACE -DZLIB_CONST=1) target_compile_definitions(3rdparty_zlib INTERFACE -DZLIB_CONST=1)
else() else()
option(ZLIB_BUILD_TESTING "Enable Zlib Examples as tests" OFF) option(ZLIB_BUILD_EXAMPLES "Enable Zlib Examples" OFF)
option(ZLIB_BUILD_SHARED "Enable building zlib shared library" OFF)
message(STATUS "RPCS3: Using builtin ZLIB") message(STATUS "RPCS3: Using builtin ZLIB")
set(SKIP_INSTALL_ALL ON) set(SKIP_INSTALL_ALL ON)
add_subdirectory(zlib EXCLUDE_FROM_ALL) add_subdirectory(zlib EXCLUDE_FROM_ALL)
add_library(3rdparty_zlib INTERFACE) add_library(3rdparty_zlib INTERFACE)
target_link_libraries(3rdparty_zlib INTERFACE zlibstatic) target_link_libraries(3rdparty_zlib INTERFACE zlibstatic)
target_include_directories(3rdparty_zlib SYSTEM INTERFACE zlib ${CMAKE_CURRENT_BINARY_DIR}/zlib) target_include_directories(3rdparty_zlib INTERFACE zlib ${CMAKE_CURRENT_BINARY_DIR}/zlib)
target_compile_definitions(3rdparty_zlib INTERFACE -DZLIB_CONST=1) target_compile_definitions(3rdparty_zlib INTERFACE -DZLIB_CONST=1)
endif() endif()
+1 -1
View File
@@ -3,7 +3,7 @@ if(USE_SYSTEM_ZSTD)
pkg_check_modules(zstd REQUIRED IMPORTED_TARGET libzstd) pkg_check_modules(zstd REQUIRED IMPORTED_TARGET libzstd)
add_library(3rdparty_zstd INTERFACE) add_library(3rdparty_zstd INTERFACE)
target_link_libraries(3rdparty_zstd INTERFACE PkgConfig::zstd) target_link_libraries(3rdparty_zstd INTERFACE PkgConfig::zstd)
target_include_directories(3rdparty_zstd SYSTEM INTERFACE PkgConfig::RtMidi) target_include_directories(3rdparty_zstd INTERFACE PkgConfig::RtMidi)
else() else()
option(ZSTD_BUILD_PROGRAMS "BUILD PROGRAMS" OFF) option(ZSTD_BUILD_PROGRAMS "BUILD PROGRAMS" OFF)
option(ZSTD_BUILD_SHARED "BUILD SHARED LIBRARIES" OFF) option(ZSTD_BUILD_SHARED "BUILD SHARED LIBRARIES" OFF)
+10 -11
View File
@@ -20,27 +20,27 @@ The following tools are required to build RPCS3 on Windows 10 or later:
with standalone **CMake** tool. with standalone **CMake** tool.
- [Python 3.6+](https://www.python.org/downloads/) (add to PATH) - [Python 3.6+](https://www.python.org/downloads/) (add to PATH)
- [Qt 6.11.1](https://www.qt.io/download-qt-installer) In case you can't download from the official installer, you can use [Another Qt installer](https://github.com/miurahr/aqtinstall) (In that case you will need to manually add the "qtmultimedia" module when installing Qt) - [Qt 6.10.1](https://www.qt.io/download-qt-installer) In case you can't download from the official installer, you can use [Another Qt installer](https://github.com/miurahr/aqtinstall) (In that case you will need to manually add the "qtmultimedia" module when installing Qt)
- [Vulkan SDK 1.4.341.1](https://vulkan.lunarg.com/sdk/home) (see "Install the SDK" [here](https://vulkan.lunarg.com/doc/sdk/latest/windows/getting_started.html)). Note that future SDKs may not work. - [Vulkan SDK 1.3.268.0](https://vulkan.lunarg.com/sdk/home) (see "Install the SDK" [here](https://vulkan.lunarg.com/doc/sdk/latest/windows/getting_started.html)) for now future SDKs don't work. You need precisely 1.3.268.0.
The `sln` solution available only on **Visual Studio** is the preferred building solution. It easily allows to build the **RPCS3** application in `Release` and `Debug` mode. The `sln` solution available only on **Visual Studio** is the preferred building solution. It easily allows to build the **RPCS3** application in `Release` and `Debug` mode.
In order to build **RPCS3** with the `sln` solution (with **Visual Studio**), **Qt** libs need to be detected. To detect the libs: In order to build **RPCS3** with the `sln` solution (with **Visual Studio**), **Qt** libs need to be detected. To detect the libs:
- add and set the `QTDIR` environment variable, e.g. `<QtInstallFolder>\6.11.1\msvc2022_64\` - add and set the `QTDIR` environment variable, e.g. `<QtInstallFolder>\6.10.1\msvc2022_64\`
- or use the [Visual Studio Qt Plugin](https://marketplace.visualstudio.com/items?itemName=TheQtCompany.QtVisualStudioTools2022) - or use the [Visual Studio Qt Plugin](https://marketplace.visualstudio.com/items?itemName=TheQtCompany.QtVisualStudioTools2022)
**NOTE:** If you have issues with the **Visual Studio Qt Plugin**, you may want to uninstall it and install the [Legacy Qt Plugin](https://marketplace.visualstudio.com/items?itemName=TheQtCompany.LEGACYQtVisualStudioTools2022) instead. **NOTE:** If you have issues with the **Visual Studio Qt Plugin**, you may want to uninstall it and install the [Legacy Qt Plugin](https://marketplace.visualstudio.com/items?itemName=TheQtCompany.LEGACYQtVisualStudioTools2022) instead.
In order to build **RPCS3** with the `CMake` solution (with both **Visual Studio** and standalone **CMake** tool): In order to build **RPCS3** with the `CMake` solution (with both **Visual Studio** and standalone **CMake** tool):
- add and set the `Qt6_ROOT` environment variable to the **Qt** libs path, e.g. `<QtInstallFolder>\6.11.1\msvc2022_64\` - add and set the `Qt6_ROOT` environment variable to the **Qt** libs path, e.g. `<QtInstallFolder>\6.10.1\msvc2022_64\`
### Linux ### Linux
These are the essentials tools to build RPCS3 on Linux. Some of them can be installed through your favorite package manager: These are the essentials tools to build RPCS3 on Linux. Some of them can be installed through your favorite package manager:
- Clang 17+ or GCC 13+ - Clang 17+ or GCC 13+
- [CMake 3.28.0+](https://www.cmake.org/download/) - [CMake 3.28.0+](https://www.cmake.org/download/)
- [Qt 6.11.1](https://www.qt.io/download-qt-installer) - [Qt 6.10.1](https://www.qt.io/download-qt-installer)
- [Vulkan SDK 1.4.341.1](https://vulkan.lunarg.com/sdk/home) (See "Install the SDK" [here](https://vulkan.lunarg.com/doc/sdk/latest/linux/getting_started.html)). Note that future SDKs may not work. - [Vulkan SDK 1.3.268.0](https://vulkan.lunarg.com/sdk/home) (See "Install the SDK" [here](https://vulkan.lunarg.com/doc/sdk/latest/linux/getting_started.html)) for now future SDKs don't work. You need precisely 1.3.268.0.
- [SDL3](https://github.com/libsdl-org/SDL/releases) (for the FAudio backend) - [SDL3](https://github.com/libsdl-org/SDL/releases) (for the FAudio backend)
**If you have an NVIDIA GPU, you may need to install the libglvnd package.** **If you have an NVIDIA GPU, you may need to install the libglvnd package.**
@@ -51,7 +51,7 @@ These are the essentials tools to build RPCS3 on Linux. Some of them can be inst
#### Debian & Ubuntu #### Debian & Ubuntu
sudo apt-get install build-essential ninja-build libasound2-dev libpulse-dev libopenal-dev libglew-dev zlib1g-dev libedit-dev libvulkan-dev libudev-dev git libevdev-dev libsdl3-dev libjack-dev libsndio-dev libcurl4-openssl-dev qt6-base-dev qt6-base-private-dev qt6-multimedia-dev qt6-svg-dev libxkbcommon-dev sudo apt-get install build-essential ninja-build libasound2-dev libpulse-dev libopenal-dev libglew-dev zlib1g-dev libedit-dev libvulkan-dev libudev-dev git libevdev-dev libsdl3-3.2 libsdl3-dev libjack-dev libsndio-dev
Ubuntu is usually horrendously out of date, and some packages need to be downloaded by hand. This part is for Qt, GCC, Vulkan, and CMake Ubuntu is usually horrendously out of date, and some packages need to be downloaded by hand. This part is for Qt, GCC, Vulkan, and CMake
@@ -95,7 +95,7 @@ sudo apt-get install cmake
#### Fedora #### Fedora
sudo dnf install alsa-lib-devel cmake ninja-build glew glew-devel libatomic libevdev-devel libudev-devel openal-soft-devel qt6-qtbase-devel qt6-qtbase-private-devel vulkan-devel pipewire-jack-audio-connection-kit-devel qt6-qtmultimedia-devel qt6-qtsvg-devel llvm-devel libcurl-devel sudo dnf install alsa-lib-devel cmake ninja-build glew glew-devel libatomic libevdev-devel libudev-devel openal-devel qt6-qtbase-devel qt6-qtbase-private-devel vulkan-devel pipewire-jack-audio-connection-kit-devel qt6-qtmultimedia-devel qt6-qtsvg-devel llvm-devel
#### OpenSUSE #### OpenSUSE
@@ -108,10 +108,9 @@ Clone and initialize the repository
```bash ```bash
git clone --recurse-submodules https://github.com/RPCS3/rpcs3.git git clone --recurse-submodules https://github.com/RPCS3/rpcs3.git
cd rpcs3 cd rpcs3
git submodule sync
# This is automatically done by `git clone --recurse-submodules`, # This is automatically done by `git clone --recurse-submodules`,
# but in case you forgot it, you can manually fetch submodules this way: # but in case you forgot it, you can manually fetch submodules this way:
git submodule update --init --recursive git submodule update --init
``` ```
### Windows ### Windows
@@ -123,7 +122,7 @@ Start **Visual Studio**, click on `Open a project or solution` and select the `r
##### Configuring the Qt Plugin (if used) ##### Configuring the Qt Plugin (if used)
1) go to `Extensions->Qt VS Tools->Qt Versions` 1) go to `Extensions->Qt VS Tools->Qt Versions`
2) add the path to your Qt installation with compiler e.g. `<QtInstallFolder>\6.11.1\msvc2022_64`, version will fill in automatically 2) add the path to your Qt installation with compiler e.g. `<QtInstallFolder>\6.10.1\msvc2022_64`, version will fill in automatically
3) go to `Extensions->Qt VS Tools->Options->Legacy Project Format`. (Only available in the **Legacy Qt Plugin**) 3) go to `Extensions->Qt VS Tools->Options->Legacy Project Format`. (Only available in the **Legacy Qt Plugin**)
4) set `Build: Run pre-build setup` to `true`. (Only available in the **Legacy Qt Plugin**) 4) set `Build: Run pre-build setup` to `true`. (Only available in the **Legacy Qt Plugin**)
+57 -10
View File
@@ -13,12 +13,12 @@ set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
set(CMAKE_POSITION_INDEPENDENT_CODE ON) set(CMAKE_POSITION_INDEPENDENT_CODE ON)
if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU") if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 13) if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 11)
message(FATAL_ERROR "RPCS3 requires at least gcc-13.") message(FATAL_ERROR "RPCS3 requires at least gcc-11.")
endif() endif()
elseif(CMAKE_CXX_COMPILER_ID STREQUAL "Clang") elseif(CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 19.0) if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 12.0)
message(FATAL_ERROR "RPCS3 requires at least clang-19.0.") message(FATAL_ERROR "RPCS3 requires at least clang-12.0.")
endif() endif()
endif() endif()
@@ -37,12 +37,12 @@ option(USE_LIBEVDEV "libevdev-based joystick support" ON)
option(USE_DISCORD_RPC "Discord rich presence integration" OFF) option(USE_DISCORD_RPC "Discord rich presence integration" OFF)
option(USE_VULKAN "Vulkan render backend" ON) option(USE_VULKAN "Vulkan render backend" ON)
option(USE_PRECOMPILED_HEADERS "Use precompiled headers" OFF) option(USE_PRECOMPILED_HEADERS "Use precompiled headers" OFF)
option(USE_SDL "Enables SDL input handler" ON) option(USE_SDL "Enables SDL input handler" OFF)
option(USE_SYSTEM_CUBEB "Prefer system cubeb instead of the builtin one" OFF) option(USE_SYSTEM_CUBEB "Prefer system cubeb instead of the builtin one" OFF)
option(USE_SYSTEM_CURL "Prefer system Curl instead of the prebuild one" ON) option(USE_SYSTEM_CURL "Prefer system Curl instead of the prebuild one" ON)
option(USE_SYSTEM_FAUDIO "Prefer system FAudio instead of the builtin one" OFF) option(USE_SYSTEM_FAUDIO "Prefer system FAudio instead of the builtin one" OFF)
option(USE_SYSTEM_FFMPEG "Prefer system ffmpeg instead of the prebuild one" OFF) option(USE_SYSTEM_FFMPEG "Prefer system ffmpeg instead of the prebuild one" OFF)
option(USE_SYSTEM_PROTOBUF "Prefer system protobuf instead of the builtin one" OFF) option(USE_SYSTEM_FLATBUFFERS "Prefer system flatbuffers instead of the builtin one" OFF)
option(USE_SYSTEM_GLSLANG "Prefer system glslang instead of the builtin one" OFF) option(USE_SYSTEM_GLSLANG "Prefer system glslang instead of the builtin one" OFF)
option(USE_SYSTEM_HIDAPI "Prefer system hidapi instead of the builtin one" OFF) option(USE_SYSTEM_HIDAPI "Prefer system hidapi instead of the builtin one" OFF)
option(USE_SYSTEM_LIBPNG "Prefer system libpng instead of the builtin one" OFF) option(USE_SYSTEM_LIBPNG "Prefer system libpng instead of the builtin one" OFF)
@@ -86,7 +86,50 @@ if(CMAKE_BUILD_TYPE MATCHES "Debug" AND NOT MSVC)
endif() endif()
if(MSVC) if(MSVC)
add_compile_options("$<$<COMPILE_LANGUAGE:C,CXX>:/MP>") option(USE_MSVC_STATIC_CRT "Use static MSVC C runtime" OFF)
# TODO(cjj19970505@live.cn)
# DiscordRPC binary in 3rdparty is compiled /MT
# So theoretically we should enable DiscordRPC in Release and static CRT build
# since we might encounter some rumtime issues when more than one CRT version are presented.
# https://docs.microsoft.com/en-us/cpp/c-runtime-library/crt-library-features?view=msvc-160#what-problems-exist-if-an-application-uses-more-than-one-crt-version
# Add other DiscordRPC binaries(compiled with /MTd, /MD, /MDd) or compile it from source may address this issue.
if(NOT IS_MULTI_CONFIG)
if(NOT(CMAKE_BUILD_TYPE MATCHES "Release" AND USE_MSVC_STATIC_CRT))
set(USE_DISCORD_RPC OFF CACHE BOOL "Discord RPC is only available in Release and static CRT build." FORCE)
endif()
endif()
if(USE_MSVC_STATIC_CRT)
set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$<CONFIG:Debug>:Debug>")
else()
# though doc ( https://cmake.org/cmake/help/latest/variable/CMAKE_MSVC_RUNTIME_LIBRARY.html )
# says if that property is not set then CMake uses the default value MultiThreaded$<$<CONFIG:Debug>:Debug>DLL
# to select a MSVC runtime library.
# But yaml-cpp set /MT(d) if CMAKE_MSVC_RUNTIME_LIBRARY is undefined
# So we have to define it explicitly
set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$<CONFIG:Debug>:Debug>DLL")
endif()
# TODO(cjj19970505@live.cn)
# offical QT uses dynamic CRT.
# When building our lib with static CRT and debug build type
# and linking with Qt with dynamic CRT and debug build,
# error is encountered in runtime (which is expected).
# But building our lib with static CRT and release build type,
# and linking with Qt with dynamic CRT and release build seems to be working,
# which is the same config with VS solution.
# (though technically it might still have some hidden errors).
# So we allow static CRT in both relase and debug build, but prompt warning in debug build.
# For more info:
# https://docs.microsoft.com/en-us/cpp/c-runtime-library/crt-library-features?view=msvc-160#what-problems-exist-if-an-application-uses-more-than-one-crt-version
# https://wiki.qt.io/Technical_FAQ#Why_does_a_statically_built_Qt_use_the_dynamic_Visual_Studio_runtime_libraries_.3F_Do_I_need_to_deploy_those_with_my_application_.3F
if(USE_MSVC_STATIC_CRT)
if(IS_MULTI_CONFIG OR CMAKE_BUILD_TYPE MATCHES "Debug")
message(AUTHOR_WARNING "Debug build currently can not work with static CRT.")
endif()
endif()
add_compile_options(/MP)
endif() endif()
if(NOT CMAKE_SIZEOF_VOID_P EQUAL 8) if(NOT CMAKE_SIZEOF_VOID_P EQUAL 8)
@@ -94,12 +137,12 @@ if(NOT CMAKE_SIZEOF_VOID_P EQUAL 8)
endif() endif()
if(APPLE AND CMAKE_OSX_ARCHITECTURES STREQUAL "arm64") if(APPLE AND CMAKE_OSX_ARCHITECTURES STREQUAL "arm64")
list(APPEND CMAKE_PREFIX_PATH "/opt/homebrew") include_directories(/opt/homebrew/include)
list(APPEND CMAKE_SYSTEM_PREFIX_PATH "/opt/homebrew") link_directories(/opt/homebrew/lib)
endif() endif()
if(MSVC) if(MSVC)
add_compile_options("$<$<COMPILE_LANGUAGE:C,CXX>:/wd4530;/utf-8>") # C++ exception handler used, but unwind semantics are not enabled add_compile_options(/wd4530 /utf-8) # C++ exception handler used, but unwind semantics are not enabled
endif() endif()
add_subdirectory(3rdparty) add_subdirectory(3rdparty)
@@ -118,6 +161,10 @@ if (NOT FOUND_LTO EQUAL -1)
message(FATAL_ERROR "RPCS3 doesn't support building with LTO, use -DDISABLE_LTO=TRUE to force-disable it") message(FATAL_ERROR "RPCS3 doesn't support building with LTO, use -DDISABLE_LTO=TRUE to force-disable it")
endif() endif()
if(NOT WIN32)
add_compile_options(-pthread)
endif()
## Look for Gamemode if its installed on Linux ## Look for Gamemode if its installed on Linux
if(LINUX) if(LINUX)
## User chooses whether to Enable GameMode features or not ## User chooses whether to Enable GameMode features or not
-10
View File
@@ -23,16 +23,6 @@ If you want to contribute as a developer, please take a look at the following pa
You should also contact any of the developers in the forums or in the Discord server to learn more about the current state of the emulator. You should also contact any of the developers in the forums or in the Discord server to learn more about the current state of the emulator.
### AI Use
Use of AI tools for research and reverse engineering purposes is permitted. However, contributors are expected to fully own and understand all code they submit. Any communication with the team — including code, code comments, and GitHub comments — must come from the human contributor, not an AI agent acting autonomously.
We have unfortunately seen a rise in untested and unverified AI-generated slop being submitted to this project. This wastes maintainer time and, in worse cases, such changes get merged and break functionality for all users. Repeated violations will result in a ban from the repository. Please be respectful of everyone's time.
**Pull requests opened by AI agents or automated tools must include a disclosure in the PR description** stating the scope of AI involvement — which parts were AI-generated and what human testing or review was performed prior to submission. PRs that omit this disclosure may be closed without review.
If you are unsure about your work, open a discussion issue to talk it through with the team, or reach out to a maintainer on [Discord](https://discord.gg/RPCS3).
## Building ## Building
See [BUILDING.md](BUILDING.md) for more information about how to setup an environment to build RPCS3. See [BUILDING.md](BUILDING.md) for more information about how to setup an environment to build RPCS3.
+51 -140
View File
@@ -40,7 +40,7 @@ namespace cfg
owner->m_nodes.emplace_back(this); owner->m_nodes.emplace_back(this);
} }
bool _base::from_string(std::string_view /*value*/, bool /*dynamic*/) bool _base::from_string(std::string_view, bool)
{ {
cfg_log.fatal("cfg::_base::from_string() purecall"); cfg_log.fatal("cfg::_base::from_string() purecall");
return false; return false;
@@ -68,7 +68,7 @@ namespace cfg
// Incrementally load config entries from YAML::Node. // Incrementally load config entries from YAML::Node.
// The config value is preserved if the corresponding YAML node doesn't exist. // The config value is preserved if the corresponding YAML node doesn't exist.
[[nodiscard]] static bool decode(const YAML::Node& data, class _base& rhs, bool dynamic, bool strict); static void decode(const YAML::Node& data, class _base& rhs, bool dynamic = false);
} }
std::vector<std::string> cfg::make_int_range(s64 min, s64 max) std::vector<std::string> cfg::make_int_range(s64 min, s64 max)
@@ -76,11 +76,11 @@ std::vector<std::string> cfg::make_int_range(s64 min, s64 max)
return {std::to_string(min), std::to_string(max)}; return {std::to_string(min), std::to_string(max)};
} }
bool try_to_int64(s64* out, std::string_view value, s64 min, s64 max, std::string_view name) bool try_to_int64(s64* out, std::string_view value, s64 min, s64 max)
{ {
if (value.empty()) if (value.empty())
{ {
if (out) cfg_log.error("cfg::try_to_int64('%s'): called with an empty string", name); if (out) cfg_log.error("cfg::try_to_int64(): called with an empty string");
return false; return false;
} }
@@ -107,7 +107,7 @@ bool try_to_int64(s64* out, std::string_view value, s64 min, s64 max, std::strin
if (ret.ec != std::errc() || ret.ptr != end || (start[0] == '-' && sign < 0)) if (ret.ec != std::errc() || ret.ptr != end || (start[0] == '-' && sign < 0))
{ {
if (out) cfg_log.error("cfg::try_to_int64('%s', '%s'): invalid integer", value, name); if (out) cfg_log.error("cfg::try_to_int64('%s'): invalid integer", value);
return false; return false;
} }
@@ -115,7 +115,7 @@ bool try_to_int64(s64* out, std::string_view value, s64 min, s64 max, std::strin
if (result < min || result > max) if (result < min || result > max)
{ {
if (out) cfg_log.error("cfg::try_to_int64('%s', '%s'): out of bounds (val=%d, min=%d, max=%d)", value, name, result, min, max); if (out) cfg_log.error("cfg::try_to_int64('%s'): out of bounds (val=%d, min=%d, max=%d)", value, result, min, max);
return false; return false;
} }
@@ -128,11 +128,11 @@ std::vector<std::string> cfg::make_uint_range(u64 min, u64 max)
return {std::to_string(min), std::to_string(max)}; return {std::to_string(min), std::to_string(max)};
} }
bool try_to_uint64(u64* out, std::string_view value, u64 min, u64 max, std::string_view name) bool try_to_uint64(u64* out, std::string_view value, u64 min, u64 max)
{ {
if (value.empty()) if (value.empty())
{ {
if (out) cfg_log.error("cfg::try_to_uint64('%s'): called with an empty string", name); if (out) cfg_log.error("cfg::try_to_uint64(): called with an empty string");
return false; return false;
} }
@@ -152,13 +152,13 @@ bool try_to_uint64(u64* out, std::string_view value, u64 min, u64 max, std::stri
if (ret.ec != std::errc() || ret.ptr != end) if (ret.ec != std::errc() || ret.ptr != end)
{ {
if (out) cfg_log.error("cfg::try_to_uint64('%s', '%s'): invalid integer", value, name); if (out) cfg_log.error("cfg::try_to_uint64('%s'): invalid integer", value);
return false; return false;
} }
if (result < min || result > max) if (result < min || result > max)
{ {
if (out) cfg_log.error("cfg::try_to_uint64('%s', '%s'): out of bounds (val=%u, min=%u, max=%u)", value, name, result, min, max); if (out) cfg_log.error("cfg::try_to_uint64('%s'): out of bounds (val=%u, min=%u, max=%u)", value, result, min, max);
return false; return false;
} }
@@ -166,11 +166,11 @@ bool try_to_uint64(u64* out, std::string_view value, u64 min, u64 max, std::stri
return true; return true;
} }
bool try_to_uint128(u128* out, std::string_view value, std::string_view name) bool try_to_uint128(u128* out, std::string_view value)
{ {
if (value.empty()) if (value.empty())
{ {
if (out) cfg_log.error("cfg::try_to_uint128('%s'): called with an empty string", name); if (out) cfg_log.error("cfg::try_to_uint128(): called with an empty string");
return false; return false;
} }
@@ -193,7 +193,7 @@ bool try_to_uint128(u128* out, std::string_view value, std::string_view name)
if (ret.ec != std::errc() || ret.ptr != end) if (ret.ec != std::errc() || ret.ptr != end)
{ {
if (out) cfg_log.error("cfg::try_to_uint128('%s', '%s'): invalid integer", value, name); if (out) cfg_log.error("cfg::try_to_uint128('%s'): invalid integer", value);
return false; return false;
} }
@@ -207,7 +207,7 @@ bool try_to_uint128(u128* out, std::string_view value, std::string_view name)
if (ret.ec != std::errc() || ret.ptr != start_low64) if (ret.ec != std::errc() || ret.ptr != start_low64)
{ {
if (out) cfg_log.error("cfg::try_to_uint128('%s', '%s'): invalid integer", value, name); if (out) cfg_log.error("cfg::try_to_uint128('%s'): invalid integer", value);
return false; return false;
} }
@@ -220,11 +220,11 @@ std::vector<std::string> cfg::make_float_range(f64 min, f64 max)
return {std::to_string(min), std::to_string(max)}; return {std::to_string(min), std::to_string(max)};
} }
bool try_to_float(f64* out, std::string_view value, f64 min, f64 max, std::string_view name) bool try_to_float(f64* out, std::string_view value, f64 min, f64 max)
{ {
if (value.empty()) if (value.empty())
{ {
if (out) cfg_log.error("cfg::try_to_float('%s'): called with an empty string", name); if (out) cfg_log.error("cfg::try_to_float(): called with an empty string");
return false; return false;
} }
@@ -237,13 +237,13 @@ bool try_to_float(f64* out, std::string_view value, f64 min, f64 max, std::strin
if (end_check != str.data() + str.size()) if (end_check != str.data() + str.size())
{ {
if (out) cfg_log.error("cfg::try_to_float('%s', '%s'): invalid float", value, name); if (out) cfg_log.error("cfg::try_to_float('%s'): invalid float", value);
return false; return false;
} }
if (result < min || result > max) if (result < min || result > max)
{ {
if (out) cfg_log.error("cfg::try_to_float('%s', '%s'): out of bounds (val=%f, min=%f, max=%f)", value, name, result, min, max); if (out) cfg_log.error("cfg::try_to_float('%s'): out of bounds (val=%f, min=%f, max=%f)", value, result, min, max);
return false; return false;
} }
@@ -251,8 +251,12 @@ bool try_to_float(f64* out, std::string_view value, f64 min, f64 max, std::strin
return true; return true;
} }
bool try_to_string(std::string* out, f64 value, std::string_view name) bool try_to_string(std::string* out, const f64& value)
{ {
#ifdef __APPLE__
if (out) *out = std::to_string(value);
return true;
#else
std::array<char, 32> str{}; std::array<char, 32> str{};
if (auto [ptr, ec] = std::to_chars(str.data(), str.data() + str.size(), value, std::chars_format::fixed); ec == std::errc()) if (auto [ptr, ec] = std::to_chars(str.data(), str.data() + str.size(), value, std::chars_format::fixed); ec == std::errc())
@@ -262,15 +266,14 @@ bool try_to_string(std::string* out, f64 value, std::string_view name)
} }
else else
{ {
if (out) cfg_log.error("cfg::try_to_string('%s'): could not convert value '%f' to string. error='%s'", name, value, std::make_error_code(ec).message()); if (out) cfg_log.error("cfg::try_to_string(): could not convert value '%f' to string. error='%s'", value, std::make_error_code(ec).message());
return false; return false;
} }
#endif
} }
bool cfg::try_to_enum_value(u64* out, decltype(&fmt_class_string<int>::format) func, std::string_view value, std::string_view name) bool cfg::try_to_enum_value(u64* out, decltype(&fmt_class_string<int>::format) func, std::string_view value)
{ {
ensure(func);
u64 max = umax; u64 max = umax;
for (u64 i = 0;; i++) for (u64 i = 0;; i++)
@@ -299,7 +302,7 @@ bool cfg::try_to_enum_value(u64* out, decltype(&fmt_class_string<int>::format) f
const char* end = start + value.size(); const char* end = start + value.size();
int base = 10; int base = 10;
if (value.size() >= 2 && start[0] == '0' && (start[1] == 'x' || start[1] == 'X')) if (start[0] == '0' && (start[1] == 'x' || start[1] == 'X'))
{ {
// Limited hex support // Limited hex support
base = 16; base = 16;
@@ -310,13 +313,13 @@ bool cfg::try_to_enum_value(u64* out, decltype(&fmt_class_string<int>::format) f
if (ret.ec != std::errc() || ret.ptr != end) if (ret.ec != std::errc() || ret.ptr != end)
{ {
if (out) cfg_log.error("cfg::try_to_enum_value('%s', '%s'): invalid enum or integer", value, name); if (out) cfg_log.error("cfg::try_to_enum_value('%s'): invalid enum or integer", value);
return false; return false;
} }
if (result > max) if (result > max)
{ {
if (out) cfg_log.error("cfg::try_to_enum_value('%s', '%s'): out of bounds(val=%u, min=0, max=%u)", value, name, result, max); if (out) cfg_log.error("cfg::try_to_enum_value('%s'): out of bounds(val=%u, min=0, max=%u)", value, result, max);
return false; return false;
} }
@@ -359,27 +362,6 @@ std::vector<std::string> cfg::try_to_enum_list(decltype(&fmt_class_string<int>::
return result; return result;
} }
size_t cfg::try_to_enum_size(decltype(&fmt_class_string<int>::format) func)
{
size_t result = 0;
for (u64 i = 0;; i++)
{
std::string var;
func(var, i);
std::string hex;
fmt_class_string<u64>::format(hex, i);
if (var == hex)
{
break;
}
result++;
}
return result;
}
void cfg::encode(YAML::Emitter& out, const cfg::_base& rhs) void cfg::encode(YAML::Emitter& out, const cfg::_base& rhs)
{ {
switch (rhs.get_type()) switch (rhs.get_type())
@@ -434,7 +416,7 @@ void cfg::encode(YAML::Emitter& out, const cfg::_base& rhs)
out << YAML::BeginMap; out << YAML::BeginMap;
for (const auto& np : static_cast<const log_entry&>(rhs).get_map()) for (const auto& np : static_cast<const log_entry&>(rhs).get_map())
{ {
if (np.second == logs::level::_default) continue; if (np.second == logs::level::notice) continue;
out << YAML::Key << np.first; out << YAML::Key << np.first;
out << YAML::Value << fmt::format("%s", np.second); out << YAML::Value << fmt::format("%s", np.second);
} }
@@ -465,50 +447,37 @@ void cfg::encode(YAML::Emitter& out, const cfg::_base& rhs)
} }
} }
bool cfg::decode(const YAML::Node& data, cfg::_base& rhs, bool dynamic, bool strict) void cfg::decode(const YAML::Node& data, cfg::_base& rhs, bool dynamic)
{ {
if (dynamic && !rhs.get_is_dynamic()) if (dynamic && !rhs.get_is_dynamic())
{ {
return true; return;
} }
switch (rhs.get_type()) switch (rhs.get_type())
{ {
case type::node: case type::node:
{ {
if (!data.IsMap()) if (data.IsScalar() || data.IsSequence())
{ {
cfg_log.error("node node is not a map"); return; // ???
return false;
} }
bool success = true;
for (const auto& pair : data) for (const auto& pair : data)
{ {
if (!pair.first.IsScalar()) continue; if (!pair.first.IsScalar()) continue;
// Find the key among existing nodes // Find the key among existing nodes
const auto& nodes = static_cast<node&>(rhs).get_nodes(); for (const auto& node : static_cast<node&>(rhs).get_nodes())
const auto it = std::find_if(nodes.cbegin(), nodes.cend(), [&pair](const auto& node) { return ensure(node)->get_name() == pair.first.Scalar(); });
if (it == nodes.cend())
{ {
if (strict) if (node->get_name() == pair.first.Scalar())
{ {
cfg_log.error("Unknown key found: '%s'", pair.first.Scalar()); decode(pair.second, *node, dynamic);
success = false;
} }
continue;
}
if (!decode(pair.second, *ensure(*it), dynamic, strict) && strict)
{
success = false;
} }
} }
return success; break;
} }
case type::set: case type::set:
{ {
@@ -516,10 +485,7 @@ bool cfg::decode(const YAML::Node& data, cfg::_base& rhs, bool dynamic, bool str
if (YAML::convert<decltype(values)>::decode(data, values)) if (YAML::convert<decltype(values)>::decode(data, values))
{ {
if (!rhs.from_list(std::move(values)) && strict) rhs.from_list(std::move(values));
{
return false;
}
} }
break; break;
@@ -529,8 +495,7 @@ bool cfg::decode(const YAML::Node& data, cfg::_base& rhs, bool dynamic, bool str
{ {
if (!data.IsMap()) if (!data.IsMap())
{ {
cfg_log.error("map node is not a map"); return;
return false;
} }
map_of_type<std::string> values; map_of_type<std::string> values;
@@ -547,36 +512,22 @@ bool cfg::decode(const YAML::Node& data, cfg::_base& rhs, bool dynamic, bool str
} }
case type::log: case type::log:
{ {
if (!data.IsMap()) if (data.IsScalar() || data.IsSequence())
{ {
cfg_log.error("log node is not a map"); return; // ???
return false;
} }
map_of_type<logs::level> values; map_of_type<logs::level> values;
for (const auto& pair : data) for (const auto& pair : data)
{ {
if (!pair.first.IsScalar() || !pair.second.IsScalar()) if (!pair.first.IsScalar() || !pair.second.IsScalar()) continue;
{
if (strict)
{
if (!pair.first.IsScalar())
cfg_log.error("Key in map is not a scalar");
else
cfg_log.error("Value in map is not a scalar. key='%s'", pair.first.Scalar());
return false;
}
continue;
}
u64 value; u64 value;
if (!cfg::try_to_enum_value(&value, &fmt_class_string<logs::level>::format, pair.second.Scalar(), pair.first.Scalar()) && strict) if (cfg::try_to_enum_value(&value, &fmt_class_string<logs::level>::format, pair.second.Scalar()))
{ {
return false; values.emplace(pair.first.Scalar(), static_cast<logs::level>(static_cast<int>(value)));
} }
values.emplace(pair.first.Scalar(), static_cast<logs::level>(static_cast<int>(value)));
} }
static_cast<log_entry&>(rhs).set_map(std::move(values)); static_cast<log_entry&>(rhs).set_map(std::move(values));
@@ -586,43 +537,20 @@ bool cfg::decode(const YAML::Node& data, cfg::_base& rhs, bool dynamic, bool str
{ {
if (!data.IsMap()) if (!data.IsMap())
{ {
cfg_log.error("device node is not a map"); return; // ???
return false;
} }
map_of_type<device_info> values; map_of_type<device_info> values;
for (const auto& pair : data) for (const auto& pair : data)
{ {
if (!pair.first.IsScalar() || !pair.second.IsMap()) if (!pair.first.IsScalar() || !pair.second.IsMap()) continue;
{
if (strict)
{
if (!pair.first.IsScalar())
cfg_log.error("Key in device map is not a scalar");
else
cfg_log.error("Value in device map is not a map. key='%s'", pair.first.Scalar());
return false;
}
continue;
}
device_info info{}; device_info info{};
for (const auto& key_value : pair.second) for (const auto& key_value : pair.second)
{ {
if (!key_value.first.IsScalar() || !key_value.second.IsScalar()) if (!key_value.first.IsScalar() || !key_value.second.IsScalar()) continue;
{
if (strict)
{
if (!key_value.first.IsScalar())
cfg_log.error("Key in device info map is not a scalar");
else
cfg_log.error("Value in device map is not a scalar. key='%s'", key_value.first.Scalar());
return false;
}
continue;
}
if (key_value.first.Scalar() == "Path") if (key_value.first.Scalar() == "Path")
info.path = key_value.second.Scalar(); info.path = key_value.second.Scalar();
@@ -649,17 +577,12 @@ bool cfg::decode(const YAML::Node& data, cfg::_base& rhs, bool dynamic, bool str
if (YAML::convert<std::string>::decode(data, value)) if (YAML::convert<std::string>::decode(data, value))
{ {
if (!rhs.from_string(value, dynamic) && strict) rhs.from_string(value, dynamic);
{
return false;
}
} }
break; // ??? break; // ???
} }
} }
return true;
} }
std::string cfg::node::to_string() const std::string cfg::node::to_string() const
@@ -676,7 +599,8 @@ bool cfg::node::from_string(std::string_view value, bool dynamic)
if (error.empty()) if (error.empty())
{ {
return cfg::decode(result, *this, dynamic, false); cfg::decode(result, *this, dynamic);
return true;
} }
cfg_log.error("Failed to load node: %s", error); cfg_log.error("Failed to load node: %s", error);
@@ -699,19 +623,6 @@ void cfg::node::restore_defaults()
} }
} }
bool cfg::node::validate(std::string_view value)
{
auto [result, error] = yaml_load(std::string(value));
if (error.empty())
{
return cfg::decode(result, *this, false, true);
}
cfg_log.error("Failed to load node: %s", error);
return false;
}
std::string cfg::map_entry::get_value(std::string_view key) std::string cfg::map_entry::get_value(std::string_view key)
{ {
if (auto it = m_map.find(key); it != m_map.end()) if (auto it = m_map.find(key); it != m_map.end())
+12 -28
View File
@@ -25,14 +25,11 @@ namespace cfg
std::vector<std::string> make_float_range(f64 min, f64 max); std::vector<std::string> make_float_range(f64 min, f64 max);
// Internal hack // Internal hack
bool try_to_enum_value(u64* out, decltype(&fmt_class_string<int>::format) func, std::string_view value, std::string_view name = {}); bool try_to_enum_value(u64* out, decltype(&fmt_class_string<int>::format) func, std::string_view);
// Internal hack // Internal hack
std::vector<std::string> try_to_enum_list(decltype(&fmt_class_string<int>::format) func); std::vector<std::string> try_to_enum_list(decltype(&fmt_class_string<int>::format) func);
// Internal hack
size_t try_to_enum_size(decltype(&fmt_class_string<int>::format) func);
// Config tree entry type. // Config tree entry type.
enum class type : unsigned enum class type : unsigned
{ {
@@ -110,7 +107,7 @@ namespace cfg
} }
// Try to convert from string (optional) // Try to convert from string (optional)
virtual bool from_string(std::string_view value, bool dynamic = false); virtual bool from_string(std::string_view, bool /*dynamic*/ = false);
// Get string list (optional) // Get string list (optional)
virtual std::vector<std::string> to_list() const virtual std::vector<std::string> to_list() const
@@ -161,9 +158,6 @@ namespace cfg
// Restore default members // Restore default members
void restore_defaults() override; void restore_defaults() override;
// Try to convert from string and validate
bool validate(std::string_view value);
}; };
class _bool final : public _base class _bool final : public _base
@@ -304,7 +298,7 @@ namespace cfg
{ {
u64 result; u64 result;
if (try_to_enum_value(&result, &fmt_class_string<T>::format, value, m_name)) if (try_to_enum_value(&result, &fmt_class_string<T>::format, value))
{ {
// No narrowing check, it's hard to do right there // No narrowing check, it's hard to do right there
m_value = static_cast<T>(static_cast<std::underlying_type_t<T>>(result)); m_value = static_cast<T>(static_cast<std::underlying_type_t<T>>(result));
@@ -318,11 +312,6 @@ namespace cfg
{ {
return try_to_enum_list(&fmt_class_string<T>::format); return try_to_enum_list(&fmt_class_string<T>::format);
} }
size_t size() const
{
return try_to_enum_size(&fmt_class_string<T>::format);
}
}; };
// Signed 32/64-bit integer entry with custom Min/Max range. // Signed 32/64-bit integer entry with custom Min/Max range.
@@ -385,7 +374,7 @@ namespace cfg
bool from_string(std::string_view value, bool /*dynamic*/ = false) override bool from_string(std::string_view value, bool /*dynamic*/ = false) override
{ {
s64 result; s64 result;
if (try_to_int64(&result, value, Min, Max, m_name)) if (try_to_int64(&result, value, Min, Max))
{ {
m_value = static_cast<int_type>(result); m_value = static_cast<int_type>(result);
return true; return true;
@@ -396,7 +385,7 @@ namespace cfg
void set(const s64& value) void set(const s64& value)
{ {
if (value < Min || value > Max) fmt::throw_exception("'%s': value %d out of bounds (min=%d, max=%d)", m_name, value, Min, Max); ensure(value >= Min && value <= Max);
m_value = static_cast<int_type>(value); m_value = static_cast<int_type>(value);
} }
@@ -454,7 +443,7 @@ namespace cfg
std::string to_string() const override std::string to_string() const override
{ {
std::string result; std::string result;
if (try_to_string(&result, m_value, m_name)) if (try_to_string(&result, m_value))
{ {
return result; return result;
} }
@@ -465,7 +454,7 @@ namespace cfg
std::string def_to_string() const override std::string def_to_string() const override
{ {
std::string result; std::string result;
if (try_to_string(&result, def, m_name)) if (try_to_string(&result, def))
{ {
return result; return result;
} }
@@ -476,7 +465,7 @@ namespace cfg
bool from_string(std::string_view value, bool /*dynamic*/ = false) override bool from_string(std::string_view value, bool /*dynamic*/ = false) override
{ {
f64 result; f64 result;
if (try_to_float(&result, value, Min, Max, m_name)) if (try_to_float(&result, value, Min, Max))
{ {
m_value = static_cast<float_type>(result); m_value = static_cast<float_type>(result);
return true; return true;
@@ -487,7 +476,7 @@ namespace cfg
void set(const f64& value) void set(const f64& value)
{ {
if (value < Min || value > Max) fmt::throw_exception("'%s': value %d out of bounds (min=%d, max=%d)", m_name, value, Min, Max); ensure(value >= Min && value <= Max);
m_value = static_cast<float_type>(value); m_value = static_cast<float_type>(value);
} }
@@ -563,7 +552,7 @@ namespace cfg
bool from_string(std::string_view value, bool /*dynamic*/ = false) override bool from_string(std::string_view value, bool /*dynamic*/ = false) override
{ {
u64 result; u64 result;
if (try_to_uint64(&result, value, Min, Max, m_name)) if (try_to_uint64(&result, value, Min, Max))
{ {
m_value = static_cast<int_type>(result); m_value = static_cast<int_type>(result);
return true; return true;
@@ -574,7 +563,7 @@ namespace cfg
void set(const u64& value) void set(const u64& value)
{ {
if (value < Min || value > Max) fmt::throw_exception("'%s': value %d out of bounds (min=%d, max=%d)", m_name, value, Min, Max); ensure(value >= Min && value <= Max);
m_value = static_cast<int_type>(value); m_value = static_cast<int_type>(value);
} }
@@ -649,7 +638,7 @@ namespace cfg
bool from_string(std::string_view value, bool /*dynamic*/ = false) override bool from_string(std::string_view value, bool /*dynamic*/ = false) override
{ {
u128 result; u128 result;
if (try_to_uint128(&result, value, m_name)) if (try_to_uint128(&result, value))
{ {
m_value = result; m_value = result;
return true; return true;
@@ -717,11 +706,6 @@ namespace cfg
m_value = std::string(value); m_value = std::string(value);
return true; return true;
} }
void set(std::string_view value)
{
m_value = std::string(value);
}
}; };
// Simple set entry (TODO: template for various types) // Simple set entry (TODO: template for various types)
+14 -162
View File
@@ -38,17 +38,6 @@ static std::unique_ptr<wchar_t[]> to_wchar(std::string_view source)
// Buffer for max possible output length // Buffer for max possible output length
std::unique_ptr<wchar_t[]> buffer(new wchar_t[buf_size + 8 + 32768]); std::unique_ptr<wchar_t[]> buffer(new wchar_t[buf_size + 8 + 32768]);
// If path points to an optical raw device, copy it AS IS
if (fs::is_optical_raw_device(std::string(source)))
{
ensure(MultiByteToWideChar(CP_UTF8, 0, source.data(), size, buffer.get() + 32768, size)); // "to_wchar"
// Canonicalize wide path (replace '/', ".", "..", \\ repetitions, etc)
ensure(GetFullPathNameW(buffer.get() + 32768, 32768, buffer.get(), nullptr) - 1 < 32768 - 1); // "to_wchar"
return buffer;
}
// Prepend wide path prefix (4 characters) // Prepend wide path prefix (4 characters)
std::memcpy(buffer.get() + 32768, L"\\\\\?\\", 4 * sizeof(wchar_t)); std::memcpy(buffer.get() + 32768, L"\\\\\?\\", 4 * sizeof(wchar_t));
@@ -128,7 +117,6 @@ static fs::error to_error(DWORD e)
case ERROR_NEGATIVE_SEEK: return fs::error::inval; case ERROR_NEGATIVE_SEEK: return fs::error::inval;
case ERROR_DIRECTORY: return fs::error::inval; case ERROR_DIRECTORY: return fs::error::inval;
case ERROR_INVALID_NAME: return fs::error::inval; case ERROR_INVALID_NAME: return fs::error::inval;
case ERROR_INVALID_FUNCTION: return fs::error::inval;
case ERROR_SHARING_VIOLATION: return fs::error::acces; case ERROR_SHARING_VIOLATION: return fs::error::acces;
case ERROR_DIR_NOT_EMPTY: return fs::error::notempty; case ERROR_DIR_NOT_EMPTY: return fs::error::notempty;
case ERROR_NOT_READY: return fs::error::noent; case ERROR_NOT_READY: return fs::error::noent;
@@ -177,7 +165,6 @@ static fs::error to_error(int e)
case ENOTEMPTY: return fs::error::notempty; case ENOTEMPTY: return fs::error::notempty;
case EROFS: return fs::error::readonly; case EROFS: return fs::error::readonly;
case EISDIR: return fs::error::isdir; case EISDIR: return fs::error::isdir;
case ENOTDIR: return fs::error::notdir;
case ENOSPC: return fs::error::nospace; case ENOSPC: return fs::error::nospace;
case EXDEV: return fs::error::xdev; case EXDEV: return fs::error::xdev;
default: return fs::error::unknown; default: return fs::error::unknown;
@@ -411,12 +398,12 @@ namespace fs
class windows_file final : public file_base class windows_file final : public file_base
{ {
HANDLE m_handle; HANDLE m_handle;
bool m_raw_device; atomic_t<u64> m_pos;
atomic_t<u64> m_pos {0};
public: public:
windows_file(HANDLE handle, bool raw_device = false) windows_file(HANDLE handle)
: m_handle(handle), m_raw_device(raw_device) : m_handle(handle)
, m_pos(0)
{ {
} }
@@ -430,10 +417,10 @@ namespace fs
stat_t get_stat() override stat_t get_stat() override
{ {
FILE_BASIC_INFO basic_info {}; FILE_BASIC_INFO basic_info;
ensure(GetFileInformationByHandleEx(m_handle, FileBasicInfo, &basic_info, sizeof(FILE_BASIC_INFO))); // "file::stat" ensure(GetFileInformationByHandleEx(m_handle, FileBasicInfo, &basic_info, sizeof(FILE_BASIC_INFO))); // "file::stat"
stat_t info {}; stat_t info;
info.is_directory = (basic_info.FileAttributes & FILE_ATTRIBUTE_DIRECTORY) != 0; info.is_directory = (basic_info.FileAttributes & FILE_ATTRIBUTE_DIRECTORY) != 0;
info.is_writable = (basic_info.FileAttributes & FILE_ATTRIBUTE_READONLY) == 0; info.is_writable = (basic_info.FileAttributes & FILE_ATTRIBUTE_READONLY) == 0;
info.size = this->size(); info.size = this->size();
@@ -454,7 +441,7 @@ namespace fs
bool trunc(u64 length) override bool trunc(u64 length) override
{ {
FILE_END_OF_FILE_INFO _eof {}; FILE_END_OF_FILE_INFO _eof;
_eof.EndOfFile.QuadPart = length; _eof.EndOfFile.QuadPart = length;
if (!SetFileInformationByHandle(m_handle, FileEndOfFileInfo, &_eof, sizeof(_eof))) if (!SetFileInformationByHandle(m_handle, FileEndOfFileInfo, &_eof, sizeof(_eof)))
@@ -576,20 +563,10 @@ namespace fs
u64 size() override u64 size() override
{ {
if (!m_raw_device) LARGE_INTEGER size;
{ ensure(GetFileSizeEx(m_handle, &size)); // "file::size"
// NOTE: this can fail if we access a mounted empty drive (e.g. after unmounting an iso).
LARGE_INTEGER size;
ensure(GetFileSizeEx(m_handle, &size)); // "file::size" return size.QuadPart;
return size.QuadPart;
}
// For a raw device, we need to use DeviceIoControl.
DISK_GEOMETRY_EX geometry;
ensure(DeviceIoControl(m_handle, IOCTL_DISK_GET_DRIVE_GEOMETRY_EX, nullptr, 0, &geometry, sizeof(geometry), nullptr, nullptr));
return geometry.DiskSize.QuadPart;
} }
native_handle get_handle() override native_handle get_handle() override
@@ -602,12 +579,12 @@ namespace fs
file_id id{"windows_file"}; file_id id{"windows_file"};
id.data.resize(sizeof(FILE_ID_INFO)); id.data.resize(sizeof(FILE_ID_INFO));
FILE_ID_INFO info {}; FILE_ID_INFO info;
if (!GetFileInformationByHandleEx(m_handle, FileIdInfo, &info, sizeof(info))) if (!GetFileInformationByHandleEx(m_handle, FileIdInfo, &info, sizeof(info)))
{ {
// Try GetFileInformationByHandle as a fallback // Try GetFileInformationByHandle as a fallback
BY_HANDLE_FILE_INFORMATION info2{}; BY_HANDLE_FILE_INFORMATION info2;
ensure(GetFileInformationByHandle(m_handle, &info2)); ensure(GetFileInformationByHandle(m_handle, &info2));
info = {}; info = {};
@@ -648,7 +625,7 @@ namespace fs
struct ::stat file_info; struct ::stat file_info;
ensure(::fstat(m_fd, &file_info) == 0); // "file::stat" ensure(::fstat(m_fd, &file_info) == 0); // "file::stat"
stat_t info {}; stat_t info;
info.is_directory = S_ISDIR(file_info.st_mode); info.is_directory = S_ISDIR(file_info.st_mode);
info.is_writable = file_info.st_mode & 0200; // HACK: approximation info.is_writable = file_info.st_mode & 0200; // HACK: approximation
info.size = file_info.st_size; info.size = file_info.st_size;
@@ -924,22 +901,6 @@ std::string_view fs::get_parent_dir_view(std::string_view path, u32 parent_level
return result; return result;
} }
std::string fs::get_path_if_dir(const std::string& path)
{
if (path.empty() || !fs::is_dir(path))
{
return {};
}
// If delimiters are already present at the end of the string then nothing else to do
if (usz sz = path.find_last_of(delim); sz != umax && (sz + 1) == path.size())
{
return path;
}
return path + '/';
}
bool fs::get_stat(const std::string& path, stat_t& info) bool fs::get_stat(const std::string& path, stat_t& info)
{ {
// Ensure consistent information on failure // Ensure consistent information on failure
@@ -1112,55 +1073,6 @@ bool fs::is_symlink(const std::string& path)
return true; return true;
} }
bool fs::is_optical_raw_device([[maybe_unused]] const std::string& path)
{
#ifdef _WIN32
if (path.starts_with("\\\\.\\"))
{
return true;
}
#endif
return false;
}
bool fs::get_optical_raw_device(const std::string& path, std::string* raw_device)
{
if (fs::is_optical_raw_device(path))
{
if (raw_device)
{
*raw_device = path;
}
return true;
}
#ifdef _WIN32
// Skip a useless check to detect an optical raw device if navigating on subfolders (e.g. C:\subfolder_1\subfolder_2\),
// it means we are on a HDD/SSD. A path for an optical drive should include only the drive letter (e.g. E:\)
const size_t drive_delim_pos = path.find_first_of(":");
if (drive_delim_pos != 1 || drive_delim_pos != path.find_last_not_of(delim))
{
return false;
}
const std::string drive_letter = path.substr(0, drive_delim_pos + 1); // e.g. "E:"
const std::string drive_path = drive_letter + "\\"; // e.g. "E:\"
if (GetDriveTypeA(drive_path.c_str()) == DRIVE_CDROM)
{
if (raw_device)
{
*raw_device = "\\\\.\\" + drive_letter;
}
return true;
}
#endif
return false;
}
bool fs::statfs(const std::string& path, fs::device_stat& info) bool fs::statfs(const std::string& path, fs::device_stat& info)
{ {
if (auto device = get_virtual_device(path)) if (auto device = get_virtual_device(path))
@@ -1728,65 +1640,6 @@ fs::file::file(const std::string& path, bs_t<open_mode> mode)
return; return;
} }
// If path points to an optical raw device, complete the file opening
// (the following GetFileInformationByHandle() would always fail on a raw device).
if (is_optical_raw_device(path))
{
DISK_GEOMETRY_EX geometry;
// Try to retrieve information on content. If it fails, no disc is probably mounted so abort the file opening
if (!DeviceIoControl(handle, IOCTL_DISK_GET_DRIVE_GEOMETRY_EX, nullptr, 0, &geometry, sizeof(geometry), nullptr, nullptr))
{
const DWORD last_error = GetLastError();
CloseHandle(handle);
g_tls_error = to_error(last_error);
return;
}
m_file = std::make_unique<windows_file>(handle, true);
return;
}
// Check if the handle is actually valid.
// This can fail on empty mounted drives (e.g. with ERROR_NOT_READY or ERROR_INVALID_FUNCTION).
BY_HANDLE_FILE_INFORMATION info{};
if (!GetFileInformationByHandle(handle, &info))
{
const DWORD last_error = GetLastError();
CloseHandle(handle);
if (last_error == ERROR_INVALID_FUNCTION)
{
g_tls_error = fs::error::isdir;
return;
}
g_tls_error = to_error(last_error);
return;
}
if (info.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
{
CloseHandle(handle);
g_tls_error = fs::error::isdir;
return;
}
if (info.dwFileAttributes & FILE_ATTRIBUTE_SYSTEM)
{
CloseHandle(handle);
g_tls_error = fs::error::acces;
return;
}
if ((mode & fs::write) && (info.dwFileAttributes & FILE_ATTRIBUTE_READONLY))
{
CloseHandle(handle);
g_tls_error = fs::error::readonly;
return;
}
m_file = std::make_unique<windows_file>(handle); m_file = std::make_unique<windows_file>(handle);
#else #else
int flags = O_CLOEXEC; // Ensures all files are closed on execl for auto updater int flags = O_CLOEXEC; // Ensures all files are closed on execl for auto updater
@@ -2726,7 +2579,7 @@ bool fs::pending_file::commit(bool overwrite)
while (file_handle != INVALID_HANDLE_VALUE) while (file_handle != INVALID_HANDLE_VALUE)
{ {
// Get file ID (used to check for hardlinks) // Get file ID (used to check for hardlinks)
BY_HANDLE_FILE_INFORMATION file_info{}; BY_HANDLE_FILE_INFORMATION file_info;
if (!GetFileInformationByHandle(file_handle, &file_info) || file_info.nNumberOfLinks == 1) if (!GetFileInformationByHandle(file_handle, &file_info) || file_info.nNumberOfLinks == 1)
{ {
@@ -2924,7 +2777,6 @@ void fmt_class_string<fs::error>::format(std::string& out, u64 arg)
case fs::error::notempty: return "Not empty"; case fs::error::notempty: return "Not empty";
case fs::error::readonly: return "Read only"; case fs::error::readonly: return "Read only";
case fs::error::isdir: return "Is a directory"; case fs::error::isdir: return "Is a directory";
case fs::error::notdir: return "Not a directory";
case fs::error::toolong: return "Path too long"; case fs::error::toolong: return "Path too long";
case fs::error::nospace: return "Not enough space on the device"; case fs::error::nospace: return "Not enough space on the device";
case fs::error::xdev: return "Device mismatch"; case fs::error::xdev: return "Device mismatch";
+8 -20
View File
@@ -66,13 +66,13 @@ namespace fs
// File attributes (TODO) // File attributes (TODO)
struct stat_t struct stat_t
{ {
bool is_directory = false; bool is_directory;
bool is_symlink = false; bool is_symlink;
bool is_writable = false; bool is_writable;
u64 size = 0; u64 size;
s64 atime = 0; s64 atime;
s64 mtime = 0; s64 mtime;
s64 ctime = 0; s64 ctime;
using enable_bitcopy = std::true_type; using enable_bitcopy = std::true_type;
@@ -155,7 +155,7 @@ namespace fs
// Virtual device // Virtual device
struct device_base struct device_base
{ {
std::string fs_prefix; const std::string fs_prefix;
device_base(); device_base();
virtual ~device_base(); virtual ~device_base();
@@ -195,9 +195,6 @@ namespace fs
return std::string{get_parent_dir_view(path, parent_level)}; return std::string{get_parent_dir_view(path, parent_level)};
} }
// Return "path" plus an ending delimiter (if missing) if "path" is an existing directory. Otherwise, an empty string
std::string get_path_if_dir(const std::string& path);
// Get file information // Get file information
bool get_stat(const std::string& path, stat_t& info); bool get_stat(const std::string& path, stat_t& info);
@@ -213,12 +210,6 @@ namespace fs
// Check whether the path points to an existing symlink // Check whether the path points to an existing symlink
bool is_symlink(const std::string& path); bool is_symlink(const std::string& path);
// Check whether the path points to a raw device
bool is_optical_raw_device(const std::string& path);
// Check whether the path points to an optical drive. If so, provide the raw device in "raw_device" if requested
bool get_optical_raw_device(const std::string& path, std::string* raw_device = nullptr);
// Get filesystem information // Get filesystem information
bool statfs(const std::string& path, device_stat& info); bool statfs(const std::string& path, device_stat& info);
@@ -263,8 +254,6 @@ namespace fs
// Open file with specified mode // Open file with specified mode
explicit file(const std::string& path, bs_t<open_mode> mode = ::fs::read); explicit file(const std::string& path, bs_t<open_mode> mode = ::fs::read);
file(std::unique_ptr<file_base>&& ptr) : m_file(std::move(ptr)) {}
static file from_native_handle(native_handle handle); static file from_native_handle(native_handle handle);
// Open memory for read // Open memory for read
@@ -689,7 +678,6 @@ namespace fs
notempty, notempty,
readonly, readonly,
isdir, isdir,
notdir,
toolong, toolong,
nospace, nospace,
xdev, xdev,
-13
View File
@@ -493,10 +493,6 @@ inline FT build_function_asm(std::string_view name, F&& builder, ::jit_runtime*
return reinterpret_cast<FT>(uptr(result)); return reinterpret_cast<FT>(uptr(result));
} }
#if defined(__INTELLISENSE__) && !defined(LLVM_AVAILABLE)
#define LLVM_AVAILABLE
#endif
#ifdef LLVM_AVAILABLE #ifdef LLVM_AVAILABLE
namespace llvm namespace llvm
@@ -543,15 +539,9 @@ public:
// Add module (path to obj cache dir) // Add module (path to obj cache dir)
void add(std::unique_ptr<llvm::Module> _module, const std::string& path); void add(std::unique_ptr<llvm::Module> _module, const std::string& path);
// Returns false after LLVM fatal recovery. The compiler must be discarded.
bool try_add(std::unique_ptr<llvm::Module> _module, const std::string& path, std::string& error);
// Add module (not cached) // Add module (not cached)
void add(std::unique_ptr<llvm::Module> _module); void add(std::unique_ptr<llvm::Module> _module);
// Returns false after LLVM fatal recovery. The compiler must be discarded.
bool try_add(std::unique_ptr<llvm::Module> _module, std::string& error);
// Add object (path to obj file) // Add object (path to obj file)
bool add(const std::string& path); bool add(const std::string& path);
@@ -564,9 +554,6 @@ public:
// Finalize // Finalize
void fin(); void fin();
// Returns false after LLVM fatal recovery. The compiler must be discarded.
bool try_fin(std::string& error);
// Get compiled function address // Get compiled function address
u64 get(const std::string& name); u64 get(const std::string& name);
-4
View File
@@ -14,10 +14,6 @@
#define CAN_OVERCOMMIT #define CAN_OVERCOMMIT
#endif #endif
#if defined(__APPLE__)
#include <mutex>
#endif
LOG_CHANNEL(jit_log, "JIT"); LOG_CHANNEL(jit_log, "JIT");
void jit_announce(uptr func, usz size, std::string_view name) void jit_announce(uptr func, usz size, std::string_view name)
-131
View File
@@ -12,10 +12,6 @@
#include <charconv> #include <charconv>
#if defined(__APPLE__)
#include <pthread.h>
#endif
LOG_CHANNEL(jit_log, "JIT"); LOG_CHANNEL(jit_log, "JIT");
#ifdef LLVM_AVAILABLE #ifdef LLVM_AVAILABLE
@@ -54,44 +50,6 @@ LOG_CHANNEL(jit_log, "JIT");
#include "Emu/CPU/Backends/AArch64/AArch64Common.h" #include "Emu/CPU/Backends/AArch64/AArch64Common.h"
#endif #endif
namespace
{
thread_local std::string* g_llvm_fatal_message = nullptr;
template <typename F>
bool run_recoverable_llvm(F&& func, std::string& error)
{
error.clear();
// Run LLVM codegen in a disposable thread. If LLVM invokes the fatal
// handler, only this helper thread exits.
named_thread worker("LLVM JIT", [&]()
{
#if defined(__APPLE__)
pthread_jit_write_protect_np(false);
#endif
g_llvm_fatal_message = &error;
std::forward<F>(func)();
g_llvm_fatal_message = nullptr;
#if defined(__APPLE__)
pthread_jit_write_protect_np(true);
#endif
});
worker();
const bool result = static_cast<thread_state>(worker) == thread_state::finished;
if (!result && error.empty())
{
error = "LLVM crash recovery invoked";
}
return result;
}
}
const bool jit_initialize = []() -> bool const bool jit_initialize = []() -> bool
{ {
llvm::InitializeNativeTarget(); llvm::InitializeNativeTarget();
@@ -691,13 +649,6 @@ jit_compiler::jit_compiler(const std::unordered_map<std::string, u64>& _link, co
llvm::install_fatal_error_handler([](void*, const char* msg, bool) llvm::install_fatal_error_handler([](void*, const char* msg, bool)
{ {
const std::string_view out = msg ? msg : ""; const std::string_view out = msg ? msg : "";
if (g_llvm_fatal_message)
{
*g_llvm_fatal_message = out;
thread_ctrl::silent_exit();
}
fmt::throw_exception("LLVM Emergency Exit Invoked: '%s'", out); fmt::throw_exception("LLVM Emergency Exit Invoked: '%s'", out);
}, nullptr); }, nullptr);
@@ -737,30 +688,6 @@ jit_compiler::jit_compiler(const std::unordered_map<std::string, u64>& _link, co
mem = std::make_unique<MemoryManager1>(std::move(symbols_cement)); mem = std::make_unique<MemoryManager1>(std::move(symbols_cement));
} }
std::vector<std::string> attributes;
#if defined(ARCH_ARM64)
if (utils::has_sha3())
attributes.push_back("+sha3");
else
attributes.push_back("-sha3");
if (utils::has_dotprod())
attributes.push_back("+dotprod");
else
attributes.push_back("-dotprod");
if (utils::has_sve())
attributes.push_back("+sve");
else
attributes.push_back("-sve");
if (utils::has_sve2())
attributes.push_back("+sve2");
else
attributes.push_back("-sve2");
#endif
{ {
m_engine.reset(llvm::EngineBuilder(std::move(null_mod)) m_engine.reset(llvm::EngineBuilder(std::move(null_mod))
.setErrorStr(&result) .setErrorStr(&result)
@@ -772,7 +699,6 @@ jit_compiler::jit_compiler(const std::unordered_map<std::string, u64>& _link, co
//.setCodeModel(llvm::CodeModel::Large) //.setCodeModel(llvm::CodeModel::Large)
#endif #endif
.setRelocationModel(llvm::Reloc::Model::PIC_) .setRelocationModel(llvm::Reloc::Model::PIC_)
.setMAttrs(attributes)
.setMCPU(m_cpu) .setMCPU(m_cpu)
.create()); .create());
} }
@@ -837,33 +763,6 @@ void jit_compiler::add(std::unique_ptr<llvm::Module> _module, const std::string&
} }
} }
bool jit_compiler::try_add(std::unique_ptr<llvm::Module> _module, const std::string& path, std::string& error)
{
ObjectCache cache{path, this};
m_engine->setObjectCache(&cache);
const auto ptr = _module.get();
m_engine->addModule(std::move(_module));
if (!run_recoverable_llvm([&]()
{
m_engine->generateCodeForModule(ptr);
}, error))
{
return false;
}
m_engine->setObjectCache(nullptr);
for (auto& func : ptr->functions())
{
// Delete IR to lower memory consumption
func.deleteBody();
}
return true;
}
void jit_compiler::add(std::unique_ptr<llvm::Module> _module) void jit_compiler::add(std::unique_ptr<llvm::Module> _module)
{ {
const auto ptr = _module.get(); const auto ptr = _module.get();
@@ -877,28 +776,6 @@ void jit_compiler::add(std::unique_ptr<llvm::Module> _module)
} }
} }
bool jit_compiler::try_add(std::unique_ptr<llvm::Module> _module, std::string& error)
{
const auto ptr = _module.get();
m_engine->addModule(std::move(_module));
if (!run_recoverable_llvm([&]()
{
m_engine->generateCodeForModule(ptr);
}, error))
{
return false;
}
for (auto& func : ptr->functions())
{
// Delete IR to lower memory consumption
func.deleteBody();
}
return true;
}
bool jit_compiler::add(const std::string& path) bool jit_compiler::add(const std::string& path)
{ {
auto cache = ObjectCache::load(path); auto cache = ObjectCache::load(path);
@@ -950,14 +827,6 @@ void jit_compiler::fin()
m_engine->finalizeObject(); m_engine->finalizeObject();
} }
bool jit_compiler::try_fin(std::string& error)
{
return run_recoverable_llvm([&]()
{
m_engine->finalizeObject();
}, error);
}
u64 jit_compiler::get(const std::string& name) u64 jit_compiler::get(const std::string& name)
{ {
return m_engine->getGlobalValueAddress(name); return m_engine->getGlobalValueAddress(name);
+5 -85
View File
@@ -16,12 +16,12 @@
#include <errno.h> #include <errno.h>
#endif #endif
#ifdef __clang__ #ifdef _MSC_VER
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
#elif defined(_MSC_VER)
#pragma warning(push) #pragma warning(push)
#pragma warning(disable : 4996) #pragma warning(disable : 4996)
#elif defined(__clang__)
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
#else #else
#pragma GCC diagnostic push #pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdeprecated-declarations" #pragma GCC diagnostic ignored "-Wdeprecated-declarations"
@@ -83,8 +83,7 @@ std::string fmt::win_error_to_string(unsigned long error, void* module_handle)
if (FormatMessageW((module_handle ? FORMAT_MESSAGE_FROM_HMODULE : FORMAT_MESSAGE_FROM_SYSTEM) | FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_IGNORE_INSERTS, if (FormatMessageW((module_handle ? FORMAT_MESSAGE_FROM_HMODULE : FORMAT_MESSAGE_FROM_SYSTEM) | FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_IGNORE_INSERTS,
module_handle, error, 0, reinterpret_cast<LPWSTR>(&message_buffer), 0, nullptr)) module_handle, error, 0, reinterpret_cast<LPWSTR>(&message_buffer), 0, nullptr))
{ {
const std::string utf8 = wchar_to_utf8(message_buffer); message = fmt::format("%s (0x%x)", fmt::trim(wchar_to_utf8(message_buffer), " \t\n\r\f\v"), error);
message = fmt::format("%s (0x%x)", fmt::trim_sv(utf8, " \t\n\r\f\v"), error);
} }
else else
{ {
@@ -824,50 +823,6 @@ std::vector<std::string> fmt::split(std::string_view source, std::initializer_li
return result; return result;
} }
std::vector<std::string_view> fmt::split_sv(std::string_view source, std::initializer_list<std::string_view> separators, bool is_skip_empty)
{
std::vector<std::string_view> result;
for (usz index = 0; index < source.size();)
{
usz pos = -1;
usz sep_size = 0;
for (auto& separator : separators)
{
if (usz pos0 = source.find(separator, index); pos0 < pos)
{
pos = pos0;
sep_size = separator.size();
}
}
if (!sep_size)
{
result.emplace_back(&source[index], source.size() - index);
return result;
}
std::string_view piece = {&source[index], pos - index};
index = pos + sep_size;
if (piece.empty() && is_skip_empty)
{
continue;
}
result.emplace_back(std::move(piece));
}
if (result.empty() && !is_skip_empty)
{
result.emplace_back();
}
return result;
}
std::string fmt::trim(const std::string& source, std::string_view values) std::string fmt::trim(const std::string& source, std::string_view values)
{ {
const usz begin = source.find_first_not_of(values); const usz begin = source.find_first_not_of(values);
@@ -883,21 +838,6 @@ std::string fmt::trim(const std::string& source, std::string_view values)
return source.substr(begin, end + 1 - begin); return source.substr(begin, end + 1 - begin);
} }
std::string_view fmt::trim_sv(std::string_view source, std::string_view values)
{
const usz begin = source.find_first_not_of(values);
if (begin == source.npos)
return {};
const usz end = source.find_last_not_of(values);
if (end == source.npos)
return source.substr(begin);
return source.substr(begin, end + 1 - begin);
}
std::string fmt::trim_front(const std::string& source, std::string_view values) std::string fmt::trim_front(const std::string& source, std::string_view values)
{ {
const usz begin = source.find_first_not_of(values); const usz begin = source.find_first_not_of(values);
@@ -908,32 +848,12 @@ std::string fmt::trim_front(const std::string& source, std::string_view values)
return source.substr(begin); return source.substr(begin);
} }
std::string_view fmt::trim_front_sv(std::string_view source, std::string_view values)
{
const usz begin = source.find_first_not_of(values);
if (begin == source.npos)
return {};
return source.substr(begin);
}
void fmt::trim_back(std::string& source, std::string_view values) void fmt::trim_back(std::string& source, std::string_view values)
{ {
const usz index = source.find_last_not_of(values); const usz index = source.find_last_not_of(values);
source.resize(index + 1); source.resize(index + 1);
} }
std::string_view fmt::trim_back_sv(std::string_view source, std::string_view values)
{
const usz index = source.find_last_not_of(values);
if (index == std::string_view::npos)
return {};
source.remove_suffix(source.size() - (index + 1));
return source;
}
std::string fmt::to_upper(std::string_view string) std::string fmt::to_upper(std::string_view string)
{ {
std::string result; std::string result;
+17 -50
View File
@@ -13,29 +13,29 @@ std::string wchar_to_utf8(std::wstring_view src);
std::string utf16_to_utf8(std::u16string_view src); std::string utf16_to_utf8(std::u16string_view src);
std::u16string utf8_to_utf16(std::string_view src); std::u16string utf8_to_utf16(std::string_view src);
// Copy null-terminated string from a std::basic_string or a char array to a char array with truncation // Copy null-terminated string from a std::string or a char array to a char array with truncation
template <typename D, typename T> requires requires (D& d, T& t) { std::declval<decltype(&t[0])&>() = &d[0]; } template <typename D, typename T>
inline void strcpy_trunc(D&& dst, const T& src) inline void strcpy_trunc(D&& dst, const T& src)
{ {
const usz count = std::size(src) >= std::size(dst) ? std::max<usz>(std::size(dst), 1) - 1 : std::size(src); const usz count = std::size(src) >= std::size(dst) ? std::max<usz>(std::size(dst), 1) - 1 : std::size(src);
std::copy_n(std::data(src), count, std::data(dst)); std::memcpy(std::data(dst), std::data(src), count);
std::fill_n(std::data(dst) + count, std::size(dst) - count, std::remove_cvref_t<decltype(dst[0])>{}); std::memset(std::data(dst) + count, 0, std::size(dst) - count);
} }
// Convert string to signed integer // Convert string to signed integer
bool try_to_int64(s64* out, std::string_view value, s64 min, s64 max, std::string_view name = {}); bool try_to_int64(s64* out, std::string_view value, s64 min, s64 max);
// Convert string to unsigned integer // Convert string to unsigned integer
bool try_to_uint64(u64* out, std::string_view value, u64 min, u64 max, std::string_view name = {}); bool try_to_uint64(u64* out, std::string_view value, u64 min, u64 max);
// Convert string to unsigned int128_t // Convert string to unsigned int128_t
bool try_to_uint128(u128* out, std::string_view value, std::string_view name = {}); bool try_to_uint128(u128* out, std::string_view value);
// Convert string to float // Convert string to float
bool try_to_float(f64* out, std::string_view value, f64 min, f64 max, std::string_view name = {}); bool try_to_float(f64* out, std::string_view value, f64 min, f64 max);
// Convert float to string locale independent // Convert float to string locale independent
bool try_to_string(std::string* out, f64 value, std::string_view name = {}); bool try_to_string(std::string* out, const f64& value);
// Get the file extension of a file path ("png", "jpg", etc.) // Get the file extension of a file path ("png", "jpg", etc.)
std::string get_file_extension(const std::string& file_path); std::string get_file_extension(const std::string& file_path);
@@ -139,90 +139,57 @@ namespace fmt
// Splits the string into a vector of strings using the separators. The vector may contain empty strings unless is_skip_empty is true. // Splits the string into a vector of strings using the separators. The vector may contain empty strings unless is_skip_empty is true.
std::vector<std::string> split(std::string_view source, std::initializer_list<std::string_view> separators, bool is_skip_empty = true); std::vector<std::string> split(std::string_view source, std::initializer_list<std::string_view> separators, bool is_skip_empty = true);
// Splits the string_view into a vector of string_views using the separators. The vector may contain empty string_views unless is_skip_empty is true.
std::vector<std::string_view> split_sv(std::string_view source, std::initializer_list<std::string_view> separators, bool is_skip_empty = true);
// Removes all preceding and trailing characters specified by 'values' from 'source'. // Removes all preceding and trailing characters specified by 'values' from 'source'.
std::string trim(const std::string& source, std::string_view values = " \t"); std::string trim(const std::string& source, std::string_view values = " \t");
// Removes all preceding and trailing characters specified by 'values' from 'source' and returns the result.
std::string_view trim_sv(std::string_view source, std::string_view values = " \t");
// Removes all preceding characters specified by 'values' from 'source'. // Removes all preceding characters specified by 'values' from 'source'.
std::string trim_front(const std::string& source, std::string_view values = " \t"); std::string trim_front(const std::string& source, std::string_view values = " \t");
// Removes all preceding characters specified by 'values' from 'source' and returns the result.
std::string_view trim_front_sv(std::string_view source, std::string_view values = " \t");
// Removes all trailing characters specified by 'values' from 'source'. // Removes all trailing characters specified by 'values' from 'source'.
void trim_back(std::string& source, std::string_view values = " \t"); void trim_back(std::string& source, std::string_view values = " \t");
// Removes all trailing characters specified by 'values' from 'source' and returns the result.
std::string_view trim_back_sv(std::string_view source, std::string_view values = " \t");
template <typename T> template <typename T>
std::string merge(const T& source, std::string_view separator) std::string merge(const T& source, const std::string& separator)
{ {
if (source.empty()) if (source.empty())
{ {
return {}; return {};
} }
usz total = (source.size() - 1) * separator.size();
for (const auto& s : source)
{
total += s.size();
}
std::string result; std::string result;
result.reserve(total);
auto it = source.begin(); auto it = source.begin();
auto end = source.end(); auto end = source.end();
for (--end; it != end; ++it) for (--end; it != end; ++it)
{ {
result.append(*it); result += std::string{*it} + separator;
if (!separator.empty())
result.append(separator);
} }
return result.append(*end); return result + std::string{source.back()};
} }
template <typename T> template <typename T>
std::string merge(std::initializer_list<T> sources, std::string_view separator) std::string merge(std::initializer_list<T> sources, const std::string& separator)
{ {
if (!sources.size()) if (!sources.size())
{ {
return {}; return {};
} }
usz total = (sources.size() - 1) * separator.size();
for (const auto& s : sources)
{
if (s.empty()) continue;
total += s.size() + (s.size() - 1) * separator.size();
}
std::string result; std::string result;
result.reserve(total);
bool first = true; bool first = true;
for (const auto& v : sources) for (const auto& v : sources)
{ {
if (first) if (first)
{ {
first = false; result = fmt::merge(v, separator);
first = false;
} }
else if (!separator.empty()) else
{ {
result.append(separator); result += separator + fmt::merge(v, separator);
} }
result.append(fmt::merge(v, separator));
} }
return result; return result;
+35 -235
View File
@@ -8,24 +8,19 @@
#include "Emu/RSX/RSXThread.h" #include "Emu/RSX/RSXThread.h"
#include "Thread.h" #include "Thread.h"
#include "Utilities/JIT.h" #include "Utilities/JIT.h"
#include <thread>
#include <cfenv> #include <cfenv>
#ifdef ARCH_ARM64 #ifdef ARCH_ARM64
#include "Emu/CPU/Backends/AArch64/AArch64Signal.h" #include "Emu/CPU/Backends/AArch64/AArch64Signal.h"
#endif #endif
#ifdef __cpp_lib_stacktrace
#include "rpcs3_version.h"
#include <stacktrace>
#endif
#ifdef _WIN32 #ifdef _WIN32
#include <Windows.h> #include <Windows.h>
#include <Psapi.h> #include <Psapi.h>
#include <process.h> #include <process.h>
#include <sysinfoapi.h> #include <sysinfoapi.h>
#include "stack_trace.h"
#include "util/dyn_lib.hpp" #include "util/dyn_lib.hpp"
DYNAMIC_IMPORT_RENAME("Kernel32.dll", SetThreadDescriptionImport, "SetThreadDescription", HRESULT(HANDLE hThread, PCWSTR lpThreadDescription)); DYNAMIC_IMPORT_RENAME("Kernel32.dll", SetThreadDescriptionImport, "SetThreadDescription", HRESULT(HANDLE hThread, PCWSTR lpThreadDescription));
@@ -108,7 +103,7 @@ thread_local u64 g_tls_fault_rsx = 0;
thread_local u64 g_tls_fault_spu = 0; thread_local u64 g_tls_fault_spu = 0;
thread_local u64 g_tls_wait_time = 0; thread_local u64 g_tls_wait_time = 0;
thread_local u64 g_tls_wait_fail = 0; thread_local u64 g_tls_wait_fail = 0;
thread_local u64 g_tls_access_violation_recovered = umax; thread_local bool g_tls_access_violation_recovered = false;
extern thread_local std::string(*g_tls_log_prefix)(); extern thread_local std::string(*g_tls_log_prefix)();
namespace stx namespace stx
@@ -1270,7 +1265,7 @@ namespace rsx
extern std::function<bool(u32 addr, bool is_writing)> g_access_violation_handler; extern std::function<bool(u32 addr, bool is_writing)> g_access_violation_handler;
} }
bool handle_access_violation(u32 addr, bool is_writing, bool is_exec, ucontext_t* context) noexcept bool handle_access_violation(u32 addr, bool is_writing, ucontext_t* context) noexcept
{ {
g_tls_fault_all++; g_tls_fault_all++;
@@ -1306,7 +1301,7 @@ bool handle_access_violation(u32 addr, bool is_writing, bool is_exec, ucontext_t
} }
} spu_protection{cpu}; } spu_protection{cpu};
if (!is_exec && addr < RAW_SPU_BASE_ADDR && vm::check_addr(addr) && rsx::g_access_violation_handler) if (addr < RAW_SPU_BASE_ADDR && vm::check_addr(addr) && rsx::g_access_violation_handler)
{ {
bool state_changed = false; bool state_changed = false;
@@ -1372,7 +1367,7 @@ bool handle_access_violation(u32 addr, bool is_writing, bool is_exec, ucontext_t
{ {
auto thread = idm::get_unlocked<named_thread<spu_thread>>(spu_thread::find_raw_spu((addr - RAW_SPU_BASE_ADDR) / RAW_SPU_OFFSET)); auto thread = idm::get_unlocked<named_thread<spu_thread>>(spu_thread::find_raw_spu((addr - RAW_SPU_BASE_ADDR) / RAW_SPU_OFFSET));
if (!thread || is_exec) if (!thread)
{ {
break; break;
} }
@@ -1384,7 +1379,11 @@ bool handle_access_violation(u32 addr, bool is_writing, bool is_exec, ucontext_t
return false; return false;
} }
bool handled = true; if (a_size != 4)
{
// Might be unimplemented, such as writing MFC proxy EAL+EAH using 64-bit store
break;
}
switch (op) switch (op)
{ {
@@ -1394,37 +1393,14 @@ bool handle_access_violation(u32 addr, bool is_writing, bool is_exec, ucontext_t
case X64OP_LOAD_TEST: case X64OP_LOAD_TEST:
{ {
u32 value; u32 value;
const u32 addr_aligned = addr & -4; if (is_writing || !thread->read_reg(addr, value))
if (addr % 4 + a_size > 4)
{
handled = false;
break;
}
if (is_writing || !thread->read_reg(addr_aligned, value))
{ {
return false; return false;
} }
// Adjust value for 8-bit and 16-bit reads
value >>= ((4 - a_size) * 8) - ((addr % 4) * 8);
value &= a_size == 4 ? u32{umax} : ((1u << (a_size * 8)) - 1);
if (op != X64OP_LOAD_BE) if (op != X64OP_LOAD_BE)
{ {
if (a_size == 4) value = stx::se_storage<u32>::swap(value);
{
value = stx::se_storage<u32>::swap(value);
}
else if (a_size == 2)
{
value = stx::se_storage<u16>::swap(value);
}
else
{
ensure(a_size == 1);
}
} }
if (op == X64OP_LOAD_CMP) if (op == X64OP_LOAD_CMP)
@@ -1459,35 +1435,12 @@ bool handle_access_violation(u32 addr, bool is_writing, bool is_exec, ucontext_t
case X64OP_BEXTR: case X64OP_BEXTR:
{ {
u32 value; u32 value;
const u32 addr_aligned = addr & -4; if (is_writing || !thread->read_reg(addr, value))
if (addr % 4 + a_size > 4)
{
handled = false;
break;
}
if (is_writing || !thread->read_reg(addr_aligned, value))
{ {
return false; return false;
} }
// Adjust value for 8-bit and 16-bit reads value = stx::se_storage<u32>::swap(value);
value >>= ((4 - a_size) * 8) - ((addr % 4) * 8);
value &= a_size == 4 ? u32{umax} : ((1u << (a_size * 8)) - 1);
if (a_size == 4)
{
value = stx::se_storage<u32>::swap(value);
}
else if (a_size == 2)
{
value = stx::se_storage<u16>::swap(value);
}
else
{
ensure(a_size == 1);
}
u64 ctrl; u64 ctrl;
if (!get_x64_reg_value(context, s_tls_reg3, d_size, i_size, ctrl)) if (!get_x64_reg_value(context, s_tls_reg3, d_size, i_size, ctrl))
@@ -1513,13 +1466,6 @@ bool handle_access_violation(u32 addr, bool is_writing, bool is_exec, ucontext_t
case X64OP_STORE: case X64OP_STORE:
case X64OP_STORE_BE: case X64OP_STORE_BE:
{ {
if (a_size != 4)
{
// Might be unimplemented, such as writing MFC proxy EAL+EAH using 64-bit store
handled = false;
break;
}
u64 reg_value; u64 reg_value;
if (!is_writing || !get_x64_reg_value(context, reg, d_size, i_size, reg_value)) if (!is_writing || !get_x64_reg_value(context, reg, d_size, i_size, reg_value))
{ {
@@ -1538,19 +1484,12 @@ bool handle_access_violation(u32 addr, bool is_writing, bool is_exec, ucontext_t
case X64OP_STOS: case X64OP_STOS:
default: default:
{ {
sig_log.error("Invalid or unsupported operation (op=%d, addr=0x%x, reg=%d, d_size=%lld, i_size=%lld, a_size=%d)", +op, addr, +reg, d_size, i_size, a_size); sig_log.error("Invalid or unsupported operation (op=%d, reg=%d, d_size=%lld, i_size=%lld)", +op, +reg, d_size, i_size);
report_opcode(); report_opcode();
return false; return false;
} }
} }
if (!handled)
{
sig_log.error("Invalid or unsupported operation (op=%d, addr=0x%x, reg=%d, d_size=%lld, i_size=%lld, a_size=%d)", +op, addr, +reg, d_size, i_size, a_size);
report_opcode();
break;
}
// skip processed instruction // skip processed instruction
RIP(context) += i_size; RIP(context) += i_size;
g_tls_fault_spu++; g_tls_fault_spu++;
@@ -1560,9 +1499,7 @@ bool handle_access_violation(u32 addr, bool is_writing, bool is_exec, ucontext_t
static_cast<void>(context); static_cast<void>(context);
#endif /* ARCH_ */ #endif /* ARCH_ */
const auto required_page_perms = (is_writing ? vm::page_writable : vm::page_readable) + (is_exec ? vm::page_executable : 0); if (vm::check_addr(addr, is_writing ? vm::page_writable : vm::page_readable))
if (vm::check_addr(addr, required_page_perms))
{ {
return true; return true;
} }
@@ -1570,7 +1507,9 @@ bool handle_access_violation(u32 addr, bool is_writing, bool is_exec, ucontext_t
// Hack: allocate memory in case the emulator is stopping // Hack: allocate memory in case the emulator is stopping
const auto hack_alloc = [&]() const auto hack_alloc = [&]()
{ {
if (vm::check_addr(addr, required_page_perms)) g_tls_access_violation_recovered = true;
if (vm::check_addr(addr, is_writing ? vm::page_writable : vm::page_readable))
{ {
return true; return true;
} }
@@ -1582,45 +1521,17 @@ bool handle_access_violation(u32 addr, bool is_writing, bool is_exec, ucontext_t
return false; return false;
} }
extern void ppu_register_range(u32 addr, u32 size);
bool reprotected = false;
if (vm::writer_lock mlock; area->flags & vm::preallocated || vm::check_addr(addr, 0)) if (vm::writer_lock mlock; area->flags & vm::preallocated || vm::check_addr(addr, 0))
{ {
// For allocated memory with protection lower than required (such as protection::no or read-only while writing to it) // For allocated memory with protection lower than required (such as protection::no or read-only while writing to it)
utils::memory_protect(vm::base(addr & -0x1000), 0x1000, utils::protection::rw); utils::memory_protect(vm::base(addr & -0x1000), 0x1000, utils::protection::rw);
reprotected = true;
}
if (reprotected)
{
if (is_exec && !vm::check_addr(addr, vm::page_executable))
{
ppu_register_range(addr & -0x10000, 0x10000);
}
g_tls_access_violation_recovered = addr;
return true; return true;
} }
const bool allocated = area->falloc(addr & -0x10000, 0x10000); return area->falloc(addr & -0x10000, 0x10000) || vm::check_addr(addr, is_writing ? vm::page_writable : vm::page_readable);
if (allocated)
{
if (is_exec && !vm::check_addr(addr, vm::page_executable))
{
ppu_register_range(addr & -0x10000, 0x10000);
}
g_tls_access_violation_recovered = addr;
return true;
}
return false;
}; };
if (cpu && (cpu->get_class() == thread_class::ppu || cpu->get_class() == thread_class::spu) && !is_exec) if (cpu && (cpu->get_class() == thread_class::ppu || cpu->get_class() == thread_class::spu))
{ {
vm::temporary_unlock(*cpu); vm::temporary_unlock(*cpu);
u32 pf_port_id = 0; u32 pf_port_id = 0;
@@ -1763,7 +1674,7 @@ bool handle_access_violation(u32 addr, bool is_writing, bool is_exec, ucontext_t
if (cpu->get_class() == thread_class::spu) if (cpu->get_class() == thread_class::spu)
{ {
if (g_tls_access_violation_recovered != addr) if (!g_tls_access_violation_recovered)
{ {
vm_log.notice("\n%s", dump_useful_thread_info()); vm_log.notice("\n%s", dump_useful_thread_info());
vm_log.always()("[%s] Access violation %s location 0x%x (%s)", cpu->get_name(), is_writing ? "writing" : "reading", addr, (is_writing && vm::check_addr(addr)) ? "read-only memory" : "unmapped memory"); vm_log.always()("[%s] Access violation %s location 0x%x (%s)", cpu->get_name(), is_writing ? "writing" : "reading", addr, (is_writing && vm::check_addr(addr)) ? "read-only memory" : "unmapped memory");
@@ -1799,10 +1710,10 @@ bool handle_access_violation(u32 addr, bool is_writing, bool is_exec, ucontext_t
// Note: a thread may access violate more than once after hack_alloc recovery // Note: a thread may access violate more than once after hack_alloc recovery
// Do not log any further access violations in this case. // Do not log any further access violations in this case.
if (g_tls_access_violation_recovered != addr) if (!g_tls_access_violation_recovered)
{ {
vm_log.notice("\n%s", dump_useful_thread_info()); vm_log.notice("\n%s", dump_useful_thread_info());
vm_log.fatal("Access violation %s location 0x%x (%s)", is_writing ? "writing" : (is_exec ? "executing" : "reading"), addr, (is_writing && vm::check_addr(addr)) ? "read-only memory" : "unmapped memory"); vm_log.fatal("Access violation %s location 0x%x (%s)", is_writing ? "writing" : (cpu && cpu->get_class() == thread_class::ppu && cpu->get_pc() == addr ? "executing" : "reading"), addr, (is_writing && vm::check_addr(addr)) ? "read-only memory" : "unmapped memory");
} }
while (Emu.IsPausedOrReady()) while (Emu.IsPausedOrReady())
@@ -1851,13 +1762,8 @@ bool handle_access_violation(u32 addr, bool is_writing, bool is_exec, ucontext_t
} }
} }
if (Emu.IsStopped()) if (Emu.IsStopped() && !hack_alloc())
{ {
while (!hack_alloc())
{
thread_ctrl::wait_for(1000);
}
return false; return false;
} }
@@ -1896,7 +1802,6 @@ static LONG exception_handler(PEXCEPTION_POINTERS pExp) noexcept
if (pExp->ExceptionRecord->ExceptionCode == EXCEPTION_ACCESS_VIOLATION && !is_executing) if (pExp->ExceptionRecord->ExceptionCode == EXCEPTION_ACCESS_VIOLATION && !is_executing)
{ {
u32 addr = 0; u32 addr = 0;
bool is_exec = false;
if (auto [addr0, ok] = vm::try_get_addr(ptr); ok) if (auto [addr0, ok] = vm::try_get_addr(ptr); ok)
{ {
@@ -1904,21 +1809,14 @@ static LONG exception_handler(PEXCEPTION_POINTERS pExp) noexcept
} }
else if (const usz exec64 = (ptr - vm::g_exec_addr) / 2; exec64 <= u32{umax}) else if (const usz exec64 = (ptr - vm::g_exec_addr) / 2; exec64 <= u32{umax})
{ {
is_exec = true;
addr = static_cast<u32>(exec64); addr = static_cast<u32>(exec64);
} }
else if (const usz exec64 = (ptr - vm::g_exec_addr - vm::g_exec_addr_seg_offset); exec64 <= u32{umax}) else
{ {
is_exec = true;
addr = static_cast<u32>(exec64);
}
else
{
std::this_thread::sleep_for(1ms);
return EXCEPTION_CONTINUE_SEARCH; return EXCEPTION_CONTINUE_SEARCH;
} }
if (thread_ctrl::get_current() && handle_access_violation(addr, is_writing, is_exec, pExp->ContextRecord)) if (thread_ctrl::get_current() && handle_access_violation(addr, is_writing, pExp->ContextRecord))
{ {
return EXCEPTION_CONTINUE_EXECUTION; return EXCEPTION_CONTINUE_EXECUTION;
} }
@@ -2038,39 +1936,9 @@ static LONG exception_filter(PEXCEPTION_POINTERS pExp) noexcept
} }
fmt::append(msg, "RPCS3 image base: %p.\n", GetModuleHandle(NULL)); fmt::append(msg, "RPCS3 image base: %p.\n", GetModuleHandle(NULL));
#if defined(ARCH_X64)
fmt::append(msg, "RAX: %016llX RBX: %016llX\n", pExp->ContextRecord->Rax, pExp->ContextRecord->Rbx);
fmt::append(msg, "RCX: %016llX RDX: %016llX\n", pExp->ContextRecord->Rcx, pExp->ContextRecord->Rdx);
fmt::append(msg, "RSI: %016llX RDI: %016llX\n", pExp->ContextRecord->Rsi, pExp->ContextRecord->Rdi);
fmt::append(msg, "RBP: %016llX RSP: %016llX\n", pExp->ContextRecord->Rbp, pExp->ContextRecord->Rsp);
fmt::append(msg, "R8: %016llX R9: %016llX\n", pExp->ContextRecord->R8, pExp->ContextRecord->R9);
fmt::append(msg, "R10: %016llX R11: %016llX\n", pExp->ContextRecord->R10, pExp->ContextRecord->R11);
fmt::append(msg, "R12: %016llX R13: %016llX\n", pExp->ContextRecord->R12, pExp->ContextRecord->R13);
fmt::append(msg, "R14: %016llX R15: %016llX\n", pExp->ContextRecord->R14, pExp->ContextRecord->R15);
fmt::append(msg, "RFLAGS: %08X\n", pExp->ContextRecord->EFlags);
#elif defined(ARCH_ARM64)
for (int i = 0; i < 29; i += 2)
{
if (i + 1 < 29)
fmt::append(msg, "X%-2d: %016llX X%-2d: %016llX\n", i, pExp->ContextRecord->X[i], i + 1, pExp->ContextRecord->X[i + 1]);
else
fmt::append(msg, "X%-2d: %016llX\n", i, pExp->ContextRecord->X[i]);
}
fmt::append(msg, "SP: %016llX FP: %016llX LR: %016llX\n", pExp->ContextRecord->Sp, pExp->ContextRecord->Fp, pExp->ContextRecord->Lr);
fmt::append(msg, "CPSR: %08X\n", pExp->ContextRecord->Cpsr);
#endif
const auto stack_trace = utils::get_backtrace(64, pExp->ContextRecord); // TODO: print registers and the callstack
const auto stack_symbols = utils::get_backtrace_symbols(stack_trace);
msg += "Stack Trace:\n";
for (const auto& symbol : stack_symbols)
{
fmt::append(msg, "%s\n", symbol);
}
sys_log.fatal("\n%s", msg); sys_log.fatal("\n%s", msg);
logs::listener::sync_all(); logs::listener::sync_all();
@@ -2155,13 +2023,12 @@ static void signal_handler(int /*sig*/, siginfo_t* info, void* uct) noexcept
#endif #endif
const u64 exec64 = (reinterpret_cast<u64>(info->si_addr) - reinterpret_cast<u64>(vm::g_exec_addr)) / 2; const u64 exec64 = (reinterpret_cast<u64>(info->si_addr) - reinterpret_cast<u64>(vm::g_exec_addr)) / 2;
const u64 exec64_2 = (reinterpret_cast<u64>(info->si_addr) - reinterpret_cast<u64>(vm::g_exec_addr)) - vm::g_exec_addr_seg_offset;
const auto cause = is_executing ? "executing" : is_writing ? "writing" : "reading"; const auto cause = is_executing ? "executing" : is_writing ? "writing" : "reading";
if (auto [addr, ok] = vm::try_get_addr(info->si_addr); ok && !is_executing) if (auto [addr, ok] = vm::try_get_addr(info->si_addr); ok && !is_executing)
{ {
// Try to process access violation // Try to process access violation
if (thread_ctrl::get_current() && handle_access_violation(addr, is_writing, false, context)) if (thread_ctrl::get_current() && handle_access_violation(addr, is_writing, context))
{ {
return; return;
} }
@@ -2169,14 +2036,7 @@ static void signal_handler(int /*sig*/, siginfo_t* info, void* uct) noexcept
if (exec64 < 0x100000000ull && !is_executing) if (exec64 < 0x100000000ull && !is_executing)
{ {
if (thread_ctrl::get_current() && handle_access_violation(static_cast<u32>(exec64), is_writing, true, context)) if (thread_ctrl::get_current() && handle_access_violation(static_cast<u32>(exec64), is_writing, context))
{
return;
}
}
else if (exec64_2 < 0x100000000ull && !is_executing)
{
if (thread_ctrl::get_current() && handle_access_violation(static_cast<u32>(exec64_2), is_writing, true, context))
{ {
return; return;
} }
@@ -2305,17 +2165,10 @@ void thread_base::start()
ensure(m_thread); ensure(m_thread);
ensure(::ResumeThread(reinterpret_cast<HANDLE>(+m_thread)) != static_cast<DWORD>(-1)); ensure(::ResumeThread(reinterpret_cast<HANDLE>(+m_thread)) != static_cast<DWORD>(-1));
#elif defined(__APPLE__) #elif defined(__APPLE__)
pthread_attr_t attrs; pthread_attr_t stack_size_attr;
struct sched_param sp; pthread_attr_init(&stack_size_attr);
memset(&sp, 0, sizeof(struct sched_param)); pthread_attr_setstacksize(&stack_size_attr, 0x800000);
sp.sched_priority=99; ensure(pthread_create(reinterpret_cast<pthread_t*>(&m_thread.raw()), &stack_size_attr, entry_point, this) == 0);
pthread_attr_init(&attrs);
pthread_attr_setstacksize(&attrs, 0x800000);
pthread_attr_set_qos_class_np(&attrs, QOS_CLASS_USER_INTERACTIVE, 0);
pthread_attr_setschedpolicy(&attrs, SCHED_RR);
pthread_attr_setschedparam(&attrs, &sp);
ensure(pthread_create(reinterpret_cast<pthread_t*>(&m_thread.raw()), &attrs, entry_point, this) == 0);
#else #else
ensure(pthread_create(reinterpret_cast<pthread_t*>(&m_thread.raw()), nullptr, entry_point, this) == 0); ensure(pthread_create(reinterpret_cast<pthread_t*>(&m_thread.raw()), nullptr, entry_point, this) == 0);
#endif #endif
@@ -2495,7 +2348,7 @@ thread_base::native_entry thread_base::finalize(u64 _self) noexcept
g_tls_fault_spu = 0; g_tls_fault_spu = 0;
g_tls_wait_time = 0; g_tls_wait_time = 0;
g_tls_wait_fail = 0; g_tls_wait_fail = 0;
g_tls_access_violation_recovered = umax; g_tls_access_violation_recovered = false;
g_tls_log_prefix = []() -> std::string { return {}; }; g_tls_log_prefix = []() -> std::string { return {}; };
@@ -2939,25 +2792,8 @@ void thread_base::exec()
} }
} }
void thread_ctrl::set_name(std::string name)
{
ensure(g_tls_this_thread);
g_tls_this_thread->m_tname.store(make_single<std::string>(name));
g_tls_this_thread->set_name(std::move(name));
}
[[noreturn]] void thread_ctrl::emergency_exit(std::string_view reason) [[noreturn]] void thread_ctrl::emergency_exit(std::string_view reason)
{ {
// Print stacktrace
#ifdef __cpp_lib_stacktrace
if (rpcs3::is_local_build())
{
std::ostringstream oss;
oss << std::stacktrace::current();
sys_log.notice("StackTrace\n\n%s\n", oss.str());
}
#endif
if (const std::string info = dump_useful_thread_info(); !info.empty()) if (const std::string info = dump_useful_thread_info(); !info.empty())
{ {
sys_log.notice("\n%s", info); sys_log.notice("\n%s", info);
@@ -2973,16 +2809,6 @@ void thread_ctrl::set_name(std::string name)
} }
} }
if (auto [total, current] = utils::get_memory_usage(); total - current <= 256 * 1024 * 1024)
{
if (reason_buf.empty())
{
reason_buf = std::string{reason};
}
fmt::append(reason_buf, " (Possible RAM deficiency: free RAM: %dMB)", (total - current) / (1024 * 1024));
}
if (!reason_buf.empty()) if (!reason_buf.empty())
{ {
reason = reason_buf; reason = reason_buf;
@@ -3044,32 +2870,6 @@ void thread_ctrl::set_name(std::string name)
report_fatal_error(reason); report_fatal_error(reason);
} }
void thread_ctrl::silent_exit() noexcept
{
if (const auto _this = g_tls_this_thread)
{
g_tls_error_callback();
u64 _self = _this->finalize(thread_state::errored);
if (_self == umax)
{
// Unused, detached thread support remnant
delete _this;
}
thread_base::finalize(umax);
}
#ifdef _WIN32
_endthreadex(0);
#else
pthread_exit(nullptr);
#endif
std::abort();
}
void thread_ctrl::detect_cpu_layout() void thread_ctrl::detect_cpu_layout()
{ {
if (!g_native_core_layout.compare_and_swap_test(native_core_arrangement::undefined, native_core_arrangement::generic)) if (!g_native_core_layout.compare_and_swap_test(native_core_arrangement::undefined, native_core_arrangement::generic))
+12 -11
View File
@@ -4,7 +4,6 @@
#include "util/atomic.hpp" #include "util/atomic.hpp"
#include "util/shared_ptr.hpp" #include "util/shared_ptr.hpp"
#include <thread>
#include <string> #include <string>
// Hardware core layout // Hardware core layout
@@ -129,7 +128,7 @@ public:
const native_entry entry_point; const native_entry entry_point;
// Set name for debugger // Set name for debugger
static void set_name(std::string name); static void set_name(std::string);
private: private:
// Thread handle (platform-specific) // Thread handle (platform-specific)
@@ -232,7 +231,11 @@ public:
} }
// Set current thread name (not recommended) // Set current thread name (not recommended)
static void set_name(std::string name); static void set_name(std::string name)
{
g_tls_this_thread->m_tname.store(make_single<std::string>(name));
g_tls_this_thread->set_name(std::move(name));
}
// Set thread name (not recommended) // Set thread name (not recommended)
template <typename T> template <typename T>
@@ -315,9 +318,6 @@ public:
// Exit. // Exit.
[[noreturn]] static void emergency_exit(std::string_view reason); [[noreturn]] static void emergency_exit(std::string_view reason);
// Exit the current named thread as errored without reporting a fatal error.
[[noreturn]] static void silent_exit() noexcept;
// Get current thread (may be nullptr) // Get current thread (may be nullptr)
static thread_base* get_current() static thread_base* get_current()
{ {
@@ -800,30 +800,31 @@ public:
m_count = 0; m_count = 0;
// Create all threads // Create all threads
for (; m_count < count - 1; m_count++) for (u32 i = 0; i < count - 1; i++)
{ {
// Copy the context // Copy the context
std::remove_cvref_t<Context> context(static_cast<const Context&>(f)); std::remove_cvref_t<Context> context(static_cast<const Context&>(f));
// Perform the check and additional preparations for each context // Perform the check and additional preparations for each context
if (!std::invoke(std::forward<CheckAndPrepare>(check), m_count, context)) if (!std::invoke(std::forward<CheckAndPrepare>(check), i, context))
{ {
return; return;
} }
new (static_cast<void*>(m_threads + m_count)) Thread(std::string(name) + std::to_string(m_count + 1), std::move(context)); m_count++;
new (static_cast<void*>(m_threads + i)) Thread(std::string(name) + std::to_string(i + 1), std::move(context));
} }
// Move the context (if movable) // Move the context (if movable)
std::remove_cvref_t<Context> context(std::forward<Context>(f)); std::remove_cvref_t<Context> context(std::forward<Context>(f));
if (!std::invoke(std::forward<CheckAndPrepare>(check), m_count, context)) if (!std::invoke(std::forward<CheckAndPrepare>(check), m_count - 1, context))
{ {
return; return;
} }
new (static_cast<void*>(m_threads + m_count)) Thread(std::string(name) + std::to_string(m_count + 1), std::move(context));
m_count++; m_count++;
new (static_cast<void*>(m_threads + m_count - 1)) Thread(std::string(name) + std::to_string(m_count - 1), std::move(context));
} }
// Default constructor // Default constructor
+1 -1
View File
@@ -329,7 +329,7 @@ bool patch_engine::load(patch_map& patches_map, const std::string& path, std::st
is_valid = false; is_valid = false;
continue; continue;
} }
else if (serial.size() != 9 || !std::all_of(serial.begin(), serial.end(), [](char c) { return std::isalnum(static_cast<unsigned char>(c)); })) else if (serial.size() != 9 || !std::all_of(serial.begin(), serial.end(), [](char c) { return std::isalnum(c); }))
{ {
append_log_message(log_messages, fmt::format("Error: Serial '%s' invalid (patch: %s, key: %s, location: %s, file: %s)", serial, description, main_key, get_yaml_node_location(serial_node), path), &patch_log.error); append_log_message(log_messages, fmt::format("Error: Serial '%s' invalid (patch: %s, key: %s, location: %s, file: %s)", serial, description, main_key, get_yaml_node_location(serial_node), path), &patch_log.error);
is_valid = false; is_valid = false;
+1 -3
View File
@@ -23,6 +23,7 @@ Intersection (&) and symmetric difference (^) is also available.
#include "util/types.hpp" #include "util/types.hpp"
#include "util/atomic.hpp" #include "util/atomic.hpp"
#include "Utilities/StrFmt.h"
template <typename T> template <typename T>
concept BitSetEnum = std::is_enum_v<T> && requires(T x) concept BitSetEnum = std::is_enum_v<T> && requires(T x)
@@ -383,9 +384,6 @@ public:
} }
}; };
template <typename T>
struct fmt_unveil;
template <typename T> template <typename T>
struct fmt_unveil<bs_t<T>> struct fmt_unveil<bs_t<T>>
{ {
+3 -3
View File
@@ -27,14 +27,14 @@ void fmt_class_string<cheat_type>::format(std::string& out, u64 arg)
}); });
} }
bool cheat_info::from_str(std::string_view cheat_line) bool cheat_info::from_str(const std::string& cheat_line)
{ {
const auto cheat_vec = fmt::split(cheat_line, {"@@@"}, false); auto cheat_vec = fmt::split(cheat_line, {"@@@"}, false);
s64 val64 = 0; s64 val64 = 0;
if (cheat_vec.size() != 5 || !try_to_int64(&val64, cheat_vec[2], 0, cheat_type_max - 1)) if (cheat_vec.size() != 5 || !try_to_int64(&val64, cheat_vec[2], 0, cheat_type_max - 1))
{ {
log_cheat.error("Failed to parse cheat line: '%s'", cheat_line); log_cheat.fatal("Failed to parse cheat line");
return false; return false;
} }
+1 -1
View File
@@ -28,6 +28,6 @@ struct cheat_info
u32 offset{}; u32 offset{};
std::string red_script{}; std::string red_script{};
bool from_str(std::string_view cheat_line); bool from_str(const std::string& cheat_line);
std::string to_str() const; std::string to_str() const;
}; };
-12
View File
@@ -1,6 +1,5 @@
#pragma once #pragma once
#include <array>
#include <cmath> #include <cmath>
#include <type_traits> #include <type_traits>
@@ -822,14 +821,6 @@ struct color4_base
a *= rhs; a *= rhs;
} }
void operator += (const color4_base<T>& rhs)
{
r += rhs.r;
g += rhs.g;
b += rhs.b;
a += rhs.a;
}
constexpr color4_base<T> operator * (const color4_base<T>& rhs) const constexpr color4_base<T> operator * (const color4_base<T>& rhs) const
{ {
return { r * rhs.r, g * rhs.g, b * rhs.b, a * rhs.a }; return { r * rhs.r, g * rhs.g, b * rhs.b, a * rhs.a };
@@ -1028,6 +1019,3 @@ using color1u = color1_base<unsigned int>;
using color1i = color1_base<int>; using color1i = color1_base<int>;
using color1f = color1_base<float>; using color1f = color1_base<float>;
using color1d = color1_base<double>; using color1d = color1_base<double>;
using mat3f = color3_base<float>[3];
static_assert(sizeof(mat3f) == sizeof(float) * 3 * 3);
-13
View File
@@ -10,19 +10,6 @@ rXmlNode::rXmlNode(const pugi::xml_node& node)
handle = node; handle = node;
} }
std::shared_ptr<rXmlNode> rXmlNode::GetChild(std::string_view name)
{
if (handle)
{
if (const pugi::xml_node child = handle.child(name))
{
return std::make_shared<rXmlNode>(child);
}
}
return nullptr;
}
std::shared_ptr<rXmlNode> rXmlNode::GetChildren() std::shared_ptr<rXmlNode> rXmlNode::GetChildren()
{ {
if (handle) if (handle)
-1
View File
@@ -20,7 +20,6 @@ struct rXmlNode
{ {
rXmlNode(); rXmlNode();
rXmlNode(const pugi::xml_node& node); rXmlNode(const pugi::xml_node& node);
std::shared_ptr<rXmlNode> GetChild(std::string_view name);
std::shared_ptr<rXmlNode> GetChildren(); std::shared_ptr<rXmlNode> GetChildren();
std::shared_ptr<rXmlNode> GetNext(); std::shared_ptr<rXmlNode> GetNext();
std::string GetName(); std::string GetName();
+12 -31
View File
@@ -30,61 +30,42 @@ namespace utils
return out.data(); return out.data();
} }
std::vector<void*> get_backtrace(int max_depth, PCONTEXT ctx) std::vector<void*> get_backtrace(int max_depth)
{ {
static struct sym_initer_t
{
sym_initer_t() noexcept
{
SymInitialize(GetCurrentProcess(), NULL, TRUE);
}
~sym_initer_t() noexcept
{
SymCleanup(GetCurrentProcess());
}
} s_initer{};
std::vector<void*> result = {}; std::vector<void*> result = {};
const auto hProcess = ::GetCurrentProcess(); const auto hProcess = ::GetCurrentProcess();
const auto hThread = ::GetCurrentThread(); const auto hThread = ::GetCurrentThread();
CONTEXT context{}; CONTEXT context{};
if (ctx) RtlCaptureContext(&context);
context = *ctx;
else
RtlCaptureContext(&context);
STACKFRAME64 stack = {}; STACKFRAME64 stack = {};
stack.AddrPC.Mode = AddrModeFlat; stack.AddrPC.Mode = AddrModeFlat;
stack.AddrStack.Mode = AddrModeFlat; stack.AddrStack.Mode = AddrModeFlat;
stack.AddrFrame.Mode = AddrModeFlat; stack.AddrFrame.Mode = AddrModeFlat;
#if defined(ARCH_X64) #if defined(ARCH_X64)
const DWORD machineType = IMAGE_FILE_MACHINE_AMD64;
stack.AddrPC.Offset = context.Rip; stack.AddrPC.Offset = context.Rip;
stack.AddrStack.Offset = context.Rsp; stack.AddrStack.Offset = context.Rsp;
stack.AddrFrame.Offset = context.Rbp; stack.AddrFrame.Offset = context.Rbp;
#elif defined(ARCH_ARM64) #elif defined(ARCH_ARM64)
const DWORD machineType = IMAGE_FILE_MACHINE_ARM64;
stack.AddrPC.Offset = context.Pc; stack.AddrPC.Offset = context.Pc;
stack.AddrStack.Offset = context.Sp; stack.AddrStack.Offset = context.Sp;
stack.AddrFrame.Offset = context.Fp; stack.AddrFrame.Offset = context.Fp;
#else
#error "Unsupported architecture"
#endif #endif
while (max_depth--) while (max_depth--)
{ {
if (!StackWalk64( if (!StackWalk64(
machineType, IMAGE_FILE_MACHINE_AMD64,
hProcess, hProcess,
hThread, hThread,
&stack, &stack,
&context, &context,
NULL, NULL,
SymFunctionTableAccess64, SymFunctionTableAccess64,
SymGetModuleBase64, SymGetModuleBase64,
NULL)) NULL))
{ {
break; break;
} }
@@ -135,7 +116,7 @@ namespace utils
} }
else else
{ {
result.push_back(fmt::format("rpcs3@0x%p", pointer)); result.push_back(fmt::format("rpcs3@0xp", pointer));
} }
} }
-10
View File
@@ -2,11 +2,6 @@
#include <util/types.hpp> #include <util/types.hpp>
#include <util/logs.hpp> #include <util/logs.hpp>
#ifdef _WIN32
#define WIN32_LEAN_AND_MEAN
#include <Windows.h>
#endif
namespace utils namespace utils
{ {
namespace stack_trace namespace stack_trace
@@ -35,12 +30,7 @@ namespace utils
}; };
} }
#ifdef _WIN32
std::vector<void*> get_backtrace(int max_depth = 255, PCONTEXT ctx = nullptr);
#else
std::vector<void*> get_backtrace(int max_depth = 255); std::vector<void*> get_backtrace(int max_depth = 255);
#endif
std::vector<std::string> get_backtrace_symbols(const std::vector<void*>& stack); std::vector<std::string> get_backtrace_symbols(const std::vector<void*>& stack);
FORCE_INLINE void print_trace(stack_trace::Logger auto& logger, int max_depth = 255) FORCE_INLINE void print_trace(stack_trace::Logger auto& logger, int max_depth = 255)
-159
View File
@@ -1,159 +0,0 @@
#include "stdafx.h"
#include "stereo_config.h"
#include "Emu/system_config.h"
stereo_config::stereo_matrices::stereo_matrices(const std::array<color3_base<f32>, 3>& l, const std::array<color3_base<f32>, 3>& r)
{
for (usz i = 0; i < 3; i++)
{
left[i] = l[i];
right[i] = r[i];
}
}
atomic_t<bool> stereo_config::s_live_preview_enabled = false;
stereo_config::stereo_matrices stereo_config::m_live_matrices = {};
const std::unordered_map<stereo_render_mode_options, stereo_config::stereo_matrices> stereo_config::m_matrices =
{
{stereo_render_mode_options::anaglyph_red_cyan, stereo_matrices(
{
color3_base<f32>(1, 0, 0),
color3_base<f32>(0, 0, 0),
color3_base<f32>(0, 0, 0)
},
{
color3_base<f32>(0, 0, 0),
color3_base<f32>(0, 1, 0),
color3_base<f32>(0, 0, 1)
}
)},
{stereo_render_mode_options::anaglyph_red_green, stereo_matrices(
{
color3_base<f32>(1, 0, 0),
color3_base<f32>(0, 0, 0),
color3_base<f32>(0, 0, 0)
},
{
color3_base<f32>(0, 0, 0),
color3_base<f32>(0, 1, 0),
color3_base<f32>(0, 0, 0)
}
)},
{stereo_render_mode_options::anaglyph_red_blue, stereo_matrices(
{
color3_base<f32>(1, 0, 0),
color3_base<f32>(0, 0, 0),
color3_base<f32>(0, 0, 0)
},
{
color3_base<f32>(0, 0, 0),
color3_base<f32>(0, 0, 0),
color3_base<f32>(0, 0, 1)
}
)},
{stereo_render_mode_options::anaglyph_magenta_cyan, stereo_matrices(
{
color3_base<f32>(1, 0, 0),
color3_base<f32>(0, 0, 0),
color3_base<f32>(0, 0, 0.5f)
},
{
color3_base<f32>(0, 0, 0),
color3_base<f32>(0, 1, 0),
color3_base<f32>(0, 0, 0.5f)
}
)},
{stereo_render_mode_options::anaglyph_trioscopic, stereo_matrices(
{
color3_base<f32>(0, 0, 0),
color3_base<f32>(0, 1, 0),
color3_base<f32>(0, 0, 0)
},
{
color3_base<f32>(1, 0, 0),
color3_base<f32>(0, 0, 0),
color3_base<f32>(0, 0, 1)
}
)},
{stereo_render_mode_options::anaglyph_amber_blue, stereo_matrices(
{
color3_base<f32>(1, 0, 0),
color3_base<f32>(0, 1, 0),
color3_base<f32>(0, 0, 0)
},
{
color3_base<f32>(0, 0, 1.0f / 3.0f),
color3_base<f32>(0, 0, 1.0f / 3.0f),
color3_base<f32>(0, 0, 1.0f / 3.0f)
}
)},
};
void stereo_config::update_from_config(bool stereo_enabled)
{
m_stereo_mode = stereo_enabled ? g_cfg.video.stereo_render_mode.get() : stereo_render_mode_options::disabled;
if (m_stereo_mode == stereo_render_mode_options::anaglyph_custom)
{
stereo_config::convert_matrix(m_custom_matrices.left, g_cfg.video.custom_anaglyph_matrices.left.get_map());
stereo_config::convert_matrix(m_custom_matrices.right, g_cfg.video.custom_anaglyph_matrices.right.get_map());
}
}
const stereo_config::stereo_matrices& stereo_config::matrices() const
{
if (m_in_emulation && s_live_preview_enabled)
{
return m_live_matrices;
}
switch (m_stereo_mode)
{
case stereo_render_mode_options::disabled:
case stereo_render_mode_options::side_by_side:
case stereo_render_mode_options::over_under:
case stereo_render_mode_options::interlaced:
break;
case stereo_render_mode_options::anaglyph_red_green:
case stereo_render_mode_options::anaglyph_red_blue:
case stereo_render_mode_options::anaglyph_red_cyan:
case stereo_render_mode_options::anaglyph_magenta_cyan:
case stereo_render_mode_options::anaglyph_trioscopic:
case stereo_render_mode_options::anaglyph_amber_blue:
return ::at32(m_matrices, m_stereo_mode);
case stereo_render_mode_options::anaglyph_custom:
return m_custom_matrices;
}
static const stereo_matrices s_left_only_matrices = stereo_matrices(
{
color3_base<float>(1, 0, 0),
color3_base<float>(0, 1, 0),
color3_base<float>(0, 0, 1)
},
{
color3_base<float>(0, 0, 0),
color3_base<float>(0, 0, 0),
color3_base<float>(0, 0, 0)
});
return s_left_only_matrices;
}
std::map<std::string, std::string> stereo_config::get_custom_matrix(bool is_left) const
{
return convert_matrix(is_left ? m_custom_matrices.left : m_custom_matrices.right);
}
std::map<std::string, std::string> stereo_config::convert_matrix(const mat3f& mat)
{
std::map<std::string, std::string> values {};
for (int i = 0; i < 3; i++)
{
for (int j = 0; j < 3; j++)
{
values[fmt::format("%d%d", i, j)] = fmt::format("%f", mat[i].rgb[j]);
}
}
return values;
}
-79
View File
@@ -1,79 +0,0 @@
#pragma once
#include "geometry.h"
#include "Emu/system_config_types.h"
#include "util/atomic.hpp"
#include "Utilities/StrFmt.h"
#include "Utilities/StrUtil.h"
#include <map>
#include <mutex>
struct stereo_config
{
public:
struct stereo_matrices
{
stereo_matrices() = default;
stereo_matrices(const std::array<color3_base<f32>, 3>& l, const std::array<color3_base<f32>, 3>& r);
mat3f left {};
mat3f right {};
};
stereo_config(bool in_emulation) : m_in_emulation(in_emulation) {}
void set_stereo_mode(stereo_render_mode_options mode) { m_stereo_mode = mode; }
stereo_render_mode_options stereo_mode() const { return m_stereo_mode; }
const stereo_matrices& matrices() const;
void update_from_config(bool stereo_enabled);
void set_custom_matrices(const stereo_matrices& matrices) { m_custom_matrices = matrices; }
static void set_live_matrices(const stereo_matrices& matrices) { m_live_matrices = matrices; }
std::map<std::string, std::string> get_custom_matrix(bool is_left) const;
template <typename T>
static void convert_matrix(mat3f& mat, const T& values)
{
mat[0] = {};
mat[1] = {};
mat[2] = {};
if (values.empty())
{
return;
}
for (int i = 0; i < 3; i++)
{
for (int j = 0; j < 3; j++)
{
const std::string key = fmt::format("%d%d", i, j);
const auto it = values.find(key);
if (it == values.cend()) continue;
const std::string& val_s = it->second;
if (val_s.empty()) continue;
if (f64 val = 0.0f; try_to_float(&val, val_s, -10.0f, 10.0f))
{
mat[i].rgb[j] = static_cast<f32>(val);
}
}
}
}
static std::map<std::string, std::string> convert_matrix(const mat3f& mat);
static atomic_t<bool> s_live_preview_enabled;
private:
stereo_matrices m_custom_matrices {};
stereo_render_mode_options m_stereo_mode = stereo_render_mode_options::disabled;
bool m_in_emulation = false;
static stereo_matrices m_live_matrices;
static const std::unordered_map<stereo_render_mode_options, stereo_matrices> m_matrices;
};
+9 -88
View File
@@ -17,8 +17,6 @@
#include <sys/time.h> #include <sys/time.h>
#include <unistd.h> #include <unistd.h>
#include <fcntl.h> #include <fcntl.h>
#elif __APPLE__
#include <os/os_sync_wait_on_address.h>
#endif #endif
#ifdef _WIN32 #ifdef _WIN32
@@ -74,75 +72,25 @@ enum
}; };
#endif #endif
inline int futex(volatile void* uaddr, int futex_op, uint val, const timespec* timeout = nullptr, [[maybe_unused]] uint mask = 0) inline int futex(volatile void* uaddr, int futex_op, uint val, const timespec* timeout = nullptr, uint mask = 0)
{ {
#ifdef __linux__ #ifdef __linux__
return syscall(SYS_futex, uaddr, futex_op, static_cast<int>(val), timeout, nullptr, static_cast<int>(mask)); return syscall(SYS_futex, uaddr, futex_op, static_cast<int>(val), timeout, nullptr, static_cast<int>(mask));
#elif __APPLE__
switch (futex_op)
{
case FUTEX_WAIT_PRIVATE:
case FUTEX_WAIT_BITSET_PRIVATE:
{
if (timeout)
{
const uint64_t nsec = timeout->tv_nsec + timeout->tv_sec * 1000000000ull;
return os_sync_wait_on_address_with_timeout(const_cast<void*>(uaddr), static_cast<uint64_t>(val), sizeof(uint), OS_SYNC_WAIT_ON_ADDRESS_NONE, OS_CLOCK_MACH_ABSOLUTE_TIME, nsec);
}
else
{
return os_sync_wait_on_address(const_cast<void*>(uaddr), static_cast<uint64_t>(val), sizeof(uint), OS_SYNC_WAIT_ON_ADDRESS_NONE);
}
}
case FUTEX_WAKE_PRIVATE:
case FUTEX_WAKE_BITSET_PRIVATE:
{
for (;;)
{
int ret = 0;
if (val == INT32_MAX)
{
ret = os_sync_wake_by_address_all(const_cast<void*>(uaddr), sizeof(uint), OS_SYNC_WAKE_BY_ADDRESS_NONE);
}
else if (val-- >= 0)
{
ret = os_sync_wake_by_address_any(const_cast<void*>(uaddr), sizeof(uint), OS_SYNC_WAKE_BY_ADDRESS_NONE);
}
if (val <= 0 || val == INT32_MAX || (ret < 0 && errno == ENOENT))
{
return ret;
}
}
}
}
errno = EINVAL;
return -1;
#else #else
static struct futex_manager static struct futex_manager
{ {
struct waiter struct waiter
{ {
uint val; uint val;
uint mask; uint mask;
std::condition_variable cv; std::condition_variable cv;
}; };
struct bucket_t std::mutex mutex;
{ std::unordered_multimap<volatile void*, waiter*> map;
std::mutex mutex;
std::unordered_multimap<volatile void*, waiter*> map;
};
// Not a power of 2 on purpose (for alignment optimiations)
bucket_t bucks[63];
int operator()(volatile void* uaddr, int futex_op, uint val, const timespec* timeout, uint mask) int operator()(volatile void* uaddr, int futex_op, uint val, const timespec* timeout, uint mask)
{ {
auto& bucket = bucks[(reinterpret_cast<u64>(uaddr) / 8) % std::size(bucks)];
auto& mutex = bucket.mutex;
auto& map = bucket.map;
std::unique_lock lock(mutex); std::unique_lock lock(mutex);
switch (futex_op) switch (futex_op)
@@ -163,9 +111,7 @@ inline int futex(volatile void* uaddr, int futex_op, uint val, const timespec* t
waiter rec; waiter rec;
rec.val = val; rec.val = val;
rec.mask = mask; rec.mask = mask;
const auto& ref = *map.emplace(uaddr, &rec);
// Announce the waiter
map.emplace(uaddr, &rec);
int res = 0; int res = 0;
@@ -181,16 +127,6 @@ inline int futex(volatile void* uaddr, int futex_op, uint val, const timespec* t
{ {
res = -1; res = -1;
errno = ETIMEDOUT; errno = ETIMEDOUT;
// Cleanup
for (auto range = map.equal_range(uaddr); range.first != range.second; range.first++)
{
if (range.first->second == &rec)
{
map.erase(range.first);
break;
}
}
} }
} }
else else
@@ -198,6 +134,7 @@ inline int futex(volatile void* uaddr, int futex_op, uint val, const timespec* t
// TODO: absolute timeout // TODO: absolute timeout
} }
map.erase(std::find(map.find(uaddr), map.end(), ref));
return res; return res;
} }
@@ -216,29 +153,13 @@ inline int futex(volatile void* uaddr, int futex_op, uint val, const timespec* t
if (entry.mask & mask) if (entry.mask & mask)
{ {
entry.mask = 0;
entry.cv.notify_one(); entry.cv.notify_one();
entry.mask = 0;
res++; res++;
val--; val--;
} }
} }
if (res)
{
// Cleanup
for (auto range = map.equal_range(uaddr); range.first != range.second;)
{
if (range.first->second->mask == 0)
{
map.erase(range.first);
range = map.equal_range(uaddr);
continue;
}
range.first++;
}
}
return res; return res;
} }
} }
+4
View File
@@ -37,6 +37,10 @@ QSlider#sizeSlider::handle:horizontal {
QLabel#toolbar_icon_color { QLabel#toolbar_icon_color {
color: rgba(64,64,64,255); color: rgba(64,64,64,255);
} }
/* thumbnail icon color stylesheet */
QLabel#thumbnail_icon_color {
color: rgba(0,100,231,255);
}
/* gamelist icon color stylesheet */ /* gamelist icon color stylesheet */
QLabel#gamelist_icon_background_color { QLabel#gamelist_icon_background_color {
color: rgba(209,209,209,255); color: rgba(209,209,209,255);
@@ -237,6 +237,11 @@ QLabel#gamelist_icon_background_color {
color: transparent; color: transparent;
} }
/* Set Windows Taskbar Thumbnail colors */
QLabel#thumbnail_icon_color {
color: #262626;
}
/* Set Log colors */ /* Set Log colors */
QPlainTextEdit#log_frame { QPlainTextEdit#log_frame {
background-color: #000; /* Black */ background-color: #000; /* Black */
+5
View File
@@ -573,6 +573,11 @@ QLabel#gamelist_icon_background_color {
color: transparent; color: transparent;
} }
/* Set Windows Taskbar Thumbnail colors */
QLabel#thumbnail_icon_color {
color: #23262d;
}
/* Log colors */ /* Log colors */
QPlainTextEdit#log_frame { QPlainTextEdit#log_frame {
background-color: #23262d; background-color: #23262d;
+5
View File
@@ -265,6 +265,11 @@ QLabel#gamelist_icon_background_color {
color: transparent; color: transparent;
} }
/* Set Taskbar Thumbnail colors */
QLabel#thumbnail_icon_color {
color: #444444;
}
/* Memory Viewer */ /* Memory Viewer */
QLabel#memory_viewer_address_panel { QLabel#memory_viewer_address_panel {
color: #00cbff; /* Font Color: Blue */ color: #00cbff; /* Font Color: Blue */
@@ -244,6 +244,11 @@ QLabel#gamelist_icon_background_color {
color: transparent; color: transparent;
} }
/* Set Windows Taskbar Thumbnail colors */
QLabel#thumbnail_icon_color {
color: #262626;
}
/* Set Log colors */ /* Set Log colors */
QPlainTextEdit#log_frame { QPlainTextEdit#log_frame {
background-color: #181d24; /* Black */ background-color: #181d24; /* Black */
@@ -397,6 +397,12 @@ QLabel#gamelist_icon_background_color {
} }
/* Set Windows Taskbar Thumbnail colors */
QLabel#thumbnail_icon_color {
color: #ffd785;
}
QLabel#log_level_always { QLabel#log_level_always {
color: #00ffff; /* Cyan */ color: #00ffff; /* Cyan */
} }
+5
View File
@@ -656,6 +656,11 @@ QLabel#color_button {
background: transparent; background: transparent;
} }
/* Set Windows Taskbar Thumbnail colors */
QLabel#thumbnail_icon_color {
color: #370048;
}
/* Debugger colors */ /* Debugger colors */
QLabel#debugger_frame_breakpoint { QLabel#debugger_frame_breakpoint {
color: #000; /* Font Color: Black */ color: #000; /* Font Color: Black */
+5
View File
@@ -664,6 +664,11 @@ QLabel#color_button {
background: transparent; background: transparent;
} }
/* Set Windows Taskbar Thumbnail colors */
QLabel#thumbnail_icon_color {
color: #8500ae;
}
/* Debugger colors */ /* Debugger colors */
QLabel#debugger_frame_breakpoint { QLabel#debugger_frame_breakpoint {
color: #000; /* Font Color: Black */ color: #000; /* Font Color: Black */
@@ -349,24 +349,24 @@ QPushButton:disabled {
} }
QDialog QDialogButtonBox QPushButton:default { QDialog QDialogButtonBox QPushButton {
color: #000000; color: #000000;
background-color: #4CC2FF; background-color: #4CC2FF;
border-color: #5AC7FF; border-color: #5AC7FF;
} }
QDialog QDialogButtonBox QPushButton:default:hover { QDialog QDialogButtonBox QPushButton:hover {
background-color: #48B2E9; background-color: #48B2E9;
border-color: #56B8EB; border-color: #56B8EB;
} }
QDialog QDialogButtonBox QPushButton:default:pressed { QDialog QDialogButtonBox QPushButton:pressed {
color: #22526A; color: #22526A;
background-color: #45A4D5; background-color: #45A4D5;
border-color: #45A4D5; border-color: #45A4D5;
} }
QDialog QDialogButtonBox QPushButton:default:disabled { QDialog QDialogButtonBox QPushButton:disabled {
color: #ABABAB; color: #ABABAB;
background-color: #4C4C4C; background-color: #4C4C4C;
border-color: #4C4C4C; border-color: #4C4C4C;
@@ -614,15 +614,10 @@ QComboBox QAbstractItemView {
QComboBox QAbstractItemView::item { QComboBox QAbstractItemView::item {
color: #FFFFFF; color: #FFFFFF;
padding: 4px 6px; padding: 4px 6px;
margin: 2px 0px;
background-color: transparent; background-color: transparent;
border-radius: 4px; border-radius: 4px;
} }
QComboBox QAbstractItemView::item:hover {
background-color: #383838;
}
QComboBox QAbstractItemView::item:selected { QComboBox QAbstractItemView::item:selected {
background-color: #383838; background-color: #383838;
} }
@@ -647,7 +642,7 @@ QDoubleSpinBox::up-button, QDoubleSpinBox::down-button {
border-radius: 4px; border-radius: 4px;
width: 8px; width: 8px;
height: 8px; height: 8px;
padding: 3px 4px; padding: 3px 4px;
} }
QSpinBox::up-button:hover, QSpinBox::down-button:hover, QSpinBox::up-button:hover, QSpinBox::down-button:hover,
@@ -714,16 +709,6 @@ QSlider::handle:horizontal:disabled {
image: url("GuiConfigs/dark/slider-handle-disabled.svg"); image: url("GuiConfigs/dark/slider-handle-disabled.svg");
} }
QSlider::sub-page:horizontal {
background-color: #4CC2FF;
border-radius: 2px;
height: 4px;
}
QSlider::sub-page:horizontal:disabled {
background-color: #767A7D;
}
/* LINE EDIT */ /* LINE EDIT */
QLineEdit { QLineEdit {
@@ -806,7 +791,7 @@ QMenuBar::item:pressed {
QMenu { QMenu {
background-color: #2C2C2C; background-color: #2C2C2C;
border: 1px solid #3E3E3E; border: 1px solid #131313;
padding: 4px 0px; padding: 4px 0px;
} }
@@ -814,12 +799,12 @@ QMenu::item {
color: #FFFFFF; color: #FFFFFF;
background-color: transparent; background-color: transparent;
border-radius: 4px; border-radius: 4px;
padding: 4px 20px; padding: 8px 20px;
margin: 0px 4px; margin: 0px 4px;
} }
QMenu::item:selected { QMenu::item:selected {
background-color: #353535; background-color: #383838;
} }
QMenu::item:disabled { QMenu::item:disabled {
@@ -829,8 +814,8 @@ QMenu::item:disabled {
QMenu::separator { QMenu::separator {
height: 1px; height: 1px;
background: #3E3E3E; background: #131313;
margin: 4px 8px; margin: 4px 0px;
} }
QMenu::indicator, QMenu::right-arrow { QMenu::indicator, QMenu::right-arrow {
@@ -349,24 +349,24 @@ QPushButton:disabled {
} }
QDialog QDialogButtonBox QPushButton:default { QDialog QDialogButtonBox QPushButton {
color: #FFFFFF; color: #FFFFFF;
background-color: #0067C0; background-color: #0067C0;
border-color: #1473C5; border-color: #1473C5;
} }
QDialog QDialogButtonBox QPushButton:default:hover { QDialog QDialogButtonBox QPushButton:hover {
background-color: #1A76C6; background-color: #1A76C6;
border-color: #2C80CA; border-color: #2C80CA;
} }
QDialog QDialogButtonBox QPushButton:default:pressed { QDialog QDialogButtonBox QPushButton:pressed {
color: #C2DAEF; color: #C2DAEF;
background-color: #3284CB; background-color: #3284CB;
border-color: #3284CB; border-color: #3284CB;
} }
QDialog QDialogButtonBox QPushButton:default:disabled { QDialog QDialogButtonBox QPushButton:disabled {
color: #FFFFFF; color: #FFFFFF;
background-color: #C5C5C5; background-color: #C5C5C5;
border-color: #C5C5C5; border-color: #C5C5C5;
@@ -614,15 +614,10 @@ QComboBox QAbstractItemView {
QComboBox QAbstractItemView::item { QComboBox QAbstractItemView::item {
color: #1B1B1B; color: #1B1B1B;
padding: 4px 6px; padding: 4px 6px;
margin: 2px 0px;
background-color: transparent; background-color: transparent;
border-radius: 4px; border-radius: 4px;
} }
QComboBox QAbstractItemView::item:hover {
background-color: #F0F0F0;
}
QComboBox QAbstractItemView::item:selected { QComboBox QAbstractItemView::item:selected {
background-color: #F0F0F0; background-color: #F0F0F0;
} }
@@ -647,7 +642,7 @@ QDoubleSpinBox::up-button, QDoubleSpinBox::down-button {
border-radius: 4px; border-radius: 4px;
width: 8px; width: 8px;
height: 8px; height: 8px;
padding: 3px 4px; padding: 3px 4px;
} }
QSpinBox::up-button:hover, QSpinBox::down-button:hover, QSpinBox::up-button:hover, QSpinBox::down-button:hover,
@@ -714,16 +709,6 @@ QSlider::handle:horizontal:disabled {
image: url("GuiConfigs/light/slider-handle-disabled.svg"); image: url("GuiConfigs/light/slider-handle-disabled.svg");
} }
QSlider::sub-page:horizontal {
background-color: #1A76C6;
border-radius: 2px;
height: 4px;
}
QSlider::sub-page:horizontal:disabled {
background-color: #868788;
}
/* LINE EDIT */ /* LINE EDIT */
QLineEdit { QLineEdit {
@@ -806,7 +791,7 @@ QMenuBar::item:pressed {
QMenu { QMenu {
background-color: #F9F9F9; background-color: #F9F9F9;
border: 1px solid #E5E5E5; border: 1px solid #EEEEEE;
padding: 4px 0px; padding: 4px 0px;
} }
@@ -814,7 +799,7 @@ QMenu::item {
color: #1B1B1B; color: #1B1B1B;
background-color: transparent; background-color: transparent;
border-radius: 4px; border-radius: 4px;
padding: 4px 20px; padding: 8px 20px;
margin: 0px 4px; margin: 0px 4px;
} }
@@ -829,8 +814,8 @@ QMenu::item:disabled {
QMenu::separator { QMenu::separator {
height: 1px; height: 1px;
background: #E5E5E5; background: #EEEEEE;
margin: 4px 8px; margin: 4px 0px;
} }
QMenu::indicator, QMenu::right-arrow { QMenu::indicator, QMenu::right-arrow {

Some files were not shown because too many files have changed in this diff Show More