Skip to content

Instantly share code, notes, and snippets.

@haad
Created July 12, 2013 18:46
Show Gist options
  • Save haad/5986781 to your computer and use it in GitHub Desktop.
Save haad/5986781 to your computer and use it in GitHub Desktop.
homebrew libssh head formula
require 'formula'
class Libssh < Formula
homepage 'http://www.libssh.org/'
url 'https://red.libssh.org/attachments/download/41/libssh-0.5.4.tar.gz'
sha1 '4a372378db8fffaf28d5c79d80b2235843aa587c'
head 'git://git.libssh.org/projects/libssh.git'
if build.head?
depends_on 'openssl'
depends_on 'lzlib'
depends_on 'libgcrypt'
end
depends_on 'cmake' => :build
option 'with-gcrypt', "Compile libssh with gcrypt"
def install
args = std_cmake_args
args << '-DWITH_GCRYPT=ON' if build.include? 'with-gcrypt'
mkdir 'build' unless build.head?
chdir 'build' do
system "cmake", "..", *args
system "make install"
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment