Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 939895 - dev-vcs/git-2.46.1 - [gcc-15] patch -p1 failed with /var/tmp/portage/dev-vcs/git-2.46.1/files/git-2.37.2-unsafe-directory.patch
Summary: dev-vcs/git-2.46.1 - [gcc-15] patch -p1 failed with /var/tmp/portage/dev-vcs/...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Robin Johnson
URL:
Whiteboard:
Keywords:
: 940362 (view as bug list)
Depends on:
Blocks:
 
Reported: 2024-09-20 10:01 UTC by Toralf Förster
Modified: 2024-09-30 05:14 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge-info.txt (emerge-info.txt,19.08 KB, text/plain)
2024-09-20 10:01 UTC, Toralf Förster
Details
dev-vcs:git-2.46.1:20240920-100018.log (dev-vcs:git-2.46.1:20240920-100018.log,4.10 KB, text/plain)
2024-09-20 10:01 UTC, Toralf Förster
Details
emerge-history.txt (emerge-history.txt,79.85 KB, text/plain)
2024-09-20 10:01 UTC, Toralf Förster
Details
environment (environment,141.25 KB, text/plain)
2024-09-20 10:01 UTC, Toralf Förster
Details
etc.clang.tar.xz (etc.clang.tar.xz,1.21 KB, application/x-xz)
2024-09-20 10:01 UTC, Toralf Förster
Details
etc.portage.tar.xz (etc.portage.tar.xz,18.68 KB, application/x-xz)
2024-09-20 10:01 UTC, Toralf Förster
Details
qlist-info.txt (qlist-info.txt,191.08 KB, text/plain)
2024-09-20 10:01 UTC, Toralf Förster
Details
temp.tar.xz (temp.tar.xz,31.53 KB, application/x-xz)
2024-09-20 10:01 UTC, Toralf Förster
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Toralf Förster gentoo-dev 2024-09-20 10:01:32 UTC
 * Applying git-2.37.2-unsafe-directory.patch ...
patching file setup.c
Hunk #1 FAILED at 1157.
1 out of 1 hunk FAILED -- saving rejects to file setup.c.rej
 [ !! ]
 * ERROR: dev-vcs/git-2.46.1::gentoo failed (prepare phase):
 *   patch -p1  failed with /var/tmp/portage/dev-vcs/git-2.46.1/files/git-2.37.2-unsafe-directory.patch
 * 
 * Call stack:

  -------------------------------------------------------------------

  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 23.0_desktop-20240918-102504

  UNMASKED:
    Please re-assign to toolchain@ if you get a test failure in C, C++, or Fortran code which makes no sense.
  /etc/portage/package.unmask/60gcc:<sys-devel/gcc-15.0.9999:15

  The attached etc.portage.tar.xz has all details.
  -------------------------------------------------------------------

gcc-config -l:
 [1] x86_64-pc-linux-gnu-10
 [2] x86_64-pc-linux-gnu-15 *
clang/llvm (if any):
clang version 19.1.0
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/lib/llvm/19/bin
Configuration file: /etc/clang/x86_64-pc-linux-gnu-clang.cfg
/usr/lib/llvm/19
19.1.0
Python 3.12.6
Available Ruby profiles:
  [1]   ruby31 (with Rubygems)
  [2]   ruby32 (with Rubygems)
  [3]   ruby33 (with Rubygems) *
Available Rust versions:
  [1]   rust-bin-1.81.0 *
The following VMs are available for generation-2:
1)	Eclipse Temurin JDK 17.0.12_p7 [openjdk-bin-17]
*)	Eclipse Temurin JDK 21.0.4_p7 [openjdk-bin-21]
3)	Eclipse Temurin JDK 8.422_p05 [openjdk-bin-8]
Available Java Virtual Machines:
  [1]   openjdk-bin-8 
  [2]   openjdk-bin-17 
  [3]   openjdk-bin-21  system-vm

