From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?utf-8?Q?=C3=93scar_Fuentes?= Newsgroups: gmane.emacs.devel Subject: Re: MSYS2 PATH problems with native compilation Date: Tue, 07 Dec 2021 22:13:09 +0100 Message-ID: <87ee6o9l0a.fsf@telefonica.net> References: <83a6hks26v.fsf@gnu.org> <83pmqgqi6e.fsf@gnu.org> <87czmghqui.fsf@telefonica.net> <834k7rqxru.fsf@gnu.org> <87a6hebma1.fsf_-_@telefonica.net> <83lf0x248u.fsf@gnu.org> <875ys1bb9f.fsf@telefonica.net> <83mtlczh4m.fsf@gnu.org> <87ilw09z1y.fsf@telefonica.net> <83wnkgxs19.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="27408"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) To: emacs-devel@gnu.org Cancel-Lock: sha1:f4WoALkM6sFxjWLRAplbsnaGSUI= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Dec 07 22:19:00 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 1muhrX-0006rX-3m for ged-emacs-devel@m.gmane-mx.org; Tue, 07 Dec 2021 22:18:59 +0100 Original-Received: from localhost ([::1]:42220 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1muhrV-00070t-U5 for ged-emacs-devel@m.gmane-mx.org; Tue, 07 Dec 2021 16:18:57 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:46928) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1muhmB-0001jH-4a for emacs-devel@gnu.org; Tue, 07 Dec 2021 16:13:27 -0500 Original-Received: from ciao.gmane.io ([116.202.254.214]:49270) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1muhm9-0003fa-8i for emacs-devel@gnu.org; Tue, 07 Dec 2021 16:13:26 -0500 Original-Received: from list by ciao.gmane.io with local (Exim 4.92) (envelope-from ) id 1muhm4-00090s-5e for emacs-devel@gnu.org; Tue, 07 Dec 2021 22:13:20 +0100 X-Injected-Via-Gmane: http://gmane.org/ Received-SPF: pass client-ip=116.202.254.214; envelope-from=ged-emacs-devel@m.gmane-mx.org; helo=ciao.gmane.io X-Spam_score_int: -15 X-Spam_score: -1.6 X-Spam_bar: - X-Spam_report: (-1.6 / 5.0 requ) BAYES_00=-1.9, HEADER_FROM_DIFFERENT_DOMAINS=0.25, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no 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" Xref: news.gmane.io gmane.emacs.devel:281285 Archived-At: Eli Zaretskii writes: >> Duplicating executables here and there just to appease Emacs is a not >> very appealing, to say the least. > > But above you say that placing these executables in the same directory > as Emacs solves the problem, No, I didn't said that. > so you are going to duplicate them > anyway, right? Because the "normal" GCC installation doesn't > necessarily put them in the same directory, right? gcc.exe, ld.exe, as.exe etc are on the same directory as emacs.exe. This is no coincidence, is how packages are installed on MSYS2/Mingw-w64, which follows a similar approach to GNU/Linux. > And if they _are_ > installed in the same directory, then what is again the problem of > adding that single directory to the system-wide PATH? You say that adding PATH automatically from emacs is a no-no, but you are fine with forcing the user to set PATH globally (thus affecting the whole system) ?? >> > I don't know what kind of GNU/Linux installations you have in mind, >> > but I don't know about any reliable installation technique that causes >> > all the installed tools to seamlessly work together, except by either >> > modifying PATH or installing all the tools in the same common tree. >> >> Precisely, MSYS2/Mingw-w64 installs everything in the same tree. > > So why on Earth not tell your users to add that single bin/ directory > to system-wide PATH, and be done with that? I have no method for telling the users, apart from patching Emacs to show a prominent message. Anyways, a package that requires further action after installation (and changing the global environment, no less) is anything but user-friendly. >> Well, that's something for the user to care about. Our job is to provide >> an Emacs that works as installed, and right now native-comp is broken >> unless the user sets PATH globally. > > Then I suggest to tell the users to set PATH globally. That's the > correct solution, on any system, because it makes the MinGW64 programs > accessible from anywhere and by any program running on the system. The correct solution is to make native-comp work out of the box. Transiently setting PATH while generating .eln is a fix. What do you have against it?