diff --git a/pkgs/by-name/bl/blink-qt/package.nix b/pkgs/by-name/bl/blink-qt/package.nix index 4c6dde719b68..e5667fcdebfb 100644 --- a/pkgs/by-name/bl/blink-qt/package.nix +++ b/pkgs/by-name/bl/blink-qt/package.nix @@ -55,7 +55,7 @@ python3Packages.buildPythonApplication rec { python3-application python3-eventlib python3-gnutls - sipsimple + python3-sipsimple sqlobject standard-imghdr xcaplib diff --git a/pkgs/by-name/sy/sylkserver/package.nix b/pkgs/by-name/sy/sylkserver/package.nix index 8f8fce608f9f..d2fcb511e53c 100644 --- a/pkgs/by-name/sy/sylkserver/package.nix +++ b/pkgs/by-name/sy/sylkserver/package.nix @@ -37,7 +37,7 @@ python3Packages.buildPythonApplication rec { msrplib python3-eventlib python3-gnutls - sipsimple + python3-sipsimple wokkel xcaplib ]; diff --git a/pkgs/development/python-modules/sipsimple/default.nix b/pkgs/development/python-modules/python3-sipsimple/default.nix similarity index 59% rename from pkgs/development/python-modules/sipsimple/default.nix rename to pkgs/development/python-modules/python3-sipsimple/default.nix index 2b879db6eeed..0cb17e89985b 100644 --- a/pkgs/development/python-modules/sipsimple/default.nix +++ b/pkgs/development/python-modules/python3-sipsimple/default.nix @@ -20,44 +20,7 @@ x264, python3-application, }: - let - extDeps = { - pjsip = rec { - # Hardcoded in get_dependencies.sh, checked at buildtime - # need tarball specifically for buildscript to detect it - version = "2.10"; - src = fetchurl { - url = "https://github.com/pjsip/pjproject/archive/${version}.tar.gz"; - hash = "sha256-k2pMW5hgG1IyVGOjl93xGrQQbGp7BPjcfN03fvu1l94="; - }; - patches = [ - # Backported https://github.com/pjsip/pjproject/commit/4a8d180529d6ffb0760838b1f8cadc4cb5f7ac03 - ./pjsip-0001-NEON.patch - - # Backported https://github.com/pjsip/pjproject/commit/f56fd48e23982c47f38574a3fd93ebf248ef3762 - ./pjsip-0002-RISC-V.patch - - # Backported https://github.com/pjsip/pjproject/commit/f94b18ef6e0c0b5d34eb274f85ac0a3b2cf9107a - ./pjsip-0003-LoongArch64.patch - ]; - }; - zrtpcpp = rec { - # Hardcoded in get_dependencies.sh, NOT checked at buildtime - rev = "6b3cd8e6783642292bad0c21e3e5e5ce45ff3e03"; - src = fetchFromGitHub { - owner = "wernerd"; - repo = "ZRTPCPP"; - inherit rev; - hash = "sha256-pGng1Y9N51nGBpiZbn2NTx4t2NGg4qkmbghTscJVhIA="; - postFetch = '' - # fix build with gcc15 - sed -e '9i #include ' -i $out/zrtp/EmojiBase32.cpp - ''; - }; - }; - }; - applyPatchesWhenAvailable = extDep: dir: lib.optionalString (extDep ? patches) ( @@ -67,7 +30,7 @@ let '') extDep.patches ); in -buildPythonPackage rec { +buildPythonPackage (finalAttrs: { pname = "python3-sipsimple"; version = "5.3.3.2"; pyproject = true; @@ -75,7 +38,7 @@ buildPythonPackage rec { src = fetchFromGitHub { owner = "AGProjects"; repo = "python3-sipsimple"; - tag = "${version}-mac"; + tag = "${finalAttrs.version}-mac"; hash = "sha256-kDXVzLmgfXxm8phKrV7DvPuZ9O2iNFo1s6Lc0jcc/dM="; }; @@ -122,13 +85,13 @@ buildPythonPackage rec { ]; preConfigure = '' - ln -s ${passthru.extDeps.pjsip.src} deps/${passthru.extDeps.pjsip.version}.tar.gz - cp -r --no-preserve=all ${passthru.extDeps.zrtpcpp.src} deps/ZRTPCPP + ln -s ${finalAttrs.passthru.extDeps.pjsip.src} deps/${finalAttrs.passthru.extDeps.pjsip.version}.tar.gz + cp -r --no-preserve=all ${finalAttrs.passthru.extDeps.zrtpcpp.src} deps/ZRTPCPP bash ./get_dependencies.sh '' - + applyPatchesWhenAvailable extDeps.pjsip "deps/pjsip" - + applyPatchesWhenAvailable extDeps.zrtpcpp "deps/ZRTPCPP" + + applyPatchesWhenAvailable finalAttrs.passthru.extDeps.pjsip "deps/pjsip" + + applyPatchesWhenAvailable finalAttrs.passthru.extDeps.zrtpcpp "deps/ZRTPCPP" + '' # Fails to link some static libs due to missing -lc DSO. Just use the compiler frontend instead of raw ld. substituteInPlace deps/pjsip/build/rules.mak \ @@ -145,13 +108,47 @@ buildPythonPackage rec { pythonImportsCheck = [ "sipsimple" ]; passthru = { - inherit extDeps; updateScript = nix-update-script { extraArgs = [ "--version-regex" "^(.*)-mac$" ]; }; + extDeps = { + pjsip = rec { + # Hardcoded in get_dependencies.sh, checked at buildtime + # need tarball specifically for buildscript to detect it + version = "2.10"; + src = fetchurl { + url = "https://github.com/pjsip/pjproject/archive/${version}.tar.gz"; + hash = "sha256-k2pMW5hgG1IyVGOjl93xGrQQbGp7BPjcfN03fvu1l94="; + }; + patches = [ + # Backported https://github.com/pjsip/pjproject/commit/4a8d180529d6ffb0760838b1f8cadc4cb5f7ac03 + ./pjsip-0001-NEON.patch + + # Backported https://github.com/pjsip/pjproject/commit/f56fd48e23982c47f38574a3fd93ebf248ef3762 + ./pjsip-0002-RISC-V.patch + + # Backported https://github.com/pjsip/pjproject/commit/f94b18ef6e0c0b5d34eb274f85ac0a3b2cf9107a + ./pjsip-0003-LoongArch64.patch + ]; + }; + zrtpcpp = rec { + # Hardcoded in get_dependencies.sh, NOT checked at buildtime + rev = "6b3cd8e6783642292bad0c21e3e5e5ce45ff3e03"; + src = fetchFromGitHub { + owner = "wernerd"; + repo = "ZRTPCPP"; + inherit rev; + hash = "sha256-pGng1Y9N51nGBpiZbn2NTx4t2NGg4qkmbghTscJVhIA="; + postFetch = '' + # fix build with gcc15 + sed -e '9i #include ' -i $out/zrtp/EmojiBase32.cpp + ''; + }; + }; + }; }; meta = { @@ -162,4 +159,4 @@ buildPythonPackage rec { teams = [ lib.teams.ngi ]; maintainers = [ lib.maintainers.ethancedwards8 ]; }; -} +}) diff --git a/pkgs/development/python-modules/sipsimple/pjsip-0001-NEON.patch b/pkgs/development/python-modules/python3-sipsimple/pjsip-0001-NEON.patch similarity index 100% rename from pkgs/development/python-modules/sipsimple/pjsip-0001-NEON.patch rename to pkgs/development/python-modules/python3-sipsimple/pjsip-0001-NEON.patch diff --git a/pkgs/development/python-modules/sipsimple/pjsip-0002-RISC-V.patch b/pkgs/development/python-modules/python3-sipsimple/pjsip-0002-RISC-V.patch similarity index 100% rename from pkgs/development/python-modules/sipsimple/pjsip-0002-RISC-V.patch rename to pkgs/development/python-modules/python3-sipsimple/pjsip-0002-RISC-V.patch diff --git a/pkgs/development/python-modules/sipsimple/pjsip-0003-LoongArch64.patch b/pkgs/development/python-modules/python3-sipsimple/pjsip-0003-LoongArch64.patch similarity index 100% rename from pkgs/development/python-modules/sipsimple/pjsip-0003-LoongArch64.patch rename to pkgs/development/python-modules/python3-sipsimple/pjsip-0003-LoongArch64.patch diff --git a/pkgs/top-level/python-aliases.nix b/pkgs/top-level/python-aliases.nix index fc422f95a703..b437c9631ded 100644 --- a/pkgs/top-level/python-aliases.nix +++ b/pkgs/top-level/python-aliases.nix @@ -451,6 +451,7 @@ mapAliases { sharkiqpy = throw "'sharkiqpy' has been renamed to/replaced by 'sharkiq'"; # Converted to throw 2025-10-29 shippai = throw "shippai has been removed because the upstream repository was archived in 2023"; # added 2025-07-09 sip_4 = throw "'sip_4' has been renamed to/replaced by 'sip4'"; # Converted to throw 2025-10-29 + sipsimple = lib.warnOnInstantiate "'sipsimple' has been renamed to 'python3-sipsimple' to fit upstream naming" python3-sipsimple; # added 2026-01-05 slackclient = throw "'slackclient' has been renamed to/replaced by 'slack-sdk'"; # Converted to throw 2025-10-29 smart_open = throw "'smart_open' has been renamed to/replaced by 'smart-open'"; # Converted to throw 2025-10-29 smpp_pdu = throw "'smpp_pdu' has been renamed to/replaced by 'smpp-pdu'"; # Converted to throw 2025-10-29 diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 85854a912bbd..f6816c65d333 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -15654,6 +15654,8 @@ self: super: with self; { python3-saml = callPackage ../development/python-modules/python3-saml { }; + python3-sipsimple = callPackage ../development/python-modules/python3-sipsimple { }; + pythondialog = callPackage ../development/python-modules/pythondialog { }; pythonefl = callPackage ../development/python-modules/python-efl { }; @@ -17324,8 +17326,6 @@ self: super: with self; { siphashc = callPackage ../development/python-modules/siphashc { }; - sipsimple = callPackage ../development/python-modules/sipsimple { }; - sipyco = callPackage ../development/python-modules/sipyco { }; sirius = toPythonModule (