aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula/libgarmin.rb
diff options
context:
space:
mode:
authorAdam Vandenberg2010-04-06 22:58:35 -0700
committerAdam Vandenberg2010-08-07 18:08:53 -0700
commitd0efd9ee94a55e243f3b10e903526274fc21d569 (patch)
treeb21984390a0292957a3819df57c62bac558d284d /Library/Formula/libgarmin.rb
parentcdf768bc328f01e64e9f74551ff4b40d5cf0da70 (diff)
downloadhomebrew-d0efd9ee94a55e243f3b10e903526274fc21d569.tar.bz2
Update formulae for version 0.7
* Use new "url" features * Use keg_only DSL * Use "skip_clean :all" DSL * Whitespace and style cleanups * Make bash invocations less silly * Use new man2-man8 helpers * Remove "FileUtils." since it is included in Formula * Use real names for deps instead of aliases * ENV.x11 now updates path, so remove that from individual brews
Diffstat (limited to 'Library/Formula/libgarmin.rb')
-rw-r--r--Library/Formula/libgarmin.rb17
1 files changed, 7 insertions, 10 deletions
diff --git a/Library/Formula/libgarmin.rb b/Library/Formula/libgarmin.rb
index fc6eda401..e366f7110 100644
--- a/Library/Formula/libgarmin.rb
+++ b/Library/Formula/libgarmin.rb
@@ -4,6 +4,10 @@ class Libgarmin <Formula
head 'http://libgarmin.svn.sourceforge.net/svnroot/libgarmin/libgarmin/dev/'
homepage 'http://libgarmin.sourceforge.net/'
+ def rewrite_version
+ File.open("version.h","w") { |f| f.puts "#define LIBVERSION \"libgarmin 0.1\"" }
+ end
+
def install
system "./autosh.sh" unless File.exist? "configure"
system "./configure", "--prefix=#{prefix}"
@@ -16,17 +20,10 @@ class Libgarmin <Formula
s.change_make_var! "BUILT_SOURCES", ""
end
- File.open("version.h","w") do |f|
- f.puts "#define LIBVERSION \"libgarmin 0.1\""
- end
-
- system "make"
-
# Yep, need to recreate before make and make install
- File.open("version.h","w") do |f|
- f.puts "#define LIBVERSION \"libgarmin 0.1\""
- end
-
+ rewrite_version
+ system "make"
+ rewrite_version
system "make install"
end
end