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

Problems with local build instructions on Mac (and perhaps other 'nix platforms) #123

Closed
mwcraig opened this issue Mar 7, 2019 · 12 comments · Fixed by #190
Closed

Problems with local build instructions on Mac (and perhaps other 'nix platforms) #123

mwcraig opened this issue Mar 7, 2019 · 12 comments · Fixed by #190
Labels
bug Something isn't working
Milestone

Comments

@mwcraig
Copy link
Contributor

mwcraig commented Mar 7, 2019

It turns out that the instructions for doing local builds ( at least on a Mac) don't work. The steps I've gone through so far to make progress (with links to some of the relevant roadblocks) are:

Once that stuff is done, make install proceeds much farther, until it gets to building eventmachine, which uses openssl, and it can't find the headers for that:

./project.h:119:10: fatal error: 'openssl/ssl.h' file not found
#include <openssl/ssl.h>
         ^~~~~~~~~~~~~~~

That led me to this anaconda issue about building gems. I tried the monkey patch at ContinuumIO/anaconda-issues#9863 (comment) but it didn't do the trick for me.

Will continue trying for a little bit longer and report back if I get something to work.

@mwcraig
Copy link
Contributor Author

mwcraig commented Mar 7, 2019

Success, sort of....

In addition to the monkey patch I linked to above, I had to add this to CPPFLAGS in rbconfig.rb:

-I/Users/mattcraig/anaconda3/anaconda/envs/ccd-guide/include

I think there are a couple of other places I could have stuck that.

Let me know if you want me to write this up into install instructions.

@choldgraf
Copy link
Collaborator

holy moly, thanks for all of this information. @emdupre you may be interested in this too in thinking about whether we should try to use something that's less of a hassle like hugo instead of jekyll

@choldgraf
Copy link
Collaborator

another quick question for you: it seemed like the ruby gems header problem wasn't present when using Ruby installed with conda-forge...did you double-check that this is the version of ruby you're using?

@mwcraig
Copy link
Contributor Author

mwcraig commented Mar 7, 2019

I was using the version from defaults, can try with the conda-forge version in a fresh environment if you want:

~/a/a/e/c/l/r/2/x86_64-darwin14 $ conda list ruby                                                                                                                                           (ccd-guide)
# packages in environment at /Users/mattcraig/anaconda3/anaconda/envs/ccd-guide:
#
# Name                    Version                   Build  Channel
ruby                      2.5.1                h74228e1_0

@emdupre emdupre added the bug Something isn't working label Mar 8, 2019
@choldgraf
Copy link
Collaborator

@mwcraig if conda-forge doesn't work, could you try with brew since you're on a mac? We will figure this out one way or another :-)

@mwcraig
Copy link
Contributor Author

mwcraig commented Mar 10, 2019

@choldgraf -- with just a touch of modification things seem to work with the conda-forge ruby. The twist is that the compilers either need to be installed before ruby or the ruby version needs to be pinned because the version on main is a more recent version than the one on conda-forge.

So this should work:

conda install -c conda-forge clangxx_osx-64
conda install -c conda-forge ruby

OR

conda install -c conda-forge ruby=1.4.5 clangxx_osx-64

It may still be necessary to do the header thing on OSX...I'm not sure because I don't know how to undo the header installation and didn't want to risk breaking things by deleting stuff from /usr/include 😀

@emdupre
Copy link
Collaborator

emdupre commented Mar 10, 2019

Thanks for the tip, @mwcraig ! It sounds like you've gotten it all working now ?

We're starting to add Docker installation instructions in #127 to hopefully avoid some of these installation headaches. We'd really appreciate your feedback there, if you're interested !

Either way, thanks again for keeping us updated -- happy to hear it seems to be working ✨

@mwcraig
Copy link
Contributor Author

mwcraig commented Mar 11, 2019

Yep, it is all working now.

You should add installation of the conda-forge compilers to the install instructions for mac/linux because both platforms will need them.

@choldgraf
Copy link
Collaborator

@mwcraig that's a good point - would you mind opening an issue about it so that we don't lose that point? Would also love to hear your thoughts over in #83 if you've got any :-)

@choldgraf choldgraf added this to the v0.5 milestone Apr 7, 2019
@mwcraig
Copy link
Contributor Author

mwcraig commented Apr 30, 2019

To wrap this up, these steps worked for me in a clean environment on a system on which I had upgraded to mojave fairly recently (so the headers are not in the standard places); it ends being simpler than what I originally reported. The first two steps will be necessary on mac and linux. The list step should be needed only on OSX 10.14 or later:

# Line below should change for linux...
conda install clangxx_osx-64
conda install -c conda-forge ruby

# OSX 10.14+ only:
open /Library/Developer/CommandLineTools/Packages/macOS_SDK_headers_for_macOS_10.14.pkg

@mwcraig
Copy link
Contributor Author

mwcraig commented Apr 30, 2019

Can open a PR to the instructions for this Wednesday am....

@choldgraf
Copy link
Collaborator

@mwcraig please do! improvements here are most-welcome :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants