From d6673a51bc974753373714c15a9a8f5c191e1336 Mon Sep 17 00:00:00 2001 From: Andrew Morgan <1342360+anoadragon453@users.noreply.github.com> Date: Fri, 15 Jul 2022 00:21:53 +0100 Subject: [PATCH] python3Packages.nextcord: fix issue with loading libopus The substitution patch used to point nextcord to the installed location of libopus in nix's store was incorrectly formatted: * `@opus@` was used while default.nix attempted to substitute instances of `@libopus@`. * `ctypes.util.find_library()` will return a path to a library. If we already have the path (provided by the substitution), then `find_library` is not necessary to call (nor will it produce the desired result). --- pkgs/development/python-modules/nextcord/paths.patch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/python-modules/nextcord/paths.patch b/pkgs/development/python-modules/nextcord/paths.patch index 8e6b58897f55..b5c9ce4f77a7 100644 --- a/pkgs/development/python-modules/nextcord/paths.patch +++ b/pkgs/development/python-modules/nextcord/paths.patch @@ -7,7 +7,7 @@ index 52e4ddbd..d8b8090b 100644 _lib = libopus_loader(_filename) else: - opus = ctypes.util.find_library("opus") -+ opus = ctypes.util.find_library("@opus@") ++ opus = "@libopus@" if opus is None: _lib = None