diff options
Diffstat (limited to 'nixpkgs/pkgs/games/anki/patches')
3 files changed, 55 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/games/anki/patches/disable-auto-update.patch b/nixpkgs/pkgs/games/anki/patches/disable-auto-update.patch new file mode 100644 index 000000000000..25071a0f1943 --- /dev/null +++ b/nixpkgs/pkgs/games/anki/patches/disable-auto-update.patch @@ -0,0 +1,15 @@ +diff --git a/qt/aqt/main.py b/qt/aqt/main.py +index 6c634132d..f3f3d4d10 100644 +--- a/qt/aqt/main.py ++++ b/qt/aqt/main.py +@@ -1421,6 +1421,8 @@ title="{}" {}>{}</button>""".format( + ########################################################################## + + def setup_auto_update(self, _log: list[DownloadLogEntry]) -> None: ++ return ++ + from aqt.update import check_for_update + + check_for_update() +-- +2.42.0 diff --git a/nixpkgs/pkgs/games/anki/patches/remove-the-gl-library-workaround.patch b/nixpkgs/pkgs/games/anki/patches/remove-the-gl-library-workaround.patch new file mode 100644 index 000000000000..0a3f94e132a0 --- /dev/null +++ b/nixpkgs/pkgs/games/anki/patches/remove-the-gl-library-workaround.patch @@ -0,0 +1,19 @@ +diff --git a/qt/aqt/__init__.py b/qt/aqt/__init__.py +index 6f28d2dd0..fcd6a5ee4 100644 +--- a/qt/aqt/__init__.py ++++ b/qt/aqt/__init__.py +@@ -402,12 +402,6 @@ def setupGL(pm: aqt.profiles.ProfileManager) -> None: + # RHI errors are emitted multiple times so make sure we only handle them once + driver_failed = False + +- # work around pyqt loading wrong GL library +- if is_lin: +- import ctypes +- +- ctypes.CDLL("libGL.so.1", ctypes.RTLD_GLOBAL) +- + # catch opengl errors + def msgHandler(category: Any, ctx: Any, msg: Any) -> None: + if category == QtMsgType.QtDebugMsg: +-- +2.42.0 diff --git a/nixpkgs/pkgs/games/anki/patches/skip-formatting-python-code.patch b/nixpkgs/pkgs/games/anki/patches/skip-formatting-python-code.patch new file mode 100644 index 000000000000..c471c6ecb325 --- /dev/null +++ b/nixpkgs/pkgs/games/anki/patches/skip-formatting-python-code.patch @@ -0,0 +1,21 @@ +From 104572dc7ebb75061b867158ce3d4311d8cf4594 Mon Sep 17 00:00:00 2001 +From: Euan Kemp <euank@euank.com> +Date: Thu, 6 Jul 2023 10:05:15 +0900 +Subject: [PATCH] Skip formatting Python code. + +Co-authored-by: Pavel Sobolev <paveloom@riseup.net> +--- + pylib/tools/hookslib.py | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/pylib/tools/hookslib.py b/pylib/tools/hookslib.py +index 6361c633e..6b16d3ec1 100644 +--- a/pylib/tools/hookslib.py ++++ b/pylib/tools/hookslib.py +@@ -208,4 +208,3 @@ def write_file(path: str, hooks: list[Hook], prefix: str, suffix: str): + os.environ["USERPROFILE"] = os.environ["HOME"] + with open(path, "wb") as file: + file.write(code.encode("utf8")) +- subprocess.run([sys.executable, "-m", "black", "-q", path], check=True) +-- +2.42.0 |