Re: MLton Homebrew package (Mac OS X)?

Adam Chlipala <[email protected]> Fri, 1 Jan 2016 16:17:43 -0500
Newsgroups gmane.comp.lang.ml.mlton.user
Message-ID <[email protected]>
On 01/01/2016 02:19 PM, Matthew Fluet wrote:
> On Thu, Dec 31, 2015 at 6:13 PM, Adam Chlipala <[email protected]> wrote:
>> (2) The existing binary MLton package hardcodes a path to libgmp that
>> apparently is quite nonstandard.  As a result, what I'm told is a
>> standard Travis Continuous Integration script based on Homebrew fails to
>> run MLton successfully.  See this log:
>> https://travis-ci.org/urweb/urweb/jobs/99660971
> That looks like a simple packaging bug when I created the statically
> linked binary.  (Considering that no one else has ever noted the
> problem in 2+ years, it seems that the statically linked binary is not
> commonly used.)  You could simply patch the /usr/local/bin/mlton
> script to remove the '/opt/local/lib/libgmp.a' option.

OK, sounds straightforward enough!

> I think that you could easily deal with issue #2 (in the short term) 
> by updating the mlton formula 
> (https://github.com/Homebrew/homebrew-boneyard/blob/master/mlton.rb) 
> to include some post-install action that appropriately updates the 
> /usr/local/bin/mlton script.
> [...]
>
> Issue #1 is really a policy issue.  As we've noted elsewhere, we don't
> really think that building MLton with SML/NJ is a solution to the
> build-from-source issue.
>
> [...] In any case, perhaps it would suffice to install a temporary copy of
> the binary MLton package for the purposes of building the source MLton
> package?  As noted above, we can, with some post extract actions,
> handle putting the binary MLton package at any suitably obscure,
> non-canonical location, as long as it is in PATH for the source MLton
> build.

Yeah, that sounds like a good plan.  I think it needs someone 
representing the MLton community and starting a conversation with the 
Homebrew maintainers, maybe as a GitHub issue.  I would be willing to 
take the lead there, though it feels a little funny for me to do it, as 
someone who is not involved with developing MLton. What do you think 
would be the best way to proceed?

If the Homebrew folks accept a binary package as legit, for this reason 
that is very compelling in my opinion, then it would be great if the 
MLton team could also implement one of the simple fixes for the libgmp 
path, in what would become the standard package.

P.S.: Sorry for probably coming across as entitled-feeling in my 
original post.  I think a small amount of work here can have a big 
impact on how easy MLton is to use for open-source developers.

------------------------------------------------------------------------------