Skip to content

Instantly share code, notes, and snippets.

@sguzman
Forked from kinnala/README.md
Last active September 25, 2023 18:39
Show Gist options
  • Save sguzman/80fe0cccec4add5fa595ecf17ebe0fb9 to your computer and use it in GitHub Desktop.
Save sguzman/80fe0cccec4add5fa595ecf17ebe0fb9 to your computer and use it in GitHub Desktop.
Install Mathematica in NixOS

First you find a copy of Mathematica_13.2.1_LINUX.sh or similar and find its sha256sum. Then you go to nixpkgs and copy all Mathematica files to a local directory. You need to modify default.nix and wrap its contents into

let pkgs = import <nixpkgs> {};
in pkgs.callPackage (
  # whatever is in default.nix
) {}

Next modify sha256 checksum and filename in version.nix to match what you have above. Run nix hash file Mathematica_13.2.1_BNDL_LINUX.sh. Finally, running nix-build will install Mathematica to Nix store.

@sguzman
Copy link
Author

sguzman commented Sep 25, 2023

Wow you're right haha. I'm going to spin up a qemu instance of NixOS. I need to see for myself. I'll try installing 13.3.1. I'll let you know about my results :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment