From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Lars Magne Ingebrigtsen Newsgroups: gmane.emacs.devel Subject: Recursive compilation? Date: Tue, 31 May 2011 22:44:09 +0200 Organization: Programmerer Ingebrigtsen Message-ID: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1306875293 4722 80.91.229.12 (31 May 2011 20:54:53 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 31 May 2011 20:54:53 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue May 31 22:54:49 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from [140.186.70.17] (helo=lists.gnu.org) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1QRVxf-00060d-AI for ged-emacs-devel@m.gmane.org; Tue, 31 May 2011 22:54:47 +0200 Original-Received: from localhost ([::1]:52355 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QRVxS-00034X-2N for ged-emacs-devel@m.gmane.org; Tue, 31 May 2011 16:54:34 -0400 Original-Received: from [140.186.70.92] (port=45662 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QRVng-0000ll-BE for emacs-devel@gnu.org; Tue, 31 May 2011 16:44:29 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QRVnZ-00020F-3I for emacs-devel@gnu.org; Tue, 31 May 2011 16:44:22 -0400 Original-Received: from lo.gmane.org ([80.91.229.12]:34814) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QRVnY-00020B-D1 for emacs-devel@gnu.org; Tue, 31 May 2011 16:44:20 -0400 Original-Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1QRVnX-0001K2-60 for emacs-devel@gnu.org; Tue, 31 May 2011 22:44:19 +0200 Original-Received: from cm-84.215.51.58.getinternet.no ([84.215.51.58]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 31 May 2011 22:44:19 +0200 Original-Received: from larsi by cm-84.215.51.58.getinternet.no with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 31 May 2011 22:44:19 +0200 X-Injected-Via-Gmane: http://gmane.org/ Mail-Followup-To: emacs-devel@gnu.org Original-Lines: 38 Original-X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: cm-84.215.51.58.getinternet.no Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAD1BMVEVreomswMWQNz1plKV7 n6ucONMEAAACSUlEQVQ4jU2TgXXkIAxEZeECLEwBwLoAb0QBsNB/TTcCb3K8xOvH90gjgSjbii5e lHdVvXMcZZS90wPs6XSSXEfgB8znNYEqczwYAWw3TllcoByZ87UUbv4AFAOjVyL73M3IC3SQME4t 9ik7ZQMv1Q5JDSOMAfAh1c9UjNG1a93lOJV0usxrXaqool33phR2M+NNkOPVSxmXRIonRd77VxGv UcqVj6E/leK9O33/gj7857j0JuIytPOTY9hij1RK5YSVaQr1wuaQ6DOCE0noK0VEI7Cfs48v6vSS ECx5zMwNAnhOmUqnLQR5WrKnMZpFjRKUYpOhtHqZ2mjBfj0ql0NspYTvsLyPFvWt9Eny/0p+dgY5 RmsiwYtP/lgg5YxzoV4kCCASmCJ45hw7QikA9hFhm7FwrqkmuBoWiQ/J4CsNQE4LCHEeUnd7NbsU kQNNMD1Scy4myEfK1/UohNGowbMS8ejZ/gXmXpjWO18VzZDHyzyO+Ro2nGn/Ap63ZJWyod0Ay+U8 WDWJ3zaPi0Nyvr8gTIdytXQChFOfULzNYoUbDhKga1uKnAJIuEb6eVkO1ffjCmU06Vo2u9nU8ACI TDHjAHGry3WaKw0mqThx4ibYqu9SgMlGogjZVTdPMJ/nXGEEWkdH3ZiW7J/4Jp0K4bytz0OolZgx aA5XqxwczzJrqw3Tl2kCpM5xO62YVvfqbgRx889mwNxL2KveAO525AworlbvmFRsAkzJAgWNtAlf wKmbIvM81uTTd7kHEN2/W38vs8hf8Lf+AeNIlWGVn+JZAAAAAElFTkSuQmCC Mail-Copies-To: never X-Now-Playing: Boris's _Buzz In: Scion AV Remix_: "Buzz In (Optimo Remix)" User-Agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.50 (gnu/linux) Cancel-Lock: sha1:V1HpFcDnqudmz+cQLZZiC+n4BwY= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 80.91.229.12 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 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.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:140000 Archived-At: Sometimes after doing a "bzr update", the Emacs Lisp files won't build because a new macro is needed from a .el file, but the old .elc file already exists, so it requires the .elc file, and fails compiling the .el file, and I delete all the .elc files, and then build everything. Which takes forever! So I was wondering whether it would be feasible to compile required files recursively. Basically, I envision a function like `M-x byte-compile-file-recursively' which would work just like the normal one, but would instrument `require' to call `byte-compile-file-recursively' on all files that it tries to load and that are older than their .elc counterparts. The obvious "gotcha" here is that one probably shouldn't try to (recursively) byte-compile files in directories that we don't have write access to. So if somebody has set their load-path to my directory, and I have an old .elc file there, then this function shouldn't try to compile that file, too. The other caveat is that Makefiles typically first mark all files that are to be compiled, and then compile them. This would then possibly lead to some files being compiled twice. However, that could be worked around by `byte-compile-file-recursively' not compiling a file that it's been asked to compile if the .elc file is newer than the .el file. So... I have a feeling that this won't be very difficult to implement, but it needs meddling with the C layer, since `require' is a C function. But I think it would make compiling Emacs after a "bzr update" a lot less likely to break. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog http://lars.ingebrigtsen.no/