meas_algorithms cannot be built with XCode 7.2.1

XMLWordPrintable

Details

• Type: Story
• Status: Done
• Resolution: Done
• Fix Version/s: None
• Component/s:
• Labels:
• Story Points:
0
• Team:

Description

The LSST stack fails to build on OS X 10.10 "Yosemite" using XCode 7.2.1, the last version that is compatible with that operating system. I have attached a build log from Michael Wood-Vasey.

Serge Monkewitz suggests trying the following (HipChat UW DM room, 2016-05-12 18:12 Pacific): in BinnedWcs.h change:

 virtual PTR(afw::image::Wcs) clone() const {  return PTR(afw::image::Wcs)(new BinnedWcs(_parent, _xBin, _yBin, _xy0)); } 

to:

 virtual PTR(afw::image::Wcs) clone() const {  return PTR(afw::image::Wcs)(std::make_shared(_parent, _xBin, _yBin, _xy0)); } 

with the following explanation (HipChat SQuaRE room 2016-05-12 18:26 Pacific):

enable_shared_from_this usually holds a weak_ptr to this internally, and the first shared_ptr to manage an instance is assigned to the internal weak_ref. It looks to me like this particular version of the STL only allows std::shared_ptr<A> to be assigned to a weak_ptr<B> if A is implicitly convertible to B. In this case the first shared_ptr to manage the BinnedWcs is a shared_ptr<Wcs>, and I think a static cast is required to get from Wcs * to BinnedWcs *, so the compiler barfs.

Activity

Hide
Michael Wood-Vasey added a comment -

I confirm. I was similarly able to
rebuild -r tickets/DM-6084 lsst_apps

Show
Michael Wood-Vasey added a comment - I confirm. I was similarly able to rebuild -r tickets/ DM-6084 lsst_apps
Hide
David Reiss added a comment -

lsst_sims built successfully as well.

Show
David Reiss added a comment - lsst_sims built successfully as well.
Hide
Tim Jenness added a comment -

Great. Sounds like this can be merged. Can someone take ownership of this ticket and merge it please?

Show
Tim Jenness added a comment - Great. Sounds like this can be merged. Can someone take ownership of this ticket and merge it please?
Hide
Michael Wood-Vasey added a comment -

lsst_sims failed for me on mpi4py, but that should be tracked on a different ticket (which I'll create later this evening).

I agree that this present ticket, DM-6084 should be merged.

Show
Michael Wood-Vasey added a comment - lsst_sims failed for me on mpi4py , but that should be tracked on a different ticket (which I'll create later this evening). I agree that this present ticket, DM-6084 should be merged.
Hide
Russell Owen added a comment -

Merged to master. Many thanks to Serge Monkewitz for diagnosing the problem and providing the fix. Also thanks to David Reiss and Michael Wood-Vasey for testing the fix.

Show
Russell Owen added a comment - Merged to master. Many thanks to Serge Monkewitz for diagnosing the problem and providing the fix. Also thanks to David Reiss and Michael Wood-Vasey for testing the fix.

People

• Assignee:
Russell Owen
Reporter:
Russell Owen
Watchers:
David Reiss, Jim Bosch, Michael Wood-Vasey, Pim Schellart [X] (Inactive), Russell Owen, Serge Monkewitz, Tim Jenness