X-Recipient: archive-cygwin@delorie.com
DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 8BB77393A045
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com;
	s=default; t=1594971246;
	bh=+61YQ0EFUPdUp3EtciFCkOu4IWcUc34zlkxVpQpKYQ0=;
	h=References:In-Reply-To:Date:Subject:To:List-Id:List-Unsubscribe:
	 List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc:
	 From;
	b=weZOH6xdkS+bpzy2vwCAkXJMn4CUE9G5BYdbOPwscntUxcd0ktrDt4E9VDg2hAw0U
	 KebgiU8ETKhEpRffKYH0ZRNwHewnWwczA+OrZZVRIwqJyAq9vEN/2c0ri+/Xi2H+Qg
	 ruU223kUzAPiYvAMm1ziO544tuOzSkdtft5HApkI=
X-Original-To: cygwin@cygwin.com
Delivered-To: cygwin@cygwin.com
DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org F1708382E06A
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:mime-version:references:in-reply-to:from:date
 :message-id:subject:to:cc;
 bh=okvoyImxyYpXza6tJe+dutGWrBPLFfdUyi01lJJxzsM=;
 b=TXjoj2m3OlWrc6elS5BNc9SMHpxfrP5YtgDTVQ6FjmFPggxszSlGrkYyvK5aPCcHnD
 qWe/IWpr2tgujflh5uJbVEr7XDwTdJLqLSweGTkI3q4z7JdC8NWTEG20DmQ7QJd/dPwF
 +cgxLb6Xz4+nloDTSWbbr5w60KYN+HHTg9N5c9wFnPB5rMnUB87tV7HqSuvyx5mknmvP
 9ngBJF9nz+CzRFx1gbUO/fbWSs9ykRI0WwnRQ+5dEsQUGJLxhyI7kLlywPxhSfOoN67C
 7/ieWI4EFfZ/kumorkhS26DEAt61KdZlSaZpXjmSqVrIgtmlaEgYvzqPJjTGLy6BI6hn
 whlA==
X-Gm-Message-State: AOAM5306uU3QLzKm8oiG6XhcBy4oI5s+TWFl7oGBv15rzROxJ9D7y0pz
 JWcx4vgd+GDQah0EjzmSHbm0sT9PayyCWzo3qLg=
X-Google-Smtp-Source: ABdhPJzKvBUZOF06VpXfFp7leeWHtnTu4D9F9s4Im1inQwNzd9259UrK7bDbq8CnksiRfuzZdrGa5OUnHE+H59qW+NE=
X-Received: by 2002:a02:2b0a:: with SMTP id h10mr9098654jaa.61.1594971243319; 
 Fri, 17 Jul 2020 00:34:03 -0700 (PDT)
MIME-Version: 1.0
References: <CAOTD34bQzhw6Vv+8Aeh9hZ1oNO8L_H7h1Jne0mkTWCH5vLAH1A@mail.gmail.com>
In-Reply-To: <CAOTD34bQzhw6Vv+8Aeh9hZ1oNO8L_H7h1Jne0mkTWCH5vLAH1A@mail.gmail.com>
Date: Fri, 17 Jul 2020 09:33:52 +0200
Message-ID: <CAO1jNwuDQXMT7pzkZxLnZnTa4pUnhmutMByMu_8tnhZ3DX546Q@mail.gmail.com>
Subject: Re: Cygwin's sqlite3 modifies DLL search order
To: "E. Madison Bray" <erik.m.bray@gmail.com>
X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00, DKIM_SIGNED,
 DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,
 SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on
 server2.sourceware.org
X-BeenThere: cygwin@cygwin.com
X-Mailman-Version: 2.1.29
List-Id: General Cygwin discussions and problem reports <cygwin.cygwin.com>
List-Archive: <https://cygwin.com/pipermail/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-request@cygwin.com?subject=help>
List-Subscribe: <http://cygwin.com/mailman/listinfo/cygwin>,
 <mailto:cygwin-request@cygwin.com?subject=subscribe>
From: Jan Nijtmans via Cygwin <cygwin@cygwin.com>
Reply-To: Jan Nijtmans <jan.nijtmans@gmail.com>
Cc: cygwin@cygwin.com
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Sender: "Cygwin" <cygwin-bounces@cygwin.com>

Op do 16 jul. 2020 om 18:48 schreef E. Madison Bray via Cygwin:
>
> Hi all,
>
> After some significant headache I discovered a problem introduced by
> the Cygwin patches for sqlite3.  The effect of this patch is that it
> modifies the DLL search order for all subsequent DLL loads (by
> filename instead of absolute path) in the application.

Thanks for bringing this to my attention. I'm open to suggestions how
to fix this. Yes, this code is already in for a long time. It even contains
an experimental part (the part within #ifdef _WIN32), when I was
trying to make a Win32 build of SQLite work in a Cygwin environment,
oviously a bad idea ......

Thinking about it, I have an idea how to fix it:  Currently extensions
(when using the win32 vfs) are loaded using the Win32 function
LoadLibrary().  Changing that to use dlopen() might already have
the desired effect, then this section can simply be removed
completely.

Thanks!
       Jan Nijtmans
--
Problem reports:      https://cygwin.com/problems.html
FAQ:                  https://cygwin.com/faq/
Documentation:        https://cygwin.com/docs.html
Unsubscribe info:     https://cygwin.com/ml/#unsubscribe-simple