The Glorious Glasgow Haskell Compilation System, version 9.2.8
php cli (if any):
go version go1.23.1 linux/amd64

  HEAD of ::gentoo
commit df7990eca11a6da1a088cf31130dd7d931f5d151
Author: Repository mirror & CI <repomirrorci@gentoo.org>
Date:   Fri Sep 20 09:19:15 2024 +0000

    2024-09-20 09:19:14 UTC

emerge -qpvO =dev-vcs/git-2.46.1
[ebuild     U ] dev-vcs/git-2.46.1 [2.46.0] USE="blksha1 curl gpg iconv nls pcre tk -cgi -cvs -doc -highlight -keyring -mediawiki -perforce -perl -safe-directory (-selinux) -subversion -test -webdav -xinetd" PYTHON_SINGLE_TARGET="python3_12 -python3_10 -python3_11 -python3_13"
Comment 1 Toralf Förster gentoo-dev 2024-09-20 10:01:33 UTC
Created attachment 903415 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2024-09-20 10:01:34 UTC
Created attachment 903416 [details]
dev-vcs:git-2.46.1:20240920-100018.log
Comment 3 Toralf Förster gentoo-dev 2024-09-20 10:01:35 UTC
Created attachment 903417 [details]
emerge-history.txt
Comment 4 Toralf Förster gentoo-dev 2024-09-20 10:01:37 UTC
Created attachment 903418 [details]
environment
Comment 5 Toralf Förster gentoo-dev 2024-09-20 10:01:37 UTC
Created attachment 903419 [details]
etc.clang.tar.xz
Comment 6 Toralf Förster gentoo-dev 2024-09-20 10:01:38 UTC
Created attachment 903420 [details]
etc.portage.tar.xz
Comment 7 Toralf Förster gentoo-dev 2024-09-20 10:01:40 UTC
Created attachment 903421 [details]
qlist-info.txt
Comment 8 Toralf Förster gentoo-dev 2024-09-20 10:01:41 UTC
Created attachment 903422 [details]
temp.tar.xz
Comment 9 Grzegorz Kulewski 2024-09-21 01:01:44 UTC
BTW. This has nothing to do with gcc-15 (or any other) and is a regression in dev-vcs/git-2.46.1 vs 2.46.0 (and only when -safe-directory is in USE).
Comment 10 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2024-09-28 09:24:19 UTC
*** Bug 940362 has been marked as a duplicate of this bug. ***
Comment 11 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2024-09-28 09:24:37 UTC
Sorry, I'd forgot about this. I'll look today.

Obviously, workaround is to just use default USE=safe-directory.
Comment 12 stefan11111 2024-09-28 09:52:36 UTC
Linking my patch here too, as instructed on irc:
https://github.com/gentoo/gentoo/pull/38802
Comment 13 Larry the Git Cow gentoo-dev 2024-09-30 05:14:22 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f989b3c750b5a59aabd83464b2177c73b0b932f3

commit f989b3c750b5a59aabd83464b2177c73b0b932f3
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2024-09-30 04:59:03 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-30 05:02:17 +0000

    dev-vcs/git: rebase USE=-safe-directory patch
    
    Closes: https://github.com/gentoo/gentoo/pull/38802
    Closes: https://bugs.gentoo.org/939895
    Signed-off-by: Sam James <sam@gentoo.org>

 dev-vcs/git/files/git-2.46.2-unsafe-directory.patch | 14 ++++++++++++++
 dev-vcs/git/git-2.46.2.ebuild                       |  2 +-
 dev-vcs/git/git-9999-r1.ebuild                      |  2 +-
 dev-vcs/git/git-9999-r2.ebuild                      |  2 +-
 dev-vcs/git/git-9999-r3.ebuild                      |  2 +-
 dev-vcs/git/git-9999.ebuild                         |  2 +-
 6 files changed, 19 insertions(+), 5 deletions(-)