From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Alan Third Newsgroups: gmane.emacs.bugs Subject: bug#45934: native-comp - Dylib ID of ELN files not optimal Date: Sat, 7 Aug 2021 14:11:24 +0100 Message-ID: References: <87eeb9hf63.fsf@gnus.org> <87im0ki2lq.fsf@gnus.org> <877dgyc0fw.fsf@gnus.org> <87mtpt8tus.fsf@gnus.org> <87im0h8tmo.fsf@gnus.org> <877dgx8sch.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="9141"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Davide Restivo , 45934@debbugs.gnu.org, xgutter@yahoo.it, Andrea Corallo To: Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Aug 07 15:12:26 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1mCM7m-0002DM-Nr for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 07 Aug 2021 15:12:26 +0200 Original-Received: from localhost ([::1]:47628 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mCM7l-0004zd-Op for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 07 Aug 2021 09:12:25 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:56848) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mCM7O-0004X7-P9 for bug-gnu-emacs@gnu.org; Sat, 07 Aug 2021 09:12:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:40620) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mCM7O-0002VG-I8 for bug-gnu-emacs@gnu.org; Sat, 07 Aug 2021 09:12:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mCM7O-0004lr-Dv for bug-gnu-emacs@gnu.org; Sat, 07 Aug 2021 09:12:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Alan Third Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 07 Aug 2021 13:12:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 45934 X-GNU-PR-Package: emacs Original-Received: via spool by 45934-submit@debbugs.gnu.org id=B45934.162834191118323 (code B ref 45934); Sat, 07 Aug 2021 13:12:02 +0000 Original-Received: (at 45934) by debbugs.gnu.org; 7 Aug 2021 13:11:51 +0000 Original-Received: from localhost ([127.0.0.1]:52166 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mCM78-0004lM-Jl for submit@debbugs.gnu.org; Sat, 07 Aug 2021 09:11:51 -0400 Original-Received: from [217.169.17.33] (port=52082 helo=breton.holly.idiocy.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mCM6z-0004kw-TG for 45934@debbugs.gnu.org; Sat, 07 Aug 2021 09:11:45 -0400 Original-Received: by breton.holly.idiocy.org (Postfix, from userid 501) id 16C7D202D4C2D4; Sat, 7 Aug 2021 14:11:24 +0100 (BST) Mail-Followup-To: Alan Third , Lars Ingebrigtsen , Davide Restivo , 45934@debbugs.gnu.org, xgutter@yahoo.it, Andrea Corallo Content-Disposition: inline In-Reply-To: <877dgx8sch.fsf@gnus.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:211378 Archived-At: On Sat, Aug 07, 2021 at 12:25:02PM +0200, Lars Ingebrigtsen wrote: > So... it had no effect? This was the patch I applied: Looks like the function only takes one string at a time, so this seems to work here: @@ -4490,6 +4490,15 @@ DEFUN ("comp--compile-ctxt-to-file", Fcomp__compile_ctxt_to_file, GCC_JIT_INT_OPTION_OPTIMIZATION_LEVEL, comp.speed < 0 ? 0 : (comp.speed > 3 ? 3 : comp.speed)); + + /* On MacOS set a unique dylib ID (Bug#45934). */ +#if defined (LIBGCCJIT_HAVE_gcc_jit_context_add_driver_option) \ + && defined (DARWIN_OS) + gcc_jit_context_add_driver_option (comp.ctxt, "-install_name"); + gcc_jit_context_add_driver_option ( + comp.ctxt, SSDATA (Ffile_name_nondirectory (filename))); +#endif + comp.d_default_idx = CALL1I (comp-data-container-idx, CALL1I (comp-ctxt-d-default, Vcomp_ctxt)); comp.d_impure_idx = -- Alan Third