Homebrew/homebrew-science — pull request #135 by durka (2013-04-11 22:47:52+00:00)
Title: New formula: torch7

At long last, here is my refreshed formula for Torch7 (actually the latest version this time).

**This PR is not ready for merging** because of two issues.
The nonblocking issue is:
Torch7 requires GCC >= 4.6. I don't know what the canonical way to express this is, in the formula (there was a mailing list thread, but it fizzled with no real solution). The hackish solution I chose is to depend on versions/gcc48 (which didn't install -- I have two PRs pending on homebrew-versions to fix that), and manipulate ENV['CC'], ENV['CXX'] in the formula. Advice welcome.

The blocking issue is:
Officially there is no stable version. The installation instructions say "install from source". So maybe the formula should be head-only. Of course, brew-audit complains about this. There are tags in the git repository, so I put in the latest tag (7.0.3-0) as the stable version. However, 7.0.3-0 uses Lua 5.1.4, so the formula would need to `conflicts_with 'lua'` (same issue as with the Torch5 PR).
But, since tagging 7.0.3-0 they have switched to LuaJIT 2.0.0 and they rename the binary, so there are no conflicts when installing with --HEAD.
So I am not sure what to do. Should the formula be head-only, or conflict_with lua, or is it possible to make conflicts_with conditional on --HEAD?