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?Augustin_Ch=c3=a9neau_=28BTuin=29?= Newsgroups: gmane.emacs.devel Subject: Re: [PROPOSAL] Builder, a build system integration for Emacs Date: Tue, 23 May 2023 23:10:17 +0200 Message-ID: References: <95980ffc-86e7-ad54-4a20-539d8c6ea5d0@mailo.com> <3f68f4bc-d426-0bcc-1329-674c12b29386@mailo.com> <76e12f7c-335f-476b-ffb3-fd8e8e4ab5d0@mailo.com> <87pm6rx4ea.fsf@yahoo.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="29192"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0 To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue May 23 23:11:17 2023 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 1q1ZHp-0007Ne-Db for ged-emacs-devel@m.gmane-mx.org; Tue, 23 May 2023 23:11:17 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1q1ZH6-0004RD-Js; Tue, 23 May 2023 17:10:32 -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 1q1ZH5-0004Qo-1W for emacs-devel@gnu.org; Tue, 23 May 2023 17:10:31 -0400 Original-Received: from msg-2.mailo.com ([213.182.54.12]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q1ZH0-0006hV-PN for emacs-devel@gnu.org; Tue, 23 May 2023 17:10:30 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=mailo.com; s=mailo; t=1684876218; bh=4/RyGgdGsnlV49EFh0Hxn2OX+31wfPLiv5P0pbettL0=; h=X-EA-Auth:Message-ID:Date:MIME-Version:Subject:To:References:From: In-Reply-To:Content-Type:Content-Transfer-Encoding; b=jF6ap9IGqQY1hhgz/Wif5CUlEMy7ss1ecpgVj2+P0vGXVUHHAIBHNeUqOAGhOUL3n 9glwweC8Y5MlWaKKcTxW+bMB18CwBYCLcRgKiZ9oSVjSutLeemLG56v/YIi2DdszXz F7XImYbq0rnKHFVY2oyAV0+msNNtEe1tkG6qp0/A= Original-Received: by b221-6.in.mailobj.net [192.168.90.26] with ESMTP via ip-20.mailobj.net [213.182.54.20] Tue, 23 May 2023 23:10:18 +0200 (CEST) X-EA-Auth: 9H21t0+uopcsWZKAxcn6mdPdAw6WFaz9hzq4itqT5iCG1hZjMhWjpoLzzzQmAfca7prlIUztBPQn57T6TzOId1w5WNyt8ufz Content-Language: fr, en-US In-Reply-To: <87pm6rx4ea.fsf@yahoo.com> Received-SPF: pass client-ip=213.182.54.12; envelope-from=btuin@mailo.com; helo=msg-2.mailo.com X-Spam_score_int: -21 X-Spam_score: -2.2 X-Spam_bar: -- X-Spam_report: (-2.2 / 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, NICE_REPLY_A=-0.089, 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:306286 Archived-At: Le 23/05/2023 à 02:44, Po Lu a écrit : > "Augustin Chéneau (BTuin)" writes: > >> Oh I didn't mean a simple toggle, I meant an arbitrary command >> variant. For instance with Builder you can define a "debug2", >> "compile_arm" or any other command. > > I don't understand how this works; before you can change targets, you > need to regenerate the build system for your program by running > configure. > > Are you saying that in Builder, `configure' is an extra step, run each > time the target changes? > Yes, it is. Let's illustrate with an hypothetical workflow: you work on Emacs, and you want to easily switch between multiple configurations, say "minimal" which enable very few features to ease debugging and "regular" which enable many features, such as pgtk, json, native compilation... (and possibly many other variants, there is no limit of number). First, you execute `builder-configure' which detects the build system, finds Autotools and asks you to chose between "minimal", "regular", and others. Once you've chosen, the minibuffer is filled with the "minimal" command (for example `../configure --without-threads --without-toolkit-scroll-bars`. You press enter, the command is executed in a compile buffer. Then, you need to compile. You call `builder-compile', and you may have to chose between multiple targets, for example "default" with the value "make" and "parallel" with the value "make -jN", N being the number of cores on you processor. Once you've chosen, the same as for configure happens, the command is executed in a compilation buffer. If you want to change to the "regular" configuration target, you call `builder-configure` and select this target. Then, you call `builder-compile` to compile the project. So each time you want to change the target you call `builder-configure`. But with out of tree builds, it could be possible to create one build directory for each configuration, which would remove the need to execute the configuration step each time you want to change. It's not yet available as it is really not trivial to implement, but I'll try to find a satisfying solution.