-
-
Notifications
You must be signed in to change notification settings - Fork 11.4k
riak 1.4.0 #21186
riak 1.4.0 #21186
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,28 +4,29 @@ class Riak < Formula | |
homepage 'http://wiki.basho.com/Riak.html' | ||
|
||
if Hardware.is_64_bit? and not build.build_32_bit? | ||
url 'http://s3.amazonaws.com/downloads.basho.com/riak/1.3/1.3.1/osx/10.6/riak-1.3.1-osx-x86_64.tar.gz' | ||
version '1.3.1-x86_64' | ||
sha256 'e7b4db2273ef3fc0ba76f37468ff040d94a9bdac90ed129e226e483b19451414' | ||
url 'http://s3.amazonaws.com/downloads.basho.com/riak/1.4/1.4.0/osx/10.8/riak-1.4.0-OSX-x86_64.tar.gz' | ||
version '1.4.0-x86_64' | ||
sha256 '4830b9e00b520b8494264017bfc2ff10753fd51b9e013bafd3054e29e5be1443' | ||
else | ||
url 'http://s3.amazonaws.com/downloads.basho.com/riak/1.3/1.3.1/osx/10.6/riak-1.3.1-osx-i386.tar.gz' | ||
version '1.3.1-i386' | ||
sha256 '1169ddcbc1a613c734f3df7350b416e84c667faaae73b647d2fa696aa45bc085' | ||
ohai "There is no pre-compiled 32-bit version anymore. Go to http://docs.basho.com/riak/latest/tutorials/installation/Installing-on-Mac-OS-X/#From-Source and compile from source." | ||
end | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Need to remove the *entire* conditional (i.e don't wrap these attributes in an if statement at all); it doesn't serve any purpose unless the package provides both 32- and 64-bit versions. |
||
|
||
skip_clean 'libexec' | ||
depends_on :arch => :x86_64 | ||
|
||
option '32-bit' | ||
# patch scripts to work with homebrew symlinking | ||
def patches | ||
[ | ||
"https://gist.github.com/erbmicha/5970803/raw", # env.sh patch | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I like the other approach of just hardcoding the Homebrew path instead. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It was designed to work for all symlinking, not just homebrew. This way Basho can use it in their build process for other products. On Jul 13, 2013, at 9:50 AM, Adam Vandenberg [email protected] wrote:
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. When they accept it upstream then we won't need a patch, but in the meantime, the approach used in the other riak 1.4.0 submission has a smaller footprint. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If by "they" you mean Basho, then you are correct, but I've been told that won't be until the next release and then the formula will be updated accordingly. On Jul 13, 2013, at 12:04 PM, Adam Vandenberg [email protected] wrote:
|
||
"https://gist.github.com/erbmicha/5970790/raw", # riak patch | ||
"https://gist.github.com/erbmicha/5972538/raw", # search-cmd patch | ||
"https://gist.github.com/erbmicha/5972526/raw", # riak-admin patch | ||
"https://gist.github.com/erbmicha/5972531/raw", # riak-debug patch | ||
] | ||
end | ||
|
||
def install | ||
libexec.install Dir['*'] | ||
|
||
# The scripts don't dereference symlinks correctly. | ||
# Help them find stuff in libexec. - @adamv | ||
inreplace Dir["#{libexec}/bin/*"] do |s| | ||
s.change_make_var! "RUNNER_SCRIPT_DIR", "#{libexec}/bin" | ||
end | ||
|
||
prefix.install Dir['*'] | ||
rm Dir.glob("#{bin}/*.orig") # get rid of the patch backups before symlinking to bin | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Remove files before installing. |
||
bin.install_symlink Dir["#{libexec}/bin/*"] | ||
end | ||
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This conditional needs to be removed; it's not OK to print stuff in the DSL section of the formula, as that means it will be printed every time this formula is loaded on 32-bit systems. The
depends_on :arch => :x86_64
tells Homebrew to print an appropriate warning and disallow installing on such platforms.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed. Sending a new pull request...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you cancel this pull request so I can send a new one? It won't let me send while this is open.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can force-push back to the same branch and the current pull request will be updated.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nevermind. I didn't realize that the pull request would update with subsequent commits to the files included. Neat :)