Merge pull request #154697 from mweinelt/python2-byebye

This commit is contained in:
Martin Weinelt 2022-01-16 03:22:15 +01:00 committed by GitHub
commit ae02cde6df
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
33 changed files with 52 additions and 898 deletions

View file

@ -208,6 +208,13 @@
removed due to it being an outdated version.
</para>
</listitem>
<listitem>
<para>
The <literal>mailpile</literal> email webclient
(<literal>services.mailpile</literal>) has been removed due to
its reliance on python2.
</para>
</listitem>
<listitem>
<para>
The MoinMoin wiki engine

View file

@ -71,6 +71,8 @@ In addition to numerous new and upgraded packages, this release has the followin
- `services.kubernetes.addons.dashboard` was removed due to it being an outdated version.
- The `mailpile` email webclient (`services.mailpile`) has been removed due to its reliance on python2.
- The MoinMoin wiki engine (`services.moinmoin`) has been removed, because Python 2 is being retired from nixpkgs.
- The `wafHook` hook now honors `NIX_BUILD_CORES` when `enableParallelBuilding` is not set explicitly. Packages can restore the old behaviour by setting `enableParallelBuilding=false`.

View file

@ -182,7 +182,7 @@ in
yandexdisk = 143;
mxisd = 144; # was once collectd
#consul = 145;# dynamically allocated as of 2021-09-03
mailpile = 146;
#mailpile = 146; # removed 2022-01-12
redmine = 147;
#seeks = 148; # removed 2020-06-21
prosody = 149;
@ -502,7 +502,7 @@ in
#yandexdisk = 143; # unused
mxisd = 144; # was once collectd
#consul = 145; # unused
mailpile = 146;
#mailpile = 146; # removed 2022-01-12
redmine = 147;
#seeks = 148; # removed 2020-06-21
prosody = 149;

View file

@ -791,7 +791,6 @@
./services/networking/lldpd.nix
./services/networking/logmein-hamachi.nix
./services/networking/lxd-image-server.nix
./services/networking/mailpile.nix
./services/networking/magic-wormhole-mailbox-server.nix
./services/networking/matterbridge.nix
./services/networking/mjpg-streamer.nix

View file

@ -51,6 +51,7 @@ with lib;
(mkRemovedOptionModule [ "services" "fourStoreEndpoint" ] "The fourStoreEndpoint module has been removed")
(mkRemovedOptionModule [ "services" "frab" ] "The frab module has been removed")
(mkRemovedOptionModule [ "services" "kippo" ] "The corresponding package was removed from nixpkgs.")
(mkRemovedOptionModule [ "services" "mailpile" ] "The corresponding package was removed from nixpkgs.")
(mkRemovedOptionModule [ "services" "marathon" ] "The corresponding package was removed from nixpkgs.")
(mkRemovedOptionModule [ "services" "mathics" ] "The Mathics module has been removed")
(mkRemovedOptionModule [ "services" "meguca" ] "Use meguca has been removed from nixpkgs")

View file

@ -1,74 +0,0 @@
{ config, lib, pkgs, ... }:
with lib;
let
cfg = config.services.mailpile;
hostname = cfg.hostname;
port = cfg.port;
in
{
###### interface
options = {
services.mailpile = {
enable = mkEnableOption "Mailpile the mail client";
hostname = mkOption {
type = types.str;
default = "localhost";
description = "Listen to this hostname or ip.";
};
port = mkOption {
type = types.port;
default = 33411;
description = "Listen on this port.";
};
};
};
###### implementation
config = mkIf config.services.mailpile.enable {
users.users.mailpile =
{ uid = config.ids.uids.mailpile;
description = "Mailpile user";
createHome = true;
home = "/var/lib/mailpile";
};
users.groups.mailpile =
{ gid = config.ids.gids.mailpile;
};
systemd.services.mailpile =
{
description = "Mailpile server.";
after = [ "network.target" ];
wantedBy = [ "multi-user.target" ];
serviceConfig = {
User = "mailpile";
ExecStart = "${pkgs.mailpile}/bin/mailpile --www ${hostname}:${port} --wait";
# mixed - first send SIGINT to main process,
# then after 2min send SIGKILL to whole group if neccessary
KillMode = "mixed";
KillSignal = "SIGINT"; # like Ctrl+C - safe mailpile shutdown
TimeoutSec = 120; # wait 2min untill SIGKILL
};
environment.MAILPILE_HOME = "/var/lib/mailpile/.local/share/Mailpile";
};
environment.systemPackages = [ pkgs.mailpile ];
};
}

View file

