···10101111If the build broke as a result of a package update, try those solutions in order:
12121313-- search the [sage trac](https://trac.sagemath.org/) for keywords like "Upgrade <package>". Maybe somebody has already proposed a patch that fixes the issue. You can then add a `fetchpatch` to `sage-src.nix`.
1313+- search the [sage GitHub repo](https://github.com/sagemath/sage) for keywords like "Upgrade <package>". Maybe somebody has already proposed a patch that fixes the issue. You can then add a `fetchpatch` to `sage-src.nix`.
14141515- check if [gentoo](https://github.com/cschwan/sage-on-gentoo/tree/master/sci-mathematics/sage), [debian](https://salsa.debian.org/science-team/sagemath/tree/master/debian) or [arch linux](https://git.archlinux.org/svntogit/community.git/tree/trunk?h=packages/sagemath) already solved the problem. You can then again add a `fetchpatch` to `sage-src.nix`. If applicable you should also [propose the patch upstream](#proposing-a-sage-patch).
1616···1919```
2020[user@localhost ~]$ git clone https://github.com/sagemath/sage.git
2121[user@localhost ~]$ cd sage
2222-[user@localhost sage]$ git checkout 8.2 # substitute the relevant version here
2222+[user@localhost sage]$ git checkout 9.8 # substitute the relevant version here
2323```
24242525Then make the needed changes and generate a patch with `git diff`:
···2929[user@localhost ~]$ git diff -u > /path/to/nixpkgs/pkgs/applications/science/math/sage/patches/name-of-patch.patch
3030```
31313232-Now just add the patch to `sage-src.nix` and test your changes. If they fix the problem, [propose them upstream](#proposing-a-sage-patch) and add a link to the trac ticket.
3232+Now just add the patch to `sage-src.nix` and test your changes. If they fix the problem, submit a PR upstream (refer to sages [Developer's Guide](http://doc.sagemath.org/html/en/developer/index.html) for further details).
33333434- pin the package version in `default.nix` and add a note that explains why that is necessary.
35353636-3737-## Proposing a sage patch
3838-3939-You can [login the sage trac using GitHub](https://trac.sagemath.org/login). Your username will then be `gh-<your-github-name>`. The only other way is to request a trac account via email. After that refer to [git the hard way](http://doc.sagemath.org/html/en/developer/manual_git.html#chapter-manual-git) in the sage documentation. The "easy way" requires a non-GitHub account (requested via email) and a special tool. The "hard way" is really not all that hard if you're a bit familiar with git.
4040-4141-Here's the gist, assuming you want to use ssh key authentication. First, [add your public ssh key](https://trac.sagemath.org/prefs/sshkeys). Then:
4242-4343-```
4444-[user@localhost ~]$ git clone https://github.com/sagemath/sage.git
4545-[user@localhost ~]$ cd sage
4646-[user@localhost sage]$ git remote add trac git@trac.sagemath.org:sage.git -t master
4747-[user@localhost sage]$ git checkout -b u/gh-<your-github-username>/<your-branch-name> develop
4848-[user@localhost sage]$ <make changes>
4949-[user@localhost sage]$ git add .
5050-[user@localhost sage]$ git commit
5151-[user@localhost sage]$ git show # review your changes
5252-[user@localhost sage]$ git push --set-upstream trac u/gh-<your-github-username>/<your-branch-name>
5353-```
5454-5555-You now created a branch on the trac server (you *must* follow the naming scheme as you only have push access to branches with the `u/gh-<your-github-username>/` prefix).
5656-Now you can [create a new trac ticket](https://trac.sagemath.org/newticket).
5757-- Write a description of the change
5858-- set the type and component as appropriate
5959-- write your real name in the "Authors" field
6060-- write `u/gh-<your-github-username>/<your-branch-name>` in the "Branch" field
6161-- click "Create ticket"
6262-- click "Modify" on the top right of your ticket (for some reason you can only change the ticket status after you have created it)
6363-- set the ticket status from `new` to `needs_review`
6464-- click "Save changes"
6565-6666-Refer to sages [Developer's Guide](http://doc.sagemath.org/html/en/developer/index.html) for further details.
6767-6836## I want to update sage
69377038You'll need to change the `version` field in `sage-src.nix`. Afterwards just try to build and let nix tell you which patches no longer apply (hopefully because they were adopted upstream). Remove those.
···74427543## Well, that didn't help!
76447777-If you couldn't fix the problem, create a GitHub issue on the nixpkgs repo and ping @timokau (or whoever is listed in the `maintainers` list of the sage package).
4545+If you couldn't fix the problem, create a GitHub issue on the nixpkgs repo and ping the sage maintainers (as listed in the sage package).
7846Describe what you did and why it didn't work. Afterwards it would be great if you help the next guy out and improve this documentation!
···11+{ lib
22+, stdenv
33+, fetchurl
44+}:
55+66+stdenv.mkDerivation rec {
77+ pname = "gnu-cim";
88+ version = "5.1";
99+1010+ outputs = ["out" "lib" "man" "info"];
1111+1212+ src = fetchurl {
1313+ url = "mirror://gnu/cim/cim-${version}.tar.gz";
1414+ hash = "sha256-uQcXtm7EAFA73WnlN+i38+ip0QbDupoIoErlc2mgaak=";
1515+ };
1616+1717+ postPatch = ''
1818+ for fname in lib/{simulation,simset}.c; do
1919+ substituteInPlace "$fname" \
2020+ --replace \
2121+ '#include "../../lib/cim.h"' \
2222+ '#include "../lib/cim.h"'
2323+ done
2424+ '';
2525+2626+ CFLAGS = lib.optionalString stdenv.cc.isClang "-Wno-return-type";
2727+2828+ doCheck = true;
2929+3030+ meta = with lib; {
3131+ description = "A GNU compiler for the programming language Simula";
3232+ longDescription = ''
3333+ GNU Cim is a compiler for the programming language Simula.
3434+ It offers a class concept, separate compilation with full type checking,
3535+ interface to external C routines, an application package for process
3636+ simulation and a coroutine concept. Commonly used with the Demos for
3737+ discrete event modelling.
3838+ '';
3939+ homepage = "https://www.gnu.org/software/cim/";
4040+ license = licenses.gpl2;
4141+ platforms = platforms.all;
4242+ badPlatforms = [ "aarch64-darwin" ];
4343+ maintainers = with maintainers; [ pbsds ];
4444+ };
4545+}
+1
pkgs/development/compilers/zig/0.10.nix
···4747 cmakeFlags = [
4848 # file RPATH_CHANGE could not write new RPATH
4949 "-DCMAKE_SKIP_BUILD_RPATH=ON"
5050+ "-DZIG_TARGET_MCPU=baseline"
5051 ];
51525253 doCheck = true;
···380380 docker_compose = throw "'docker_compose' has been renamed to/replaced by 'docker-compose'"; # Converted to throw 2022-02-22
381381 docker-compose_2 = throw "'docker-compose_2' has been renamed to 'docker-compose'"; # Added 2022-06-05
382382 docker-edge = throw "'docker-edge' has been removed, it was an alias for 'docker'"; # Added 2022-06-05
383383+ dolphin-emu-beta = dolphin-emu; # Added 2023-02-11
383384 dolphinEmu = dolphin-emu; # Added 2021-11-10
384385 dolphinEmuMaster = dolphin-emu-beta; # Added 2021-11-10
385386 dot-http = throw "'dot-http' has been removed: abandoned by upstream. Use hurl instead."; # Added 2023-01-16
···156156 pycallgraph = throw "pycallgraph has been removed, it was using setuptools 2to3 translation feature, which has been removed in setuptools 58"; # added 2022-01-18
157157 pychef = throw "pychef has been removed because it's been archived upstream and abandoned since 2017."; # added 2022-11-14
158158 pycryptodome-test-vectors = throw "pycryptodome-test-vectors has been removed because it is an internal package to pycryptodome"; # added 2022-05-28
159159+ pyflunearyou = pyoutbreaksnearme; # added 2023-02-11
159160 pyialarmxr = pyialarmxr-homeassistant; # added 2022-06-07
160161 pyialarmxr-homeassistant = throw "The package was removed together with the component support in home-assistant 2022.7.0"; # added 2022-07-07
161162 PyICU = pyicu; # Added 2022-12-22