From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id CD4E53858CDB; Thu, 2 May 2024 10:43:01 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org CD4E53858CDB DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1714646581; bh=JxKxSqn81KnTzxmMshB9Rh9CGc6S+MKuGO3Q2ccSI/E=; h=From:To:Subject:Date:In-Reply-To:References:From; b=mdaklt/cS2M5mk2J5R5ydsqPtefmAzVYqbbFn/Oo4qhhWzTumXeN25VYS9RK2Oee0 L21xIy9uKuTr+zbcixfhe/kjlW/bRmDjp1d5sULwhtONEUifaLO46NmdGGbXI7aFg0 6lm802rN3v8NiryHljCLhlSoE/KC02C0xoAtaVxU= From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug lto/110710] LTO linker on Windows creates an invalid Makefile Date: Thu, 02 May 2024 10:43:00 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: lto X-Bugzilla-Version: 12.2.0 X-Bugzilla-Keywords: patch X-Bugzilla-Severity: normal X-Bugzilla-Who: cvs-commit at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: peter0x44 at disroot dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D110710 --- Comment #16 from GCC Commits --- The master branch has been updated by Richard Biener : https://gcc.gnu.org/g:a704554d2e798e2e1b74b9fea4baf3477180bd9d commit r15-108-ga704554d2e798e2e1b74b9fea4baf3477180bd9d Author: Peter Damianov Date: Sun Apr 28 16:16:12 2024 -0700 lto-wrapper: Truncate files using -truncate driver option [PR110710] This commit changes the Makefiles generated by lto-wrapper to no longer= use the "mv" and "touch" shell commands. These don't exist on Windows, so w= hen the Makefile attempts to call them, it results in errors like: The system cannot find the file specified. This problem only manifested when calling gcc from cmd.exe, and having = no sh.exe present on the PATH. The Windows port of GNU Make searches the P= ATH for an sh.exe, and uses it if present. I have tested this in environments with and without sh.exe on the PATH = and confirmed it works as expected. Signed-off-by: Peter Damianov PR lto/110710 * lto-wrapper.cc (run_gcc): Instead of truncating a processed ltrans input from the Makefile use the new -truncate option to accomplish the same.=