@ -1,72 +0,0 @@
{ python2
, lib
, fetchurl
, pkg-config
, libXext
, libXxf86vm
, libX11
, libXrandr
, libXinerama
, libXScrnSaver
, argyllcms
}:
let
inherit (python2.pkgs) buildPythonApplication wxPython numpy dbus-python;
in buildPythonApplication rec {
pname = "displaycal";
version = "3.8.9.3";
enableParallelBuilding = true;
src = fetchurl {
url = "mirror://sourceforge/project/dispcalgui/release/${version}/DisplayCAL-${version}.tar.gz";
sha256 = "1sivi4q7sqsrc95qg5gh37bsm2761md4mpl89hflzwk6kyyxyd3w";
};
propagatedBuildInputs = [
libXext
libXxf86vm
libX11
libXrandr
libXinerama
libXScrnSaver
argyllcms
wxPython
numpy
dbus-python
];
nativeBuildInputs = [
pkg-config
];
preConfigure = ''
mkdir dist
cp {misc,dist}/net.displaycal.DisplayCAL.appdata.xml
touch dist/copyright
mkdir -p $out
ln -s $out/share/DisplayCAL $out/Resources
'';
# no idea why it looks there - symlink .json lang (everything)
postInstall = ''
for x in $out/share/DisplayCAL/*; do
ln -s $x $out/lib/python2.7/site-packages/DisplayCAL
done
for prog in "$out/bin/"*; do
wrapProgram "$prog" \
--prefix PYTHONPATH : "$PYTHONPATH" \
--prefix PATH : ${argyllcms}/bin
done
'';
meta = {
description = "Display Calibration and Characterization powered by Argyll CMS";
homepage = "https://displaycal.net/";
license = lib.licenses.gpl3;
maintainers = [lib.maintainers.marcweber];
platforms = lib.platforms.linux;
};
}

View file

@ -1,78 +0,0 @@
{ stdenv, runtimeShell, lib, fetchurl, python2Packages, unzip }:
# This package uses a precompiled "binary" distribution of CuraByDagoma,
# distributed by the editor.
#
# To update the package, follow the links on https://dist.dagoma.fr/:
# * Cura By Dagoma
# * Linux
# * 64 bits
# * Genric archive
#
# I made the arbitrary choice to compile this package only for x86_64.
# I guess people owning a 3D printer generally don't use i686.
# If, however, someone needs it, we certainly can find a solution.
let
pythonPackages = python2Packages;
in stdenv.mkDerivation rec {
pname = "curabydagoma";
# Version is the date, UNIX format
version = "1520506579";
# Hash of the user's choice: os, arch, package type...
hash = "58228cce5bbdcf764b7116850956f1e5";
src = fetchurl {
url = "https://dist.dagoma.fr/get/zip/CuraByDagoma/${version}/${hash}";
sha256 = "16wfipdyjkf6dq8awjzs4zgkmqk6230277mf3iz8swday9hns8pq";
};
unpackCmd = "unzip $curSrc && tar zxf CuraByDagoma_amd64.tar.gz";
nativeBuildInputs = [ unzip ];
buildInputs = [ pythonPackages.python pythonPackages.pyopengl pythonPackages.wxPython pythonPackages.pyserial pythonPackages.numpy ];
# Compile all pyc files because the included pyc files may be older than the
# py files. However, Python doesn't realize that because the packages
# have all dates set to epoch.
buildPhase = ''
python -m compileall -f curabydago
'';
# * Simply copy the stuff there
# * Create an executable with the correct path etc
# * Create a .desktop file to have a launcher in the desktop environments
installPhase = ''
mkdir $out
cp -r * $out/
mkdir $out/bin
cat > $out/bin/curabydago <<EOF
#!${runtimeShell}
export PYTHONPATH=$PYTHONPATH
${pythonPackages.python.interpreter} $out/curabydago/cura.py
EOF
chmod a+x $out/bin/curabydago
mkdir -p $out/share/applications
cat > $out/share/applications/curabydago.desktop <<EOF
[Desktop Entry]
Type=Application
Name=Cura-by-dagoma
Comment=CuraByDagoma is a fork of Legacy Cura made by Dagoma for its own printers.
Icon=$out/curabydago/resources/images/cura.ico
Exec=$out/bin/curabydago
Path=$out/
StartupNotify=true
Terminal=false
Categories=GNOME;GTK;Utility;
EOF
'';
meta = with lib; {
description = "Slicer for 3D printers built by Dagoma";
homepage = "https://dagoma.fr/cura-by-dagoma.html";
license = licenses.agpl3;
platforms = [ "x86_64-linux" ];
maintainers = with maintainers; [ tiramiseb ];
};
}

View file

@ -1,43 +0,0 @@
{ lib, stdenv, fetchgit, makeWrapper, gettext
, python27, python2Packages
}:
stdenv.mkDerivation {
pname = "metamorphose2";
version = "0.9.0beta";
# exif-py vendored via submodule
# mutagen vendored via copy
src = fetchgit {
url = "https://github.com/metamorphose/metamorphose2.git";
#rev = "refs/tags/v2.${version}"; #for when wxPython3 support is released
rev = "d2bdd6a86340b9668e93b35a6a568894c9909d68";
sha256 = "0ivcb3c8hidrff0ivl4dnwa2p3ihpqjdbvdig8dhg9mm5phdbabn";
};
postPatch = ''
substituteInPlace messages/Makefile \
--replace "\$(shell which msgfmt)" "${gettext}/bin/msgfmt"
'';
postInstall = ''
rm $out/bin/metamorphose2
makeWrapper ${python27}/bin/python $out/bin/metamorphose2 \
--prefix PYTHONPATH : $PYTHONPATH:$(toPythonPath "$out") \
--add-flags "-O $out/share/metamorphose2/metamorphose2.py -w=3"
'';
buildInput = [ gettext python27 ];
nativeBuildInputs = [ makeWrapper ];
propagatedBuildInputs = [ python2Packages.wxPython python2Packages.pillow ];
makeFlags = [ "PREFIX=$(out)" ];
meta = with lib; {
description = "a graphical mass renaming program for files and folders";
homepage = "https://github.com/metamorphose/metamorphose2";
license = with licenses; gpl3Plus;
maintainers = with maintainers; [ ramkromberg ];
platforms = with platforms; linux;
};
}

View file

@ -1,44 +0,0 @@
{ lib, stdenv, fetchFromGitHub, python2Packages }:
stdenv.mkDerivation rec {
pname = "neap";
version = "0.7.2";
src = fetchFromGitHub {
owner = "vzxwco";
repo = "neap";
rev = "v${version}";
sha256 = "04da8rq23rl1qcvrdm5m3l90xbwyli7x601sckv7hmkip2q3g1kz";
};
nativeBuildInputs = [
python2Packages.wrapPython
];
buildInputs = [
python2Packages.python
];
pythonPath = [
python2Packages.xlib
python2Packages.pygtk
];
installPhase = ''
install -D -t $out/bin neap
install -D -t $out/share/man/man1 neap.1
install -D -t $out/share/applications neap.desktop
'';
postFixup = ''
wrapPythonPrograms
'';
meta = with lib; {
description = "Systray workspace pager";
homepage = "https://github.com/vzxwco/neap";
license = licenses.bsd2;
platforms = platforms.unix;
maintainers = [ maintainers.romildo ];
};
}

View file

@ -1,68 +0,0 @@
{ lib, fetchdarcs, python2Packages, libvncserver, zlib
, gnutls, libvpx, makeDesktopItem, mkDerivationWith }:
mkDerivationWith python2Packages.buildPythonApplication rec {
pname = "blink";
version = "3.2.0";
src = fetchdarcs {
url = "http://devel.ag-projects.com/repositories/blink-qt";
rev = "release-${version}";
sha256 = "19rcwr5scw48qnj79q1pysw95fz9h98nyc3161qy2kph5g7dwkc3";
};
patches = [ ./pythonpath.patch ];
postPatch = ''
sed -i 's|@out@|'"''${out}"'|g' blink/resources.py
'';
propagatedBuildInputs = with python2Packages; [
pyqt5_with_qtwebkit
cjson
sipsimple
twisted
google-api-python-client
];
buildInputs = [
python2Packages.cython
zlib
libvncserver
libvpx
];
desktopItem = makeDesktopItem {
name = "Blink";
exec = "blink";
comment = meta.description;
desktopName = "Blink";
icon = "blink";
genericName = "Instant Messaging";
categories = "Internet;";
};
dontWrapQtApps = true;
postInstall = ''
mkdir -p "$out/share/applications"
mkdir -p "$out/share/pixmaps"
cp "$desktopItem"/share/applications/* "$out/share/applications"
cp "$out"/share/blink/icons/blink.* "$out/share/pixmaps"
'';
preFixup = ''
makeWrapperArgs+=(
--prefix "LD_LIBRARY_PATH" ":" "${gnutls.out}/lib"
"''${qtWrapperArgs[@]}"
)
'';
meta = with lib; {
homepage = "https://icanblink.com/";
description = "A state of the art, easy to use SIP client for Voice, Video and IM";
platforms = platforms.linux;
license = licenses.gpl3;
maintainers = with maintainers; [ pSub ];
};
}

View file

@ -1,49 +0,0 @@
--- blink-2.0.0/blink/resources.py 2016-03-09 14:39:07.000000000 +0100
+++ blink-2.0.0/blink/resources-patched.py 2016-03-12 21:34:14.965476623 +0100
@@ -1,7 +1,10 @@
+# Copyright (C) 2010-2013 AG Projects. See LICENSE for details.
+#
"""Provide access to Blink's resources"""
-import __main__
+__all__ = ['ApplicationData', 'Resources', 'IconManager']
+
import imghdr
import os
import platform
@@ -19,14 +22,10 @@
from blink.util import run_in_gui_thread
-__all__ = ['ApplicationData', 'Resources', 'IconManager']
-
-
class DirectoryContextManager(unicode):
def __enter__(self):
self.directory = os.getcwdu()
os.chdir(self)
-
def __exit__(self, type, value, traceback):
os.chdir(self.directory)
@@ -61,18 +60,7 @@
@classproperty
def directory(cls):
if cls._cached_directory is None:
- try:
- binary_directory = os.path.dirname(os.path.realpath(__main__.__file__))
- except AttributeError:
- if hasattr(sys, 'frozen'):
- application_directory = os.path.dirname(os.path.realpath(sys.executable))
- else:
- application_directory = os.path.realpath('') # executed in interactive interpreter
- else:
- if os.path.basename(binary_directory) == 'bin':
- application_directory = os.path.dirname(binary_directory)
- else:
- application_directory = binary_directory
+ application_directory = '@out@'
if os.path.exists(os.path.join(application_directory, 'resources', 'blink.ui')):
cls._cached_directory = os.path.join(application_directory, 'resources').decode(sys.getfilesystemencoding())
else:

View file

@ -1,52 +0,0 @@
{ lib, fetchFromGitHub, python2Packages, gnupg1orig, openssl, git }:
python2Packages.buildPythonApplication rec {
pname = "mailpile";
version = "1.0.0rc2";
src = fetchFromGitHub {
owner = "mailpile";
repo = "Mailpile";
rev = version;
sha256 = "1z5psh00fjr8gnl4yjcl4m9ywfj24y1ffa2rfb5q8hq4ksjblbdj";
};
postPatch = ''
patchShebangs scripts
'';
nativeBuildInputs = with python2Packages; [ pbr git ];
PBR_VERSION=version;
propagatedBuildInputs = with python2Packages; [
appdirs
cryptography
fasteners
gnupg1orig
jinja2
pgpdump
pillow
python2Packages.lxml
spambayes
];
postInstall = ''
wrapProgram $out/bin/mailpile \
--prefix PATH ":" "${lib.makeBinPath [ gnupg1orig openssl ]}" \
--set-default MAILPILE_SHARED "$out/share/mailpile"
'';
# No tests were found
doCheck = false;
meta = with lib; {
description = "A modern, fast web-mail client with user-friendly encryption and privacy features";
homepage = "https://www.mailpile.is/";
license = [ licenses.asl20 licenses.agpl3 ];
platforms = platforms.linux;
maintainers = [ ];
knownVulnerabilities = [
"Numerous and uncounted, upstream has requested we not package it. See more: https://github.com/NixOS/nixpkgs/pull/23058#issuecomment-283515104"
];
};
}

View file

@ -1,50 +0,0 @@
{ lib, stdenv, fetchFromGitHub, htslib, zlib, curl, openssl, samblaster, sambamba
, samtools, hexdump, python2Packages, which }:
let
python =
python2Packages.python.withPackages (pkgs: with pkgs; [ pysam numpy ]);
in stdenv.mkDerivation rec {
pname = "lumpy";
version = "0.3.1";
src = fetchFromGitHub {
owner = "arq5x";
repo = "lumpy-sv";
rev = "v${version}";
sha256 = "0r71sg7qch8r6p6dw995znrqdj6q49hjdylhzbib2qmv8nvglhs9";
fetchSubmodules = true;
};
nativeBuildInputs = [ which ];
buildInputs =
[ htslib zlib curl openssl python samblaster sambamba samtools hexdump ];
preConfigure = ''
patchShebangs ./.
# Use Nix htslib over bundled version
sed -i 's/lumpy_filter: htslib/lumpy_filter:/' Makefile
sed -i 's|../../lib/htslib/libhts.a|-lhts|' src/filter/Makefile
# Also make sure we use the includes from Nix's htslib
sed -i 's|../../lib/htslib/|${htslib}|' src/filter/Makefile
'';
# Upstream's makefile doesn't have an install target
installPhase = ''
mkdir -p $out
cp -r bin $out
cp -r scripts $out
sed -i 's|/build/source|'$out'|' $out/bin/lumpyexpress.config
'';
meta = with lib; {
description = "Probabilistic structural variant caller";
homepage = "https://github.com/arq5x/lumpy-sv";
maintainers = with maintainers; [ jbedo ];
license = licenses.mit;
platforms = [ "x86_64-linux" ];
};
}

View file

@ -1,17 +1,20 @@
{ lib, fetchFromGitHub, python2Packages }:
{ lib, fetchFromGitHub, python3 }:
python2Packages.buildPythonApplication rec {
python3.pkgs.buildPythonApplication rec {
pname = "git-crecord";
version = "20161216.0";
version = "20201025.0";
src = fetchFromGitHub {
owner = "andrewshadura";
repo = "git-crecord";
rev = version;
sha256 = "0v3y90zi43myyi4k7q3892dcrbyi9dn2q6xgk12nw9db9zil269i";
sha256 = "1rkdmy2d2vsx22fx97nd9afh0g5lq4pns7rdxyl711apq1bhiihn";
};
propagatedBuildInputs = with python2Packages; [ docutils ];
propagatedBuildInputs = with python3.pkgs; [ docutils ];
# has no tests
doCheck = false;
meta = {
homepage = "https://github.com/andrewshadura/git-crecord";

View file

@ -1,26 +0,0 @@
{ lib, fetchFromGitHub, python2Packages }:
python2Packages.buildPythonApplication rec {
pname = "gitinspector";
version = "0.4.4";
namePrefix = "";
src = fetchFromGitHub {
owner = "ejwa";
repo = "gitinspector";
rev = "v${version}";
sha256 = "sha256-9bChvE5aAZFunu599pH7QKHZFd7aQzv0i9LURrvh2t0=";
};
checkInputs = with python2Packages; [
unittest2
];
meta = with lib; {
homepage = "https://github.com/ejwa/gitinspector";
description = "Statistical analysis tool for git repositories";
license = licenses.gpl3;
platforms = platforms.all;
maintainers = [ maintainers.bjornfor ];
};
}

View file

@ -1,34 +0,0 @@
{ lib, stdenv, fetchFromGitHub, python2Packages }:
stdenv.mkDerivation rec {
pname = "cdetheme";
version = "1.3";
src = fetchFromGitHub {
owner = "josvanr";
repo = "cde-motif-theme";
rev = version;
sha256 = "1v5c4db69cmzdci8xxlkx3s3cifg1h5160qq5siwfps0sj7pvggj";
};
dontBuild = true;
pythonPath = with python2Packages; [ pyqt4 pillow pyxdg pyyaml ];
nativeBuildInputs = with python2Packages; [ python wrapPython ];
installPhase = ''
mkdir -p $out/share/themes
cp -r cdetheme $out/share/themes
patchShebangs $out/share/themes/cdetheme/scripts/switchtheme
wrapPythonProgramsIn "$out/share/themes/cdetheme/scripts" "$out $pythonPath"
'';
meta = with lib; {
description = "Gtk2 / Gtk3 theme mimicking CDE / Motif";
homepage = "https://www.gnome-look.org/p/1231025";
license = licenses.gpl3;
platforms = platforms.all;
maintainers = with maintainers; [ ];
hydraPlatforms = [];
};
}

View file

@ -1,46 +0,0 @@
{ lib, fetchurl, python2Packages, picocom
, avrdude, arduino-core }:
python2Packages.buildPythonApplication rec {
pname = "ino";
version = "0.3.6";
src = fetchurl {
url = "mirror://pypi/i/ino/ino-${version}.tar.gz";
sha256 = "0k6lzfcn55favbj0w4afrvnmwyskf7bgzg9javv2ycvskp35srwv";
};
# TODO: add avrgcclibc, it must be rebuild with C++ support
propagatedBuildInputs = with python2Packages; [
arduino-core
avrdude
picocom
configobj
jinja2
pyserial
six
];
patchPhase = ''
echo "Patching Arduino distribution path"
sed -i 's@/usr/local/share/arduino@${arduino-core}/share/arduino@g' \
ino/environment.py
sed -i -e 's@argparse@@' -e 's@ordereddict@@' \
requirements.txt
sed -i -e 's@from ordereddict@from collections@' \
ino/environment.py ino/utils.py
# Patch the upload command so it uses the correct avrdude
substituteInPlace ino/commands/upload.py \
--replace "self.e['avrdude']" "'${avrdude}/bin/avrdude'" \
--replace "'-C', self.e['avrdude.conf']," ""
'';
meta = with lib; {
description = "Command line toolkit for working with Arduino hardware";
homepage = "http://inotool.org/";
license = licenses.mit;
maintainers = with maintainers; [ antono ];
platforms = platforms.linux;
};
}

View file

@ -1,19 +0,0 @@
{ lib, fetchurl, python2Packages }:
python2Packages.buildPythonPackage rec {
pname = "pyrex";
version = "0.9.5.1.1";
src = fetchurl {
url = "https://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/oldtar/Pyrex-${version}.tar.gz";
sha256 = "0lxxvn4mjfb83swcbqb5908q4iy53w4ip5i0f9angm2va1jyhd3z";
};
doCheck = false;
meta = {
homepage = "http://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/";
description = "A language for writing Python extension modules";
license = lib.licenses.asl20;
};
}

View file

@ -1,19 +0,0 @@
{ lib, fetchurl, python2Packages }:
python2Packages.buildPythonPackage rec {
pname = "pyrex";
version = "0.9.6.4";
src = fetchurl {
url = "https://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/oldtar/Pyrex-${version}.tar.gz";
sha256 = "18pd9f8al3l6i27cc0ddhgg7hxf28lnfs75x4a8jzscydxgiq5a8";
};
doCheck = false;
meta = {
homepage = "http://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/";
description = "A language for writing Python extension modules";
license = lib.licenses.asl20;
};
}

View file

@ -1,62 +0,0 @@
{ lib, stdenv, fetchurl, python2Packages, pkg-config, SDL2
, libpng, ffmpeg, freetype, glew, libGL, libGLU, fribidi, zlib
, glib
}:
with python2Packages;
stdenv.mkDerivation rec {
pname = "renpy";
version = "7.3.5";
meta = with lib; {
description = "Ren'Py Visual Novel Engine";
homepage = "https://renpy.org/";
license = licenses.mit;
platforms = platforms.linux;
};
src = fetchurl {
url = "https://www.renpy.org/dl/${version}/renpy-${version}-source.tar.bz2";
sha256 = "1anr5cfbvbsbik4v4rvrkdkciwhg700k4lydfbs4n85raimz9mw4";
};
patches = [
./launcherenv.patch
];
postPatch = ''
substituteInPlace launcher/game/choose_directory.rpy --replace /usr/bin/python ${python.interpreter}
'';
nativeBuildInputs = [ pkg-config ];
buildInputs = [
python cython wrapPython tkinter
SDL2 libpng ffmpeg freetype glew libGLU libGL fribidi zlib pygame_sdl2 glib
];
pythonPath = [ pygame_sdl2 tkinter ];
RENPY_DEPS_INSTALL = lib.concatStringsSep "::" (map (path: path) [
SDL2 SDL2.dev libpng ffmpeg ffmpeg.out freetype glew.dev glew.out libGLU libGL fribidi zlib
]);
buildPhase = ''
python module/setup.py build
'';
installPhase = ''
mkdir -p $out/share/renpy
cp -vr * $out/share/renpy
rm -rf $out/share/renpy/module
python module/setup.py install --prefix=$out --install-lib=$out/share/renpy/module
makeWrapper ${python}/bin/python $out/bin/renpy \
--set PYTHONPATH $PYTHONPATH \
--set RENPY_BASE $out/share/renpy \
--add-flags "-O $out/share/renpy/renpy.py"
'';
NIX_CFLAGS_COMPILE = "-I${pygame_sdl2}/include/${python.libPrefix}";
}

View file

@ -1,14 +0,0 @@
# The launcher game starts projects in a separate python process
# with the -E flag, which prevents the nix set PYTHONPATH envvar
# from taking effect, preventing the loading of pygame_sdl2
--- a/launcher/game/project.rpy
+++ b/launcher/game/project.rpy
@@ -239,7 +239,7 @@
raise Exception("Python interpreter not found: %r", executables)
# Put together the basic command line.
- cmd = [ executable, "-EO", sys.argv[0] ]
+ cmd = [ executable, "-O", sys.argv[0] ]
cmd.append(self.path)
cmd.extend(args)

View file

@ -1,5 +1,5 @@
{ lib, stdenv, fetchurl, libjpeg, libtiff, zlib
, postgresql, libmysqlclient, libgeotiff, python2Packages, proj, geos, openssl
, postgresql, libmysqlclient, libgeotiff, python3Packages, proj, geos, openssl
, libpng, sqlite, libspatialite, poppler, hdf4, qhull, giflib, expat
, libiconv, libxml2
, netcdfSupport ? true, netcdf, hdf5, curl
@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
buildInputs = [ libjpeg libtiff libgeotiff libpng proj openssl sqlite
libspatialite poppler hdf4 qhull giflib expat libxml2 proj ]
++ (with python2Packages; [ python numpy wrapPython ])
++ (with python3Packages; [ python numpy wrapPython ])
++ lib.optional stdenv.isDarwin libiconv
++ lib.optionals netcdfSupport [ netcdf hdf5 curl ];

View file

@ -1,6 +1,6 @@
{ lib, stdenv, fetchFromGitHub, cmake
, libuuid, json_c
, doxygen, perl, python2, python2Packages
, doxygen, perl, python3
}:
stdenv.mkDerivation rec {
@ -23,10 +23,11 @@ stdenv.mkDerivation rec {
NIX_CFLAGS_COMPILE = [
"-Wno-error=format-truncation"
"-Wno-error=address-of-packed-member"
"-Wno-array-bounds"
];
nativeBuildInputs = [ cmake doxygen perl python2Packages.sphinx ];
buildInputs = [ libuuid json_c python2 ];
nativeBuildInputs = [ cmake doxygen perl python3.pkgs.sphinx ];
buildInputs = [ libuuid json_c python3 ];
# Set the Epoch to 1980; otherwise the Python wheel/zip code
# gets very angry

View file

@ -1,4 +1,4 @@
{ lib, stdenv, fetchFromGitHub, python2Packages, hexio
{ lib, stdenv, fetchFromGitHub, python3Packages, hexio
, cmake, bash, arpa2cm, git, asn2quickder }:
stdenv.mkDerivation rec {
@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ cmake ];
buildInputs = with python2Packages; [
buildInputs = with python3Packages; [
arpa2cm
asn1ate
hexio

View file

@ -12,12 +12,11 @@
, libpng
, libtiff
, openexr
, python2Packages
, python3
}:
let
inherit (python2Packages) python numpy;
# Might want to use `python2.withPackages(ps: [ps.numpy]);` here...
python = python3.withPackages (py: with py; [ numpy ]);
in
stdenv.mkDerivation rec {
pname = "vigra";
@ -50,7 +49,6 @@ stdenv.mkDerivation rec {
libjpeg
libpng
libtiff
numpy
openexr
python
];

View file

@ -1,18 +0,0 @@
{ lib, buildPythonPackage, fetchPypi, isPy3k, isPyPy }:
buildPythonPackage rec {
pname = "python-cjson";
version = "1.2.2";
disabled = isPy3k || isPyPy;
src = fetchPypi {
inherit pname version;
sha256 = "3006c2c218297be3448dc793218e0b15d20fe9839775521bfc294fc6aa24972b";
};
meta = with lib; {
description = "A very fast JSON encoder/decoder for Python";
homepage = "https://ag-projects.com/";
license = licenses.lgpl2;
};
}

View file

@ -1,5 +1,5 @@
{ lib, fetchgit, pkg-config, gettext, runCommand, makeWrapper
, elfutils, kernel, gnumake, python2, python2Packages
, cpio, elfutils, kernel, gnumake, python3
}:
let
@ -16,8 +16,8 @@ let
pname = "systemtap";
inherit version;
src = fetchgit { inherit url rev sha256; };
nativeBuildInputs = [ pkg-config ];
buildInputs = [ elfutils gettext python2 python2Packages.setuptools ];
nativeBuildInputs = [ pkg-config cpio ];
buildInputs = [ elfutils gettext python3 python3.pkgs.setuptools ];
enableParallelBuilding = true;
};
@ -33,7 +33,7 @@ let
done
'';
pypkgs = with python2Packages; makePythonPath [ pyparsing ];
pypkgs = with python3.pkgs; makePythonPath [ pyparsing ];
in runCommand "systemtap-${kernel.version}-${version}" {
inherit stapBuild kernelBuildDir;

View file

@ -1,38 +0,0 @@
{ lib, python2Packages, fetchFromGitHub, pkg-config, glib, alsa-lib, libjack2 }:
python2Packages.buildPythonApplication {
version = "2015-11-17";
pname = "mididings";
src = fetchFromGitHub {
owner = "dsacre";
repo = "mididings";
rev = "bbec99a8c878a2a7029e78e84fc736e4a68ed5a0";
sha256 = "1pdf5mib87zy7yjh9vpasja419h28wvgq6x5hw2hkm7bg9ds4p2m";
};
nativeBuildInputs = [ pkg-config ];
buildInputs = [ glib alsa-lib libjack2 python2Packages.boost ];
propagatedBuildInputs = with python2Packages; [ decorator ]
# for livedings
++ [ tkinter pyliblo ]
# for mididings.extra
++ [ dbus-python pyinotify ]
# to read/write standard MIDI files
++ [ pysmf ]
# so mididings knows where to look for config files
++ [ pyxdg ];
preBuild = with lib.versions; ''
substituteInPlace setup.py \
--replace boost_python "boost_python${major python2Packages.python.version}${minor python2Packages.python.version}"
'';
meta = with lib; {
description = "A MIDI router and processor based on Python, supporting ALSA and JACK MIDI";
homepage = "http://das.nasophon.de/mididings";
license = licenses.gpl2;
maintainers = [ ];
platforms = platforms.linux;
};
}

View file

@ -1,29 +0,0 @@
{ lib, fetchurl, python2Packages }:
python2Packages.buildPythonApplication rec {
pname = "getmail";
version = "5.14";
src = fetchurl {
url = "http://pyropus.ca/software/getmail/old-versions/${pname}-${version}.tar.gz";
sha256 = "1hcrd9h4g12f5gvl1djsbchcjry02ghq4icdr897s8v48pkrzagk";
};
doCheck = false;
postPatch = ''
# getmail spends a lot of effort to build an absolute path for
# documentation installation; too bad it is counterproductive now
sed -e '/datadir or prefix,/d' -i setup.py
'';
meta = {
description = "A program for retrieving mail";
maintainers = [ lib.maintainers.raskin ];
platforms = lib.platforms.linux;
homepage = "http://pyropus.ca/software/getmail/";
updateWalker = true;
license = lib.licenses.gpl2Plus;
};
}

View file

@ -100,6 +100,7 @@ mapAliases ({
bitwarden_rs-postgresql = vaultwarden-postgresql;
bitwarden_rs-vault = vaultwarden-vault;
blink = throw "blink has been removed from nixpkgs, it was unmaintained and required python2 at the time of removal."; # added 2022-01-12
bs1770gain = throw "bs1770gain has been removed from nixpkgs, as it had no maintainer or reverse dependencies."; # added 2021-01-02
bsod = throw "bsod has been removed: deleted by upstream"; # added 2022-01-07
btc1 = throw "btc1 has been removed, it was abandoned by upstream"; # added 2020-11-03
@ -118,6 +119,7 @@ mapAliases ({
casperjs = throw "casperjs has been removed, it was abandoned by upstream and broken.";
catfish = xfce.catfish; # added 2019-12-22
ccnet = throw "ccnet has been removed because seafile does not depend on it anymore"; # added 2021-03-25
cde-gtk-theme = throw "cde-gtk-theme has been removed from nixpkgs as it shipped with python2 scripts that didn't work anymore."; # added 2022-01-12
cgmanager = throw "cgmanager was deprecated by lxc and therefore removed from nixpkgs."; # added 2020-06-05
checkbashism = checkbashisms; # added 2016-08-16
chronos = throw "chronos has been removed from nixpkgs, as it was unmaintained"; # added 2020-08-15
@ -180,6 +182,7 @@ mapAliases ({
cups_filters = cups-filters; # added 2016-08
cups-googlecloudprint = throw "Google Cloudprint is officially discontinued since Jan 2021, more info https://support.google.com/chrome/a/answer/9633006";
cloud-print-connector = throw "Google Cloudprint is officially discontinued since Jan 2021, more info https://support.google.com/chrome/a/answer/9633006";
curaByDagoma = throw "curaByDagoma has been removed from nixpkgs, because it was unmaintained and dependent on python2 packages."; # added 2022-01-12
curaLulzbot = throw "curaLulzbot has been removed due to insufficient upstream support for a modern dependency chain"; # added 2021-10-23
cquery = throw "cquery has been removed because it is abandoned by upstream. Consider switching to clangd or ccls instead."; # added 2020-06-15
cv = progress; # added 2015-09-06
@ -214,6 +217,7 @@ mapAliases ({
desktop_file_utils = desktop-file-utils; # added 2018-02-25
devicemapper = lvm2; # added 2018-04-25
digikam5 = digikam; # added 2017-02-18
displaycal = throw "displaycal has been removed from nixpkgs, as it hasn't migrated to python3."; # added 2022-01-12
dmtx = dmtx-utils; # added 2018-04-25
dnnl = oneDNN; # added 2020-04-22
docbook5_xsl = docbook_xsl_ns; # added 2018-04-25
@ -306,6 +310,7 @@ mapAliases ({
gdb-multitarget = gdb; # added 2017-11-13
gdk_pixbuf = gdk-pixbuf; # added 2019-05-22
gettextWithExpat = gettext; # 2016-02-19
getmail = throw "getmail has been removed from nixpkgs, migrate to getmail6."; # added 2022-01-12
giflib_4_1 = throw "giflib_4_1 has been removed; use giflib instead"; # 2020-02-12
git-bz = throw "giz-bz has been removed from nixpkgs as it is stuck on python2."; # added 2022-01-01
gitAndTools = self // { # added 2021-01-14
@ -318,6 +323,7 @@ mapAliases ({
topGit = top-git;
};
gitin = throw "gitin has been remove because it was unmaintained and depended on an insecure version of libgit2"; # added 2021-12-07
gitinspector = throw "gitinspector has been removed because it doesn't work with python3."; # added 2022-01-12
glib_networking = glib-networking; # added 2018-02-25
gmailieer = lieer; # added 2020-04-19
gmvault = throw "gmvault has been removed because it is unmaintained, mostly broken, and insecure"; # added 2021-03-08
@ -419,6 +425,7 @@ mapAliases ({
kodiGBM = kodi-gbm;
kodiPlain = kodi;
kodiPlainWayland = kodi-wayland;
ino = throw "ino has been removed from nixpkgs, the project is stuck on python2 and upstream has archived the project."; # added 2022-01-12
jellyfin_10_5 = throw "Jellyfin 10.5 is no longer supported and contains a security vulnerability. Please upgrade to a newer version."; # added 2021-04-26
julia_07 = throw "julia_07 has been deprecated in favor of the latest LTS version"; # added 2020-09-15
julia_1 = throw "julia_1 has been deprecated in favor of julia_10 as it was ambiguous"; # added 2021-03-13
@ -565,10 +572,12 @@ mapAliases ({
lua5_1_sockets = lua51Packages.luasocket; # added 2017-05-02
lua5_expat = luaPackages.luaexpat; # added 2017-05-02
lua5_sec = luaPackages.luasec; # added 2017-05-02
lumpy = throw "lumpy has been removed from nixpkgs, as it is stuck on python2."; # added 2022-01-12
lxappearance-gtk3 = throw "lxappearance-gtk3 has been removed. Use lxappearance instead, which now defaults to Gtk3"; # added 2020-06-03
lzma = xz; # moved from top-level 2021-03-14
m3d-linux = m33-linux; # added 2016-08-13
mail-notification = throw "mail-notification has been removed from nixpkgs, as it's unmaintained and has dependencies on old gnome libraries we want to remove"; # added 2021-08-21
mailpile = throw "mailpile was removed from nixpkgs, as it is stuck on python2."; # added 2022-01-12
man_db = man-db; # added 2016-05
manpages = man-pages; # added 2015-12-06
marathon = throw "marathon has been removed from nixpkgs, as it's unmaintained"; # added 2020-08-15
@ -580,8 +589,10 @@ mapAliases ({
mbedtls_1_3 = throw "mbedtls_1_3 is end of life, see https://tls.mbed.org/kb/how-to/upgrade-2.0"; # added 2019-12-08
meme = meme-image-generator; # added 2021-04-21
mess = mame; # added 2019-10-30
metamorphose2 = throw "metamorphose2 has been removed from nixpkgs, as it was stuck on python2."; # added 2022-01-12
mcgrid = throw "mcgrid has been removed from nixpkgs, as it's not compatible with rivet 3"; # added 2020-05-23
mcomix = throw "mcomix has been removed from nixpkgs, as it's unmaintained; try mcomix3 a Python 3 fork"; # added 2019-12-10, modified 2020-11-25
mididings = throw "mididings has been removed from nixpkgs as it doesn't support recent python3 versions and its upstream stopped maintaining it."; # added 2022-01-12
mimms = throw "mimms has been removed from nixpkgs as the upstream project is stuck on python2."; # added 2022-01-01
mirage = throw "mirage has been removed from nixpkgs, as it's unmaintained"; # added 2019-12-10
minergate = throw "minergate has been removed from nixpkgs, because the package is unmaintained and the site has a bad reputation"; # added 2021-08-13
@ -624,6 +635,7 @@ mapAliases ({
nagiosPluginsOfficial = monitoring-plugins;
navit = throw "navit has been removed from nixpkgs, due to being unmaintained"; # added 2021-06-07
ncat = nmap; # added 2016-01-26
neap = throw "neap was removed from nixpkgs, as it relies on python2"; # added 2022-01-12
netcat-openbsd = libressl.nc; # added 2018-04-25
netease-cloud-music = throw "netease-cloud-music has been removed together with deepin"; # added 2020-08-31
networkmanager_fortisslvpn = networkmanager-fortisslvpn; # added 2018-02-25
@ -800,6 +812,9 @@ mapAliases ({
pybind11 = throw "pybind11 was removed because pythonPackages.pybind11 for the appropriate version of Python should be used"; # added 2021-05-14
pybitmessage = throw "pybitmessage was removed from nixpkgs as it is stuck on python2."; # added 2022-01-01
pynagsystemd = throw "pynagsystemd was removed as it was unmaintained and incompatible with recent systemd versions. Instead use its fork check_systemd."; # added 2020-10-24
pyrex = throw "pyrex has been removed from nixpkgs as the project is still stuck on python2."; # added 2022-01-12
pyrex095 = throw "pyrex has been removed from nixpkgs as the project is still stuck on python2."; # added 2022-01-12
pyrex096 = throw "pyrex has been removed from nixpkgs as the project is still stuck on python2."; # added 2022-01-12
pyrit = throw "pyrit has been removed from nixpkgs as the project is still stuck on python2."; # added 2022-01-01
python2nix = throw "python2nix has been removed as it is outdated. Use e.g. nixpkgs-pytools instead."; # added 2021-03-08
python-swiftclient = swiftclient; # added 2021-09-09
@ -843,6 +858,7 @@ mapAliases ({
radare2-cutter = cutter; # added 2021-03-30
redkite = throw "redkite was archived by upstream"; # added 2021-04-12
redshift-wlr = throw "redshift-wlr has been replaced by gammastep"; # added 2021-12-25
renpy = throw "renpy has been removed from nixpkgs, it was unmaintained and the latest packaged version required python2."; # added 2022-01-12
retroArchCores = throw "retroArchCores has been removed. Please use overrides instead, e.g.: `retroarch.override { cores = with libretro; [ ... ]; }`"; # added 2021-11-19
rkt = throw "rkt was archived by upstream"; # added 2020-05-16
rpiboot-unstable = rpiboot; # added 2021-07-30

View file

@ -2197,8 +2197,6 @@ with pkgs;
bitbucket-server-cli = callPackage ../applications/version-management/git-and-tools/bitbucket-server-cli { };
blink = libsForQt5.callPackage ../applications/networking/instant-messengers/blink { };
blitz = callPackage ../development/libraries/blitz { };
blockbook = callPackage ../servers/blockbook { };
@ -3400,8 +3398,6 @@ with pkgs;
midicsv = callPackage ../tools/audio/midicsv { };
mididings = callPackage ../tools/audio/mididings { };
miniscript = callPackage ../applications/blockchains/miniscript { };
miniserve = callPackage ../tools/misc/miniserve {
@ -5583,8 +5579,6 @@ with pkgs;
geteltorito = callPackage ../tools/misc/geteltorito { };
getmail = callPackage ../tools/networking/getmail { };
getmail6 = callPackage ../tools/networking/getmail6 { };
getopt = callPackage ../tools/misc/getopt { };
@ -5817,8 +5811,6 @@ with pkgs;
github-runner = callPackage ../development/tools/continuous-integration/github-runner { };
gitinspector = callPackage ../applications/version-management/gitinspector { };
gitkraken = callPackage ../applications/version-management/gitkraken { };
gitlab = callPackage ../applications/version-management/gitlab { };
@ -7596,8 +7588,6 @@ with pkgs;
mailsend = callPackage ../tools/networking/mailsend { };
mailpile = callPackage ../applications/networking/mailreaders/mailpile { };
mailutils = callPackage ../tools/networking/mailutils {
sasl = gsasl;
};
@ -7701,8 +7691,6 @@ with pkgs;
mencal = callPackage ../applications/misc/mencal { } ;
metamorphose2 = callPackage ../applications/misc/metamorphose2 { };
metar = callPackage ../applications/misc/metar { };
mfcuk = callPackage ../tools/security/mfcuk { };
@ -13775,12 +13763,6 @@ with pkgs;
pyradio = callPackage ../applications/audio/pyradio {};
pyrex = pyrex095;
pyrex095 = callPackage ../development/interpreters/pyrex/0.9.5.nix { };
pyrex096 = callPackage ../development/interpreters/pyrex/0.9.6.nix { };
racket = callPackage ../development/interpreters/racket {
# racket 6.11 doesn't build with gcc6 + recent glibc:
# https://github.com/racket/racket/pull/1886
@ -13813,8 +13795,6 @@ with pkgs;
inherit (ocamlPackages) reason;
renpy = callPackage ../development/interpreters/renpy { };
pixie = callPackage ../development/interpreters/pixie { };
dust = callPackage ../development/interpreters/pixie/dust.nix { };
@ -14911,8 +14891,6 @@ with pkgs;
indent = callPackage ../development/tools/misc/indent { };
ino = callPackage ../development/embedded/arduino/ino { };
inotify-tools = callPackage ../development/tools/misc/inotify-tools { };
intel-gpu-tools = callPackage ../development/tools/misc/intel-gpu-tools { };
@ -23283,8 +23261,6 @@ with pkgs;
cascadia-code = callPackage ../data/fonts/cascadia-code { };
cde-gtk-theme = callPackage ../data/themes/cdetheme { };
charis-sil = callPackage ../data/fonts/charis-sil { };
cherry = callPackage ../data/fonts/cherry { inherit (xorg) fonttosfnt mkfontdir; };
@ -27393,8 +27369,6 @@ with pkgs;
n8n = callPackage ../applications/networking/n8n {};
neap = callPackage ../applications/misc/neap { };
neomutt = callPackage ../applications/networking/mailreaders/neomutt { };
natron = callPackage ../applications/video/natron { };
@ -28614,8 +28588,6 @@ with pkgs;
curaPlugins = callPackage ../applications/misc/cura/plugins.nix { };
curaByDagoma = callPackage ../applications/misc/curabydagoma { };
peru = callPackage ../applications/version-management/peru {};
petrinizer = haskellPackages.callPackage ../applications/science/logic/petrinizer {};
@ -30259,8 +30231,6 @@ with pkgs;
digikam = libsForQt5.callPackage ../applications/graphics/digikam {};
displaycal = callPackage ../applications/graphics/displaycal {};
drumkv1 = libsForQt5.callPackage ../applications/audio/drumkv1 { };
### GAMES
@ -31691,8 +31661,6 @@ with pkgs;
last = callPackage ../applications/science/biology/last { };
lumpy = callPackage ../applications/science/biology/lumpy { };
macse = callPackage ../applications/science/biology/macse { };
MACS2 = callPackage ../applications/science/biology/MACS2 { };

View file

@ -1609,8 +1609,6 @@ in {
cjkwrap = callPackage ../development/python-modules/cjkwrap { };
cjson = callPackage ../development/python-modules/cjson { };
ckcc-protocol = callPackage ../development/python-modules/ckcc-protocol { };
claripy = callPackage ../development/python-modules/claripy { };
@ -2825,9 +2823,7 @@ in {
fints = callPackage ../development/python-modules/fints { };
fiona = callPackage ../development/python-modules/fiona {
gdal = pkgs.gdal_2;
};
fiona = callPackage ../development/python-modules/fiona { };
fipy = callPackage ../development/python-modules/fipy { };
@ -8393,9 +8389,7 @@ in {
inherit (pkgs) libarchive;
};
rasterio = callPackage ../development/python-modules/rasterio {
gdal = pkgs.gdal_2;
};
rasterio = callPackage ../development/python-modules/rasterio { };
ratelim = callPackage ../development/python-modules/ratelim { };