From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Daniel Semyonov Newsgroups: gmane.emacs.devel Subject: Re: Vendoring code in a (Non?)GNU ELPA package Date: Mon, 01 Jan 2024 14:07:29 +0200 Message-ID: <87v88dl0ji.fsf@dsemy.com> References: <871qb83teq.fsf@dsemy.com> <87frzl3ars.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="6094"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: No Wayman , emacs-devel@gnu.org To: Richard Stallman Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Jan 01 13:15:36 2024 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 1rKHCh-0001JU-OB for ged-emacs-devel@m.gmane-mx.org; Mon, 01 Jan 2024 13:15:35 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rKHBr-0007Mg-AC; Mon, 01 Jan 2024 07:14:43 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rKHBn-0007MB-17 for emacs-devel@gnu.org; Mon, 01 Jan 2024 07:14:40 -0500 Original-Received: from dsemy.com ([46.23.89.208]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rKHBj-0002k5-DY; Mon, 01 Jan 2024 07:14:37 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; s=dkim; bh=UhL2Zaaf+Znyj AIN0YekgOpvjKVeGCh/AhIuLvqjmXo=; h=date:references:in-reply-to: subject:cc:to:from; d=dsemy.com; b=dM1eHslsA0Rgd1kvNfwS6+rD8sXO9yZUuLl ToQx9yNGgGk3kJylHQsPF5SPi0Ma9LW90Yg26ysCF0vd9eft2d5LlZ5+G4SG3GXQmFvfAl K3mkWL0mhnWy3g25x3wGyTW9hELdBlPtYAm6E81tYs8VGASJ2O5OBOcvK0iYTawZp5pe9e bz2RxaBsWVs16dJLS88JZlor2Z0E7409cHjKOjJseYZ9w7bBDIinzfVFbIbawsbHNdF/e8 /huTTbCyvIRML/a2lfUaCKw4VltEBkutyhbfebM8Rexo4K7w9YKOcv/ttqN8VkyWAZytjK 4sGSH4SMVHOtj4lPRHz11uFeebA== Original-Received: from coldharbour.local ( [147.235.217.68]) by dsemy.com (OpenSMTPD) with ESMTPSA id bbe4cdae (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO); Mon, 1 Jan 2024 13:13:30 +0100 (CET) Original-Received: from localhost (coldharbour.local [local]) by coldharbour.local (OpenSMTPD) with ESMTPA id 0d29416f; Mon, 1 Jan 2024 12:07:29 +0000 (UTC) In-Reply-To: (Richard Stallman's message of "Sat, 30 Dec 2023 22:15:42 -0500") Received-SPF: pass client-ip=46.23.89.208; envelope-from=daniel@dsemy.com; helo=dsemy.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01, UNPARSEABLE_RELAY=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action 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-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:314415 Archived-At: >>>>> Richard Stallman writes: > Let's not adopt that term "vendoring", particularly since the GNU > Project is not a "vender". But the question is a reasonable one > to pose. I agree; I only used the term originally since it seemed to describe what I wanted to do and I saw it used online. > The answer would depend on questions such as > (1) What is the license of that library? A choice of either Unlicense (public domain) or MIT No Attribution (I'll paste the exact license text as it appears in the library at the end of this email). > (2) What on does it do? It provides a uniform API for playing or recording audio on various platforms (GNU/Linux, FreeBSD, OpenBSD, NetBSD, Windows, macOS, Android, iOS and browsers). It also includes (quoted from the website, 'miniaud.io'): "Built-in decoders, advanced mixing and effect processing, resource management, 3D spatialization, filters, data conversion and more." > (3) What is the reason for using it? My module only uses the audio playback API to play music through Emacs. I don't currently have plans to make use of other parts of the library. > (4) When running, how does it communicate with Emacs? Some functions exposed to Elisp in my module use subroutines defined in "miniaudio.h". Emacs also gets input through a pipe process (created with 'make-pipe-process') from the module, which writes to the pipe process through a file descriptor; this is required to notify Emacs when audio playback finishes. > (5) Does it get linked with Emacs? If so, when does that happen? > (6) In what sense is it a "library"? > (7) Would this be source code, executable, or both? I don't have a formal background in C so I might not understand the terminology correctly, but I think it gets linked with Emacs when my module does (when it is loaded by Emacs with 'module-load', for example). It is distributed as a single source file ("miniaudio.h") which is included by my module. "miniaudio.h" contains all the code of the miniaudio "library". I don't know if my module "links" with miniaudio technically, since all of its code is completely contained inside my module once built. > (8) How would it get built for your distro? Assuming you mean the miniaudio library itself, it seems there is an official "split" version of it which contains both "miniaudio.c" and "miniaudio.h", where the actual implementation lives inside "miniaudio.c". I think the few distros that do package it compile this version and distribute it like other C libraries. If you mean my module, then I'm not sure - I never really looked into how distros manage Emacs packages. > Some combinations of answers might make it ok, others would make > it unacceptable. Hopefully I've made things clear now, thanks for your interest. Daniel License text which appears at the end of the file "miniaudio.h": This software is available as a choice of the following licenses. Choose whichever you prefer. =============================================================================== ALTERNATIVE 1 - Public Domain (www.unlicense.org) =============================================================================== This is free and unencumbered software released into the public domain. Anyone is free to copy, modify, publish, use, compile, sell, or distribute this software, either in source code form or as a compiled binary, for any purpose, commercial or non-commercial, and by any means. In jurisdictions that recognize copyright laws, the author or authors of this software dedicate any and all copyright interest in the software to the public domain. We make this dedication for the benefit of the public at large and to the detriment of our heirs and successors. We intend this dedication to be an overt act of relinquishment in perpetuity of all present and future rights to this software under copyright law. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. For more information, please refer to =============================================================================== ALTERNATIVE 2 - MIT No Attribution =============================================================================== Copyright 2023 David Reid Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.