Skip to content
This repository
Browse code

slony 2.1.2

Closes #15285.
Closes #15201.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
  • Loading branch information...
commit 2f4799696cbc543af8ad493cc136cb4a1ce4848e 1 parent a2ea7da
authored adamv committed

Showing 1 changed file with 38 additions and 0 deletions. Show diff stats Hide diff stats

  1. 38  Library/Formula/slony.rb
38  Library/Formula/slony.rb
... ...
@@ -0,0 +1,38 @@
  1
+require 'formula'
  2
+
  3
+class PostgresqlInstalled < Requirement
  4
+  def message; <<-EOS.undent
  5
+    PostgresQL is required to install.
  6
+
  7
+    You can install this with:
  8
+      brew install postgresql
  9
+
  10
+    Or you can use an official installer from:
  11
+      http://www.postgresql.org/
  12
+    EOS
  13
+  end
  14
+  def satisfied?
  15
+    which 'pg_config'
  16
+  end
  17
+  def fatal?
  18
+    true
  19
+  end
  20
+end
  21
+
  22
+class Slony < Formula
  23
+  homepage 'http://slony.info/'
  24
+  url 'http://slony.info/downloads/2.1/source/slony1-2.1.2.tar.bz2'
  25
+  sha1 '47449fbc742a25eefdab088ab650973416bccb53'
  26
+
  27
+  depends_on PostgresqlInstalled.new
  28
+
  29
+  def install
  30
+    system "./configure", "--disable-debug",
  31
+                          "--prefix=#{prefix}"
  32
+    system "make install"
  33
+  end
  34
+
  35
+  def test
  36
+    system "slon", "-v"
  37
+  end
  38
+end

0 notes on commit 2f47996

Please sign in to comment.
Something went wrong with that request. Please try again.