From 6870fa89e8ac3899c1d1acdf28ca52694fa2a58d Mon Sep 17 00:00:00 2001 From: eldritch horrors Date: Sun, 19 Jan 2025 16:40:26 +0100 Subject: [PATCH] Revert "Call SetDllDirectory("") after sqlite3 init on cygwin" This reverts commit 596b0e0a045eb953b5ed3328d5ae8eb636e31373. cygwin dropped the patch that necessitated this hack with 3.34, which is still the current version of sqlite in cygwin. that was in 2020, i.e. we absolutely should not have to keep this around (especially since it will silently corrupt the library search path of things linking to libstore!) Change-Id: I251508b36f26c30533996e8d286aa8e5373eff31 --- lix/libstore/local-store.cc | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/lix/libstore/local-store.cc b/lix/libstore/local-store.cc index 9f2828920..e3fc07538 100644 --- a/lix/libstore/local-store.cc +++ b/lix/libstore/local-store.cc @@ -38,10 +38,6 @@ #include #endif -#ifdef __CYGWIN__ -#include -#endif - #include @@ -510,16 +506,6 @@ void LocalStore::openDB(State & state, bool create) : SQLiteOpenMode::NoCreate; state.db = SQLite(dbPath, openMode); -#ifdef __CYGWIN__ - /* The cygwin version of sqlite3 has a patch which calls - SetDllDirectory("/usr/bin") on init. It was intended to fix extension - loading, which we don't use, and the effect of SetDllDirectory is - inherited by child processes, and causes libraries to be loaded from - /usr/bin instead of $PATH. This breaks quite a few things (e.g. - checkPhase on openssh), so we set it back to default behaviour. */ - SetDllDirectoryW(L""); -#endif - /* !!! check whether sqlite has been built with foreign key support */