From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: Why does Emacs's source tar archive contain *.elc files? Date: Wed, 17 Jul 2024 16:16:34 +0300 Message-ID: <86a5iggnv1.fsf@gnu.org> References: <141f27f6-9e8e-49dc-a0f3-ecbf882f2f14@kmaksim.dev> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="19958"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Maksim Kislyakov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Wed Jul 17 15:18:04 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 1sU4Xj-0004yB-OS for ged-emacs-devel@m.gmane-mx.org; Wed, 17 Jul 2024 15:18:03 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sU4Wp-00025K-9Z; Wed, 17 Jul 2024 09:17:07 -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 1sU4Wm-00024W-Dk for emacs-devel@gnu.org; Wed, 17 Jul 2024 09:17:05 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sU4Wk-0005BY-SD; Wed, 17 Jul 2024 09:17:03 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=vNGF/is0se4zOcKhVrnA3aMEQUglqVnYVY9ZMjR0/cI=; b=chxJonYYCUDwiDm7X9FF NdRdIlwwNGofykO3P900ZiXHZcyQYyxKKagESFh7sUEV84WdO5CpnLbhtzh3/xNVWNq69QCWUPetc Nh3QF0BBK2VdojAFCPli63jdU6Dl9TWRuAuE7FEXSF4J3GRN1lR77zjLpgr8gA9LncWfVn7U2SJD4 zKXn3Vioowk5Z6KEzbcQ2LxIIHNaStSbXdQcl9vymh8fYkRadIuaggVCCiKGI4MElWbvZd6AMGoJj C3TsX6irtbBzx7wiSzuJyuayJ4W094Ja5osJCt9aFkZN0SYx0kQfCS5u7yaJtMSnH9WVHMhPVJEej qbyVpJMwB/DXKg==; In-Reply-To: <141f27f6-9e8e-49dc-a0f3-ecbf882f2f14@kmaksim.dev> (message from Maksim Kislyakov on Wed, 17 Jul 2024 15:45:48 +0300) 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:321750 Archived-At: > Date: Wed, 17 Jul 2024 15:45:48 +0300 > From: Maksim Kislyakov > >  I was playing around compiling Emacs from sources. At some point, I > have found out that '*.tar' files with Emacs sources contain '*.elc' files. > > As far as I understand, 'elc' is byte-compiled version of 'el' file. Yes. > - Why does the tar archive contain compiled sources? That seems strange. > Source code archive (which you use to compile program) contains compiled > code. For the same reason the tarball includes other generated files: Info manuals, the configure script, the few generated *.el files, the configure script, etc.: it makes the build faster and requires fewer development tools to be installed on the user's machine. The actual line between the files that are provided in the release tarballs and those which don't is NOT whether they are "compiled" in some sense, but rather whether they are architecture-dependent or not. The results of compiling *.c files are architecture-dependent, and likewise the *.eln files produced by native compilation of Lisp code. So we don't include those architecture-dependent files in the source tarballs. > - Also, what will happen if I apply some patch before compiling Emacs? > 'el' file's modification time will be newer that corresponding 'elc' > file's modification time. If you modify some of the *.el files, then the "make" command will recompile them and produce updated *.elc files. Similarly with the *texi source files of the Info manuals, and other generated files which come with the tarball.