Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#55980 closed defect (fixed)

uhd @3.11.0.0 fails to build on mavericks: error: thread-local storage is unsupported for the current target

Reported by: tehcog (tehcog) Owned by: michaelld (Michael Dickens)
Priority: Normal Milestone:
Component: ports Version: 2.4.2
Keywords: mavericks Cc: pinksprite
Port: uhd

Description

Mar 06 16:04:58 xxxXXXxxx --->  Computing dependencies for uhd
Mar 06 16:04:58 xxxXXXxxx --->  Fetching archive for uhd
Mar 06 16:04:58 xxxXXXxxx --->  Attempting to fetch uhd-3.11.0.0_0+docs+examples+gpsd+libusb+manpages+manual+python27+test.darwin_13.x86_64.tbz2 from https://packages.macports.org/uhd
Mar 06 16:04:59 xxxXXXxxx --->  Attempting to fetch uhd-3.11.0.0_0+docs+examples+gpsd+libusb+manpages+manual+python27+test.darwin_13.x86_64.tbz2 from http://ywg.ca.packages.macports.org/mirror/macports/packages/uhd
Mar 06 16:05:00 xxxXXXxxx --->  Attempting to fetch uhd-3.11.0.0_0+docs+examples+gpsd+libusb+manpages+manual+python27+test.darwin_13.x86_64.tbz2 from http://sea.us.packages.macports.org/macports/packages/uhd
Mar 06 16:05:00 xxxXXXxxx --->  Verifying checksums for uhd
Mar 06 16:05:00 xxxXXXxxx --->  Extracting uhd
Mar 06 16:05:01 xxxXXXxxx --->  Configuring uhd
Mar 06 16:05:07 xxxXXXxxx --->  Building uhd
Mar 06 16:05:12 xxxXXXxxx Error: Failed to build uhd: command execution failed
Mar 06 16:05:12 xxxXXXxxx Error: See /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_science_uhd/uhd/main.log for details.
Mar 06 16:05:12 xxxXXXxxx Error: Follow https://guide.macports.org/#project.tickets to report a bug.

Attachments (2)

main.log (82.6 KB) - added by tehcog (tehcog) 7 years ago.
main.log
patch-portfile-threadlocal.diff (579 bytes) - added by kencu (Ken) 7 years ago.

Download all attachments as: .zip

Change History (14)

Changed 7 years ago by tehcog (tehcog)

Attachment: main.log added

main.log

comment:1 Changed 7 years ago by pinksprite

CC Me!

comment:2 Changed 7 years ago by tehcog (tehcog)

error: thread-local storage is unsupported for the current target

comment:3 Changed 7 years ago by pinksprite

Cc: pinksprite added

comment:4 Changed 7 years ago by kencu (Ken)

only newer versions of clang support thread_local (800 or newer I think), but macports-clang-X should support it from about 3.5 onwards (not 100% certain of the floor) - certainly macports-clang-5.0+ supports it on macOS 10.7+ .

I'll check on that. I have it building now.

Last edited 7 years ago by kencu (Ken) (previous) (diff)

comment:5 Changed 7 years ago by kencu (Ken)

Cc: michaelld@… removed
Owner: set to michaelld
Status: newassigned
Summary: uhd @3.11.0.0 fails to build on mavericksuhd @3.11.0.0 fails to build on mavericks: error: thread-local storage is unsupported for the current target

comment:6 Changed 7 years ago by kencu (Ken)

blacklisting clang < 800 with compiler_blacklist_versions appears to do it. That forces mavericks to call in clang-4.0, which supports thread_local.

$ port -v installed uhd
The following ports are currently installed:
  uhd @3.11.0.0_0+docs+examples+gpsd+libusb+manpages+manual+python27+test (active) platform='darwin 13' archs='x86_64' date='2018-03-06T17:51:31-0800'

portconfigure.tcl should be updated at some point soon to fall back to clang-5.0 instead though, I think -- that's what the cxx11 1.1 portgroup calls in, so might as well be consistent.

Last edited 7 years ago by kencu (Ken) (previous) (diff)

comment:7 Changed 7 years ago by kencu (Ken)

to the original poster: To get this to build right now, you could do this:

sudo port -v -N install clang-5.0

then

sudo port -v -N install uhd configure.compiler=macports-clang-5.0

and that should do it for you, until the Portfile is updated.

comment:8 Changed 7 years ago by michaelld (Michael Dickens)

@kencu: Can you provide a patch (or do a PR)? Why recreate the wheel ;)

Changed 7 years ago by kencu (Ken)

comment:9 Changed 7 years ago by kencu (Ken)

This should do it -- works here, and looks clean to me...

comment:10 Changed 7 years ago by michaelld (Michael Dickens)

Resolution: fixed
Status: assignedclosed

In b10804aa96aac81373977be1b6d44fd5e879f0b2/macports-ports:

uhd*: require a compiler that supports thread_local storage

This requirement was introduced in 3.11.0.0.

Closes #55980

comment:11 Changed 7 years ago by michaelld (Michael Dickens)

Thanks, @kencu,. I tweaked it a little for formatting and the comment. I went ahead and closed this ticket, but if this fix doesn't work for folks please reopen and explain what's going on. Please remember that you need to "sync" or "selfupdate" to get the changes, then it would be wisest to "clean" this port before trying again.,

comment:12 Changed 7 years ago by tehcog (tehcog)

Thanks! Seems to work.

Note: See TracTickets for help on using tickets.