From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Richard Stallman Newsgroups: gmane.emacs.devel Subject: Re: master 3d38d1d: Add sqlite3 support to Emacs Date: Sat, 11 Dec 2021 22:59:53 -0500 Message-ID: References: <20211211035614.15517.53830@vcs0.savannah.gnu.org> <20211211035616.984DD20A0A@vcs0.savannah.gnu.org> <87ee6j4ty4.fsf@yahoo.com> <8735mz4o70.fsf@yahoo.com> <83k0gbr0dm.fsf@gnu.org> <87y24r33bn.fsf@yahoo.com> Reply-To: rms@gnu.org Content-Type: text/plain; charset=Utf-8 Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="13996"; mail-complaints-to="usenet@ciao.gmane.io" Cc: eliz@gnu.org, emacs-devel@gnu.org, larsi@gnus.org, stefankangas@gmail.com To: Po Lu Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sun Dec 12 05:01:36 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mwG3M-0003S6-8g for ged-emacs-devel@m.gmane-mx.org; Sun, 12 Dec 2021 05:01:36 +0100 Original-Received: from localhost ([::1]:36408 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mwG3J-0005nT-Uz for ged-emacs-devel@m.gmane-mx.org; Sat, 11 Dec 2021 23:01:33 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:54448) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mwG1h-0003bY-Rr for emacs-devel@gnu.org; Sat, 11 Dec 2021 22:59:53 -0500 Original-Received: from [2001:470:142:3::e] (port=48088 helo=fencepost.gnu.org) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mwG1h-0007X0-JS; Sat, 11 Dec 2021 22:59:53 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=Date:References:Subject:In-Reply-To:To:From: mime-version; bh=akWz0DENebPbrisxeG0St8NJ+/Ms3mChTqpb1qGTF14=; b=JcwktRHuzleq 0PgzVq5GyZ8S5oir3gFp9KxTpxbKBIPv0ZnxELB2ceYqoRXjrCeeqEUFqyR/o/ktWH/d5o4yqnyGx kX/EEmgL9Lxj6uzzOwB+rOMbXL1EfYnjZkJf85K8vRrjplNtkKPIjvMpjBD6gGsxqCxPHy27htAtH PytpgT3J138VEV7mXc8Uh6V2ThQ7be0wQi4D2HQzCwgd87oDwj51SBVqVO3Qz2yGQ/QpGmCJ2iECL kx78Ji+0hi0Ulo5Z8dNusVNAQ7DDE4pn8V4KRAazPXroaXF/+cStmcA4zwXq2FMtm5I3Z4X9XV7oN Bcdw62BdxonVWDtp+nrlrg==; Original-Received: from rms by fencepost.gnu.org with local (Exim 4.90_1) (envelope-from ) id 1mwG1h-0006A8-LM; Sat, 11 Dec 2021 22:59:53 -0500 In-Reply-To: <87y24r33bn.fsf@yahoo.com> (message from Po Lu on Sat, 11 Dec 2021 17:20:44 +0800) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:281729 Archived-At: [[[ To any NSA and FBI agents reading my email: please consider ]]] [[[ whether defending the US Constitution against all enemies, ]]] [[[ foreign or domestic, requires you to follow Snowden's example. ]]] > >> So I think we should check that the .so file passed to > >> `sqlite-load-extension' as the `module' argument contains a GPL > >> compatibility symbol before allowing SQLite to load it, similar to what > >> we do with Emacs modules. > > Would you like to prepare a patch to that effect, please? > I would be willing to, but only if someone from a higher authority says > it's necessary, It's absolutely necessary. Emacs should not be a base for nonfree extensions. and provides some details: for instance, should the > symbol be named `plugin_is_GPL_compatible', or something like > `plugin_is_free_software' (as SQLite3 is public domain instead of under > the GPL). I don't know anything technically about sqlite3, so I can't begin to think about how to implement this, and I'm not sure what your suggestions really mean. What I do know is this: the crucial question is not what name that symbol should have, but rather, Which programs need to define it? Are you proposing to modify the free plug-ins to define this symbol, and make sqlite3 itself check for it? We really should have addressed this _before_ putting sqlite3 into the Emacs repository at all. Alexandre Garreau wrote: > It should reuse what gcc does to load its plugins. GCC asks for a such > symbol to check the plugins are GPLv3-compatible. That's a good thing to do, but note that every plugin for GCC was written specifically for dynamic linking with GCC. The plugin's developers define ths symbols to be checked. If we put the same mechanism into a modified sqlite3 -- let's call it "GNUish sqlite3" -- we will need to make GNUish modified versions of the plug-ins as well. Maybe that's not a lot of work. How many free plug-ins are there? > The question here is what to do with SQLite plugins, which are specific > to SQLite and not Emacs, and are not legally required to be > GPLv3-compatible. Can we make Emacs load the plug-in, and check for the symbol, then arrange for sqlite3 to talk with it? We would need to prevent sqlite3 from loading plug-ins itself. But I think that all designs require some sort of change to sqlite3, because what it's designed to do is not acceptable as it stands. I see no way around the need to change sqlite3. Stefan Monnier wrote: > Intuitively, I think `plugin_is_GPL_compatible` is right: when sqlite is > linked with Emacs, the whole becomes GPLv3+, so in order for sqlite's > plugins to be compatible with that they too need to be compatible with > GPLv3+. I think you're right. That seems to settle the question of what name to use. But we still have to deal with how to design this code to work. -- Dr Richard Stallman (https://stallman.org) Chief GNUisance of the GNU Project (https://gnu.org) Founder, Free Software Foundation (https://fsf.org) Internet Hall-of-Famer (https://internethalloffame.org)