From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Gregory Heytings Newsgroups: gmane.emacs.devel Subject: Re: [PROPOSAL] Builder, a build system integration for Emacs Date: Sat, 27 May 2023 00:25:25 +0000 Message-ID: <3a315ddd3aa7d7cda74e@heytings.org> 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> <87wn0ytefw.fsf@gmail.com> <83h6s0n95y.fsf@gnu.org> <83edn4myz4.fsf@gnu.org> <83a5xsmuc0.fsf@gnu.org> <831qj4mlg7.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; format=flowed; charset=us-ascii Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="8955"; mail-complaints-to="usenet@ciao.gmane.io" Cc: eliz@gnu.org, tomas@tuxteam.de, emacs-devel@gnu.org To: Richard Stallman Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat May 27 02:25:54 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 1q2hko-00029L-DP for ged-emacs-devel@m.gmane-mx.org; Sat, 27 May 2023 02:25:54 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1q2hkS-0000mW-Df; Fri, 26 May 2023 20:25: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 1q2hkQ-0000jO-Uf for emacs-devel@gnu.org; Fri, 26 May 2023 20:25:30 -0400 Original-Received: from heytings.org ([95.142.160.155]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q2hkO-0003il-Mv; Fri, 26 May 2023 20:25:30 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=heytings.org; s=20220101; t=1685147125; bh=hwvocAL2dWsMbETlMYza0oBRUOsu+ioxlFKWrX++vX8=; h=Date:From:To:cc:Subject:In-Reply-To:Message-ID:References:From; b=KakrL8R/bti3jMATBoeUyYlYy3qSqKqDH20kdzFNWQ+y+b+zD4NHIC75SPY9AdjFW foYIK/xPGPIsMoe5jjhkouH8gFmA4tNlWbKKXxOD3Wpu3YToPf/ef/t8I9gnbFEX3V 7d98/2phjCafvI0HCKx1gzIOx6DjU4uQkQJE2r16EuiZkZR0NNOpKxAnl7maHfMOP4 aojsQC0LXqpQJePI3+3+HePhIueUWYLBk8205rWAXhMPk4/gTvJ8BpbEpJqR6bA9Ul WPHPfXWncfm5RBavRjrbsigInEBxk1vEBU9xOIuCuYDilYm6KO1SidWSb9DBlfsCM2 ngRuoL9X1B5/g== In-Reply-To: Received-SPF: pass client-ip=95.142.160.155; envelope-from=gregory@heytings.org; helo=heytings.org 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, SPF_HELO_PASS=-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:306358 Archived-At: >> This is the misconception I pointed to in my previous post: Rust >> libraries are not dynamic libraries, they are compiled into the >> program. This eliminates all compatibility problems: you can have as >> many programs as you want on your computer, each one compiled with a >> different version of a given library. > > I have trouble understanding that. Before dynamic libraries, we used > static libraries. Each library was a .o file, made by compilation. > Rust libraries are neither dynamic (compiled separately and loaded at run time) nor static (compiled separately and linked at build time), they are always compiled together with the program. > > But how can each program have its own version of one and the same > library? Does Rust store all libraries as **source code** and recompile > each library each time that library is linked into a program? > Yes, that's how it works. For example, there are 25 versions of the "itoa" library (which does the opposite of the well-known "atoi" function), and you could have 25 different Rust programs on your computer, each one using on a different version of that library. If you build these programs yourself, you will end up, in your local CARGO_HOME directory, with a copy of the source code of the 25 versions of that library: itoa-0.1.0, ..., itoa-1.0.6.