Opened 15 months ago

Last modified 6 weeks ago

#63761 new defect

gdb: Failed to destroot gdb: no files matched glob pattern "g*"

Reported by: joelburton (Joel Burton) Owned by:
Priority: Normal Milestone:
Component: ports Version: 2.7.1
Keywords: monterey Cc: greyhare
Port: gdb

Description

Installing gdb on a new Macbook Pro M1, it fails with:

:debug:destroot Executing proc-post-org.macports.destroot-destroot-0
:error:destroot Failed to destroot gdb: no files matched glob pattern "g*"

Attachments (1)

main.log (637.9 KB) - added by joelburton (Joel Burton) 15 months ago.
main.log

Download all attachments as: .zip

Change History (13)

Changed 15 months ago by joelburton (Joel Burton)

Attachment: main.log added

main.log

comment:1 Changed 15 months ago by ryandesign (Ryan Schmidt)

Port: gdb added
Summary: gdb fails during destroot on Mac OS12 (Monterey)gdb: Failed to destroot gdb: no files matched glob pattern "g*"
Version: 2.7.1

comment:2 Changed 15 months ago by programmingkidx

I saw this error when I ran this command: sudo port install gdb +multiarch

My info:

Mac OS 11.1

M1 MacBook Air

Last edited 15 months ago by programmingkidx (previous) (diff)

comment:3 Changed 11 months ago by barracuda156

Failed for me likewise on PPC.

comment:4 Changed 10 months ago by greyhare

Cc: greyhare added

comment:5 Changed 10 months ago by greyhare

Also seeing this problem on Mac Studio.

comment:6 Changed 10 months ago by greyhare

Odd, it seems to be building for x86_64 instead of arm64. That can't end well.

comment:7 Changed 10 months ago by greyhare

Yep, for some reason a clean install of MacPorts for Monterey creates an /opt/local/etc/macports/macports.conf with

#build_arch x86_64

and I had to uninstall all packages, uncomment that line, change x86_64 to arm64, and reinstall gdb to get it to work.

comment:8 Changed 7 months ago by opoplawski (Orion Poplawski)

Well, according to the macports.conf file - the default build_arch on an M1 system should be arm64. And it does seem like most items that have been installed are that or arm64+x86_64. But gdb seems to insist on trying to install the x86_64 version for some reason.

comment:9 Changed 7 months ago by opoplawski (Orion Poplawski)

Near as I can tell, upstream gdb just doesn't support arm64-darwin yet.

comment:10 Changed 3 months ago by greyhare

Ran into this problem today after installing a patch to work around #66163 (gmp won't build on ARM Macs under Ventura, patch to use gdiff instead of Apple's new diff).

I switched my macports.conf to build_arch arm64 long ago, so that's not the problem.

Bug #66197 says gdb itself doesn't support arm64, which would explain why it builds for x86_64 and demands gmp +universal on ARM Macs.

If I had some idea where it was trying to resolve g*, I could post a list of what's actually there.

comment:11 in reply to:  10 Changed 2 months ago by jmroot (Joshua Root)

Replying to greyhare:

If I had some idea where it was trying to resolve g*, I could post a list of what's actually there.

It would be one of these: https://github.com/macports/macports-ports/blob/master/devel/gdb/Portfile#L83-L90

comment:12 Changed 6 weeks ago by diekhans (Mark Diekhans)

I am now getting this problem on M1/13.0.1..

any idea how to fix?

Note: See TracTickets for help on using tickets.