about summary refs log tree commit diff
path: root/nixpkgs/pkgs/applications/emulators/citra
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/applications/emulators/citra')
-rw-r--r--nixpkgs/pkgs/applications/emulators/citra/default.nix10
-rw-r--r--nixpkgs/pkgs/applications/emulators/citra/generic.nix14
-rwxr-xr-xnixpkgs/pkgs/applications/emulators/citra/update.sh8
3 files changed, 20 insertions, 12 deletions
diff --git a/nixpkgs/pkgs/applications/emulators/citra/default.nix b/nixpkgs/pkgs/applications/emulators/citra/default.nix
index cdebb980b24f..41a018d9ea92 100644
--- a/nixpkgs/pkgs/applications/emulators/citra/default.nix
+++ b/nixpkgs/pkgs/applications/emulators/citra/default.nix
@@ -9,19 +9,19 @@ let
   # Please make sure to update this when updating citra!
   compat-list = fetchurl {
     name = "citra-compat-list";
-    url = "https://web.archive.org/web/20230512234055/https://api.citra-emu.org/gamedb/";
+    url = "https://web.archive.org/web/20230807103651/https://api.citra-emu.org/gamedb/";
     hash = "sha256-J+zqtWde5NgK2QROvGewtXGRAWUTNSKHNMG6iu9m1fU=";
   };
 in {
   nightly = qt6Packages.callPackage ./generic.nix rec {
     pname = "citra-nightly";
-    version = "1907";
+    version = "1963";
 
     src = fetchFromGitHub {
       owner = "citra-emu";
       repo = "citra-nightly";
       rev = "nightly-${version}";
-      sha256 = "l4pqok42/ybnRX90Qwhcgm2JR4/9C5bbCTk3j4QuWtw=";
+      sha256 = "0ggi1l8327s43xaxs616g0s9vmal6q7vsv69bn07gp71gchhcmyi";
       fetchSubmodules = true;
     };
 
@@ -30,13 +30,13 @@ in {
 
   canary = qt6Packages.callPackage ./generic.nix rec {
     pname = "citra-canary";
-    version = "2484";
+    version = "2573";
 
     src = fetchFromGitHub {
       owner = "citra-emu";
       repo = "citra-canary";
       rev = "canary-${version}";
-      sha256 = "IgCpqt3rKV9IqNstF4QwnJlE3hPH+BkIhaOvEmshh0U=";
+      sha256 = "sha256-tQJ3WcqGcnW9dOiwDrBgL0n3UNp1DGQ/FjCR28Xjdpc=";
       fetchSubmodules = true;
     };
 
diff --git a/nixpkgs/pkgs/applications/emulators/citra/generic.nix b/nixpkgs/pkgs/applications/emulators/citra/generic.nix
index 7bce3e16d872..8df720e60b79 100644
--- a/nixpkgs/pkgs/applications/emulators/citra/generic.nix
+++ b/nixpkgs/pkgs/applications/emulators/citra/generic.nix
@@ -8,9 +8,10 @@
 , stdenv
 , fetchFromGitHub
 , cmake
-, boost179
+, boost
 , pkg-config
 , libusb1
+, glslang
 , zstd
 , libressl
 , enableSdl2 ? true, SDL2
@@ -31,11 +32,12 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [
     cmake
+    glslang
     pkg-config
   ] ++ lib.optionals enableQt [ wrapQtAppsHook ];
 
   buildInputs = [
-    boost179
+    boost
     libusb1
   ] ++ lib.optionals enableQt [ qtbase qtmultimedia ]
     ++ lib.optional enableSdl2 SDL2
@@ -47,6 +49,7 @@ stdenv.mkDerivation rec {
 
   cmakeFlags = [
     "-DUSE_SYSTEM_BOOST=ON"
+    "-DCITRA_WARNINGS_AS_ERRORS=OFF"
     "-DCITRA_USE_BUNDLED_FFMPEG=OFF"
     "-DCITRA_USE_BUNDLED_QT=OFF"
     "-DUSE_SYSTEM_SDL2=ON"
@@ -66,7 +69,9 @@ stdenv.mkDerivation rec {
     ++ lib.optional useDiscordRichPresence "-DUSE_DISCORD_PRESENCE=ON"
     ++ lib.optional enableFdk "-DENABLE_FDK=ON";
 
-  postPatch = ''
+  postPatch = with lib; let
+    branchCaptialized = (lib.toUpper (lib.substring 0 1 branch) + lib.substring 1 (-1) branch);
+  in ''
     # Fix file not found when looking in var/empty instead of opt
     mkdir externals/dynarmic/src/dynarmic/ir/var
     ln -s ../opt externals/dynarmic/src/dynarmic/ir/var/empty
@@ -78,6 +83,9 @@ stdenv.mkDerivation rec {
     substituteInPlace CMakeLists.txt \
       --replace "check_submodules_present()" ""
 
+    # Add versions
+    echo 'set(BUILD_FULLNAME "${branchCaptialized} ${version}")' >> CMakeModules/GenerateBuildInfo.cmake
+
     # Devendoring
     rm -rf externals/zstd externals/libressl
     cp -r ${zstd.src} externals/zstd
diff --git a/nixpkgs/pkgs/applications/emulators/citra/update.sh b/nixpkgs/pkgs/applications/emulators/citra/update.sh
index e9150e34e0a1..e76121dac6ee 100755
--- a/nixpkgs/pkgs/applications/emulators/citra/update.sh
+++ b/nixpkgs/pkgs/applications/emulators/citra/update.sh
@@ -44,8 +44,8 @@ updateNightly() {
 
     echo "  Successfully fetched. hash: ${NEW_NIGHTLY_HASH}"
 
-    sed -i "s/${OLD_NIGHTLY_VERSION}/${NEW_NIGHTLY_VERSION}/" ./default.nix
-    sed -i "s/${OLD_NIGHTLY_HASH}/${NEW_NIGHTLY_HASH}/" ./default.nix
+    sed -i "s|${OLD_NIGHTLY_VERSION}|${NEW_NIGHTLY_VERSION}|" ./default.nix
+    sed -i "s|${OLD_NIGHTLY_HASH}|${NEW_NIGHTLY_HASH}|" ./default.nix
 }
 
 updateCanary() {
@@ -69,8 +69,8 @@ updateCanary() {
 
     echo "  Successfully fetched. hash: ${NEW_CANARY_HASH}"
 
-    sed -i "s/${OLD_CANARY_VERSION}/${NEW_CANARY_VERSION}/" ./default.nix
-    sed -i "s/${OLD_CANARY_HASH}/${NEW_CANARY_HASH}/" ./default.nix
+    sed -i "s|${OLD_CANARY_VERSION}|${NEW_CANARY_VERSION}|" ./default.nix
+    sed -i "s|${OLD_CANARY_HASH}|${NEW_CANARY_HASH}|" ./default.nix
 }
 
 if [[ "$BRANCH" = "nightly" ]]; then