Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

El Capitan R 3.4.0 osx binary build broken on CRAN #327

Closed
edzer opened this issue May 2, 2017 · 13 comments
Closed

El Capitan R 3.4.0 osx binary build broken on CRAN #327

edzer opened this issue May 2, 2017 · 13 comments

Comments

@edzer
Copy link
Member

edzer commented May 2, 2017

See also ropensci/rerddap#56

Seems that also rgdal binaries are there, but won't work.

@rsbivand
Copy link
Member

rsbivand commented May 2, 2017

Just notes from looking at the rgdal El Capitan binary package archive (I don't have access to OSX) - the proj-datumgrid files are missing from proj/. The rgdal.so in libs/ is only 127KB, the dSYM only 489KB, they look very small for a static build. As you wrote elsewhere, the Mavericks binary has very much larger files in libs/ (possibly too large if CFLAGS=-O2 and CXXFLAGS=.O2 not imposed to drop the -g flag). The proj-datumgrid files are present. The libs/ sizes for sf Mavericks maybe suggests a similar problem on the GDAL side. For El Capitan, rgeos/libs/ is 2.2MB for the *.so and 14MB for the dSYM, but I guess we know that it was the missing -lgeos and -lm (dropped earlier because geos-config gave the -m breaking value). For Mavericks and rgeos/libs/, *.so is 2.1MB, dSYM is 20MB. So something broke in building the GDAL libraries for El Capitan, maybe, and they just didn't make it through but appear to be there for rgdal, and sf failed because of -lgeos, but would have been stranded on GDAL like rgdal?

@edzer
Copy link
Member Author

edzer commented May 2, 2017

Yes, that was what I was thinking too.

@rsbivand
Copy link
Member

rsbivand commented May 2, 2017

Do we have any insight into Simon's build scripts?

@edzer
Copy link
Member Author

edzer commented May 3, 2017

Build command is

R CMD INSTALL --dsym --build --configure-args='--with-data-copy=yes --with-proj-data=/usr/local/share/proj' pkg

Working El Capitan binaries for OSX appeared again on CRAN, however both lack the conus etc. files; the Maverick binaries (at least for sf) contain conus.

@rsbivand
Copy link
Member

rsbivand commented May 3, 2017

Work-around is to copy the Mavericks proj/ folder over the one for El Capitan.

@s-u
Copy link

s-u commented May 3, 2017

@rsbivand the scripts are in https://svn.r-project.org/R-dev-web/trunk/QA/Simon/packages in particular mk.chk is what does build+check of a package. But as discussed in the e-mail thread the issue here was that GDAL's build process doesn't work properly for static build on macOS in latest versions so it required manual fix-ups.

@rsbivand
Copy link
Member

rsbivand commented May 3, 2017

Thanks very much, useful for future reference. Would you like me to post on the gdal-dev list to see if they might document this finding - they are at RC-1 for GDAL 2.2.0 now?

@s-u
Copy link

s-u commented May 3, 2017

I was sending the details to Edzer and I was using GDAL 2.1.3 - I'll send all the details to you so you can raise that with the GDAL team.

@s-u
Copy link

s-u commented May 3, 2017

I can confirm the the 2.2.0-RC1 has fixed the problem, so let's wait for the 2.2.0 release.

@edzer
Copy link
Member Author

edzer commented May 3, 2017

Thanks a lot for trying this out, Simon!

@rsbivand
Copy link
Member

rsbivand commented May 4, 2017

I've posted on this thread, so that what Simon established is on the record for GDAL developers. Maybe this is line 54 in 2.2.0/NEWS:

  • Sort files in static library to make the build reproducible #6520

but there is so much going on that it is hard to tell. We'll see whether they comment, or care about static builds.

@edzer
Copy link
Member Author

edzer commented May 8, 2017

For the record, Simon compiles gdal on max osx with

configure --with-pic --disable-shared --enable-static --with-static-proj4=/usr/local/lib/libproj.a --with-liblzma 

@edzer
Copy link
Member Author

edzer commented May 16, 2017

Issue resolved with release 0.4-3.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants