aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula/midgard2-php.rb
diff options
context:
space:
mode:
authorAlexey Zakhlestin2011-03-21 13:32:53 +0300
committerMax Howell2011-03-21 12:11:34 +0000
commita089436aa1acda48be16a765e758276950bcf498 (patch)
tree7a462edda21ff9be6b7d09ec0af5a4172d050768 /Library/Formula/midgard2-php.rb
parent44812cebb9177220d08bae055162e199ce57f860 (diff)
downloadhomebrew-a089436aa1acda48be16a765e758276950bcf498.tar.bz2
PHP bindings for Midgard2 10.05.4 + HEAD
Diffstat (limited to 'Library/Formula/midgard2-php.rb')
-rw-r--r--Library/Formula/midgard2-php.rb30
1 files changed, 30 insertions, 0 deletions
diff --git a/Library/Formula/midgard2-php.rb b/Library/Formula/midgard2-php.rb
new file mode 100644
index 000000000..f4718cc79
--- /dev/null
+++ b/Library/Formula/midgard2-php.rb
@@ -0,0 +1,30 @@
+require 'formula'
+
+class Midgard2Php <Formula
+ url 'http://www.midgard-project.org/midcom-serveattachmentguid-025abaac43f811e0b064792d116f21f421f4/php5-midgard2-10.05.4.tar.gz'
+ head 'git://github.com/midgardproject/midgard-php5.git', :branch => 'ratatoskr'
+ homepage 'http://www.midgard-project.org/'
+ md5 'a715d76abdb6ef1bb5eb8c9973fbba16'
+
+ depends_on 'pkg-config'
+ depends_on 'midgard2'
+
+ def install
+ system "/usr/bin/phpize"
+ system "./configure", "--with-php-config=/usr/bin/php-config"
+
+ system "make"
+ prefix.install 'modules/midgard2.so'
+ end
+
+ def caveats
+ <<-END_CAVEATS
+ * Add the following line to php.ini:
+ extension="#{prefix}/midgard2.so"
+ * Restart your webserver.
+ * Write a PHP page that calls "phpinfo();"
+ * Load it in a browser and look for the info on the midgard2 module.
+ * If you see it, you have been successful!
+ END_CAVEATS
+ end
+end