···8899Several versions of the Python interpreter are available on Nix, as well as a
1010high amount of packages. The attribute `python3` refers to the default
1111-interpreter, which is currently CPython 3.8. The attribute `python` refers to
1111+interpreter, which is currently CPython 3.9. The attribute `python` refers to
1212CPython 2.7 for backwards-compatibility. It is also possible to refer to
1313specific versions, e.g. `python38` refers to CPython 3.8, and `pypy` refers to
1414the default PyPy interpreter.
···839839and the aliases
840840841841* `pkgs.python2Packages` pointing to `pkgs.python27Packages`
842842-* `pkgs.python3Packages` pointing to `pkgs.python38Packages`
842842+* `pkgs.python3Packages` pointing to `pkgs.python39Packages`
843843* `pkgs.pythonPackages` pointing to `pkgs.python2Packages`
844844845845#### `buildPythonPackage` function {#buildpythonpackage-function}
···1414 </itemizedlist>
1515 <section xml:id="sec-release-21.11-highlights">
1616 <title>Highlights</title>
1717- <itemizedlist spacing="compact">
1717+ <itemizedlist>
1818 <listitem>
1919 <para>
2020 PHP now defaults to PHP 8.0, updated from 7.4.
···2424 <para>
2525 kOps now defaults to 1.21.0, which uses containerd as the
2626 default runtime.
2727+ </para>
2828+ </listitem>
2929+ <listitem>
3030+ <para>
3131+ <literal>python3</literal> now defaults to Python 3.9, updated
3232+ from Python 3.8.
2733 </para>
2834 </listitem>
2935 </itemizedlist>
···97103 <link xlink:href="https://github.com/hockeypuck/hockeypuck">Hockeypuck</link>,
98104 a OpenPGP Key Server. Available as
99105 <link linkend="opt-services.hockeypuck.enable">services.hockeypuck</link>.
106106+ </para>
107107+ </listitem>
108108+ <listitem>
109109+ <para>
110110+ <link xlink:href="https://github.com/buildkite/buildkite-agent-metrics">buildkite-agent-metrics</link>,
111111+ a command-line tool for collecting Buildkite agent metrics,
112112+ now has a Prometheus exporter available as
113113+ <link linkend="opt-services.prometheus.exporters.buildkite-agent.enable">services.prometheus.exporters.buildkite-agent</link>.
100114 </para>
101115 </listitem>
102116 </itemizedlist>
···556570 soon <literal>foot</literal>) so this is only an issue when
557571 using a customized configuration and not installing
558572 <literal>rxvt-unicode</literal> explicitly.
573573+ </para>
574574+ </listitem>
575575+ <listitem>
576576+ <para>
577577+ <literal>python3</literal> now defaults to Python 3.9. Python
578578+ 3.9 introduces many deprecation warnings, please look at the
579579+ <link xlink:href="https://docs.python.org/3/whatsnew/3.9.html">What’s
580580+ New In Python 3.9 post</link> for more information.
559581 </para>
560582 </listitem>
561583 <listitem>
+5
nixos/doc/manual/release-notes/rl-2111.section.md
···99- PHP now defaults to PHP 8.0, updated from 7.4.
1010- kOps now defaults to 1.21.0, which uses containerd as the default runtime.
11111212+- `python3` now defaults to Python 3.9, updated from Python 3.8.
1313+1214## New Services {#sec-release-21.11-new-services}
13151416- [btrbk](https://digint.ch/btrbk/index.html), a backup tool for btrfs subvolumes, taking advantage of btrfs specific capabilities to create atomic snapshots and transfer them incrementally to your backup locations. Available as [services.btrbk](options.html#opt-services.brtbk.instances).
···30323133- [Hockeypuck](https://github.com/hockeypuck/hockeypuck), a OpenPGP Key Server. Available as [services.hockeypuck](#opt-services.hockeypuck.enable).
32343535+- [buildkite-agent-metrics](https://github.com/buildkite/buildkite-agent-metrics), a command-line tool for collecting Buildkite agent metrics, now has a Prometheus exporter available as [services.prometheus.exporters.buildkite-agent](#opt-services.prometheus.exporters.buildkite-agent.enable).
33363437## Backward Incompatibilities {#sec-release-21.11-incompatibilities}
3538···139142 However, if [`services.fail2ban.enable`](options.html#opt-services.fail2ban.enable) is `true`, the `fail2ban` will override the verbosity to `"VERBOSE"`, so that `fail2ban` can observe the failed login attempts from the SSH logs.
140143141144- Sway: The terminal emulator `rxvt-unicode` is no longer installed by default via `programs.sway.extraPackages`. The current default configuration uses `alacritty` (and soon `foot`) so this is only an issue when using a customized configuration and not installing `rxvt-unicode` explicitly.
145145+146146+- `python3` now defaults to Python 3.9. Python 3.9 introduces many deprecation warnings, please look at the [What's New In Python 3.9 post](https://docs.python.org/3/whatsnew/3.9.html) for more information.
142147143148- The `claws-mail` package now references the new GTK+ 3 release branch, major version 4. To use the GTK+ 2 releases, one can install the `claws-mail-gtk2` package.
144149
+2-2
nixos/lib/test-driver/test-driver.py
···499499 output += out
500500 return output
501501502502- def wait_until_succeeds(self, command: str) -> str:
502502+ def wait_until_succeeds(self, command: str, timeout: int = 900) -> str:
503503 """Wait until a command returns success and return its output.
504504 Throws an exception on timeout.
505505 """
···511511 return status == 0
512512513513 with self.nested("waiting for success: {}".format(command)):
514514- retry(check_success)
514514+ retry(check_success, timeout)
515515 return output
516516517517 def wait_until_fails(self, command: str) -> str:
···1717 # When updating, please check if https://github.com/csound/csound/issues/1078
1818 # has been fixed in the new version so we can use the normal fluidsynth
1919 # version and remove fluidsynth 1.x from nixpkgs again.
2020- version = "6.16.0";
2020+ version = "6.16.2";
21212222 hardeningDisable = [ "format" ];
2323···2525 owner = "csound";
2626 repo = "csound";
2727 rev = version;
2828- sha256 = "sha256-1+P2W8auc34sNJdKHUcilOBCK+Is9GHnM+J+M4oNR3U=";
2828+ sha256 = "sha256-1rcS3kOspU9ACx45yB8betph4G0hso1OSJQRiabX6tE=";
2929 };
30303131 cmakeFlags = [ "-DBUILD_CSOUND_AC=0" ] # fails to find Score.hpp
···124124 # This means `-accel hvf` is broken for now, on aarch64-darwin only.
125125 substituteInPlace meson.build \
126126 --replace 'if exe_sign' 'if false'
127127+128128+ # glibc 2.33 compat fix: if `has_statx = true` is set, `tools/virtiofsd/passthrough_ll.c` will
129129+ # rely on `stx_mnt_id`[1] which is not part of glibc's `statx`-struct definition.
130130+ #
131131+ # `has_statx` will be set to `true` if a simple C program which uses a few `statx`
132132+ # consts & struct fields successfully compiles. It seems as this only builds on glibc-2.33
133133+ # since most likely[2] and because of that, the problematic code-path will be used.
134134+ #
135135+ # [1] https://github.com/torvalds/linux/commit/fa2fcf4f1df1559a0a4ee0f46915b496cc2ebf60#diff-64bab5a0a3fcb55e1a6ad77b1dfab89d2c9c71a770a07ecf44e6b82aae76a03a
136136+ # [2] https://sourceware.org/git/?p=glibc.git;a=blobdiff;f=io/bits/statx-generic.h;h=c34697e3c1fd79cddd60db294302e461ed8db6e2;hp=7a09e94be2abb92d2df612090c132e686a24d764;hb=88a2cf6c4bab6e94a65e9c0db8813709372e9180;hpb=c4e4b2e149705559d28b16a9b47ba2f6142d6a6c
137137+ substituteInPlace meson.build \
138138+ --replace 'has_statx = cc.links(statx_test)' 'has_statx = false'
127139 '';
128140129141 preConfigure = ''
···11-diff --git a/hints/darwin.sh b/hints/darwin.sh
22-index 0a91bc083c0..fdfbdd4a3b9 100644
33---- a/hints/darwin.sh
44-+++ b/hints/darwin.sh
55-@@ -301,7 +301,7 @@ case "$osvers" in # Note: osvers is the kernel version, not the 10.x
66- # We now use MACOSX_DEPLOYMENT_TARGET, if set, as an override by
77- # capturing its value and adding it to the flags.
88- case "$MACOSX_DEPLOYMENT_TARGET" in
99-- 10.*)
1010-+ [1-9][0-9].*)
1111- add_macosx_version_min ccflags $MACOSX_DEPLOYMENT_TARGET
1212- add_macosx_version_min ldflags $MACOSX_DEPLOYMENT_TARGET
1313- ;;
1414-@@ -313,7 +313,7 @@ case "$osvers" in # Note: osvers is the kernel version, not the 10.x
1515-1616- *** Unexpected MACOSX_DEPLOYMENT_TARGET=$MACOSX_DEPLOYMENT_TARGET
1717- ***
1818--*** Please either set it to 10.something, or to empty.
1919-+*** Please either set it to a valid macOS version number (e.g., 10.15) or to empty.
2020-2121- EOM
2222- exit 1
2323-@@ -327,7 +327,7 @@ EOM
2424- # "ProductVersion: 10.11" "10.11"
2525- prodvers=`sw_vers|awk '/^ProductVersion:/{print $2}'|awk -F. '{print $1"."$2}'`
2626- case "$prodvers" in
2727-- 10.*)
2828-+ [1-9][0-9].*)
2929- add_macosx_version_min ccflags $prodvers
3030- add_macosx_version_min ldflags $prodvers
3131- ;;
3232-@@ -342,11 +342,10 @@ EOM
3333- exit 1
3434- esac
3535-3636-- # The X in 10.X
3737-- prodvers_minor=$(echo $prodvers|awk -F. '{print $2}')
3838-+ darwin_major=$(echo $osvers|awk -F. '{print $1}')
3939-4040-- # macOS (10.12) deprecated syscall().
4141-- if [ "$prodvers_minor" -ge 12 ]; then
4242-+ # macOS 10.12 (darwin 16.0.0) deprecated syscall().
4343-+ if [ "$darwin_major" -ge 16 ]; then
4444- d_syscall='undef'
4545- # If deploying to pre-10.12, suppress Time::HiRes's detection of the system clock_gettime()
4646- case "$MACOSX_DEPLOYMENT_TARGET" in
+10-14
pkgs/development/interpreters/perl/default.nix
···3737 patches =
3838 [
3939 # Do not look in /usr etc. for dependencies.
4040- (if (versionOlder version "5.31.1") then ./no-sys-dirs-5.29.patch
4141- else ./no-sys-dirs-5.31.patch)
4040+ ./no-sys-dirs-5.31.patch
4241 ]
4342 ++ optional stdenv.isSunOS ./ld-shared.patch
4443 ++ optionals stdenv.isDarwin [ ./cpp-precomp.patch ./sw_vers.patch ]
4545- ++ optional crossCompiling ./MakeMaker-cross.patch
4646- # Backporting https://github.com/Perl/perl5/pull/17946, can be
4747- # removed if there's ever a 5.30.x release with it included.
4848- ++ optional (versionOlder version "5.32.1") ./aarch64-darwin.patch;
4444+ ++ optional crossCompiling ./MakeMaker-cross.patch;
49455046 # This is not done for native builds because pwd may need to come from
5147 # bootstrap tools when building bootstrap perl.
···197193 });
198194in {
199195 # Maint version
200200- perl530 = common {
201201- perl = pkgs.perl530;
202202- buildPerl = buildPackages.perl530;
203203- version = "5.30.3";
204204- sha256 = "0vs0wwwlw47sswxaflkk4hw0y45cmc7arxx788kwpbminy5lrq1j";
205205- };
206206-207207- # Maint version
208196 perl532 = common {
209197 perl = pkgs.perl532;
210198 buildPerl = buildPackages.perl532;
211199 version = "5.32.1";
212200 sha256 = "0b7brakq9xs4vavhg391as50nbhzryc7fy5i65r81bnq3j897dh3";
201201+ };
202202+203203+ # Maint version
204204+ perl534 = common {
205205+ perl = pkgs.perl534;
206206+ buildPerl = buildPackages.perl534;
207207+ version = "5.34.0";
208208+ sha256 = "16mywn5afpv1mczv9dlc1w84rbgjgrr0pyr4c0hhb2wnif0zq7jm";
213209 };
214210215211 # the latest Devel version
···11-diff -ru -x '*~' -x '*.rej' perl-5.20.0-orig/Configure perl-5.20.0/Configure
22---- perl-5.20.0-orig/Configure 2014-05-26 15:34:18.000000000 +0200
33-+++ perl-5.20.0/Configure 2014-06-25 10:43:35.368285986 +0200
44-@@ -106,15 +106,7 @@
55- fi
66-77- : Proper PATH setting
88--paths='/bin /usr/bin /usr/local/bin /usr/ucb /usr/local /usr/lbin'
99--paths="$paths /opt/bin /opt/local/bin /opt/local /opt/lbin"
1010--paths="$paths /usr/5bin /etc /usr/gnu/bin /usr/new /usr/new/bin /usr/nbin"
1111--paths="$paths /opt/gnu/bin /opt/new /opt/new/bin /opt/nbin"
1212--paths="$paths /sys5.3/bin /sys5.3/usr/bin /bsd4.3/bin /bsd4.3/usr/ucb"
1313--paths="$paths /bsd4.3/usr/bin /usr/bsd /bsd43/bin /opt/ansic/bin /usr/ccs/bin"
1414--paths="$paths /etc /usr/lib /usr/ucblib /lib /usr/ccs/lib"
1515--paths="$paths /sbin /usr/sbin /usr/libexec"
1616--paths="$paths /system/gnu_library/bin"
1717-+paths=''
1818-1919- for p in $paths
2020- do
2121-@@ -1337,8 +1329,7 @@
2222- archname=''
2323- : Possible local include directories to search.
2424- : Set locincpth to "" in a hint file to defeat local include searches.
2525--locincpth="/usr/local/include /opt/local/include /usr/gnu/include"
2626--locincpth="$locincpth /opt/gnu/include /usr/GNU/include /opt/GNU/include"
2727-+locincpth=""
2828- :
2929- : no include file wanted by default
3030- inclwanted=''
3131-@@ -1349,17 +1340,12 @@
3232-3333- libnames=''
3434- : change the next line if compiling for Xenix/286 on Xenix/386
3535--xlibpth='/usr/lib/386 /lib/386'
3636-+xlibpth=''
3737- : Possible local library directories to search.
3838--loclibpth="/usr/local/lib /opt/local/lib /usr/gnu/lib"
3939--loclibpth="$loclibpth /opt/gnu/lib /usr/GNU/lib /opt/GNU/lib"
4040-+loclibpth=""
4141-4242- : general looking path for locating libraries
4343--glibpth="/lib /usr/lib $xlibpth"
4444--glibpth="$glibpth /usr/ccs/lib /usr/ucblib /usr/local/lib"
4545--test -f /usr/shlib/libc.so && glibpth="/usr/shlib $glibpth"
4646--test -f /shlib/libc.so && glibpth="/shlib $glibpth"
4747--test -d /usr/lib64 && glibpth="$glibpth /lib64 /usr/lib64 /usr/local/lib64"
4848-+glibpth=""
4949-5050- : Private path used by Configure to find libraries. Its value
5151- : is prepended to libpth. This variable takes care of special
5252-@@ -1391,8 +1377,6 @@
5353- libswanted="$libswanted m crypt sec util c cposix posix ucb bsd BSD"
5454- : We probably want to search /usr/shlib before most other libraries.
5555- : This is only used by the lib/ExtUtils/MakeMaker.pm routine extliblist.
5656--glibpth=`echo " $glibpth " | sed -e 's! /usr/shlib ! !'`
5757--glibpth="/usr/shlib $glibpth"
5858- : Do not use vfork unless overridden by a hint file.
5959- usevfork=false
6060-6161-@@ -2446,7 +2430,6 @@
6262- zip
6363- "
6464- pth=`echo $PATH | sed -e "s/$p_/ /g"`
6565--pth="$pth $sysroot/lib $sysroot/usr/lib"
6666- for file in $loclist; do
6767- eval xxx=\$$file
6868- case "$xxx" in
6969-@@ -4936,7 +4919,7 @@
7070- : Set private lib path
7171- case "$plibpth" in
7272- '') if ./mips; then
7373-- plibpth="$incpath/usr/lib $sysroot/usr/local/lib $sysroot/usr/ccs/lib"
7474-+ plibpth="$incpath/usr/lib"
7575- fi;;
7676- esac
7777- case "$libpth" in
7878-@@ -8600,13 +8583,8 @@
7979- echo " "
8080- case "$sysman" in
8181- '')
8282-- syspath='/usr/share/man/man1 /usr/man/man1'
8383-- syspath="$syspath /usr/man/mann /usr/man/manl /usr/man/local/man1"
8484-- syspath="$syspath /usr/man/u_man/man1"
8585-- syspath="$syspath /usr/catman/u_man/man1 /usr/man/l_man/man1"
8686-- syspath="$syspath /usr/local/man/u_man/man1 /usr/local/man/l_man/man1"
8787-- syspath="$syspath /usr/man/man.L /local/man/man1 /usr/local/man/man1"
8888-- sysman=`./loc . /usr/man/man1 $syspath`
8989-+ syspath=''
9090-+ sysman=''
9191- ;;
9292- esac
9393- if $test -d "$sysman"; then
9494-@@ -19900,9 +19878,10 @@
9595- case "$full_ar" in
9696- '') full_ar=$ar ;;
9797- esac
9898-+full_ar=ar
9999-100100- : Store the full pathname to the sed program for use in the C program
101101--full_sed=$sed
102102-+full_sed=sed
103103-104104- : see what type gids are declared as in the kernel
105105- echo " "
106106-Only in perl-5.20.0/: Configure.orig
107107-diff -ru -x '*~' -x '*.rej' perl-5.20.0-orig/ext/Errno/Errno_pm.PL perl-5.20.0/ext/Errno/Errno_pm.PL
108108---- perl-5.20.0-orig/ext/Errno/Errno_pm.PL 2014-05-26 15:34:20.000000000 +0200
109109-+++ perl-5.20.0/ext/Errno/Errno_pm.PL 2014-06-25 10:31:24.317970047 +0200
110110-@@ -134,12 +126,7 @@
111111- if ($dep =~ /(\S+errno\.h)/) {
112112- $file{$1} = 1;
113113- }
114114-- } elsif ($^O eq 'linux' &&
115115-- $Config{gccversion} ne '' &&
116116-- $Config{gccversion} !~ /intel/i &&
117117-- # might be using, say, Intel's icc
118118-- $linux_errno_h
119119-- ) {
120120-+ } elsif (0) {
121121- $file{$linux_errno_h} = 1;
122122- } elsif ($^O eq 'haiku') {
123123- # hidden in a special place
124124-Only in perl-5.20.0/ext/Errno: Errno_pm.PL.orig
125125-diff -ru -x '*~' -x '*.rej' perl-5.20.0-orig/hints/freebsd.sh perl-5.20.0/hints/freebsd.sh
126126---- perl-5.20.0-orig/hints/freebsd.sh 2014-01-31 22:55:51.000000000 +0100
127127-+++ perl-5.20.0/hints/freebsd.sh 2014-06-25 10:25:53.263964680 +0200
128128-@@ -119,21 +119,21 @@
129129- objformat=`/usr/bin/objformat`
130130- if [ x$objformat = xaout ]; then
131131- if [ -e /usr/lib/aout ]; then
132132-- libpth="/usr/lib/aout /usr/local/lib /usr/lib"
133133-- glibpth="/usr/lib/aout /usr/local/lib /usr/lib"
134134-+ libpth=""
135135-+ glibpth=""
136136- fi
137137- lddlflags='-Bshareable'
138138- else
139139-- libpth="/usr/lib /usr/local/lib"
140140-- glibpth="/usr/lib /usr/local/lib"
141141-+ libpth=""
142142-+ glibpth=""
143143- ldflags="-Wl,-E "
144144- lddlflags="-shared "
145145- fi
146146- cccdlflags='-DPIC -fPIC'
147147- ;;
148148- *)
149149-- libpth="/usr/lib /usr/local/lib"
150150-- glibpth="/usr/lib /usr/local/lib"
151151-+ libpth=""
152152-+ glibpth=""
153153- ldflags="-Wl,-E "
154154- lddlflags="-shared "
155155- cccdlflags='-DPIC -fPIC'
156156-diff -ru -x '*~' -x '*.rej' perl-5.20.0-orig/hints/linux.sh perl-5.20.0/hints/linux.sh
157157---- perl-5.20.0-orig/hints/linux.sh 2014-05-26 15:34:20.000000000 +0200
158158-+++ perl-5.20.0/hints/linux.sh 2014-06-25 10:33:47.354883843 +0200
159159-@@ -150,25 +150,6 @@
160160- ;;
161161- esac
162162-163163--# Ubuntu 11.04 (and later, presumably) doesn't keep most libraries
164164--# (such as -lm) in /lib or /usr/lib. So we have to ask gcc to tell us
165165--# where to look. We don't want gcc's own libraries, however, so we
166166--# filter those out.
167167--# This could be conditional on Unbuntu, but other distributions may
168168--# follow suit, and this scheme seems to work even on rather old gcc's.
169169--# This unconditionally uses gcc because even if the user is using another
170170--# compiler, we still need to find the math library and friends, and I don't
171171--# know how other compilers will cope with that situation.
172172--# Morever, if the user has their own gcc earlier in $PATH than the system gcc,
173173--# we don't want its libraries. So we try to prefer the system gcc
174174--# Still, as an escape hatch, allow Configure command line overrides to
175175--# plibpth to bypass this check.
176176--if [ -x /usr/bin/gcc ] ; then
177177-- gcc=/usr/bin/gcc
178178--else
179179-- gcc=gcc
180180--fi
181181--
182182- case "$plibpth" in
183183- '') plibpth=`LANG=C LC_ALL=C $gcc $ccflags $ldflags -print-search-dirs | grep libraries |
184184- cut -f2- -d= | tr ':' $trnl | grep -v 'gcc' | sed -e 's:/$::'`
185185-@@ -178,32 +159,6 @@
186186- ;;
187187- esac
188188-189189--case "$libc" in
190190--'')
191191--# If you have glibc, then report the version for ./myconfig bug reporting.
192192--# (Configure doesn't need to know the specific version since it just uses
193193--# gcc to load the library for all tests.)
194194--# We don't use __GLIBC__ and __GLIBC_MINOR__ because they
195195--# are insufficiently precise to distinguish things like
196196--# libc-2.0.6 and libc-2.0.7.
197197-- for p in $plibpth
198198-- do
199199-- for trylib in libc.so.6 libc.so
200200-- do
201201-- if $test -e $p/$trylib; then
202202-- libc=`ls -l $p/$trylib | awk '{print $NF}'`
203203-- if $test "X$libc" != X; then
204204-- break
205205-- fi
206206-- fi
207207-- done
208208-- if $test "X$libc" != X; then
209209-- break
210210-- fi
211211-- done
212212-- ;;
213213--esac
214214--
215215- if ${sh:-/bin/sh} -c exit; then
216216- echo ''
217217- echo 'You appear to have a working bash. Good.'
218218-@@ -367,33 +322,6 @@
219219- ;;
220220- esac
221221-222222--# SuSE8.2 has /usr/lib/libndbm* which are ld scripts rather than
223223--# true libraries. The scripts cause binding against static
224224--# version of -lgdbm which is a bad idea. So if we have 'nm'
225225--# make sure it can read the file
226226--# NI-S 2003/08/07
227227--case "$nm" in
228228-- '') ;;
229229-- *)
230230-- for p in $plibpth
231231-- do
232232-- if $test -r $p/libndbm.so; then
233233-- if $nm $p/libndbm.so >/dev/null 2>&1 ; then
234234-- echo 'Your shared -lndbm seems to be a real library.'
235235-- _libndbm_real=1
236236-- break
237237-- fi
238238-- fi
239239-- done
240240-- if $test "X$_libndbm_real" = X; then
241241-- echo 'Your shared -lndbm is not a real library.'
242242-- set `echo X "$libswanted "| sed -e 's/ ndbm / /'`
243243-- shift
244244-- libswanted="$*"
245245-- fi
246246-- ;;
247247--esac
248248--
249249- # Linux on Synology.
250250- if [ -f /etc/synoinfo.conf -a -d /usr/syno ]; then
251251- # Tested on Synology DS213 and DS413
···3939, includeSiteCustomize ? true
4040, static ? stdenv.hostPlatform.isStatic
4141, enableOptimizations ? false
4242+# enableNoSemanticInterposition is a subset of the enableOptimizations flag that doesn't harm reproducibility.
4343+# clang starts supporting `-fno-sematic-interposition` with version 10
4444+, enableNoSemanticInterposition ? (!stdenv.cc.isClang || (stdenv.cc.isClang && lib.versionAtLeast stdenv.cc.version "10"))
4545+# enableLTO is a subset of the enableOptimizations flag that doesn't harm reproducibility.
4646+# enabling LTO on 32bit arch causes downstream packages to fail when linking
4747+# enabling LTO on *-darwin causes python3 to fail when linking.
4848+, enableLTO ? stdenv.is64bit && stdenv.isLinux
4249, reproducibleBuild ? true
4350, pythonAttr ? "python${sourceVersion.major}${sourceVersion.minor}"
4451}:
···100107 ] ++ optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
101108 buildPackages.stdenv.cc
102109 pythonForBuild
110110+ ] ++ optionals (stdenv.cc.isClang && enableLTO) [
111111+ stdenv.cc.cc.libllvm.out
103112 ];
104113105114 buildInputs = filter (p: p != null) ([
···190199 # (since it will do a futile invocation of gcc (!) to find
191200 # libuuid, slowing down program startup a lot).
192201 (./. + "/${sourceVersion.major}.${sourceVersion.minor}/no-ldconfig.patch")
202202+ # Make sure that the virtualenv activation scripts are
203203+ # owner-writable, so venvs can be recreated without permission
204204+ # errors.
205205+ ./virtualenv-permissions.patch
193206 ] ++ optionals mimetypesSupport [
194207 # Make the mimetypes module refer to the right file
195208 ./mimetypes.patch
···274287 "--with-system-ffi"
275288 ] ++ optionals enableOptimizations [
276289 "--enable-optimizations"
290290+ ] ++ optionals enableLTO [
291291+ "--with-lto"
277292 ] ++ optionals (pythonOlder "3.7") [
278293 # This is unconditionally true starting in CPython 3.7.
279294 "--with-threads"
···323338 export DETERMINISTIC_BUILD=1;
324339 '' + optionalString stdenv.hostPlatform.isMusl ''
325340 export NIX_CFLAGS_COMPILE+=" -DTHREAD_STACK_SIZE=0x100000"
341341+ '' +
342342+343343+ # enableNoSemanticInterposition essentially sets that CFLAG -fno-semantic-interposition
344344+ # which changes how symbols are looked up. This essentially means we can't override
345345+ # libpython symbols via LD_PRELOAD anymore. This is common enough as every build
346346+ # that uses --enable-optimizations has the same "issue".
347347+ #
348348+ # The Fedora wiki has a good article about their journey towards enabling this flag:
349349+ # https://fedoraproject.org/wiki/Changes/PythonNoSemanticInterpositionSpeedup
350350+ optionalString enableNoSemanticInterposition ''
351351+ export CFLAGS_NODIST="-fno-semantic-interposition"
326352 '';
327353328354 setupHook = python-setup-hook sitePackages;
···292292 # `applemedia/videotexturecache.h` requires `gst/gl/gl.h`,
293293 # but its meson build system does not declare the dependency.
294294 "-Dapplemedia=disabled"
295295+ ] ++ lib.optionals (stdenv.buildPlatform != stdenv.hostPlatform) [
296296+ "-Dintrospection=disabled"
295297 ];
296298297299 # Argument list too long
···105105 "-Dgl-graphene=disabled" # not packaged in nixpkgs as of writing
106106 # See https://github.com/GStreamer/gst-plugins-base/blob/d64a4b7a69c3462851ff4dcfa97cc6f94cd64aef/meson_options.txt#L15 for a list of choices
107107 "-Dgl_winsys=${lib.concatStringsSep "," (lib.optional enableX11 "x11" ++ lib.optional enableWayland "wayland" ++ lib.optional enableCocoa "cocoa")}"
108108+ ] ++ lib.optionals (stdenv.buildPlatform != stdenv.hostPlatform) [
109109+ "-Dintrospection=disabled"
108110 ]
109111 ++ lib.optional (!enableX11) "-Dx11=disabled"
110112 # TODO How to disable Wayland?
···7676 "-Ddbghelp=disabled" # not needed as we already provide libunwind and libdw, and dbghelp is a fallback to those
7777 "-Dexamples=disabled" # requires many dependencies and probably not useful for our users
7878 "-Ddoc=disabled" # `hotdoc` not packaged in nixpkgs as of writing
7979+ ] ++ lib.optionals (stdenv.buildPlatform != stdenv.hostPlatform) [
8080+ "-Dintrospection=disabled"
7981 ] ++ lib.optionals stdenv.isDarwin [
8082 # darwin.libunwind doesn't have pkg-config definitions so meson doesn't detect it.
8183 "-Dlibunwind=disabled"
···22222323 propagatedBuildInputs = [ agate sqlalchemy ];
24242525+ # crate is broken in nixpkgs, with SQLAlchemy > 1.3
2626+ # Skip tests for now as they rely on it.
2727+ doCheck = false;
2828+2529 checkInputs = [ crate nose geojson ];
26302731 checkPhase = ''
+2-2
pkgs/development/python-modules/ansible/base.nix
···2828in
2929buildPythonPackage rec {
3030 pname = "ansible-base";
3131- version = "2.10.11";
3131+ version = "2.10.12";
32323333 src = fetchPypi {
3434 inherit pname version;
3535- sha256 = "0jr3cxqiami9k07g2kmvfp54iafbcnd1d66l8fdnaqka5bc19wdw";
3535+ sha256 = "sha256-qWVW4tI5+Sg+FWVNQMGqhmgqTntD9Qtf8CK8jkK2mHg=";
3636 };
37373838 # ansible_connection is already wrapped, so don't pass it through
+4-4
pkgs/development/python-modules/ansible/core.nix
···23232424let
2525 ansible-collections = callPackage ./collections.nix {
2626- version = "4.1.0";
2727- sha256 = "0rrivq1g0vizah8zmf012lzig2xxfk5x1371k16s3nn4zfkwqqgm";
2626+ version = "4.2.0";
2727+ sha256 = "1l30j97q24klylchvbskdmp1xllswn9xskjvg4l0ra6pzfgq2zbk";
2828 };
2929in
3030buildPythonPackage rec {
3131 pname = "ansible-core";
3232- version = "2.11.2";
3232+ version = "2.11.3";
33333434 src = fetchPypi {
3535 inherit pname version;
3636- sha256 = "1syadgzn5ww5bhq9s2py4h1hkh11h7aac5b37zi8rw2xfvdc7r2s";
3636+ sha256 = "sha256-DO0bT2cZftsntQk0yV1MtkTG1jXXLH+CbEQl3+RTdnQ=";
3737 };
38383939 # ansible_connection is already wrapped, so don't pass it through
···3939 description = "A Python client library for CrateDB";
4040 license = licenses.asl20;
4141 maintainers = with maintainers; [ doronbehar ];
4242+ # 2021-07-12 (@layus): Please unbreak when an update fixes compatibility
4343+ # with the version of SQLAlchemy in nixpkgs
4444+ # And also re-enable tests in pythonPackages.agate-sql.
4545+ # The version string below is intentionally split, so nixpkgs-update does
4646+ # not change it. That would make this warning pretty useless.
4747+ broken = assert version == "0.2"+"6.0"; true;
4248 };
4349}
···11-{ lib, isPy27, isPy38, fetchFromGitHub, buildPythonPackage, pythonOlder, fetchpatch, flake8, importlib-metadata, six }:
11+{ lib
22+, buildPythonPackage
33+, fetchFromGitHub
44+, pythonAtLeast
55+, isPy27
66+, flake8
77+, six
88+, python
99+}:
210311buildPythonPackage rec {
412 pname = "flake8-future-import";
···1220 sha256 = "00q8n15xdnvqj454arn7xxksyrzh0dw996kjyy7g9rdk0rf8x82z";
1321 };
14221515- propagatedBuildInputs = [ flake8 six ]
1616- ++ lib.optionals (pythonOlder "3.8") [
1717- importlib-metadata
1818- ];
2323+ patches = lib.optionals (pythonAtLeast "3.8") [
2424+ ./fix-annotations-version.patch
2525+ ] ++ lib.optionals isPy27 [
2626+ # Upstream disables this test case naturally on python 3, but it also fails
2727+ # inside NixPkgs for python 2. Since it's going to be deleted, we just skip it
2828+ # on py2 as well.
2929+ ./skip-test.patch
3030+ ];
3131+3232+ propagatedBuildInputs = [ flake8 ];
3333+3434+ checkInputs = [ six ];
19352020- # Upstream disables this test case naturally on python 3, but it also fails
2121- # inside NixPkgs for python 2. Since it's going to be deleted, we just skip it
2222- # on py2 as well.
2323- patches = lib.optionals isPy38 [ ./fix-annotations-version.patch ]
2424- ++ lib.optionals isPy27 [ ./skip-test.patch ];
3636+ checkPhase = ''
3737+ ${python.interpreter} -m test_flake8_future_import
3838+ '';
25392640 meta = with lib; {
2741 description = "A flake8 extension to check for the imported __future__ modules to make it easier to have a consistent code base";
···11+From e00a5257a6ca5fedbf68b09eee7df3502971a057 Mon Sep 17 00:00:00 2001
22+From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= <joerg@thalheim.io>
33+Date: Sat, 24 Apr 2021 10:11:40 +0200
44+Subject: [PATCH 1/2] No impure bin sh
55+66+default_shell is used to populuate default shell used to execute jobs.
77+Unless SHELL is set to a different value this would be /bin/sh.
88+Our stdenv provides sh in form of bash anyway. Having this value not
99+hard-coded has some advantages:
1010+1111+- It would ensure that on all systems it uses sh from its PATH rather
1212+ than /bin/sh, which helps as different systems might have different
1313+ shells there (bash vs. dash)
1414+- In the past I had issues with LD_PRELOAD with BEAR, where /bin/sh
1515+ used a different glibc than BEAR which came from my development shell.
1616+---
1717+ src/job.c | 2 +-
1818+ 1 file changed, 1 insertion(+), 1 deletion(-)
1919+2020+diff --git a/src/job.c b/src/job.c
2121+index ae1f18b..6b4ddb3 100644
2222+--- a/src/job.c
2323++++ b/src/job.c
2424+@@ -77,7 +77,7 @@ char * vms_strsignal (int status);
2525+2626+ #else
2727+2828+-const char *default_shell = "/bin/sh";
2929++const char *default_shell = "sh";
3030+ int batch_mode_shell = 0;
3131+3232+ #endif
3333+--
3434+2.31.1
3535+
···99 sha256 = "06cfqzpqsvdnsxbysl5p2fgdgxgl9y4p7scpnrfa8z2zgkjdspz0";
1010 };
11111212+ # to update apply these patches with `git am *.patch` to https://git.savannah.gnu.org/git/make.git
1213 patches = [
1414+ # Replaces /bin/sh with sh, see patch file for reasoning
1515+ ./0001-No-impure-bin-sh.patch
1316 # Purity: don't look for library dependencies (of the form `-lfoo') in /lib
1417 # and /usr/lib. It's a stupid feature anyway. Likewise, when searching for
1518 # included Makefiles, don't look in /usr/include and friends.
1616- ./impure-dirs.patch
1919+ ./0002-remove-impure-dirs.patch
1720 ];
18211922 nativeBuildInputs = lib.optionals guileSupport [ pkg-config ];
···2626 })
2727 (fetchNuGet {
2828 name = "Fody";
2929- version = "6.5.1";
3030- sha256 = "08zpyrniajjba5isjb09spggfh0af2z6x4h2zy5ilk3y5bb9vdch";
2929+ version = "6.5.2";
3030+ sha256 = "0vq97mkfk5ijinwnhpkm212y69ik6cd5x0n61ssyxmz50q1vp84f";
3131 })
3232 (fetchNuGet {
3333 name = "HidSharpCore";
···781781 })
782782 (fetchNuGet {
783783 name = "ppy.LocalisationAnalyser";
784784- version = "2021.706.0";
785785- sha256 = "087x61vi1rv1slzr8hhcslngdd41p2d5r8yhpqm1kmls24csv556";
784784+ version = "2021.716.0";
785785+ sha256 = "0w45af0mlh4bkjxxhk5p4kb6z0na8fmm6xz10dfzs3b4i61h5x3z";
786786 })
787787 (fetchNuGet {
788788 name = "ppy.osu.Framework";
789789- version = "2021.707.0";
790790- sha256 = "1ai8yam6v67y9z8yipqjn578bk2qzqm05ncyqfgig3in6baxwpna";
789789+ version = "2021.714.0";
790790+ sha256 = "175i0hcbl01xy633zvij8185nj4g7ja1rsv2lmfz8qdykqj6g9kl";
791791 })
792792 (fetchNuGet {
793793 name = "ppy.osu.Framework.NativeLibs";
···816816 })
817817 (fetchNuGet {
818818 name = "Realm";
819819- version = "10.2.1";
820820- sha256 = "14pi7vz7nl8ag0bmlbyds52z5nx9wbg154qkm6jai10rm02ws86l";
819819+ version = "10.3.0";
820820+ sha256 = "12zmp43cf2kilzq1yi9x2hy1jdh51c0kbnddw5s960k1kvyx2s2v";
821821 })
822822 (fetchNuGet {
823823 name = "Realm.Fody";
824824- version = "10.2.1";
825825- sha256 = "1zv57wb7zcgyigsxqikf2yq2h7an4c3dbydl9la5xdpa76dgmxdi";
824824+ version = "10.3.0";
825825+ sha256 = "0mhjkahi2ldxcizv08i70mrpwgrvljxdjlr81x3dmwgpxxfji18d";
826826 })
827827 (fetchNuGet {
828828 name = "Remotion.Linq";
+50-19
pkgs/games/xmoto/default.nix
···11-{ lib, stdenv, fetchurl, chipmunk, sqlite, curl, zlib, bzip2, libjpeg
22-, libpng, freeglut, libGLU, libGL, SDL, SDL_mixer, SDL_image, SDL_net
33-, SDL_ttf, lua5, ode, libxdg_basedir, libxml2 }:
11+{ lib, stdenv, fetchFromGitHub, fetchpatch, cmake, gettext, makeWrapper, bzip2
22+, curl, libjpeg, libxml2, xz, lua, ode, libGL, libpng, SDL, SDL_mixer, SDL_net
33+, SDL_ttf, sqlite, libxdg_basedir, zlib }:
4455stdenv.mkDerivation rec {
66 pname = "xmoto";
77- version = "0.5.11";
77+ version = "0.6.1";
8899- src = fetchurl {
1010- url = "https://download.tuxfamily.org/xmoto/xmoto/${version}/xmoto-${version}-src.tar.gz";
1111- sha256 = "1ci6r8zd0l7z28cy92ddf9dmqbdqwinz2y1cny34c61b57wsd155";
99+ src = fetchFromGitHub {
1010+ owner = pname;
1111+ repo = pname;
1212+ rev = version;
1313+ sha256 = "00f5ha79lfa2iiaz66wl0hl5dapa1l15qdr7m7knzi0ll7j6z66n";
1214 };
13151616+ patches = [
1717+ # Fix build with Nix
1818+ (fetchpatch {
1919+ url = "https://github.com/xmoto/xmoto/commit/536dcc7ec77a4c4c454b86220e85b1cb3cd1c7f7.patch";
2020+ sha256 = "0h9lld668jrbmrqva89zqwp63jiagjj86prkxzx6372p3kk9y7g7";
2121+ })
2222+ ];
2323+2424+ nativeBuildInputs = [
2525+ cmake
2626+ gettext
2727+ makeWrapper
2828+ ];
2929+1430 buildInputs = [
1515- chipmunk sqlite curl zlib bzip2 libjpeg libpng
1616- freeglut libGLU libGL SDL SDL_mixer SDL_image SDL_net SDL_ttf
1717- lua5 ode libxdg_basedir libxml2
3131+ bzip2
3232+ curl
3333+ libjpeg
3434+ libxml2
3535+ xz
3636+ lua
3737+ ode
3838+ libGL
3939+ libpng
4040+ SDL
4141+ SDL_mixer
4242+ SDL_net
4343+ SDL_ttf
4444+ sqlite
4545+ libxdg_basedir
4646+ zlib
1847 ];
19482020- CXXFLAGS = [
2121- "-fpermissive"
2222- # Build using the old C++ ABI to fix issue with missing text; the issue
2323- # should be fixed in the next stable release (if that ever does happen)
2424- "-D_GLIBCXX_USE_CXX11_ABI=0"
2525- ];
4949+ preFixup = ''
5050+ wrapProgram "$out/bin/xmoto" \
5151+ --prefix XDG_DATA_DIRS : "$out/share/"
5252+ '';
26532754 meta = with lib; {
2828- description = "Obstacled race game";
5555+ description = "A challenging 2D motocross platform game, where physics play an important role";
5656+ longDescription = ''
5757+ X-Moto is a challenging 2D motocross platform game, where physics plays an all important role in the gameplay.
5858+ You need to control your bike to its limits, if you want to have a chance to finish the most difficult challenges.
5959+ '';
2960 homepage = "http://xmoto.tuxfamily.org";
3061 maintainers = with maintainers; [ raskin pSub ];
3131- platforms = platforms.linux;
3232- license = licenses.gpl2;
6262+ platforms = platforms.all;
6363+ license = licenses.gpl2Plus;
3364 };
3465}
+27-28
pkgs/misc/drivers/hplip/default.nix
···123123 {} +
124124 '';
125125126126- preConfigure = ''
127127- export configureFlags="$configureFlags
128128- --with-hpppddir=$out/share/cups/model/HP
129129- --with-cupsfilterdir=$out/lib/cups/filter
130130- --with-cupsbackenddir=$out/lib/cups/backend
131131- --with-icondir=$out/share/applications
132132- --with-systraydir=$out/xdg/autostart
133133- --with-mimedir=$out/etc/cups
134134- --enable-policykit
135135- ${lib.optionalString withStaticPPDInstall "--enable-cups-ppd-install"}
136136- --disable-qt4
137137- ${lib.optionalString withQt5 "--enable-qt5"}
138138- "
126126+ configureFlags = let out = placeholder "out"; in [
127127+ "--with-hpppddir=${out}/share/cups/model/HP"
128128+ "--with-cupsfilterdir=${out}/lib/cups/filter"
129129+ "--with-cupsbackenddir=${out}/lib/cups/backend"
130130+ "--with-icondir=${out}/share/applications"
131131+ "--with-systraydir=${out}/xdg/autostart"
132132+ "--with-mimedir=${out}/etc/cups"
133133+ "--enable-policykit"
134134+ "--disable-qt4"
135135+ ]
136136+ ++ lib.optional withStaticPPDInstall "--enable-cups-ppd-install"
137137+ ++ lib.optional withQt5 "--enable-qt5"
138138+ ;
139139140140- export makeFlags="
141141- halpredir=$out/share/hal/fdi/preprobe/10osvendor
142142- rulesdir=$out/etc/udev/rules.d
143143- policykit_dir=$out/share/polkit-1/actions
144144- policykit_dbus_etcdir=$out/etc/dbus-1/system.d
145145- policykit_dbus_sharedir=$out/share/dbus-1/system-services
146146- hplip_confdir=$out/etc/hp
147147- hplip_statedir=$out/var/lib/hp
148148- "
140140+ # Prevent 'ppdc: Unable to find include file "<font.defs>"' which prevent
141141+ # generation of '*.ppd' files.
142142+ # This seems to be a 'ppdc' issue when the tool is run in a hermetic sandbox.
143143+ # Could not find how to fix the problem in 'ppdc' so this is a workaround.
144144+ CUPS_DATADIR = "${cups}/share/cups";
149145150150- # Prevent 'ppdc: Unable to find include file "<font.defs>"' which prevent
151151- # generation of '*.ppd' files.
152152- # This seems to be a 'ppdc' issue when the tool is run in a hermetic sandbox.
153153- # Could not find how to fix the problem in 'ppdc' so this is a workaround.
154154- export CUPS_DATADIR="${cups}/share/cups"
155155- '';
146146+ makeFlags = let out = placeholder "out"; in [
147147+ "halpredir=${out}/share/hal/fdi/preprobe/10osvendor"
148148+ "rulesdir=${out}/etc/udev/rules.d"
149149+ "policykit_dir=${out}/share/polkit-1/actions"
150150+ "policykit_dbus_etcdir=${out}/etc/dbus-1/system.d"
151151+ "policykit_dbus_sharedir=${out}/share/dbus-1/system-services"
152152+ "hplip_confdir=${out}/etc/hp"
153153+ "hplip_statedir=${out}/var/lib/hp"
154154+ ];
156155157156 postConfigure = ''
158157 # don't save timestamp, in order to improve reproducibility
···258258 # Rewrap the binutils with the new glibc, so both the next
259259 # stage's wrappers use it.
260260 libc = getLibc self;
261261+262262+ # Unfortunately, when building gcc in the next stage, its LTO plugin
263263+ # would use the final libc but `ld` would use the bootstrap one,
264264+ # and that can fail to load. Therefore we upgrade `ld` to use newer libc;
265265+ # apparently the interpreter needs to match libc, too.
266266+ bintools = self.stdenvNoCC.mkDerivation {
267267+ inherit (prevStage.bintools.bintools) name;
268268+ dontUnpack = true;
269269+ dontBuild = true;
270270+ # We wouldn't need to *copy* all, but it's easier and the result is temporary anyway.
271271+ installPhase = ''
272272+ mkdir -p "$out"/bin
273273+ cp -a '${prevStage.bintools.bintools}'/bin/* "$out"/bin/
274274+ chmod +w "$out"/bin/ld.bfd
275275+ patchelf --set-interpreter '${getLibc self}'/lib/ld*.so.? \
276276+ --set-rpath "${getLibc self}/lib:$(patchelf --print-rpath "$out"/bin/ld.bfd)" \
277277+ "$out"/bin/ld.bfd
278278+ '';
279279+ };
261280 };
262281 };
263282 })