29 runescape = stdenv.mkDerivation rec {
30 pname = "runescape-launcher";
33 # Packages: https://content.runescape.com/downloads/ubuntu/dists/trusty/non-free/binary-amd64/Packages
34 # upstream is https://content.runescape.com/downloads/ubuntu/pool/non-free/r/${pname}/${pname}_${version}_amd64.deb
36 url = "https://archive.org/download/${pname}_${version}_amd64/${pname}_${version}_amd64.deb";
37 sha256 = "1v96vjiblphhbqhpp3m7wbvdvcnp76ncdlf4pdcr2z1dz8nh6shg";
60 runtimeDependencies = [
65 xdg-utils # The launcher uses `xdg-open` to open HTTP URLs in the user's browser
76 envVarsWithXmodifiers = ''
77 export MESA_GLSL_CACHE_DIR=~/Jagex
83 mkdir -p $out/bin $out/share
86 patchShebangs $out/usr/bin/runescape-launcher
87 substituteInPlace $out/usr/bin/runescape-launcher \
88 --replace "unset XMODIFIERS" "$envVarsWithXmodifiers" \
89 --replace "/usr/share/games/runescape-launcher/runescape" "$out/share/games/runescape-launcher/runescape"
91 cp -r $out/usr/bin $out/
92 cp -r $out/usr/share $out/
98 description = "Launcher for RuneScape 3, the current main RuneScape";
99 homepage = "https://www.runescape.com/";
100 sourceProvenance = with sourceTypes; [ binaryNativeCode ];
101 license = licenses.unfree;
102 maintainers = with maintainers; [ grburst ];
103 platforms = [ "x86_64-linux" ];
110 * We can patch the runescape launcher, but it downloads a client at runtime and checks it for changes.
111 * For that we need use a buildFHSEnv.
112 * FHS simulates a classic linux shell
116 inherit (runescape) version;
138 multiPkgs = pkgs: [ libGL ];
139 runScript = "runescape-launcher";
140 extraInstallCommands = ''
141 mkdir -p "$out/share/applications"
142 cp ${runescape}/share/applications/runescape-launcher.desktop "$out/share/applications"
143 cp -r ${runescape}/share/icons "$out/share/icons"
144 substituteInPlace "$out/share/applications/runescape-launcher.desktop" \
145 --replace "/usr/bin/runescape-launcher" "RuneScape"
149 description = "RuneScape Game Client (NXT) - Launcher for RuneScape 3";
150 homepage = "https://www.runescape.com/";
151 license = licenses.unfree;
152 maintainers = with maintainers; [ grburst ];
153 platforms = [ "x86_64-linux" ];