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

Support "port" package manager (for OS X) #116

Closed
wants to merge 3 commits into from

Conversation

eschnett
Copy link
Contributor

The MacPorts system for OS X uses "port" as package manager, similar to apt-get for Ubuntu. These changes add support for it to BinDeps.

Installing MacPorts is non-trivial, i.e. takes about half an hour following instructions on the MacPorts web site. Unlike HomeBrew, MacPorts also does not support installing packages into arbitrary directories. It behaves more like apt-get, except that MacPorts is not shipped with OS X by default.

I thus think that Julia should not be trying to automatically install MacPorts. Rather, BinDeps should detect whether it is available, and if so, use it. This is why support should be provided by BinDeps directly, rather than a separate package MacPorts.

@IainNZ
Copy link
Contributor

IainNZ commented Nov 14, 2014

Out of curiosity, what does port get us that Homebrew doesn't?

@eschnett
Copy link
Contributor Author

The reason I implemented this is that there is a library (hwloc) that I'm using, and which I installed via MacPorts. If BinDeps supports MacPorts, then installing hwloc is a no-op.

I tried installing it via HomeBrew first, but I couldn't find a HomeBrew recipe for hwloc. I only looked at one place, which seems to be the central HomeBrew place, but I'm unfamiliar with HomeBrew and may have missed secondary locations.

That is my other argument for MacPorts: It is older, and hence supports many more packages than HomeBrew.

@eschnett
Copy link
Contributor Author

The Travis CI failure seems to be generic and unrelated to my changes.

@jakebolewski
Copy link
Contributor

Hwloc is in the homebrew science repository Homebrew/legacy-homebrew#27949. I would support "blessing" hombrew as the solution for OS X.

@eschnett
Copy link
Contributor Author

I'm unfamiliar with how homebrew specifies package names. What would the respective provides command be for hwloc? The lines below don't work:

using Homebrew
provides(Homebrew.HB, Dict("hwloc" => libhwloc))

The error from BinDeps.debug is:

      - Homebrew Bottles hwlocError: No available formula for hwloc 
 (can't provide)

@staticfloat
Copy link
Member

If the formula is not within mainline Homebrew, the typical way to do this is to request the formula be added to Homebrew.jl (Or more specifically, to the homebrew-juliadeps tap, either place works), so that it can be bottled and made available to everyone by default. I think it would be best to provide installation of binary dependencies via only one path, so as to reduce the potential error surface and keep things as simple as possible. I've added it (staticfloat/homebrew-juliadeps@6e2cbe5) and bottled it (staticfloat/homebrew-juliadeps@f7418dd), so your Homebrew attempt above should be more successful now.

@eschnett
Copy link
Contributor Author

Even if you don't like the idea of using port -- the last of the three commits in this pull request only adds documentation to the auto-generated file "deps.jl". That may still be useful

@staticfloat
Copy link
Member

Can you rebase the first two commits out of this PR? I'm happy to merge the last one. :)

@eschnett
Copy link
Contributor Author

Done; see #117 .

@staticfloat
Copy link
Member

Cool, closing this one in favor of that one.

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

Successfully merging this pull request may close these issues.

4 participants