From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Ergus Newsgroups: gmane.emacs.devel Subject: Re: Project out of sources compilation Date: Sun, 17 Mar 2024 18:47:43 +0100 Message-ID: References: <4wwljrdnra3bsloehioa46y24ozxajajmvf2elvskxxq3mhtg2.ref@pyv2z5snot6h> <4wwljrdnra3bsloehioa46y24ozxajajmvf2elvskxxq3mhtg2@pyv2z5snot6h> <87ttl5w0mr.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="22678"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Dmitry Gutov , emacs-devel@gnu.org To: Augusto Stoffel Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sun Mar 17 18:49:00 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 1rlud1-0005ip-GU for ged-emacs-devel@m.gmane-mx.org; Sun, 17 Mar 2024 18:48:59 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rluc7-000266-32; Sun, 17 Mar 2024 13:48:03 -0400 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 1rluc1-00025j-VN for emacs-devel@gnu.org; Sun, 17 Mar 2024 13:47:57 -0400 Original-Received: from sonic314-13.consmr.mail.bf2.yahoo.com ([74.6.132.123]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rlubx-0007t4-Hm for emacs-devel@gnu.org; Sun, 17 Mar 2024 13:47:57 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aol.com; s=a2048; t=1710697670; bh=tTU2rfkCpTq0ZU0dCUFuKIXwIyEg1YTjn7pO/eUr9nU=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From:Subject:Reply-To; b=e6KzANx3GKcY/J+IB1xJ+xsbBlzhqKie0vTfzdfiJeDpPrNJo9bZK8yjjfpCQdCKIefxVp3VdtFgrFup7yLx3Y/JwO3d6IFPo/NYw+7eP0u0N/RFp/L+dGpUnKiZ5mncqVKpW7o3xsmEYIngy1I+KfGxxuTBrQc2nCsQorlVPH9QPha63DYA8qK5jjX6HSlkd6Hid5iybl+okEWTzg+cOij9kEYCUh1cpyEQdj0aZh30qePXAomAWZoWBQEX/JF9Fiy0A5iM0TOaj215GdCR/PSKp7lcmzsIKqs9xKObhv9c/7InATC+fGrVfu6pKOtddbCu+lmG1LeZ35GhJb98+w== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1710697670; bh=DIkMXFWKBafCKd6eJNwoaZpvMqvEOaNdoHmfPjIGB/x=; h=X-Sonic-MF:Date:From:To:Subject:From:Subject; b=BmHsfxrD9OpMw2N92Q2RiEdLEjJ2+eFJViwojlTKDLrpCTvLsvFpNoAXyhXph9Owk0IuORyQdrBLKmhRR+9ppzuU2xmR+jdz9IkSE0jGzzrDzmP2Y2dfoeGZlQ1061o3aAtqdgNaChhF7NmIFac50tXWHyposYl2N+4Mqj02UksvvBIlhzrgjM3aDx+jfTBRl/bncH8IE3ygWGU+AXXHUAv0qrgRmBDmMNX7b7Ogh9+coUlTEzhR3C3oe1OcBi3hF3Ou2+FVCZBPXjKjfnwn8HfwRyZReJuXX6HxenpzQ8BpZiTzuyhG7CHzHqKIQUijOiSn76/N4HoYtHb26YU6nw== X-YMail-OSG: 4CHuAWYVM1ni8U8uoN5ZXUEJtzYzIvS4_Titx32NvLluhoX8UNTFtV0tNAKpqOH 7KXKvkXGHTmz0D2cN8G4kXyvFXSjbCuHeIjOZBPHyXHiejCyRzIiVCa0HLkN7Ld0zt21ecs3Y.me OUnEBCGsG1YIhxKUvC2ilVdTLWxfA6Yy_TrZM23TSwK_u882.5hE3KKOlSfyXoKdDu9d9U638GA8 Srx8aQWoIdGH.e5V5biZHVjJj_minei5dYofj2mfOaxZFwC1lNJr.ouBA29ki8cqnGEGijOzpF0Q CtxO757jOzZjiB6kOdvyCSyBfynmOXdBIBlTJXskkOT_rv1x5jBdJzGJqdMeMg9QEINQPnneDFX3 dJEjGv8SI.R9RLgcMp28M16TNbZsV2lTIrgMSnec3WIc_h6ixBOHjfVv9QPjiIe24qhJZ1gftv4o gLwwtw34bLzd_HjBqseCAhFtL01kL5tHTc7O0IrIGBzUnp3dvmbE4suZYJ0wHNBxnjx4M4tdT4T4 koEt1efUB0WDnIfUEBJGJdmFnYRxG4gvK1DyyVRyJL9i4o0AxTHdWqElOJraZ0nPNO1glIzCFnZF yEHbY4Zwl8lv0KzczDudfChZX5Yisb4b.JZFHAiIdBCztT096iiIyZfwykypx4UZ3T3Iorz4vdub QG96FX_.pVQS_G6cltHPhBy_rvdXWI9uLqIutaLLBDTv5EaIQKLYl9BmttwdTUiMdKx9Jq7C9N1g iYpdFxKPXI9SMe6EpoglBPqXVKbjmDHyz5D88YKlS8LyUuEp0U81rG5aFQC2RsgzW17c7N15CHkF s6SDZ44RqF4JDo8WXONFA6p0dAxDOI_uPA2RBieqBq X-Sonic-MF: X-Sonic-ID: c58c3950-3f9a-4027-96e9-ed9054174c4c Original-Received: from sonic.gate.mail.ne1.yahoo.com by sonic314.consmr.mail.bf2.yahoo.com with HTTP; Sun, 17 Mar 2024 17:47:50 +0000 Original-Received: by hermes--production-ir2-7bc88bfc75-7f2jw (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID 8ea401005b102f342ab478c8f398b2ce; Sun, 17 Mar 2024 17:47:46 +0000 (UTC) Content-Disposition: inline In-Reply-To: <87ttl5w0mr.fsf@gmail.com> X-Mailer: WebService/1.1.22129 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.aol Received-SPF: pass client-ip=74.6.132.123; envelope-from=spacibba@aol.com; helo=sonic314-13.consmr.mail.bf2.yahoo.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, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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:317144 Archived-At: On Sun, Mar 17, 2024 at 12:36:44PM +0100, Augusto Stoffel wrote: >On Sat, 16 Mar 2024 at 14:12, Ergus wrote: > >> 5. Project local variables (a man can dream, a man can dream) >> >> There are some situations where we want to have variables shared among a >> project. (i.e some output directory, logging option when executing, >> flags, environment variables). >> >> At the moment these options work partially by using directory >> variables. If we have the concept of a "project", maybe it is logical to >> have some sort of project scope concept, specially for projects sharing >> a common root. > >For Emacs variables, why you think dir-local variables only works >“partially”? > >As to environment variables, they are generally assumed to be global in >Emacs and it goes a bit against the grain to make them buffer-local / >project dependent. Nonetheless, there are packages for that (one is >buffer-env, which I wrote) and they work fine (at least for me). > They work for one directory, but when the project includes multiple roots (project-external-roots) the variables are somehow missing just when jumping with xref to a definition. However, we can ignore this as I mentioned before. >> For example vs-code adds a subdirectory with project variables that the >> user (but also any plugin) can refer to in the project's scope. > >Is this meant to store editor configuration or environment variables? I >guess turning VSCode configuration variables into Emacs alternatives >would be tricky. No please. No interaction-importing from other editors will be maintainable in the long path. > But if this is about env vars and the directory >organization is sensible, then one could configure buffer-env to >interoperate. This is it. The idea is to extend project.el in order to bring more project-oriented features. Lets say: The user (or project.el backend) could specify the `build` directory and the environment that needs to be set to execute the program from the build or bin directory. So with a simple modification of dir-locals.el the user may be capable to run M-x compile (or project-compile), M-x gud-gdb... or being more ambitious M-x project-generate (to call autogen.sh and ./configure or cmake depending of the project-backend) For sure we wont cover the 100% of the projects, but wuth automake and autotools we will be very close (and in the future someone could add other backends for it)