Created
July 17, 2013 12:09
-
-
Save krismatusiak/6019989 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require File.join(File.dirname(__FILE__), 'abstract-php-extension') | |
class Php54Qrcode < AbstractPhp54Extension | |
init | |
homepage 'https://github.com/rsky/qrcode/' | |
url 'https://github.com/rsky/qrcode/archive/master.zip' | |
sha1 'dd9d61b3f4d1ab45d595564087e26fe99a3df7ce' | |
version '0.1.0' | |
depends_on 'php54' | |
def install | |
Dir.chdir "php" | |
ENV.universal_binary if build.universal? | |
safe_phpize | |
system "./configure", "--prefix=#{prefix}", phpconfig | |
system "make" | |
prefix.install "modules/qr.so" | |
write_config_file unless build.include? "without-config-file" | |
end | |
def config_file | |
super + <<-EOS.undent | |
; qrcode | |
EOS | |
end | |
def extension | |
"qr" | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment