-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Recipe for homebrew #387
Comments
I believe Joshua Griffith is working on it. Is there a way to add email addresses to github Issues? |
Don't think there is. It's also rather hard to find people on GitHub knowing just their name. |
+1 I saw rumors of strict version requirements for external dependencies which will make homebrew formula tough. They don't provide versioning other than the most current that someone puts in the formula. More things like what's suggested in #369 (ie USE_SYSTEM_LLVM=1) would be awesome. |
LLVM 3.0 is a hard requirement (they generally have API changes in each version). We port to new versions of LLVM as soon as they are stable. |
https://gist.github.com/eaddd8790b6295a076b4 works. I was awaiting my Make.inc correction before pushing it anywhere. I'm out at a café right now so can't run a final test against master. I'm thinking about pointing at a stable sha, and adding home-brews HEAD support. I also haven't put any effort into making it use system versions, at the moment this is still a big fat build that takes a long time. I'm thinking I want to send some patches to alter install to install ./julia to $PREFIX/bin/julia instead of $PREFIX/share/julia/julia. Presumably this is desired? |
I see, we need to fix the way that sys.ji is loaded to move the bin files. |
I'm taking a poke at making a Julia homebrew recipe, and I'm wondering how exactly the Am I mis-interpreting |
For now, we have moved all the suitesparse support to extras, and I am hoping that we can make the build system flexible enough to not build some troublesome dependencies at all. -viral On 08-Apr-2012, at 10:53 PM, Elliot Saba wrote:
|
So does this mean there is a way to compile without SuiteSparse at all, or On Sun, Apr 8, 2012 at 8:59 PM, Viral B. Shah <
|
Can you post the error log when you set USE_SYSTEM_SUITESPARSE=1? The way it is supposed to work is that it bypasses suitesparse in the julia build, and if you try to load("extras/linalg_suitesparse.jl"), it will try to look for libsuitesparse.dylib. -viral On 09-Apr-2012, at 9:40 AM, Elliot Saba wrote:
|
I see the problem - the Makefile was modified, which is causing the issue. -viral On 09-Apr-2012, at 9:40 AM, Elliot Saba wrote:
|
Can you give me a commit to roll back to to test? Also, which makefile? Because as far as I can tell, the Makefile in |
Can you comment out lines 67-69 in external/Makefile? I wonder if that will disable the building of libsuitesparse altogether. The problem with libsuitesparse is as follows:
Immediately, we can disable suitesparse completely from the build, as I have suggested above. I can do that if it works for you - since I won't be able to test it for the next couple of days. The plan for the long run is to change julia's suitesparse build process so that USE_SYSTEM_SUITESPARSE doesn't have to look around and do stuff, and setting it to 1 will result in the whole thing being ignored. -viral On 09-Apr-2012, at 9:40 AM, Elliot Saba wrote:
|
Can brew create standalone dmg files for OS X as well? -viral On 09-Apr-2012, at 9:59 AM, Viral Shah wrote:
|
external/Makefile is handwritten. Just those 3 lines in external/Makefile to be commented out to see if they will disable building suitesparse altogether. I don't think the USE_SYSTEM_SUITESPARSE ever worked reliably before. -viral On 09-Apr-2012, at 9:53 AM, Elliot Saba wrote:
|
Two things are to be done in external/Makefile to disable suitesparse
-viral On 09-Apr-2012, at 9:53 AM, Elliot Saba wrote:
|
brew isn't really meant for creating packaged software, it installs software it to a unique prefix (so each package has its own /bin, /etc, /lib, /include etc....), and then symlinks the results into a global /bin, /include, /lib etc.... thus allowing programs to find eachother, yet maintaining an easy way to uninstall programs. So the installation process doesn't really have anything to do with standalone dmgs at all. My build process is making it past the SuiteSparse steps now, but there are a few other smaller kinks I need to eradicate. I'll report back in the morning for a tad bit more help with integrating with as many homebrew-available libraries as possible, as I think it would be nice to take advantage of the package manager as much as we can. |
I didn't know this about homebrew — no wonder it's popular. That's such a On Monday, April 9, 2012, Elliot Saba wrote:
|
Alright, I have a brew that actually compiles, which is a good first start. :) I've managed to use homebrew-supplied I'm not sure why it's looking for Additionally, I looked at the Makefile in |
Also, I should note that if fixing this |
On mac julia looks for the file with three different extensions (.dylib, .bundle and no extension at all) .bundle is just the last one to be checked, so that's what the error message is about. I would assume that fftw3 is not within Julia's runtime library search path. (BTW, the dll loading logic is in dlload.c if you want to have a look). |
Julia looks for filenames with extensions .dylib and .bundle on OS X. If it can't find it, since it tries .bundle last, that is the error you see. If you have fftw installed in a standard path, then julia ought to be able to find it. Can you verify it is built correctly and all? I don't see why it should behave any differently than any of the other libraries. sys0.ji is an intermediate step to building sys.ji. Once we have sys.ji, sys0.ji is not used at all. Yes, I may be bypassing the build in arpack-ng. This is because I could not get the arpack-ng build process to find openblas and load it, and I simply just link it in manually. I only figured out a couple of days back that I have to use install_name_tool to add @rpath to library paths to make this work. With that knowledge, I think we could now clean up the arpack-ng build process. If we can get all the dependencies working in brew, I would personally prefer to use brew myself. -viral On 10-Apr-2012, at 5:25 AM, Elliot Saba wrote:
|
Thanks loladiro! That helped a lot. I've updated the commit, and am now able to build julia with a homebrew-provided fftw. The problem was that the With all homebrew dependencies installed, the julia install itself (including arpack-ng, and doubleprecision and such) takes less than 2 minutes, an order of magnitude faster than it took previously, when compiling all dependencies every time. New formula is here; I'll see about getting this pulled into homebrew-alt soon. (This won't be accepted in homebrew proper, as julia does not yet have a stable release, but tapping the alt repo is simple for people that wish to install julia) |
I'm going through the brew right now with the homebrew people, and we've come across some strange things in the Julia build process, that I'm hoping you all can shed some light upon:
Any light you can shed on these problems? |
Yes, we do not have CPPFLAGS, since the issue has never come up. What do you use it for? Is FCFLAGS the standard thing? That is easy to change. The fdlibm stuff is bizarre. I have never seen an fdlibm error before. Perhaps s_isnan.c is not getting linked somehow? -viral On 13-Apr-2012, at 10:45 PM, Elliot Saba wrote:
|
isnan and isinf are annoying because they're often macros and weird shenanigans go into defining them. |
They are not macros in fdlibm. -viral On 14-Apr-2012, at 7:22 AM, Stefan Karpinski wrote:
|
Quoting this: http://www.gnu.org/savannah-checkouts/gnu/autoconf/manual/autoconf-2.68/html_node/Preset-Output-Variables.html
As opposed to the description of
|
That's fine, suite-sparse is eventually going to be migrated from homebrew On Tue, May 22, 2012 at 11:26 AM, Mike Nolta <
|
Ok, i've successfully built julia using homebrew. Thanks @staticfloat, this is really neat! So neat, in fact, that now i'm wondering if we could use homebrew on all platforms. How hard could it be to port to linux? |
Wow! Congrats and thanks, @staticfloat. Epic win, after a huge amount of effort. Not so sure about using homebrew everywhere... |
The Linux port idea is ongoing, but very slow progress, as nobody is really In short, the amount of work to port it to linux is non-trivial. |
But this works
|
Did you add your homebrew On Tue, May 22, 2012 at 12:26 PM, Mike Nolta <
|
@staticfloat I've successfully built julia on two different systems using your formula. Thanks! However, I ran into one hiccup on my second machine. I have a fresh install of homebrew there. The julia formula brings in all of the dependencies, but it did not warn me that I did not have gfortran installed. So openmpi was built without fortran support. I only realized I forgot to install gfortran after the build process for arpack-ng complained. The solution was to uninstall openmpi, install gfortran, and then rebuild openmpi before continuing with the rest of the dependencies for julia. |
No, and the test succeeds after adding it. However, you're supposed to be able to have multiple homebrew repositories on the same machine, which only seems like it would work if all brew commands are relative to their repo. Otherwise how do i know which julia is being called? |
@vqv: Awesome, this is exactly the kind of testing needed. I forgot to include @nolta: Whether or not your shell knows how to find a piece of software is a shell problem, not a homebrew problem. Adding That being said, I don't think having the same executable in multiple homebrew installations is really the proper use case. My guess is this is mostly for separating different classes of software (system-level software like libraries, tools that would normally install into I've never felt the need to have multiple homebrew installations on my laptop, but on, for example, a university system, where you want users to be able to install software into their own home directories, yet still maintain a "base" installation across all computers that the student's can't touch, I can see this being very useful. |
Homebrew recommends using wget as the template for new formulae. Here's wget's test function
All you have to do is replace |
That's a good change so that users don't get confused as to what the error actually is, but if |
homebrew already prints the following warning message:
|
@staticfloat I just installed
Congratulations! Now to start playing with |
@staticfloat Can you try out the new build and install now. I am sure I have lost some features that you may need. Can you review it and git it a try? It's getting into good shape now. |
Interestingly enough, I've managed to get it to build again, but I am getting some very strange errors when I try and run Julia:
|
Yeah, i'm seeing the same problem, and upgrading to llvm 3.1 doesn't fix it. |
Re-trying today, the build process dies with:
Clearly this is a problem with the OSX |
Fixed: 946ccff
|
Thanks, but I still get the same error as a few days ago:
|
Is this perhaps a DLLEXPORT issue? On Sun, Jun 3, 2012 at 1:14 PM, Elliot Saba
-viral |
I will just note that the two missing symbols are the only ones not exported by libjulia, but by the repl application |
Are you on OS X 10.6? What is different in your environment from the latest Lion and latest dev tools? |
The problem seems to be caused by homebrew calling skip_clean, ['bin'] to the julia formula. |
@nolta; that's what I was going to check next, and it looks like it works! Nicely found. Formula updated, and confirmed to pass all tests on the latest git. |
I also had the symbol not found errors when running the repl and a slight tweak to #387 (comment) fixed it for me. skip_clean ['bin'] +1 to that change. |
@staticfloat Can we reasonably close this issue - now that brew has a way to build julia, even though issues may exist? |
Sure thing. Any further discussion regarding Homebrew and Julia can happen at my homebrew-julia tap for homebrew. |
It'd be nice if there was a recipe for Homebrew (http://mxcl.github.com/homebrew/).
The text was updated successfully, but these errors were encountered: