about summary refs log tree commit diff
path: root/pkgs/applications/emulators
diff options
context:
space:
mode:
authorSoner Sayakci <s.sayakci@shopware.com>2024-03-05 20:18:05 +0100
committerSoner Sayakci <s.sayakci@shopware.com>2024-03-05 20:18:05 +0100
commit9b90f685e58c1483cbdea6388069e1ed8f57edae (patch)
tree4fcc3c3ec3f39a2110a750c557897707d0899070 /pkgs/applications/emulators
parentef72e8b3a9b9743544b3ca6bca9da5770e20f51f (diff)
downloadnixlib-9b90f685e58c1483cbdea6388069e1ed8f57edae.tar
nixlib-9b90f685e58c1483cbdea6388069e1ed8f57edae.tar.gz
nixlib-9b90f685e58c1483cbdea6388069e1ed8f57edae.tar.bz2
nixlib-9b90f685e58c1483cbdea6388069e1ed8f57edae.tar.lz
nixlib-9b90f685e58c1483cbdea6388069e1ed8f57edae.tar.xz
nixlib-9b90f685e58c1483cbdea6388069e1ed8f57edae.tar.zst
nixlib-9b90f685e58c1483cbdea6388069e1ed8f57edae.zip
citra: remove package
Diffstat (limited to 'pkgs/applications/emulators')
-rw-r--r--pkgs/applications/emulators/citra/default.nix45
-rw-r--r--pkgs/applications/emulators/citra/generic.nix149
-rwxr-xr-xpkgs/applications/emulators/citra/update.sh84
3 files changed, 0 insertions, 278 deletions
diff --git a/pkgs/applications/emulators/citra/default.nix b/pkgs/applications/emulators/citra/default.nix
deleted file mode 100644
index a4e4578632ae..000000000000
--- a/pkgs/applications/emulators/citra/default.nix
+++ /dev/null
@@ -1,45 +0,0 @@
-{ branch
-, qt6Packages
-, fetchFromGitHub
-, fetchurl
-}:
-
-let
-  # Fetched from https://api.citra-emu.org/gamedb
-  # Please make sure to update this when updating citra!
-  compat-list = fetchurl {
-    name = "citra-compat-list";
-    url = "https://web.archive.org/web/20231111133415/https://api.citra-emu.org/gamedb";
-    hash = "sha256-J+zqtWde5NgK2QROvGewtXGRAWUTNSKHNMG6iu9m1fU=";
-  };
-in {
-  nightly = qt6Packages.callPackage ./generic.nix rec {
-    pname = "citra-nightly";
-    version = "2088";
-
-    src = fetchFromGitHub {
-      owner = "citra-emu";
-      repo = "citra-nightly";
-      rev = "nightly-${version}";
-      sha256 = "0l9w4i0zbafcv2s6pd1zqb11vh0i7gzwbqnzlz9al6ihwbsgbj3k";
-      fetchSubmodules = true;
-    };
-
-    inherit branch compat-list;
-  };
-
-  canary = qt6Packages.callPackage ./generic.nix rec {
-    pname = "citra-canary";
-    version = "2766";
-
-    src = fetchFromGitHub {
-      owner = "citra-emu";
-      repo = "citra-canary";
-      rev = "canary-${version}";
-      sha256 = "1gm3ajphpzwhm3qnchsx77jyl51za8yw3r0j0h8idf9y1ilcjvi4";
-      fetchSubmodules = true;
-    };
-
-    inherit branch compat-list;
-  };
-}.${branch}
diff --git a/pkgs/applications/emulators/citra/generic.nix b/pkgs/applications/emulators/citra/generic.nix
deleted file mode 100644
index d247a181e07c..000000000000
--- a/pkgs/applications/emulators/citra/generic.nix
+++ /dev/null
@@ -1,149 +0,0 @@
-{ pname
-, version
-, src
-, branch
-, compat-list
-
-, lib
-, stdenv
-, cmake
-, boost
-, pkg-config
-, catch2_3
-, cpp-jwt
-, cryptopp
-, enet
-, ffmpeg
-, fmt
-, gamemode
-, glslang
-, httplib
-, inih
-, libusb1
-, nlohmann_json
-, openal
-, openssl
-, SDL2
-, soundtouch
-, spirv-tools
-, zstd
-, vulkan-headers
-, vulkan-loader
-, enableSdl2Frontend ? true
-, enableQt ? true, qtbase, qtmultimedia, qtwayland, wrapQtAppsHook
-, enableQtTranslation ? enableQt, qttools
-, enableWebService ? true
-, enableCubeb ? true, cubeb
-, useDiscordRichPresence ? false, rapidjson
-}:
-stdenv.mkDerivation {
-  inherit pname version src;
-
-  nativeBuildInputs = [
-    cmake
-    pkg-config
-    ffmpeg
-    glslang
-  ] ++ lib.optionals enableQt [ wrapQtAppsHook ];
-
-  buildInputs = [
-    boost
-    catch2_3
-    cpp-jwt
-    cryptopp
-    # intentionally omitted: dynarmic - prefer vendored version for compatibility
-    enet
-    fmt
-    httplib
-    inih
-    libusb1
-    nlohmann_json
-    openal
-    openssl
-    SDL2
-    soundtouch
-    spirv-tools
-    vulkan-headers
-    # intentionally omitted: xbyak - prefer vendored version for compatibility
-    zstd
-  ] ++ lib.optionals enableQt [ qtbase qtmultimedia qtwayland ]
-    ++ lib.optional enableQtTranslation qttools
-    ++ lib.optional enableCubeb cubeb
-    ++ lib.optional useDiscordRichPresence rapidjson;
-
-  cmakeFlags = [
-    (lib.cmakeBool "USE_SYSTEM_LIBS" true)
-
-    (lib.cmakeBool "DISABLE_SYSTEM_DYNARMIC" true)
-    (lib.cmakeBool "DISABLE_SYSTEM_GLSLANG" true) # The following imported targets are referenced, but are missing: SPIRV-Tools-opt
-    (lib.cmakeBool "DISABLE_SYSTEM_LODEPNG" true) # Not packaged in nixpkgs
-    (lib.cmakeBool "DISABLE_SYSTEM_VMA" true)
-    (lib.cmakeBool "DISABLE_SYSTEM_XBYAK" true)
-
-    # We don't want to bother upstream with potentially outdated compat reports
-    (lib.cmakeBool "CITRA_ENABLE_COMPATIBILITY_REPORTING" true)
-    (lib.cmakeBool "ENABLE_COMPATIBILITY_LIST_DOWNLOAD" false) # We provide this deterministically
-
-    (lib.cmakeBool "ENABLE_SDL2_FRONTEND" enableSdl2Frontend)
-    (lib.cmakeBool "ENABLE_QT" enableQt)
-    (lib.cmakeBool "ENABLE_QT_TRANSLATION" enableQtTranslation)
-    (lib.cmakeBool "ENABLE_WEB_SERVICE" enableWebService)
-    (lib.cmakeBool "ENABLE_CUBEB" enableCubeb)
-    (lib.cmakeBool "USE_DISCORD_PRESENCE" useDiscordRichPresence)
-  ];
-
-  # causes redefinition of _FORTIFY_SOURCE
-  hardeningDisable = [ "fortify3" ];
-
-  postPatch = 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
-
-    # Prep compatibilitylist
-    ln -s ${compat-list} ./dist/compatibility_list/compatibility_list.json
-
-    # We already know the submodules are present
-    substituteInPlace CMakeLists.txt \
-      --replace "check_submodules_present()" ""
-
-    # Add versions
-    echo 'set(BUILD_FULLNAME "${branchCaptialized} ${version}")' >> CMakeModules/GenerateBuildInfo.cmake
-
-    # Add gamemode
-    substituteInPlace externals/gamemode/include/gamemode_client.h --replace "libgamemode.so.0" "${lib.getLib gamemode}/lib/libgamemode.so.0"
-  '';
-
-  postInstall = let
-    libs = lib.makeLibraryPath [ vulkan-loader ];
-  in lib.optionalString enableSdl2Frontend ''
-    wrapProgram "$out/bin/citra" \
-      --prefix LD_LIBRARY_PATH : ${libs}
-  '' + lib.optionalString enableQt ''
-    qtWrapperArgs+=(
-      --prefix LD_LIBRARY_PATH : ${libs}
-    )
-  '';
-
-  meta = with lib; {
-    broken = (stdenv.isLinux && stdenv.isAarch64);
-    homepage = "https://citra-emu.org";
-    description = "The ${branch} branch of an open-source emulator for the Nintendo 3DS";
-    longDescription = ''
-      A Nintendo 3DS Emulator written in C++
-      Using the nightly branch is recommended for general usage.
-      Using the canary branch is recommended if you would like to try out
-      experimental features, with a cost of stability.
-    '';
-    mainProgram = if enableQt then "citra-qt" else "citra";
-    platforms = platforms.linux;
-    license = licenses.gpl2Plus;
-    maintainers = with maintainers; [
-      abbradar
-      ashley
-      ivar
-    ];
-  };
-}
diff --git a/pkgs/applications/emulators/citra/update.sh b/pkgs/applications/emulators/citra/update.sh
deleted file mode 100755
index e76121dac6ee..000000000000
--- a/pkgs/applications/emulators/citra/update.sh
+++ /dev/null
@@ -1,84 +0,0 @@
-#! /usr/bin/env nix-shell
-#! nix-shell -i bash -p nix nix-prefetch-git coreutils curl jq gnused
-
-set -euo pipefail
-
-# Will be replaced with the actual branch when running this from passthru.updateScript
-BRANCH="@branch@"
-
-if [[ ! "$(basename $PWD)" = "citra" ]]; then
-    echo "error: Script must be ran from citra's directory!"
-    exit 1
-fi
-
-getLocalVersion() {
-    pushd ../../../.. >/dev/null
-    nix eval --raw -f default.nix "$1".version
-    popd >/dev/null
-}
-
-getLocalHash() {
-    pushd ../../../.. >/dev/null
-    nix eval --raw -f default.nix "$1".src.drvAttrs.outputHash
-    popd >/dev/null
-}
-
-updateNightly() {
-    OLD_NIGHTLY_VERSION="$(getLocalVersion "citra-nightly")"
-    OLD_NIGHTLY_HASH="$(getLocalHash "citra-nightly")"
-
-    NEW_NIGHTLY_VERSION="$(curl -s ${GITHUB_TOKEN:+-u ":$GITHUB_TOKEN"} \
-        "https://api.github.com/repos/citra-emu/citra-nightly/releases?per_page=1" | jq -r '.[0].name' | cut -d"-" -f2 | cut -d" " -f2)"
-
-    if [[ "${OLD_NIGHTLY_VERSION}" = "${NEW_NIGHTLY_VERSION}" ]]; then
-        echo "citra-nightly is already up to date!"
-
-        [ "$KEEP_GOING" ] && return || exit
-    else
-        echo "citra-nightly: ${OLD_NIGHTLY_VERSION} -> ${NEW_NIGHTLY_VERSION}"
-    fi
-
-    echo "  Fetching source code..."
-
-    NEW_NIGHTLY_HASH="$(nix-prefetch-git --quiet --fetch-submodules --rev "nightly-${NEW_NIGHTLY_VERSION}" "https://github.com/citra-emu/citra-nightly" | jq -r '.sha256')"
-
-    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
-}
-
-updateCanary() {
-    OLD_CANARY_VERSION="$(getLocalVersion "citra-canary")"
-    OLD_CANARY_HASH="$(getLocalHash "citra-canary")"
-
-    NEW_CANARY_VERSION="$(curl -s ${GITHUB_TOKEN:+-u ":$GITHUB_TOKEN"} \
-        "https://api.github.com/repos/citra-emu/citra-canary/releases?per_page=1" | jq -r '.[0].name' | cut -d"-" -f2 | cut -d" " -f1)"
-
-    if [[ "${OLD_CANARY_VERSION}" = "${NEW_CANARY_VERSION}" ]]; then
-        echo "citra-canary is already up to date!"
-
-        [ "$KEEP_GOING" ] && return || exit
-    else
-        echo "citra-canary: ${OLD_CANARY_VERSION} -> ${NEW_CANARY_VERSION}"
-    fi
-
-    echo "  Fetching source code..."
-
-    NEW_CANARY_HASH="$(nix-prefetch-git --quiet --fetch-submodules --rev "canary-${NEW_CANARY_VERSION}" "https://github.com/citra-emu/citra-canary" | jq -r '.sha256')"
-
-    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
-}
-
-if [[ "$BRANCH" = "nightly" ]]; then
-    updateNightly
-elif [[ "$BRANCH" = "early-access" ]]; then
-    updateCanary
-else
-    KEEP_GOING=1
-    updateNightly
-    updateCanary
-fi