From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by sourceware.org (Postfix) with ESMTPS id F34133858C78 for ; Mon, 30 Oct 2023 16:17:46 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org F34133858C78 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=suse.cz Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.cz ARC-Filter: OpenARC Filter v1.0.0 sourceware.org F34133858C78 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=195.135.220.28 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1698682668; cv=none; b=HjY/haU/+HSvFJuOnDB5nj1b2GIdg/pOhhwxH1dfQry0AmFpcKTxS0kakMevaeymKRGi2F8FLXfEB1lO1inp6k0HCTVlcmATFd9/3Iv2t1kn/xr2E4M0G3x+2/45T/MCsN2ZSF02xNcJVEz6bM66yXuRbBug+mE+947YFK6kTcI= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1698682668; c=relaxed/simple; bh=jAmLlWH+hIBdvJg/xvuGfGz68/ti5iNnuPRrRhZm84s=; h=DKIM-Signature:DKIM-Signature:From:To:Subject:Date:Message-ID: MIME-Version; b=QxGRmGQn9FhKkADBwuxxYSBjyECjpdYrr187OYdjW3KJS0vYck40hsfeuyqet6icgHyJKSLMKVRPdgLJ4VVQ+SaYkvGU+UeBzc8jgd+lEKHq73390SP8tuaGK7uSaJXoOSpKDm1EsO+O2BOl+UtNcf53BstkqdTj0dm3W1UtYfw= ARC-Authentication-Results: i=1; server2.sourceware.org Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id F0BE4219DA; Mon, 30 Oct 2023 16:17:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1698682665; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=Jks0s+6bFzkBcLdfBxMHROg6qjcEXiI7xUMaYlDVGNA=; b=Gq+F8tJHVBj5tuPxIbuxyn73yZbTsRP5uVZaXuEai3EE+yic+wVGTenRTDM+dAIZzveiJu BC8vmtzxUScwlteshQeM+yudnwjcjWM9p+z3WJICy0/0e4uVbtJLcqA0qNJPRAYPROTX9P zjXl93Z3FxpBYoU8wZlLRMIObBq1Lmg= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1698682665; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=Jks0s+6bFzkBcLdfBxMHROg6qjcEXiI7xUMaYlDVGNA=; b=9bEkI1vspsQxqyOj1c2oY9YDwsvtrwBv8TSPUOiVPUFnedpiV8uPR9WewI+WTTUYjQMW5k 5uWOZodZzSbx7uBw== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id D55E3138F8; Mon, 30 Oct 2023 16:17:45 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id kbTGMynXP2WbCAAAMHmgww (envelope-from ); Mon, 30 Oct 2023 16:17:45 +0000 From: Martin Jambor To: Iain Sandoe Cc: FX Coudert , gcc-patches@gcc.gnu.org Subject: Re: Darwin: Replace environment runpath with embedded [PR88590] In-Reply-To: References: User-Agent: Notmuch/0.37 (https://notmuchmail.org) Emacs/29.1 (x86_64-suse-linux-gnu) Date: Mon, 30 Oct 2023 17:17:39 +0100 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-Spam-Status: No, score=-11.6 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,INVALID_MSGID,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Hello Iain, On Tue, Aug 15 2023, FX Coudert via Gcc-patches wrote: > [...] > From e1cf04cadb9fa065fb3f7d6bccf9ed6f1e9e3fc1 Mon Sep 17 00:00:00 2001 > From: Iain Sandoe > Date: Sun, 28 Mar 2021 14:48:17 +0100 > Subject: [PATCH 2/4] Darwin: Allow for configuring Darwin to use embedded > runpath. our buildbot checker found that after this patch, there is an uncommitted auto(re)conf generated hunk in fixincludes/configure: diff --git a/fixincludes/configure b/fixincludes/configure index b9770489adc..1bb547a1724 100755 --- a/fixincludes/configure +++ b/fixincludes/configure @@ -3027,6 +3027,7 @@ ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. # --------------------------- # _LT_COMPILER_PIC +enable_darwin_at_rpath_$1=no # _LT_LINKER_SHLIBS([TAGNAME]) # ---------------------------- @@ -3049,7 +3050,6 @@ ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. # the compiler configuration to `libtool'. # _LT_LANG_CXX_CONFIG - # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) # --------------------------------- # Figure out "hidden" library dependencies from verbose Can I commit it (with an appropriate ChangeLog message) or do you want to take care of it yourself? Thanks, Martin > > Recent Darwin versions place contraints on the use of run paths > specified in environment variables. This breaks some assumptions > in the GCC build. > > This change allows the user to configure a Darwin build to use > '@rpath/libraryname.dylib' in library names and then to add an > embedded runpath to executables (and libraries with dependents). > > The embedded runpath is added by default unless the user adds > '-nodefaultrpaths' to the link line. > > For an installed compiler, it means that any executable built with > that compiler will reference the runtimes installed with the > compiler (equivalent to hard-coding the library path into the name > of the library). > > During build-time configurations any "-B" entries will be added to > the runpath thus the newly-built libraries will be found by exes. > > Since the install name is set in libtool, that decision needs to be > available here (but might also cause dependent ones in Makefiles, > so we need to export a conditional). > > This facility is not available for Darwin 8 or earlier, however the > existing environment variable runpath does work there. > > We default this on for systems where the external DYLD_LIBRARY_PATH > does not work and off for Darwin 8 or earlier. For systems that can > use either method, if the value is unset, we use the default (which > is currently DYLD_LIBRARY_PATH). > > ---- > > Ada changes: > add paths relative to @loader-path > > JIT changes: > > This patch expects DARWIN_RPATH to be computed and available; which > means that we will use @rpath or ${libdir} as the name prefix > depending on the system version and the setting of > --enable-darwin-at-rpath. For branches that do not have this > available, the value should be set to ${libdir}. > > added m2 library changes. > > ChangeLog: > > * configure: Regenerate. > * configure.ac: Do not add default runpaths to GCC exes > when we are building -static-libstdc++/-static-libgcc (the > default). > * libtool.m4: Add 'enable-darwin-at-runpath'. Act on the > enable flag to alter Darwin libraries to use @rpath names. > > fixincludes/ChangeLog: > > * configure: Regenerate. > > gcc/ChangeLog: > > * aclocal.m4: Regenerate. > * configure: Regenerate. > * configure.ac: Handle Darwin rpaths. > * config/darwin-driver.cc: Handle Darwin rpaths. > * config/darwin.h: Handle Darwin rpaths. > * config/darwin.opt: Handle Darwin rpaths. > * Makefile.in: Handle Darwin rpaths. > > gcc/ada/ChangeLog: > > * gcc-interface/Makefile.in: Handle Darwin rpaths. > > gcc/jit/ChangeLog: > * Make-lang.in: Handle Darwin rpaths. > > libatomic/ChangeLog: > > * Makefile.am: Handle Darwin rpaths. > * Makefile.in: Regenerate. > * configure: Regenerate. > * configure.ac: Handle Darwin rpaths. > > libbacktrace/ChangeLog: > > * configure: Regenerate. > * configure.ac: Handle Darwin rpaths. > > libcc1/ChangeLog: > > * configure: Regenerate. > > libffi/ChangeLog: > > * Makefile.am: Handle Darwin rpaths. > * Makefile.in: Regenerate. > * configure: Regenerate. > > libgcc/ChangeLog: > > * config/t-slibgcc-darwin: Generate libgcc_s > with an @rpath name. > * config.host: Handle Darwin rpaths. > > libgfortran/ChangeLog: > > * Makefile.am: Handle Darwin rpaths. > * Makefile.in: Regenerate. > * configure: Regenerate. > * configure.ac: Handle Darwin rpaths > > libgm2/ChangeLog: > > * Makefile.am: Handle Darwin rpaths. > * Makefile.in: Regenerate. > * aclocal.m4: Regenerate. > * configure: Regenerate. > * configure.ac: Handle Darwin rpaths. > * libm2cor/Makefile.am: Handle Darwin rpaths. > * libm2cor/Makefile.in: Regenerate. > * libm2iso/Makefile.am: Handle Darwin rpaths. > * libm2iso/Makefile.in: Regenerate. > * libm2log/Makefile.am: Handle Darwin rpaths. > * libm2log/Makefile.in: Regenerate. > * libm2min/Makefile.am: Handle Darwin rpaths. > * libm2min/Makefile.in: Regenerate. > * libm2pim/Makefile.am: Handle Darwin rpaths. > * libm2pim/Makefile.in: Regenerate. > > libgomp/ChangeLog: > > * Makefile.am: Handle Darwin rpaths. > * Makefile.in: Regenerate. > * configure: Regenerate. > * configure.ac: Handle Darwin rpaths > > libitm/ChangeLog: > > * Makefile.am: Handle Darwin rpaths. > * Makefile.in: Regenerate. > * configure: Regenerate. > * configure.ac: Handle Darwin rpaths. > > libobjc/ChangeLog: > > * configure: Regenerate. > * configure.ac: Handle Darwin rpaths. > > libphobos/ChangeLog: > > * configure: Regenerate. > * configure.ac: Handle Darwin rpaths. > * libdruntime/Makefile.am: Handle Darwin rpaths. > * libdruntime/Makefile.in: Regenerate. > * src/Makefile.am: Handle Darwin rpaths. > * src/Makefile.in: Regenerate. > > libquadmath/ChangeLog: > > * Makefile.am: Handle Darwin rpaths. > * Makefile.in: Regenerate. > * configure: Regenerate. > * configure.ac: Handle Darwin rpaths. > > libsanitizer/ChangeLog: > > * asan/Makefile.am: Handle Darwin rpaths. > * asan/Makefile.in: Regenerate. > * configure: Regenerate. > * hwasan/Makefile.am: Handle Darwin rpaths. > * hwasan/Makefile.in: Regenerate. > * lsan/Makefile.am: Handle Darwin rpaths. > * lsan/Makefile.in: Regenerate. > * tsan/Makefile.am: Handle Darwin rpaths. > * tsan/Makefile.in: Regenerate. > * ubsan/Makefile.am: Handle Darwin rpaths. > * ubsan/Makefile.in: Regenerate. > > libssp/ChangeLog: > > * Makefile.am: Handle Darwin rpaths. > * Makefile.in: Regenerate. > * configure: Regenerate. > * configure.ac: Handle Darwin rpaths. > > libstdc++-v3/ChangeLog: > > * configure: Regenerate. > * configure.ac: Handle Darwin rpaths. > * src/Makefile.am: Handle Darwin rpaths. > * src/Makefile.in: Regenerate. > > libvtv/ChangeLog: > > * configure: Regenerate. > * configure.ac: Handle Darwin rpaths. > > lto-plugin/ChangeLog: > * configure: Regenerate. > * configure.ac: Handle Darwin rpaths. > > zlib/ChangeLog: > * configure: Regenerate. > * configure.ac: Handle Darwin rpaths.