Merge pull request #148273 from NixOS/backport-147641-to-release-21.11

[Backport release-21.11] mathematica: Install desktop items
This commit is contained in:
Thiago Kenji Okada
2021-12-02 10:42:56 -03:00
committed by GitHub

View File

@@ -90,7 +90,16 @@ stdenv.mkDerivation rec {
cd Installer
# don't restrict PATH, that has already been done
sed -i -e 's/^PATH=/# PATH=/' MathInstaller
sed -i -e 's/\/bin\/bash/\/bin\/sh/' MathInstaller
# Fix the installation script as follows:
# 1. Adjust the shebang
# 2. Use the wrapper in the desktop items
substituteInPlace MathInstaller \
--replace "/bin/bash" "/bin/sh" \
--replace "Executables/Mathematica" "../../bin/mathematica"
# Install the desktop items
export XDG_DATA_HOME="$out/share"
echo "=== Running MathInstaller ==="
./MathInstaller -auto -createdir=y -execdir=$out/bin -targetdir=$out/libexec/Mathematica -silent