diff --git a/nixos/doc/manual/from_md/release-notes/rl-2111.section.xml b/nixos/doc/manual/from_md/release-notes/rl-2111.section.xml index 555e09600db5..2488f150248c 100644 --- a/nixos/doc/manual/from_md/release-notes/rl-2111.section.xml +++ b/nixos/doc/manual/from_md/release-notes/rl-2111.section.xml @@ -1875,6 +1875,15 @@ Superuser created successfully. directory. + + + Loki has had another release. Some default values have been + changed for the configuration and some configuration options + have been renamed. For more details, please check + the + upgrade guide. + + diff --git a/nixos/doc/manual/release-notes/rl-2111.section.md b/nixos/doc/manual/release-notes/rl-2111.section.md index 92a191ad5095..39663720eb6e 100644 --- a/nixos/doc/manual/release-notes/rl-2111.section.md +++ b/nixos/doc/manual/release-notes/rl-2111.section.md @@ -520,3 +520,5 @@ In addition to numerous new and upgraded packages, this release has the followin - The unifi run directory can now be found under: `/run/unifi` instead of `/var/lib/unifi/run`. - `security.pam.services..makeHomeDir` now uses `umask=0077` instead of `umask=0022` when creating the home directory. + +- Loki has had another release. Some default values have been changed for the configuration and some configuration options have been renamed. For more details, please check [the upgrade guide](https://grafana.com/docs/loki/latest/upgrading/#240). diff --git a/nixos/modules/module-list.nix b/nixos/modules/module-list.nix index c951db5822a2..8021682e3ffe 100644 --- a/nixos/modules/module-list.nix +++ b/nixos/modules/module-list.nix @@ -1189,6 +1189,7 @@ ./virtualisation/virtualbox-guest.nix ./virtualisation/virtualbox-host.nix ./virtualisation/vmware-guest.nix + ./virtualisation/waydroid.nix ./virtualisation/xen-dom0.nix ./virtualisation/xe-guest-utilities.nix ] diff --git a/nixos/modules/services/web-apps/mastodon.nix b/nixos/modules/services/web-apps/mastodon.nix index 7910f3980487..1e3c7e53c175 100644 --- a/nixos/modules/services/web-apps/mastodon.nix +++ b/nixos/modules/services/web-apps/mastodon.nix @@ -545,7 +545,7 @@ in { RuntimeDirectory = "mastodon-web"; RuntimeDirectoryMode = "0750"; # System Call Filtering - SystemCallFilter = [ ("~" + lib.concatStringsSep " " (systemCallsList ++ [ "@resources" ])) "@chown" "pipe" "pipe2" ]; + SystemCallFilter = [ ("~" + lib.concatStringsSep " " systemCallsList) "@chown" "pipe" "pipe2" ]; } // cfgService; path = with pkgs; [ file imagemagick ffmpeg ]; }; diff --git a/nixos/modules/virtualisation/virtualbox-host.nix b/nixos/modules/virtualisation/virtualbox-host.nix index 6c742ad371cd..2acf54aae2ef 100644 --- a/nixos/modules/virtualisation/virtualbox-host.nix +++ b/nixos/modules/virtualisation/virtualbox-host.nix @@ -6,7 +6,7 @@ let cfg = config.virtualisation.virtualbox.host; virtualbox = cfg.package.override { - inherit (cfg) enableHardening headless; + inherit (cfg) enableHardening headless enableWebService; extensionPack = if cfg.enableExtensionPack then pkgs.virtualboxExtpack else null; }; @@ -80,6 +80,14 @@ in and when virtual machines are controlled only via SSH. ''; }; + + enableWebService = mkOption { + type = types.bool; + default = false; + description = '' + Build VirtualBox web service tool (vboxwebsrv) to allow managing VMs via other webpage frontend tools. Useful for headless servers. + ''; + }; }; config = mkIf cfg.enable (mkMerge [{ diff --git a/nixos/modules/virtualisation/waydroid.nix b/nixos/modules/virtualisation/waydroid.nix new file mode 100644 index 000000000000..854ab056dbb8 --- /dev/null +++ b/nixos/modules/virtualisation/waydroid.nix @@ -0,0 +1,66 @@ +{ config, lib, pkgs, ... }: + +with lib; + +let + + cfg = config.virtualisation.waydroid; + kernelPackages = config.boot.kernelPackages; + waydroidGbinderConf = pkgs.writeText "waydroid.conf" '' + [Protocol] + /dev/binder = aidl2 + /dev/vndbinder = aidl2 + /dev/hwbinder = hidl + + [ServiceManager] + /dev/binder = aidl2 + /dev/vndbinder = aidl2 + /dev/hwbinder = hidl + ''; + +in { + + options.virtualisation.waydroid = { + enable = mkEnableOption "Waydroid"; + }; + + config = mkIf cfg.enable { + assertions = singleton { + assertion = versionAtLeast (getVersion config.boot.kernelPackages.kernel) "4.18"; + message = "Waydroid needs user namespace support to work properly"; + }; + + system.requiredKernelConfig = with config.lib.kernelConfig; [ + (isEnabled "ANDROID_BINDER_IPC") + (isEnabled "ANDROID_BINDERFS") + (isEnabled "ASHMEM") + ]; + + environment.etc."gbinder.d/waydroid.conf".source = waydroidGbinderConf; + + environment.systemPackages = with pkgs; [ waydroid ]; + + networking.firewall.trustedInterfaces = [ "waydroid0" ]; + + virtualisation.lxc.enable = true; + + systemd.services.waydroid-container = { + description = "Waydroid Container"; + + wantedBy = [ "multi-user.target" ]; + + path = with pkgs; [ getent iptables iproute kmod nftables util-linux which ]; + + unitConfig = { + ConditionPathExists = "/var/lib/waydroid/lxc/waydroid"; + }; + + serviceConfig = { + ExecStart = "${pkgs.waydroid}/bin/waydroid container start"; + ExecStop = "${pkgs.waydroid}/bin/waydroid container stop"; + ExecStopPost = "${pkgs.waydroid}/bin/waydroid session stop"; + }; + }; + }; + +} diff --git a/pkgs/applications/editors/vscode/vscode.nix b/pkgs/applications/editors/vscode/vscode.nix index d08f80fda6f5..fff0f07477f1 100644 --- a/pkgs/applications/editors/vscode/vscode.nix +++ b/pkgs/applications/editors/vscode/vscode.nix @@ -14,17 +14,17 @@ let archive_fmt = if stdenv.isDarwin then "zip" else "tar.gz"; sha256 = { - x86_64-linux = "1yfaf9qdaf6njvj8kilmivyl0nnhdvd9hbzpf8hv3kw5rfpdvy89"; - x86_64-darwin = "10rx5aif61xipf5lcjzkidz9dhbm5gc2wf87c2j456nixaxbx0b4"; - aarch64-linux = "13h4ffdm9y9p3jnqcjvapykbm73bkjy5jaqwhsi293f9r7jfp9rf"; - aarch64-darwin = "07nmrxc25rfp5ibarhg3c14ksk2ymqmsnc55hicvvhw93g2qczby"; - armv7l-linux = "1gz1mmw2vp986l9sm7rd6hypxs70sz63sbmzyxwfqpvj973dl23q"; + x86_64-linux = "18sa2avr7xl8d0yaxs0df1pkwx7bbg21s8qf3mijdndsnhri0j1c"; + x86_64-darwin = "0vx0jiw341gsf00xw92fwwylnsi5c0ybrbj5syag4vkqddvp410k"; + aarch64-linux = "0jswwz1rxddaxz6v7hzpvddhx9dia5nk5rdsaj93q4gs3nda90hk"; + aarch64-darwin = "11lxg543kl85vbndqcq5zccycxfk63ijmka0jb973jfp0nm4iq60"; + armv7l-linux = "1ryr6k93z24yk0qqv3yasbp4achwpn0mpi6f28d2pvnsr9v9bh3y"; }.${system}; in callPackage ./generic.nix rec { # Please backport all compatible updates to the stable release. # This is important for the extension ecosystem. - version = "1.61.2"; + version = "1.62.0"; pname = "vscode"; executableName = "code" + lib.optionalString isInsiders "-insiders"; diff --git a/pkgs/applications/editors/vscode/vscodium.nix b/pkgs/applications/editors/vscode/vscodium.nix index f014bf1fda39..8f383563bfc2 100644 --- a/pkgs/applications/editors/vscode/vscodium.nix +++ b/pkgs/applications/editors/vscode/vscodium.nix @@ -13,10 +13,10 @@ let archive_fmt = if system == "x86_64-darwin" then "zip" else "tar.gz"; sha256 = { - x86_64-linux = "1q260kjhyx8djl82275ii63z1mzypsz7rkz3pj1n2wjkwsnw276x"; - x86_64-darwin = "1scx155rm8j6dwn0i31b6ajsdxcn1n24p3k6dx248w0zyiwd5wm1"; - aarch64-linux = "1j788a0p767i65ying9pfg6rss8l7g76n2323dnmj12bhxs6cqd1"; - armv7l-linux = "1yfwmfxpilfv2h3pp698pg4wr6dnyzwg0r266xiwsw7z38jh54fk"; + x86_64-linux = "17vrz16q4fhc6b2rlddhz3m6y780gi9vzk28l0fcj12l9z5iprn9"; + x86_64-darwin = "1hn8sjmndmicl3gjrsb163wn5j36ij5b68mw7n6v6lqaf0a75xah"; + aarch64-linux = "0ikdy9c2ldrxyh8ij2qskv4m7j5azr1hbi53ddzgj1j6nms68lkh"; + armv7l-linux = "07a3kz4c8wzid0rd1rdzndy8c1cdg4hba7p1jmdf7zclr702i2j7"; }.${system}; sourceRoot = { @@ -31,7 +31,7 @@ in # Please backport all compatible updates to the stable release. # This is important for the extension ecosystem. - version = "1.61.2"; + version = "1.62.0"; pname = "vscodium"; executableName = "codium"; diff --git a/pkgs/applications/networking/msmtp/default.nix b/pkgs/applications/networking/msmtp/default.nix index d87d23be429c..2161e1a4ecca 100644 --- a/pkgs/applications/networking/msmtp/default.nix +++ b/pkgs/applications/networking/msmtp/default.nix @@ -9,11 +9,11 @@ let in stdenv.mkDerivation rec { pname = "msmtp"; - version = "1.8.18"; + version = "1.8.19"; src = fetchurl { url = "https://marlam.de/${pname}/releases/${pname}-${version}.tar.xz"; - sha256 = "sha256-FPxirzfr3MXtGaJFoF64N27+cBYRjwDJxZS8mZ1VYKU="; + sha256 = "sha256-NKHhmBF2h02+TuZu4NkQPJCYmqTc3Ehh5N4Fzn5EUms="; }; patches = [ diff --git a/pkgs/applications/virtualization/virtualbox/default.nix b/pkgs/applications/virtualization/virtualbox/default.nix index 98c7f80df8ad..0dcebb71cc5f 100644 --- a/pkgs/applications/virtualization/virtualbox/default.nix +++ b/pkgs/applications/virtualization/virtualbox/default.nix @@ -2,7 +2,7 @@ , libX11, xorgproto, libXext, libXcursor, libXmu, libIDL, SDL, libcap, libGL , libpng, glib, lvm2, libXrandr, libXinerama, libopus, qtbase, qtx11extras , qttools, qtsvg, qtwayland, pkg-config, which, docbook_xsl, docbook_xml_dtd_43 -, alsa-lib, curl, libvpx, nettools, dbus, substituteAll +, alsa-lib, curl, libvpx, nettools, dbus, substituteAll, gsoap, zlib # If open-watcom-bin is not passed, VirtualBox will fall back to use # the shipped alternative sources (assembly). , open-watcom-bin ? null @@ -14,6 +14,7 @@ , enableHardening ? false , headless ? false , enable32bitGuests ? true +, enableWebService ? false }: with lib; @@ -49,7 +50,8 @@ in stdenv.mkDerivation { ++ optional pythonBindings python # Python is needed even when not building bindings ++ optional pulseSupport libpulseaudio ++ optionals (headless) [ libXrandr libGL ] - ++ optionals (!headless) [ qtbase qtx11extras libXinerama SDL ]; + ++ optionals (!headless) [ qtbase qtx11extras libXinerama SDL ] + ++ optionals (enableWebService) [ gsoap zlib ]; hardeningDisable = [ "format" "fortify" "pic" "stackprotector" ]; @@ -133,6 +135,10 @@ in stdenv.mkDerivation { PATH_QT5_X11_EXTRAS_INC := ${getDev qtx11extras}/include TOOL_QT5_LRC := ${getDev qttools}/bin/lrelease ''} + ${optionalString (enableWebService) '' + # fix gsoap missing zlib include and produce errors with --as-needed + VBOX_GSOAP_CXX_LIBS := gsoapssl++ z + ''} LOCAL_CONFIG ./configure \ @@ -142,6 +148,7 @@ in stdenv.mkDerivation { ${optionalString (!pulseSupport) "--disable-pulse"} \ ${optionalString (!enableHardening) "--disable-hardening"} \ ${optionalString (!enable32bitGuests) "--disable-vmmraw"} \ + ${optionalString (enableWebService) "--enable-webservice"} \ ${optionalString (open-watcom-bin != null) "--with-ow-dir=${open-watcom-bin}"} \ --disable-kmods sed -e 's@PKG_CONFIG_PATH=.*@PKG_CONFIG_PATH=${libIDL}/lib/pkgconfig:${glib.dev}/lib/pkgconfig ${libIDL}/bin/libIDL-config-2@' \ @@ -168,7 +175,7 @@ in stdenv.mkDerivation { -name src -o -exec cp -avt "$libexec" {} + mkdir -p $out/bin - for file in ${optionalString (!headless) "VirtualBox VBoxSDL rdesktop-vrdp"} VBoxManage VBoxBalloonCtrl VBoxHeadless; do + for file in ${optionalString (!headless) "VirtualBox VBoxSDL rdesktop-vrdp"} ${optionalString (enableWebService) "vboxwebsrv"} VBoxManage VBoxBalloonCtrl VBoxHeadless; do echo "Linking $file to /bin" test -x "$libexec/$file" ln -s "$libexec/$file" $out/bin/$file diff --git a/pkgs/data/fonts/ultimate-oldschool-pc-font-pack/default.nix b/pkgs/data/fonts/ultimate-oldschool-pc-font-pack/default.nix index d34ebaf6d8f3..4733bcf04e72 100644 --- a/pkgs/data/fonts/ultimate-oldschool-pc-font-pack/default.nix +++ b/pkgs/data/fonts/ultimate-oldschool-pc-font-pack/default.nix @@ -1,12 +1,12 @@ { lib, fetchzip }: let - version = "2.0"; + version = "2.2"; in fetchzip { name = "ultimate-oldschool-pc-font-pack-${version}"; - url = "https://int10h.org/oldschool-pc-fonts/download/oldschool_pc_font_pack_v${version}_ttf.zip"; - sha256 = "0z0fw6ni7iq806y4m83xrfx46r14xxxql09ch2gxjqi062awqyh8"; + url = "https://int10h.org/oldschool-pc-fonts/download/oldschool_pc_font_pack_v${version}_linux.zip"; + sha256 = "sha256-BOA2fMa2KT3Bkpvj/0DzrzuZbl3RARvNn4qbI/+dApU="; postFetch= '' mkdir -p $out/share/fonts/truetype diff --git a/pkgs/development/interpreters/spidermonkey/1.8.5-arm-flags.patch b/pkgs/development/interpreters/spidermonkey/1.8.5-arm-flags.patch deleted file mode 100644 index 721aff154e37..000000000000 --- a/pkgs/development/interpreters/spidermonkey/1.8.5-arm-flags.patch +++ /dev/null @@ -1,342 +0,0 @@ -From: Mike Hommey -Date: Wed, 27 Apr 2011 08:58:01 +0200 -Subject: Bug 626035 - Modify the way arm compiler flags are set in configure - ---- - configure.in | 292 ++++++++++++++++++++++++++++++++------------------- - js/src/configure.in | 284 ++++++++++++++++++++++++++++++++----------------- - 2 files changed, 372 insertions(+), 204 deletions(-) - -Index: mozjs-1.8.5-1.0.0+dfsg/js/src/configure.in -=================================================================== ---- mozjs-1.8.5-1.0.0+dfsg.orig/js/src/configure.in 2012-01-21 15:57:37.507703219 +0100 -+++ mozjs-1.8.5-1.0.0+dfsg/js/src/configure.in 2012-01-21 15:58:04.951703302 +0100 -@@ -3535,34 +3535,6 @@ - AC_CHECK_LIB(socket, socket) - esac - --AC_MSG_CHECKING(for ARM SIMD support in compiler) --AC_TRY_COMPILE([], -- [asm("uqadd8 r1, r1, r2");], -- result="yes", result="no") --AC_MSG_RESULT("$result") --if test "$result" = "yes"; then -- AC_DEFINE(HAVE_ARM_SIMD) -- HAVE_ARM_SIMD=1 --fi --AC_SUBST(HAVE_ARM_SIMD) -- --AC_MSG_CHECKING(for ARM NEON support in compiler) --_SAVE_CFLAGS="$CFLAGS" --if test "$GNU_CC"; then -- # gcc needs -mfpu=neon to recognize NEON instructions -- CFLAGS="$CFLAGS -mfpu=neon -mfloat-abi=softfp" --fi --AC_TRY_COMPILE([], -- [asm("vadd.i8 d0, d0, d0");], -- result="yes", result="no") --AC_MSG_RESULT("$result") --if test "$result" = "yes"; then -- AC_DEFINE(HAVE_ARM_NEON) -- HAVE_ARM_NEON=1 --fi --CFLAGS="$_SAVE_CFLAGS" --AC_SUBST(HAVE_ARM_NEON) -- - dnl ======================================================== - dnl = pthread support - dnl = Start by checking whether the system support pthreads -@@ -4614,13 +4586,11 @@ - BUILD_STATIC_LIBS= - ENABLE_TESTS=1 - --MOZ_THUMB2= - USE_ARM_KUSER= - - case "${target}" in - arm-android-eabi) - USE_ARM_KUSER=1 -- MOZ_THUMB2=1 - ;; - esac - -@@ -4666,80 +4636,204 @@ - dnl ======================================================== - MOZ_ARG_HEADER(Individual module options) - --dnl Setup default CPU arch for arm target --case "$target_cpu" in -- arm*) -- MOZ_ARM_ARCH=armv7 -- ;; --esac - dnl ======================================================== --dnl = Enable building the Thumb2 instruction set -+dnl = ARM toolchain tweaks - dnl ======================================================== --MOZ_ARG_ENABLE_BOOL(thumb2, -- [ --enable-thumb2 Enable Thumb2 instruction set (implies ARMv7)], -- MOZ_THUMB2=1, -- MOZ_THUMB2=) --if test -n "$MOZ_THUMB2"; then -- MOZ_ARM_ARCH=armv7 -+ -+dnl Defaults -+case "${target}" in -+arm-android-eabi) -+ MOZ_THUMB=yes -+ MOZ_ARCH=armv7-a -+ MOZ_FPU=vfp -+ MOZ_FLOAT_ABI=softfp -+ ;; -+arm*-*) -+ if test -n "$MOZ_PLATFORM_MAEMO"; then -+ MOZ_THUMB=no -+ MOZ_ARCH=armv7-a -+ MOZ_FLOAT_ABI=softfp -+ fi -+ if test "$MOZ_PLATFORM_MAEMO" = 6; then -+ MOZ_THUMB=yes -+ fi -+ ;; -+esac -+ -+dnl Kept for compatibility with some buildbot mozconfig -+MOZ_ARG_DISABLE_BOOL(thumb2, [], MOZ_THUMB=no, MOZ_THUMB=yes) -+ -+MOZ_ARG_WITH_STRING(thumb, -+[ --with-thumb[[=yes|no|toolchain]]] -+[ Use Thumb instruction set (-mthumb)], -+ if test -z "$GNU_CC"; then -+ AC_MSG_ERROR([--with-thumb is not supported on non-GNU toolchains]) -+ fi -+ MOZ_THUMB=$withval) -+ -+MOZ_ARG_WITH_STRING(thumb-interwork, -+[ --with-thumb-interwork[[=yes|no|toolchain]] -+ Use Thumb/ARM instuctions interwork (-mthumb-interwork)], -+ if test -z "$GNU_CC"; then -+ AC_MSG_ERROR([--with-thumb-interwork is not supported on non-GNU toolchains]) -+ fi -+ MOZ_THUMB_INTERWORK=$withval) -+ -+MOZ_ARG_WITH_STRING(arch, -+[ --with-arch=[[type|toolchain]] -+ Use specific CPU features (-march=type)], -+ if test -z "$GNU_CC"; then -+ AC_MSG_ERROR([--with-arch is not supported on non-GNU toolchains]) -+ fi -+ MOZ_ARCH=$withval) -+ -+MOZ_ARG_WITH_STRING(fpu, -+[ --with-fpu=[[type|toolchain]] -+ Use specific FPU type (-mfpu=type)], -+ if test -z "$GNU_CC"; then -+ AC_MSG_ERROR([--with-fpu is not supported on non-GNU toolchains]) -+ fi -+ MOZ_FPU=$withval) -+ -+MOZ_ARG_WITH_STRING(float-abi, -+[ --with-float-abi=[[type|toolchain]] -+ Use specific arm float ABI (-mfloat-abi=type)], -+ if test -z "$GNU_CC"; then -+ AC_MSG_ERROR([--with-float-abi is not supported on non-GNU toolchains]) -+ fi -+ MOZ_FLOAT_ABI=$withval) -+ -+MOZ_ARG_WITH_STRING(soft-float, -+[ --with-soft-float[[=yes|no|toolchain]] -+ Use soft float library (-msoft-float)], -+ if test -z "$GNU_CC"; then -+ AC_MSG_ERROR([--with-soft-float is not supported on non-GNU toolchains]) -+ fi -+ MOZ_SOFT_FLOAT=$withval) -+ -+case "$MOZ_ARCH" in -+toolchain|"") -+ arch_flag="" -+ ;; -+*) -+ arch_flag="-march=$MOZ_ARCH" -+ ;; -+esac -+ -+case "$MOZ_THUMB" in -+yes) -+ MOZ_THUMB2=1 -+ thumb_flag="-mthumb" -+ ;; -+no) -+ MOZ_THUMB2= -+ thumb_flag="-marm" -+ ;; -+*) -+ _SAVE_CFLAGS="$CFLAGS" -+ CFLAGS="$arch_flag" -+ AC_TRY_COMPILE([],[return sizeof(__thumb2__);], -+ MOZ_THUMB2=1, -+ MOZ_THUMB2=) -+ CFLAGS="$_SAVE_CFLAGS" -+ thumb_flag="" -+ ;; -+esac -+ -+if test "$MOZ_THUMB2" = 1; then -+ AC_DEFINE(MOZ_THUMB2) - fi - --dnl ======================================================== --dnl = Enable building for ARM specific CPU features --dnl ======================================================== --MOZ_ARG_WITH_STRING(cpu-arch, --[ --with-cpu-arch=arch Use specific arm architecture CPU features, default armv7], -- MOZ_ARM_ARCH=$withval) -+case "$MOZ_THUMB_INTERWORK" in -+yes) -+ thumb_interwork_flag="-mthumb-interwork" -+ ;; -+no) -+ thumb_interwork_flag="-mno-thumb-interwork" -+ ;; -+*) # toolchain -+ thumb_interwork_flag="" -+ ;; -+esac - --if test -n "$MOZ_THUMB2"; then -- case "$target_cpu" in -- arm*) -- if test "$MOZ_ARM_ARCH" != "armv7"; then -- AC_MSG_ERROR([--enable-thumb2 is not compatible with cpu-arch=$MOZ_ARM_ARCH]) -- fi -- if test "$GNU_CC"; then -- AC_DEFINE(MOZ_THUMB2) -- AC_DEFINE(MOZ_ARM_ARCH) -- CFLAGS="$CFLAGS -march=armv7-a -mthumb -mfloat-abi=softfp $MOZ_ARM_VFP_FLAGS" -- CXXFLAGS="$CXXFLAGS -march=armv7-a -mthumb -mfloat-abi=softfp $MOZ_ARM_VFP_FLAGS" -- ASFLAGS="$ASFLAGS -march=armv7-a -mthumb -mfloat-abi=softfp $MOZ_ARM_VFP_FLAGS" -- else -- AC_MSG_ERROR([--enable-thumb2 is not supported for non-GNU toolchains]) -- fi -+case "$MOZ_FPU" in -+toolchain|"") -+ fpu_flag="" - ;; -- *) -- AC_MSG_ERROR([--enable-thumb2 is not supported for non-ARM CPU architectures]) -+*) -+ fpu_flag="-mfpu=$MOZ_FPU" - ;; -- esac --elif test "$MOZ_ARM_ARCH" = "armv7"; then -- case "$target_cpu" in -- arm*) -- if test "$GNU_CC"; then -- AC_DEFINE(MOZ_ARM_ARCH) -- CFLAGS="$CFLAGS -march=armv7-a -marm -mfloat-abi=softfp $MOZ_ARM_VFP_FLAGS" -- CXXFLAGS="$CXXFLAGS -march=armv7-a -marm -mfloat-abi=softfp $MOZ_ARM_VFP_FLAGS" -- ASFLAGS="$ASFLAGS -march=armv7-a -marm -mfloat-abi=softfp $MOZ_ARM_VFP_FLAGS" -- else -- AC_MSG_ERROR([--with-cpu-arch=armv7 is not supported for non-GNU toolchains]) -- fi -+esac -+ -+case "$MOZ_FLOAT_ABI" in -+toolchain|"") -+ float_abi_flag="" - ;; -- *) -- AC_MSG_ERROR([--with-cpu-arch=armv7 is not supported for non-ARM CPU architectures]) -+*) -+ float_abi_flag="-mfloat-abi=$MOZ_FLOAT_ABI" - ;; -- esac --else -- case "$target_cpu" in -- arm*) -- if test "$GNU_CC"; then -- CFLAGS="$CFLAGS -march=armv5te -mthumb-interwork -msoft-float" -- CXXFLAGS="$CXXFLAGS -march=armv5te -mthumb-interwork -msoft-float" -- ASFLAGS="$ASFLAGS -march=armv5te -mthumb-interwork -msoft-float" -- fi -- ;; -- esac -+esac -+ -+case "$MOZ_SOFT_FLOAT" in -+yes) -+ soft_float_flag="-msoft-float" -+ ;; -+no) -+ soft_float_flag="-mno-soft-float" -+ ;; -+*) # toolchain -+ soft_float_flag="" -+ ;; -+esac -+ -+dnl Use echo to avoid accumulating space characters -+all_flags=`echo $arch_flag $thumb_flag $thumb_interwork_flag $fpu_flag $float_abi_flag $soft_float_flag` -+if test -n "$all_flags"; then -+ _SAVE_CFLAGS="$CFLAGS" -+ CFLAGS="$all_flags" -+ AC_MSG_CHECKING(whether the chosen combination of compiler flags ($all_flags) works) -+ AC_TRY_COMPILE([],[return 0;], -+ AC_MSG_RESULT([yes]), -+ AC_MSG_ERROR([no])) -+ -+ CFLAGS="$_SAVE_CFLAGS $all_flags" -+ CXXFLAGS="$CXXFLAGS $all_flags" -+ ASFLAGS="$ASFLAGS $all_flags" -+ if test -n "$thumb_flag"; then -+ LDFLAGS="$LDFLAGS $thumb_flag" -+ fi - fi - - AC_SUBST(MOZ_THUMB2) --AC_SUBST(MOZ_ARM_ARCH) -+ -+if test "$CPU_ARCH" = "arm"; then -+ AC_MSG_CHECKING(for ARM SIMD support in compiler) -+ # We try to link so that this also fails when -+ # building with LTO. -+ AC_TRY_LINK([], -+ [asm("uqadd8 r1, r1, r2");], -+ result="yes", result="no") -+ AC_MSG_RESULT("$result") -+ if test "$result" = "yes"; then -+ AC_DEFINE(HAVE_ARM_SIMD) -+ HAVE_ARM_SIMD=1 -+ fi -+ -+ AC_MSG_CHECKING(for ARM NEON support in compiler) -+ # We try to link so that this also fails when -+ # building with LTO. -+ AC_TRY_LINK([], -+ [asm(".fpu neon\n vadd.i8 d0, d0, d0");], -+ result="yes", result="no") -+ AC_MSG_RESULT("$result") -+ if test "$result" = "yes"; then -+ AC_DEFINE(HAVE_ARM_NEON) -+ HAVE_ARM_NEON=1 -+ fi -+fi # CPU_ARCH = arm -+ -+AC_SUBST(HAVE_ARM_SIMD) -+AC_SUBST(HAVE_ARM_NEON) - - dnl ======================================================== - dnl = -@@ -6147,12 +6241,6 @@ - if test "$OS_ARCH" = "OS2"; then - ac_configure_args="$ac_configure_args CFLAGS=-Zomf AR=emxomfar" - fi -- if test -n "$MOZ_THUMB2"; then -- ac_configure_args="$ac_configure_args --enable-thumb2" -- fi -- if test -n "$MOZ_ARM_ARCH"; then -- ac_configure_args="$ac_configure_args --with-cpu-arch=$MOZ_ARM_ARCH" -- fi - - # Use a separate cache file for libffi, since it does things differently - # from our configure. diff --git a/pkgs/development/interpreters/spidermonkey/1.8.5-findvanilla.patch b/pkgs/development/interpreters/spidermonkey/1.8.5-findvanilla.patch deleted file mode 100644 index f6dab5497a0a..000000000000 --- a/pkgs/development/interpreters/spidermonkey/1.8.5-findvanilla.patch +++ /dev/null @@ -1,19 +0,0 @@ -diff --git a/js/src/Makefile.in b/js/src/Makefile.in -index a85e055..92ef441 100644 ---- a/js/src/Makefile.in -+++ b/js/src/Makefile.in -@@ -580,14 +580,6 @@ check-valgrind:: - $(check-sync-dirs) $(srcdir)/build $(MOZ_SYNC_BUILD_FILES)/build - endif - --# The "find any vanilla new/new[] calls" script is tailored to Linux, so --# only run it there. That should be enough to catch any such calls that --# creep in. --ifeq ($(OS_ARCH),Linux) --check:: -- $(srcdir)/config/find_vanilla_new_calls $(LIBRARY) --endif -- - ifdef ENABLE_TRACEJIT - ifndef WINCE - JITFLAGS = ,m,j,mj,mjp,am,amj,amjp,amd diff --git a/pkgs/development/interpreters/spidermonkey/68.nix b/pkgs/development/interpreters/spidermonkey/68.nix index 420c3d72f891..5cfb2de919f1 100644 --- a/pkgs/development/interpreters/spidermonkey/68.nix +++ b/pkgs/development/interpreters/spidermonkey/68.nix @@ -7,11 +7,11 @@ let python3Env = buildPackages.python3.withPackages (p: [p.six]); in stdenv.mkDerivation rec { pname = "spidermonkey"; - version = "68.10.0"; + version = "68.12.0"; src = fetchurl { url = "mirror://mozilla/firefox/releases/${version}esr/source/firefox-${version}esr.source.tar.xz"; - sha256 = "0azdinwqjfv2q37gqpxmfvzsk86pvsi6cjaq1310zs26gric5j1f"; + sha256 = "1k17pi4zh9hrvkzbw4rzzw879a15hpvwriylp75wl22rl7r2nsdf"; }; patches = [ diff --git a/pkgs/development/interpreters/spidermonkey/91.nix b/pkgs/development/interpreters/spidermonkey/91.nix new file mode 100644 index 000000000000..953a4c506b5c --- /dev/null +++ b/pkgs/development/interpreters/spidermonkey/91.nix @@ -0,0 +1,119 @@ +{ lib, stdenv +, fetchurl +, pkg-config +, perl +, python3 +, zip +, buildPackages +, which +, readline +, zlib +, icu69 +, cargo +, rustc +, rust-cbindgen +, yasm +, llvmPackages_latest +, nspr +, m4 +}: + +stdenv.mkDerivation rec { + pname = "spidermonkey"; + version = "91.3.0"; + + src = fetchurl { + url = "mirror://mozilla/firefox/releases/${version}esr/source/firefox-${version}esr.source.tar.xz"; + sha256 = "0v79c435vfbhsx7pqyq4jm5rv8iysig69wwqhvys1n0jy54m72qj"; + }; + + outputs = [ "out" "dev" ]; + setOutputFlags = false; # Configure script only understands --includedir + + nativeBuildInputs = [ + cargo + llvmPackages_latest.llvm # for llvm-objdump + perl + pkg-config + python3 + rust-cbindgen + rustc + which + yasm # to buid icu? seems weird + zip + m4 + ]; + + buildInputs = [ + icu69 + nspr + readline + zlib + ]; + + preConfigure = '' + export LIBXUL_DIST=$out + export PYTHON="${buildPackages.python3.interpreter}" + export M4=m4 + export AWK=awk + export AC_MACRODIR=$PWD/build/autoconf/ + + pushd js/src + sh ../../build/autoconf/autoconf.sh --localdir=$PWD configure.in > configure + chmod +x configure + popd + # We can't build in js/src/, so create a build dir + mkdir obj + cd obj/ + configureScript=../js/src/configure + ''; + + configureFlags = [ + "--with-intl-api" + "--with-system-icu" + "--with-system-nspr" + "--with-system-zlib" + "--enable-optimize" + "--enable-readline" + "--enable-release" + "--enable-shared-js" + "--disable-debug" + "--disable-jemalloc" + "--disable-strip" + "--disable-tests" + ] ++ lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [ + # Spidermonkey seems to use different host/build terminology for cross + # compilation here. + "--host=${stdenv.buildPlatform.config}" + "--target=${stdenv.hostPlatform.config}" + ]; + + depsBuildBuild = [ buildPackages.stdenv.cc ]; + + # Remove unnecessary static lib + preFixup = '' + moveToOutput bin/js91-config "$dev" + rm $out/lib/libjs_static.ajs + ln -s $out/bin/js91 $out/bin/js + ''; + + enableParallelBuilding = true; + + postPatch = '' + # This patch is a manually applied fix of + # https://bugzilla.mozilla.org/show_bug.cgi?id=1644600 + # Once that bug is fixed, this can be removed. + # This is needed in, for example, `zeroad`. + substituteInPlace js/public/StructuredClone.h \ + --replace "class SharedArrayRawBufferRefs {" \ + "class JS_PUBLIC_API SharedArrayRawBufferRefs {" + ''; + + meta = with lib; { + description = "Mozilla's JavaScript engine written in C/C++"; + homepage = "https://spidermonkey.dev/"; + license = licenses.mpl20; + maintainers = with maintainers; [ lostnet ]; + platforms = platforms.linux; + }; +} diff --git a/pkgs/development/libraries/ffmpeg/2.8.nix b/pkgs/development/libraries/ffmpeg/2.8.nix deleted file mode 100644 index 0df810ff10b0..000000000000 --- a/pkgs/development/libraries/ffmpeg/2.8.nix +++ /dev/null @@ -1,11 +0,0 @@ -{ callPackage, ... } @ args: - -callPackage ./generic.nix (rec { - version = "${branch}.17"; - branch = "2.8"; - sha256 = "05bnhvs2f82aq95z1wd3wr42sljdfq4kiyzqwhpji983mndx14vl"; - knownVulnerabilities = [ - "CVE-2021-30123" - ]; - doCheck = false; -} // args) diff --git a/pkgs/development/python-modules/coconut/default.nix b/pkgs/development/python-modules/coconut/default.nix index b140f8110a6d..b7301cf1e73a 100644 --- a/pkgs/development/python-modules/coconut/default.nix +++ b/pkgs/development/python-modules/coconut/default.nix @@ -1,7 +1,6 @@ { lib , buildPythonApplication , fetchFromGitHub -, fetchpatch , cpyparsing , ipykernel , mypy @@ -15,30 +14,22 @@ buildPythonApplication rec { pname = "coconut"; - version = "1.5.0"; + version = "1.6.0"; src = fetchFromGitHub { owner = "evhub"; repo = "coconut"; rev = "v${version}"; - sha256 = "1gc0fwqwzn1j6mcg1f6fw832w66pbaaq9mmi0r4kw3xn5f877icz"; + sha256 = "/397YGV6QWWmKfqr5hSvqRoPOu7Hx1Pak6rVPR3etzw="; }; propagatedBuildInputs = [ cpyparsing ipykernel mypy pygments prompt-toolkit watchdog ]; - postPatch = '' - substituteInPlace coconut/kernel_installer.py \ - --replace "fixpath(os.path.join(sys.exec_prefix, icoconut_custom_kernel_install_loc))" \ - "fixpath(icoconut_custom_kernel_install_loc)" - ''; - checkInputs = [ pexpect pytestCheckHook tkinter ]; - # Currently most tests do not work on Hydra due to external fetches. + # Currently most tests have performance issues pytestFlagsArray = [ "tests/constants_test.py" - "tests/main_test.py::TestShell::test_compile_to_file" - "tests/main_test.py::TestShell::test_convenience" ]; pythonImportsCheck = [ "coconut" ]; diff --git a/pkgs/development/python-modules/cpyparsing/default.nix b/pkgs/development/python-modules/cpyparsing/default.nix index 2cba79b4886e..638824a87ee9 100644 --- a/pkgs/development/python-modules/cpyparsing/default.nix +++ b/pkgs/development/python-modules/cpyparsing/default.nix @@ -2,13 +2,13 @@ buildPythonPackage rec { pname = "cpyparsing"; - version = "2.4.5.0.1.2"; + version = "2.4.7.1.0.0"; src = fetchFromGitHub { owner = "evhub"; repo = pname; - rev = "38f2b323b99cee9a080106ae9951ffc5752599f0"; # No tags on repo - sha256 = "0wrm6vzwp968z7s0qhr23v39ivyxzvav3mv9i2n0iv9zl041kypv"; + rev = "09073751d92cb40fb71c927c006baddc082df1db"; # No tags on repo + sha256 = "O9IdHipAxxbFcDFYNvmczue/wT4AF9Xb5uc3ZTAlTlo="; }; nativeBuildInputs = [ cython ]; diff --git a/pkgs/development/python-modules/fastecdsa/default.nix b/pkgs/development/python-modules/fastecdsa/default.nix index c161acdb3650..e7dbea075870 100644 --- a/pkgs/development/python-modules/fastecdsa/default.nix +++ b/pkgs/development/python-modules/fastecdsa/default.nix @@ -8,6 +8,7 @@ buildPythonPackage rec { pname = "fastecdsa"; version = "2.2.2"; + format = "setuptools"; src = fetchPypi { inherit pname version; @@ -18,10 +19,10 @@ buildPythonPackage rec { checkInputs = [ pytestCheckHook ]; - # skip tests which require being online to download test vectors - pytestFlags = [ - "--ignore=fastecdsa/tests/test_wycheproof_vectors.py" - "--ignore=fastecdsa/tests/test_rfc6979_ecdsa.py" + disabledTestPaths = [ + # skip tests which require being online to download test vectors + "fastecdsa/tests/test_wycheproof_vectors.py" + "fastecdsa/tests/test_rfc6979_ecdsa.py" ]; # skip tests for now, they fail with diff --git a/pkgs/development/python-modules/solo-python/default.nix b/pkgs/development/python-modules/solo-python/default.nix index 88df4e50fbc4..4e4a807729cf 100644 --- a/pkgs/development/python-modules/solo-python/default.nix +++ b/pkgs/development/python-modules/solo-python/default.nix @@ -14,18 +14,18 @@ buildPythonPackage rec { pname = "solo-python"; - version = "0.0.30"; + version = "0.0.31"; format = "flit"; - disabled = pythonOlder "3.6"; # only python>=3.6 is supported + + disabled = pythonOlder "3.6"; src = fetchFromGitHub { owner = "solokeys"; repo = pname; rev = version; - sha256 = "1i9kybp08qfcdx6m4wl7ij40y1v17mvvhcdg7zglwfakblf69w41"; + sha256 = "sha256-OguAHeNpom+zthREzdhejy5HJUIumrtwB0WJAwUNiSA="; }; - # replaced pinned fido, with unrestricted fido version patchPhase = '' sed -i '/fido2/c\"fido2",' pyproject.toml ''; @@ -41,12 +41,10 @@ requests ]; - # allow for writable directory for darwin preBuild = '' export HOME=$TMPDIR ''; - # repo doesn't contain tests, ensure imports aren't broken pythonImportsCheck = [ "solo" "solo.cli" diff --git a/pkgs/development/tools/yarn/default.nix b/pkgs/development/tools/yarn/default.nix index 518b98021079..50d29cb4a1d4 100644 --- a/pkgs/development/tools/yarn/default.nix +++ b/pkgs/development/tools/yarn/default.nix @@ -1,12 +1,12 @@ -{ lib, stdenv, nodejs, fetchzip }: +{ lib, stdenv, nodejs, fetchzip, testVersion, yarn }: stdenv.mkDerivation rec { pname = "yarn"; - version = "1.22.15"; + version = "1.22.17"; src = fetchzip { url = "https://github.com/yarnpkg/yarn/releases/download/v${version}/yarn-v${version}.tar.gz"; - sha256 = "1xw9z55wvij6x0dns6z0xydywvlc80kgvsh3w4xxkq9cbiman1v6"; + sha256 = "1skzlyv2976bl1063f94422jbjy4ns1nxl622biizq31z4821yvj"; }; buildInputs = [ nodejs ]; @@ -18,6 +18,8 @@ stdenv.mkDerivation rec { ln -s $out/libexec/yarn/bin/yarn.js $out/bin/yarnpkg ''; + passthru.tests = testVersion { package = yarn; }; + meta = with lib; { homepage = "https://yarnpkg.com/"; description = "Fast, reliable, and secure dependency management for javascript"; diff --git a/pkgs/games/grapejuice/default.nix b/pkgs/games/grapejuice/default.nix index 4c360b2040ad..931de10c18f4 100644 --- a/pkgs/games/grapejuice/default.nix +++ b/pkgs/games/grapejuice/default.nix @@ -49,7 +49,7 @@ python3Packages.buildPythonApplication rec { makeWrapperArgs = [ "\${gappsWrapperArgs[@]}" - "--prefix PATH : ${lib.makeBinPath [ xdg-user-dirs xdg-utils wine (winetricks.override { wine = wine; }) ]}" + "--prefix PATH : ${lib.makeBinPath [ xdg-user-dirs xdg-utils wine winetricks ]}" ]; postPatch = '' diff --git a/pkgs/games/stepmania/0001-fix-build-with-ffmpeg-4.patch b/pkgs/games/stepmania/0001-fix-build-with-ffmpeg-4.patch new file mode 100644 index 000000000000..65686f5546c4 --- /dev/null +++ b/pkgs/games/stepmania/0001-fix-build-with-ffmpeg-4.patch @@ -0,0 +1,136 @@ +From 33d928c54f4b35f8877cacd1e2c77b68b4dddc06 Mon Sep 17 00:00:00 2001 +From: Zane van Iperen +Date: Sun, 7 Nov 2021 15:46:37 +1000 +Subject: [PATCH] fix build with ffmpeg 4 + +--- + src/arch/MovieTexture/MovieTexture_FFMpeg.cpp | 5 +---- + src/arch/MovieTexture/MovieTexture_FFMpeg.h | 22 +++++++++---------- + 2 files changed, 12 insertions(+), 15 deletions(-) + +diff --git a/src/arch/MovieTexture/MovieTexture_FFMpeg.cpp b/src/arch/MovieTexture/MovieTexture_FFMpeg.cpp +index bdf2356..f79fea2 100644 +--- a/src/arch/MovieTexture/MovieTexture_FFMpeg.cpp ++++ b/src/arch/MovieTexture/MovieTexture_FFMpeg.cpp +@@ -445,7 +445,7 @@ RString MovieDecoder_FFMpeg::Open( RString sFile ) + return "Couldn't find any video streams"; + m_pStream = m_fctx->streams[stream_idx]; + +- if( m_pStream->codec->codec_id == avcodec::CODEC_ID_NONE ) ++ if( m_pStream->codec->codec_id == avcodec::AV_CODEC_ID_NONE ) + return ssprintf( "Unsupported codec %08x", m_pStream->codec->codec_tag ); + + RString sError = OpenCodec(); +@@ -474,9 +474,6 @@ RString MovieDecoder_FFMpeg::OpenCodec() + m_pStream->codec->idct_algo = FF_IDCT_AUTO; + m_pStream->codec->error_concealment = 3; + +- if( pCodec->capabilities & CODEC_CAP_DR1 ) +- m_pStream->codec->flags |= CODEC_FLAG_EMU_EDGE; +- + LOG->Trace("Opening codec %s", pCodec->name ); + + int ret = avcodec::avcodec_open2( m_pStream->codec, pCodec, NULL ); +diff --git a/src/arch/MovieTexture/MovieTexture_FFMpeg.h b/src/arch/MovieTexture/MovieTexture_FFMpeg.h +index f4d25ef..32564e5 100644 +--- a/src/arch/MovieTexture/MovieTexture_FFMpeg.h ++++ b/src/arch/MovieTexture/MovieTexture_FFMpeg.h +@@ -64,7 +64,7 @@ private: + + avcodec::AVStream *m_pStream; + avcodec::AVFrame *m_Frame; +- avcodec::PixelFormat m_AVTexfmt; /* PixelFormat of output surface */ ++ avcodec::AVPixelFormat m_AVTexfmt; /* PixelFormat of output surface */ + avcodec::SwsContext *m_swsctx; + + avcodec::AVFormatContext *m_fctx; +@@ -90,7 +90,7 @@ static struct AVPixelFormat_t + { + int bpp; + uint32_t masks[4]; +- avcodec::PixelFormat pf; ++ avcodec::AVPixelFormat pf; + bool bHighColor; + bool bByteSwapOnLittleEndian; + MovieDecoderPixelFormatYCbCr YUV; +@@ -101,7 +101,7 @@ static struct AVPixelFormat_t + 0x00FF0000, + 0x0000FF00, + 0x000000FF }, +- avcodec::PIX_FMT_YUYV422, ++ avcodec::AV_PIX_FMT_YUYV422, + false, /* N/A */ + true, + PixelFormatYCbCr_YUYV422, +@@ -112,7 +112,7 @@ static struct AVPixelFormat_t + 0x00FF0000, + 0xFF000000, + 0x000000FF }, +- avcodec::PIX_FMT_BGRA, ++ avcodec::AV_PIX_FMT_BGRA, + true, + true, + PixelFormatYCbCr_Invalid, +@@ -123,7 +123,7 @@ static struct AVPixelFormat_t + 0x0000FF00, + 0x000000FF, + 0xFF000000 }, +- avcodec::PIX_FMT_ARGB, ++ avcodec::AV_PIX_FMT_ARGB, + true, + true, + PixelFormatYCbCr_Invalid, +@@ -135,7 +135,7 @@ static struct AVPixelFormat_t + 0x0000FF00, + 0x00FF0000, + 0xFF000000 }, +- avcodec::PIX_FMT_ABGR, ++ avcodec::AV_PIX_FMT_ABGR, + true, + true, + PixelFormatYCbCr_Invalid, +@@ -146,7 +146,7 @@ static struct AVPixelFormat_t + 0x00FF0000, + 0x0000FF00, + 0x000000FF }, +- avcodec::PIX_FMT_RGBA, ++ avcodec::AV_PIX_FMT_RGBA, + true, + true, + PixelFormatYCbCr_Invalid, +@@ -157,7 +157,7 @@ static struct AVPixelFormat_t + 0x00FF00, + 0x0000FF, + 0x000000 }, +- avcodec::PIX_FMT_RGB24, ++ avcodec::AV_PIX_FMT_RGB24, + true, + true, + PixelFormatYCbCr_Invalid, +@@ -168,7 +168,7 @@ static struct AVPixelFormat_t + 0x00FF00, + 0xFF0000, + 0x000000 }, +- avcodec::PIX_FMT_BGR24, ++ avcodec::AV_PIX_FMT_BGR24, + true, + true, + PixelFormatYCbCr_Invalid, +@@ -179,12 +179,12 @@ static struct AVPixelFormat_t + 0x03E0, + 0x001F, + 0x0000 }, +- avcodec::PIX_FMT_RGB555, ++ avcodec::AV_PIX_FMT_RGB555, + false, + false, + PixelFormatYCbCr_Invalid, + }, +- { 0, { 0,0,0,0 }, avcodec::PIX_FMT_NB, true, false, PixelFormatYCbCr_Invalid } ++ { 0, { 0,0,0,0 }, avcodec::AV_PIX_FMT_NB, true, false, PixelFormatYCbCr_Invalid } + }; + + #endif +-- +2.31.1 + diff --git a/pkgs/games/stepmania/default.nix b/pkgs/games/stepmania/default.nix index 70e1acb1f34f..c7f8f0d7a27f 100644 --- a/pkgs/games/stepmania/default.nix +++ b/pkgs/games/stepmania/default.nix @@ -14,6 +14,10 @@ stdenv.mkDerivation rec { sha256 = "0a7y9l7xm510vgnpmj1is7p9m6d6yd0fcaxrjcickz295k5w3rdn"; }; + patches = [ + ./0001-fix-build-with-ffmpeg-4.patch + ]; + nativeBuildInputs = [ cmake nasm ]; buildInputs = [ diff --git a/pkgs/misc/emulators/pcsxr/0001-libpcsxcore-fix-build-with-ffmpeg-4.patch b/pkgs/misc/emulators/pcsxr/0001-libpcsxcore-fix-build-with-ffmpeg-4.patch new file mode 100644 index 000000000000..0edc6281a7ef --- /dev/null +++ b/pkgs/misc/emulators/pcsxr/0001-libpcsxcore-fix-build-with-ffmpeg-4.patch @@ -0,0 +1,76 @@ +From 351be6b3f2ad10d86ec4ae711db5a1067acc592a Mon Sep 17 00:00:00 2001 +From: Zane van Iperen +Date: Sun, 7 Nov 2021 15:17:07 +1000 +Subject: [PATCH] libpcsxcore: fix build with ffmpeg 4 + +--- + libpcsxcore/cdriso.c | 16 ++++++++-------- + 1 file changed, 8 insertions(+), 8 deletions(-) + +diff --git a/libpcsxcore/cdriso.c b/libpcsxcore/cdriso.c +index f89678e..6314482 100644 +--- a/libpcsxcore/cdriso.c ++++ b/libpcsxcore/cdriso.c +@@ -266,14 +266,14 @@ static int decode_compressed_cdda_track(FILE* outfile, const char* infilepath, s + } + + if (!decoded_frame) { +- if (!(decoded_frame = avcodec_alloc_frame())) { ++ if (!(decoded_frame = av_frame_alloc())) { + SysMessage(_(" -> Error allocating audio frame buffer. This track will not be available.")); + avformat_close_input(&inAudioFormat); +- avcodec_free_frame(&decoded_frame); ++ av_frame_free(&decoded_frame); + return 1; // error decoding frame + } + } else { +- avcodec_get_frame_defaults(decoded_frame); ++ av_frame_unref(decoded_frame); + } + len = avcodec_decode_audio4(c, decoded_frame, &got_frame, &avpkt); + if (len > 0 && got_frame) { +@@ -285,7 +285,7 @@ static int decode_compressed_cdda_track(FILE* outfile, const char* infilepath, s + fwrite(decoded_frame->data[0], 1, data_size, outfile); + } + av_free_packet(&avpkt); +- //avcodec_free_frame(&decoded_frame); ++ //av_frame_free(&decoded_frame); + } while (moreFrames >= 0); // TODO: check for possible leaks + + // file will be closed later on, now just flush it +@@ -294,7 +294,7 @@ static int decode_compressed_cdda_track(FILE* outfile, const char* infilepath, s + avformat_close_input(&inAudioFormat); + //avcodec_close(c); + //av_free(c); +- avcodec_free_frame(&decoded_frame); ++ av_frame_free(&decoded_frame); + return 0; + } + #endif +@@ -340,12 +340,12 @@ static int decode_compressed_cdda_track(FILE* outfile, FILE* infile, enum AVCode + while (avpkt.size > 0) { + int got_frame = 0; + if (!decoded_frame) { +- if (!(decoded_frame = avcodec_alloc_frame())) { ++ if (!(decoded_frame = av_frame_alloc())) { + SysPrintf(" -> Error allocating audio frame buffer. Track will not be available."); + return 1; // error decoding frame + } + } else { +- avcodec_get_frame_defaults(decoded_frame); ++ av_frame_unref(decoded_frame); + } + + len = avcodec_decode_audio4(c, decoded_frame, &got_frame, &avpkt); +@@ -383,7 +383,7 @@ static int decode_compressed_cdda_track(FILE* outfile, FILE* infile, enum AVCode + + avcodec_close(c); + av_free(c); +- avcodec_free_frame(&decoded_frame); ++ av_frame_free(&decoded_frame); + return 0; + } + #endif +-- +2.31.1 + diff --git a/pkgs/misc/emulators/pcsxr/default.nix b/pkgs/misc/emulators/pcsxr/default.nix index 099795c63fd1..e3126efe82db 100644 --- a/pkgs/misc/emulators/pcsxr/default.nix +++ b/pkgs/misc/emulators/pcsxr/default.nix @@ -47,6 +47,7 @@ stdenv.mkDerivation rec { }) ./uncompress2.patch + ./0001-libpcsxcore-fix-build-with-ffmpeg-4.patch ]; nativeBuildInputs = [ autoreconfHook intltool pkg-config wrapGAppsHook ]; diff --git a/pkgs/misc/emulators/wine/winetricks.nix b/pkgs/misc/emulators/wine/winetricks.nix index cfde64fc33ac..26c141a71e74 100644 --- a/pkgs/misc/emulators/wine/winetricks.nix +++ b/pkgs/misc/emulators/wine/winetricks.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, callPackage, wine, perl, which, coreutils, zenity, curl +{ lib, stdenv, callPackage, perl, which, coreutils, zenity, curl , cabextract, unzip, p7zip, gnused, gnugrep, bash } : stdenv.mkDerivation rec { @@ -9,9 +9,9 @@ stdenv.mkDerivation rec { buildInputs = [ perl which ]; # coreutils is for sha1sum - pathAdd = lib.concatMapStringsSep ":" (x: x + "/bin") - (lib.filter (x: x != null) - [ wine perl which coreutils zenity curl cabextract unzip p7zip gnused gnugrep bash ]); + pathAdd = lib.makeBinPath [ + perl which coreutils zenity curl cabextract unzip p7zip gnused gnugrep bash + ]; makeFlags = [ "PREFIX=$(out)" ]; diff --git a/pkgs/misc/gnash/0001-fix-build-with-ffmepg-4.patch b/pkgs/misc/gnash/0001-fix-build-with-ffmepg-4.patch new file mode 100644 index 000000000000..f6316ae972fd --- /dev/null +++ b/pkgs/misc/gnash/0001-fix-build-with-ffmepg-4.patch @@ -0,0 +1,57 @@ +From cb13c20332526a4db99e7fd0818b9a75829affad Mon Sep 17 00:00:00 2001 +From: Zane van Iperen +Date: Sun, 7 Nov 2021 15:36:02 +1000 +Subject: [PATCH] fix build with ffmepg 4 + +--- + libmedia/ffmpeg/MediaHandlerFfmpeg.cpp | 2 +- + libmedia/ffmpeg/MediaParserFfmpeg.cpp | 6 +++--- + 2 files changed, 4 insertions(+), 4 deletions(-) + +diff --git a/libmedia/ffmpeg/MediaHandlerFfmpeg.cpp b/libmedia/ffmpeg/MediaHandlerFfmpeg.cpp +index 127aaaa..216d96b 100644 +--- a/libmedia/ffmpeg/MediaHandlerFfmpeg.cpp ++++ b/libmedia/ffmpeg/MediaHandlerFfmpeg.cpp +@@ -149,7 +149,7 @@ MediaHandlerFfmpeg::cameraNames(std::vector& /*names*/) const + size_t + MediaHandlerFfmpeg::getInputPaddingSize() const + { +- return FF_INPUT_BUFFER_PADDING_SIZE; ++ return AV_INPUT_BUFFER_PADDING_SIZE; + } + + } // gnash.media.ffmpeg namespace +diff --git a/libmedia/ffmpeg/MediaParserFfmpeg.cpp b/libmedia/ffmpeg/MediaParserFfmpeg.cpp +index 9ceb8b0..a27ca56 100644 +--- a/libmedia/ffmpeg/MediaParserFfmpeg.cpp ++++ b/libmedia/ffmpeg/MediaParserFfmpeg.cpp +@@ -64,7 +64,7 @@ AVInputFormat* + MediaParserFfmpeg::probeStream() + { + const size_t probeSize = 4096; +- const size_t bufSize = probeSize + FF_INPUT_BUFFER_PADDING_SIZE; ++ const size_t bufSize = probeSize + AV_INPUT_BUFFER_PADDING_SIZE; + + std::unique_ptr buffer(new std::uint8_t[bufSize]); + +@@ -173,7 +173,7 @@ MediaParserFfmpeg::parseVideoFrame(AVPacket& packet) + + // TODO: We might avoid the copy as a whole by making EncodedVideoFrame + // virtual. +- size_t allocSize = packet.size + FF_INPUT_BUFFER_PADDING_SIZE; ++ size_t allocSize = packet.size + AV_INPUT_BUFFER_PADDING_SIZE; + std::uint8_t* data = new std::uint8_t[allocSize]; + std::copy(packet.data, packet.data+packet.size, data); + std::unique_ptr frame(new EncodedVideoFrame(data, packet.size, 0, timestamp)); +@@ -221,7 +221,7 @@ MediaParserFfmpeg::parseAudioFrame(AVPacket& packet) + + // TODO: We might avoid the copy as a whole by making EncodedAudioFrame + // virtual. +- size_t allocSize = packet.size + FF_INPUT_BUFFER_PADDING_SIZE; ++ size_t allocSize = packet.size + AV_INPUT_BUFFER_PADDING_SIZE; + std::uint8_t* data = new std::uint8_t[allocSize]; + std::copy(packet.data, packet.data+packet.size, data); + +-- +2.31.1 + diff --git a/pkgs/misc/gnash/default.nix b/pkgs/misc/gnash/default.nix index 9f5f022b8538..fc7148b40489 100644 --- a/pkgs/misc/gnash/default.nix +++ b/pkgs/misc/gnash/default.nix @@ -16,7 +16,7 @@ , enableQt ? false, qt4 ? null # media -, enableFFmpeg ? true, ffmpeg_2 ? null +, enableFFmpeg ? true, ffmpeg ? null # misc , enableJemalloc ? true, jemalloc ? null @@ -55,7 +55,7 @@ assert enableSDL -> available SDL; assert enableQt -> available qt4; # media libraries -assert enableFFmpeg -> available ffmpeg_2 ; +assert enableFFmpeg -> available ffmpeg ; # misc assert enableJemalloc -> available jemalloc; @@ -88,7 +88,7 @@ stdenv.mkDerivation { ] ++ optional enableAGG agg ++ optional enableCairo cairo ++ optional enableQt qt4 - ++ optional enableFFmpeg ffmpeg_2 + ++ optional enableFFmpeg ffmpeg ++ optional enableJemalloc jemalloc ++ optional enableHwAccel [ libGL libGLU ] ++ optionals enableOpenGL [ libGL libGLU ] @@ -107,6 +107,8 @@ stdenv.mkDerivation { url = "https://savannah.gnu.org/file/0001-Do-not-depend-on-pangox.patch?file_id=48366"; sha256 = "02x7sl5zwd1ld2n4b6bp16c5gk91qsap0spfbb5iwpglq3galv2l"; }) + + ./0001-fix-build-with-ffmepg-4.patch ]; configureFlags = with lib; [ diff --git a/pkgs/os-specific/linux/cpuid/default.nix b/pkgs/os-specific/linux/cpuid/default.nix index ea9ae06130ec..a434501d5126 100644 --- a/pkgs/os-specific/linux/cpuid/default.nix +++ b/pkgs/os-specific/linux/cpuid/default.nix @@ -1,20 +1,27 @@ -{ lib, stdenv, fetchurl, perl }: +{ lib +, stdenv +, fetchurl +, perl +}: stdenv.mkDerivation rec { pname = "cpuid"; - version = "20201006"; + version = "20211031"; src = fetchurl { - name = "${pname}-${version}.src.tar.gz"; url = "http://etallen.com/cpuid/${pname}-${version}.src.tar.gz"; - sha256 = "19jnkh57f979b78ak5mpxmdvnkgc33r55cw9shgd2hc380b3zi8k"; + sha256 = "13sxb2ar4gypiv0l87lr7hf3qjccwgsg1r92adv9jvrfxcv36pbn"; }; # For pod2man during the build process. - nativeBuildInputs = [ perl ]; + nativeBuildInputs = [ + perl + ]; # As runtime dependency for cpuinfo2cpuid. - buildInputs = [ perl ]; + buildInputs = [ + perl + ]; # The Makefile hardcodes $(BUILDROOT)/usr as installation # destination. Just nuke all mentions of /usr to get the right @@ -32,7 +39,7 @@ stdenv.mkDerivation rec { fi ''; - meta = { + meta = with lib; { description = "Linux tool to dump x86 CPUID information about the CPU"; longDescription = '' cpuid dumps detailed information about the CPU(s) gathered from the CPUID @@ -40,11 +47,10 @@ stdenv.mkDerivation rec { Intel, AMD, VIA, Hygon, and Zhaoxin CPUs, as well as older Transmeta, Cyrix, UMC, NexGen, Rise, and SiS CPUs. ''; - platforms = [ "i686-linux" "x86_64-linux" ]; - license = lib.licenses.gpl2; + license = licenses.gpl2Plus; homepage = "http://etallen.com/cpuid.html"; - maintainers = with lib.maintainers; [ blitz ]; + maintainers = with maintainers; [ blitz ]; }; } diff --git a/pkgs/os-specific/linux/smemstat/default.nix b/pkgs/os-specific/linux/smemstat/default.nix index 1510981c1767..f95532ada3c4 100644 --- a/pkgs/os-specific/linux/smemstat/default.nix +++ b/pkgs/os-specific/linux/smemstat/default.nix @@ -1,4 +1,4 @@ -{ stdenv, lib, fetchurl, ncurses }: +{ stdenv, lib, fetchurl, fetchpatch, ncurses }: stdenv.mkDerivation rec { pname = "smemstat"; @@ -7,6 +7,15 @@ stdenv.mkDerivation rec { url = "https://kernel.ubuntu.com/~cking/tarballs/smemstat/smemstat-${version}.tar.xz"; sha256 = "sha256-Vrs1jOg5yHdEffVo769aaxSawo4iZtGrFJ65Nu+RhcU="; }; + patches = [ + # Pull patch pending upstream inclusion to support ncurses-6.3: + # https://github.com/ColinIanKing/smemstat/pull/1 + (fetchpatch { + name = "ncurses-6.3.patch"; + url = "https://github.com/ColinIanKing/smemstat/commit/95119558d1679295c9f9f7f618ddbe212674a4bf.patch"; + sha256 = "sha256-Cl3Y0HIy1nXqBux6+AXoPuKJatSv3Z0X/4bD+MNjkAQ="; + }) + ]; buildInputs = [ ncurses ]; installFlags = [ "DESTDIR=$(out)" ]; postInstall = '' @@ -15,7 +24,7 @@ stdenv.mkDerivation rec { ''; meta = with lib; { description = "Memory usage monitoring tool"; - homepage = "https://kernel.ubuntu.com/~cking/smemstat/"; + homepage = "https://github.com/ColinIanKing/smemstat"; license = licenses.gpl2; platforms = platforms.linux; maintainers = with maintainers; [ womfoo ]; diff --git a/pkgs/servers/http/couchdb/3.nix b/pkgs/servers/http/couchdb/3.nix index 50d4012297fc..4a7144a8e185 100644 --- a/pkgs/servers/http/couchdb/3.nix +++ b/pkgs/servers/http/couchdb/3.nix @@ -1,16 +1,16 @@ { lib, stdenv, fetchurl, erlang, icu, openssl, spidermonkey_78 -, coreutils, bash, makeWrapper, python3 }: +, coreutils, bash, makeWrapper, python3, nixosTests }: stdenv.mkDerivation rec { pname = "couchdb"; - version = "3.2.0"; + version = "3.2.1"; # when updating this, please consider bumping the erlang/OTP version # in all-packages.nix src = fetchurl { url = "mirror://apache/couchdb/source/${version}/apache-${pname}-${version}.tar.gz"; - sha256 = "035hy76399yy32rxl536gv7nh8ijihqxhhh5cxn95c3bm97mgslb"; + sha256 = "1y5cfic88drlr9qiwyj2p8xc9m9hcbvw77j5lwbp0cav78f2vphi"; }; buildInputs = [ erlang icu openssl spidermonkey_78 (python3.withPackages(ps: with ps; [ requests ]))]; @@ -28,6 +28,10 @@ stdenv.mkDerivation rec { cp -r rel/couchdb/* $out ''; + passthru.tests = { + inherit (nixosTests) couchdb; + }; + meta = with lib; { description = "A database that uses JSON for documents, JavaScript for MapReduce queries, and regular HTTP for an API"; homepage = "http://couchdb.apache.org"; diff --git a/pkgs/servers/monitoring/loki/default.nix b/pkgs/servers/monitoring/loki/default.nix index d23a873ccecb..62cd19a89c2b 100644 --- a/pkgs/servers/monitoring/loki/default.nix +++ b/pkgs/servers/monitoring/loki/default.nix @@ -8,14 +8,14 @@ }: buildGoModule rec { - version = "2.3.0"; + version = "2.4.0"; pname = "grafana-loki"; src = fetchFromGitHub { rev = "v${version}"; owner = "grafana"; repo = "loki"; - sha256 = "sha256-Cxg3VRF4p/Kb6LyreGV0g+zPr15wplritSZgkbTiDI0="; + sha256 = "sha256-5A2DzFYLkPnBHqgMUDog0IgbdAx+U1U5npzuqJGbEHQ="; }; vendorSha256 = null; diff --git a/pkgs/tools/admin/lxd/default.nix b/pkgs/tools/admin/lxd/default.nix index e4d2b714610f..24e241f1b247 100644 --- a/pkgs/tools/admin/lxd/default.nix +++ b/pkgs/tools/admin/lxd/default.nix @@ -11,28 +11,15 @@ buildGoPackage rec { pname = "lxd"; - version = "4.19"; + version = "4.20"; goPackagePath = "github.com/lxc/lxd"; src = fetchurl { url = "https://linuxcontainers.org/downloads/lxd/lxd-${version}.tar.gz"; - sha256 = "0mxbzg8xra0qpd3g3z1b230f0519h56x4jnn09lbbqa92p5zck3f"; + sha256 = "1mcf4i4z9y4l895v50amx8nix6wnaxv9h44012vj8w6wwbr4wl1m"; }; - patches = [ - # lxd/checkfeature: check whether the kernel supports core scheduling - (fetchpatch { - url = "https://github.com/lxc/lxd/commit/ba6be1043714458b29c4b37687d4f624ee421943.patch"; - sha256 = "0716129n70c6i695fyi1j8q6cls7g62vkdpcrlfrr9i324y3w1dx"; - }) - # feat: add support for nixOS path - (fetchpatch { - url = "https://github.com/lxc/lxd/commit/eeace06b2e3151786e94811ada8c658cce479f6d.patch"; - sha256 = "sha256-knXlvcSvMPDeR0KqHFgh6YQZc+CSJ8yEqGE/vQMciEk="; - }) - ]; - postPatch = '' substituteInPlace shared/usbid/load.go \ --replace "/usr/share/misc/usb.ids" "${hwdata}/share/hwdata/usb.ids" diff --git a/pkgs/tools/misc/yubikey-manager/default.nix b/pkgs/tools/misc/yubikey-manager/default.nix index 2b7e73b35516..23b040f26097 100644 --- a/pkgs/tools/misc/yubikey-manager/default.nix +++ b/pkgs/tools/misc/yubikey-manager/default.nix @@ -2,13 +2,13 @@ python3Packages.buildPythonPackage rec { pname = "yubikey-manager"; - version = "4.0.5"; + version = "4.0.7"; src = fetchFromGitHub { repo = "yubikey-manager"; rev = version; owner = "Yubico"; - sha256 = "sha256:0ycp7k6lkxzqwkc16fifhyqaqi7hl3351pwddsn18r5l83jnzdn2"; + sha256 = "sha256-PG/mIM1rcs1SAz2kfQtfUWoMBIwLz2ASZM0YQrz9w5I="; }; postPatch = '' diff --git a/pkgs/tools/networking/eternal-terminal/default.nix b/pkgs/tools/networking/eternal-terminal/default.nix index 21bd75a3ebae..7724d2d89fdc 100644 --- a/pkgs/tools/networking/eternal-terminal/default.nix +++ b/pkgs/tools/networking/eternal-terminal/default.nix @@ -10,13 +10,13 @@ stdenv.mkDerivation rec { pname = "eternal-terminal"; - version = "6.1.8"; + version = "6.1.9"; src = fetchFromGitHub { owner = "MisterTea"; repo = "EternalTerminal"; rev = "et-v${version}"; - sha256 = "sha256-VSJ6AoVBvlCdKSirSDqsemixF+kAnvPgBQlyJxjoPcs="; + sha256 = "0kpabxpy779ppkaqaigq0x34ymz1jcwpsa78rm6nr55mdap2xxv6"; }; cmakeFlags= [ diff --git a/pkgs/tools/security/metasploit/default.nix b/pkgs/tools/security/metasploit/default.nix index 9ce3f56b58d8..c3cf57bc2ae8 100644 --- a/pkgs/tools/security/metasploit/default.nix +++ b/pkgs/tools/security/metasploit/default.nix @@ -4,6 +4,7 @@ , makeWrapper , ruby , bundlerEnv +, python3 }: let @@ -24,6 +25,7 @@ in stdenv.mkDerivation rec { }; nativeBuildInputs = [ makeWrapper ]; + buildInputs = [ (python3.withPackages (ps: [ ps.requests ])) ]; dontPatchELF = true; # stay away from exploit executables @@ -32,6 +34,8 @@ in stdenv.mkDerivation rec { cp -r * $out/share/msf + grep -rl "^#\!.*python2$" $out/share/msf | xargs -d '\n' rm + ( cd $out/share/msf/ for i in msf*; do diff --git a/pkgs/tools/security/nosqli/default.nix b/pkgs/tools/security/nosqli/default.nix index 3163d1683710..dbe336edc6d0 100644 --- a/pkgs/tools/security/nosqli/default.nix +++ b/pkgs/tools/security/nosqli/default.nix @@ -5,16 +5,16 @@ buildGoModule rec { pname = "nosqli"; - version = "0.5.2"; + version = "0.5.4"; src = fetchFromGitHub { owner = "Charlie-belmer"; repo = pname; rev = "v${version}"; - sha256 = "006z76v4a3pxzgnkj5nl0mrlsqmfgvg51w20dl118k2xa70zz63j"; + sha256 = "sha256-CgD9b5eHDK/8QhQmrqT09Jf9snn9WItNMtTNbJFT2sI="; }; - vendorSha256 = "01spdh2gbzp6yg2jbiwfnyhqb5s605hyfxhs0f9h4ps4qbi1h9cv"; + vendorSha256 = "sha256-QnrzEei4Pt4C0vCJu4YN28lWWAqEikmNLrqshd3knx4="; meta = with lib; { description = "NoSql Injection tool for finding vulnerable websites using MongoDB"; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 5e69a6291041..8c0829136e3c 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -13605,6 +13605,7 @@ with pkgs; spidermonkey_68 = callPackage ../development/interpreters/spidermonkey/68.nix { }; spidermonkey_78 = callPackage ../development/interpreters/spidermonkey/78.nix { }; + spidermonkey_91 = callPackage ../development/interpreters/spidermonkey/91.nix { }; ssm-agent = callPackage ../applications/networking/cluster/ssm-agent { }; ssm-session-manager-plugin = callPackage ../applications/networking/cluster/ssm-session-manager-plugin { }; @@ -16040,9 +16041,6 @@ with pkgs; linbox = callPackage ../development/libraries/linbox { }; - ffmpeg_2_8 = callPackage ../development/libraries/ffmpeg/2.8.nix { - inherit (darwin.apple_sdk.frameworks) Cocoa; - }; ffmpeg_3_4 = callPackage ../development/libraries/ffmpeg/3.4.nix { inherit (darwin.apple_sdk.frameworks) Cocoa CoreMedia; }; @@ -16051,7 +16049,6 @@ with pkgs; }; # Aliases - ffmpeg_2 = ffmpeg_2_8; ffmpeg_3 = ffmpeg_3_4; # Please make sure this is updated to the latest version on the next major # update to ffmpeg @@ -27242,9 +27239,7 @@ with pkgs; pcloud = callPackage ../applications/networking/pcloud { }; - pcsxr = callPackage ../misc/emulators/pcsxr { - ffmpeg = ffmpeg_2; - }; + pcsxr = callPackage ../misc/emulators/pcsxr { }; pcsx2 = callPackage ../misc/emulators/pcsx2 { wxGTK = wxGTK30-gtk3; @@ -30455,22 +30450,14 @@ with pkgs; steam-acf = callPackage ../tools/games/steam-acf { }; protontricks = python3Packages.callPackage ../tools/package-management/protontricks { - winetricks = winetricks.override { - # Remove default build of wine to reduce closure size. - # Falls back to wine in PATH. - wine = null; - }; - - inherit steam-run yad; + inherit winetricks steam-run yad; }; protonup = with python3Packages; toPythonApplication protonup; sdlpop = callPackage ../games/sdlpop { }; - stepmania = callPackage ../games/stepmania { - ffmpeg = ffmpeg_2; - }; + stepmania = callPackage ../games/stepmania { }; streamlit = python3Packages.callPackage ../applications/science/machine-learning/streamlit { };