Le dimanche 08 décembre 2013 à 12:57 +0800, Elliot Saba a écrit :
> Hello Milan, I'm glad you're taking this up! More packages would be
> awesome.
Thank you all for the replies. There's much to say about many different
points, so I'm going to reply to a few things and file separate issues
for further debate.
> 1. Building without `git` is supported (our Ubuntu binaries are built
> on canonical's buildd servers, which don't have `git` installed, or
> even the `.git` directory available) but you have to do a little bit
> extra work. The way our ubuntu nightly packaging scripts get around
> this is to save the submodules into our source package. The git
> submodules are mostly julia-specific codes; openlibm, libuv, and
> Rmath. All three of these projects are either maintained by the Julia
> team (openlibm) or modified so heavily that standard distributions
> won't work at all with Julia (libuv, Rmath). Here is a relevant
> excerpt from my "packaging scripts" repository. That repository also
> contains a patch to get versioning information into Julia without git,
> which might work a little differently from the one in the official
> debian package. You can see where it is applied here.
>
>
> Note that I perform all this patching and such BEFORE uploading the
> source to canonical's servers for building. If you don't want to deal
> with all this patching and workarounds and such, and just want a
> "git-free snapshot" of the latest source, you can use bazaar to [pull
> from canonical's
> servers](
https://code.launchpad.net/~staticfloat/julianightlies/trunk), or I could push it to github nightly where you can pull it from git/download a tarball. I suppose we could also embed this information into tagged git releases, if that would help. (So official versions wouldn't need `git` either). If that is desirable, please open an issue and tag me.
Sure, with patches adapted from Debian (which are the same as yours
IIUC) I got everything working, but as Viral said it would be great to
have this working without patches. They make packaging more much painful
an error-prone when new releases come out.
> 2. Git submodules don't follow branches, they just point to a specific
> commit (which could be included in multiple branches in any given
> repository) which you can see via `git submodule status`:
>
>
> $ git submodule status
> 004e056e4562a8e8459b3d283f7de2f655f99a8b deps/Rmath
> (remotes/origin/HEAD)
> 0bae1555437bcb1af2df9d3f320837a2a79f6e6d deps/libuv
> (node-v0.7.6-1113-g0bae155)
> ec41733ce80d52f0ca2a2d9c6bd6b41690a418a8 deps/openlibm
> (remotes/origin/HEAD)
> 9bfbd7684be14936091e7d2f0a92fcc51996cef7 doc/juliadoc
> (remotes/origin/HEAD)
>
>
> Of course, that doesn't help you much in what you want to know. The
> libuv branch we do development on is the julia-uv0.10.13 branch,
> although that is subject to change as we develop libuv more. It's
> better to pull down the specific commit pointed to in the julia.git
> repository, then rely on branch names.
Yeah, that's what I do. I was misled by Github which said when you click
on the submodule that it's 0 commits behind/ahead of the official 0.10
branch. So no I understand how it works.
> 3. I don't believe we use the value of PREFIX anywhere at runtime on
> Linux, so no matter the value of PREFIX we should be completely
> relocatable, as long as relative path structure is maintained. In
> that case, I'm not sure why you would need DESTDIR instead of PREFIX.
> The only exception I can think of is that SYSCONFDIR is an absolute
> path, but even then we have relative-path based defaults that will
> kick in if the absolute path doesn't pan out.
>
> If I'm wrong, again, please open an issue and ping me.
Nice to hear. But see the Debian patch for why it is needed for
SYSCONFDIR. I've filed this issue:
https://github.com/JuliaLang/julia/issues/5063
> 4. In the same way that we support multiarch library paths, you can
> override JL_LIBDIR and JL_PRIVATE_LIBDIR to whatever you want. You
> should be able to move them around to anything you desire.
I'd like to avoid messing with details: PREFIX and DESTDIR should be
enough to keep things simple.
> 5. UNTRUSTED_SYSTEM_LIBM is only used on windows, because we don't
> trust the windows math libraries. This flag gets set so the build
> system knows to link against openlibm instead. Here's the motivating
> issue, and the fix that was instated. I found this using github's
> blame feature; sometimes you have to go back a few steps, but you can
> see who committed what lines in a file, which is fantastic.
>
>
> USE_LLVM_SHLIB is our attempt to link against LLVM as a shared library
> instead of statically linking it into `libjulia`. This is a rather
> fine distinction, but the reason we've typically done it statically is
> because you cannot mix and match versions of LLVM, even "minor"
> versions. (E.g. Julia built against LLVM 3.3 will not work with a
> LLVM 3.2 shared library)
Thanks, I see. Copying this in the docs could be useful.
> 6. I'm not sure what your issues with openlibm-extras is. Could you
> try explaining it again?
It's just that the distinction between openlibm and openlibm-extras is
not that clear (even after Viral's explanations ;-). The tarball in
deps/ is called openlibm, does it provide openlibm, openlibm-extras, or
both? When setting USE_SYSTEM_OPENLIBM=1, can I use the system version
for both (at the moment openlibm is not packaged for Fedora anyway).
I had a similar confusion with grisu/double-conversion. One has to read
the Makefiles to understand they double-conversion provides grisu.
> 7. I think John Myles White's suggestion of `julia` and `julia-extras`
> is a good idea, but it is ultimately your choice as porter!
I'd better keep naming consistent between distributions, and I have no
strong feelings about it. I just need to check whether in Fedora (as in
Debian IIRC) one can easily get soft dependencies (Recommends/Suggests)
be installed by default, so that if I call the package julia,
julia-extras is installed too. Else it might be confusing for users, and
most of the time you also want the recommended packages.
> If you have any further questions, please ask! I'd love to have more
> people packaging Julia, and it's in all of our best interests to make
> it as easy as possible.
Be sure I will!
Regards