Update formulae to use path shortcuts

This commit is contained in:
Adam Vandenberg 2010-08-08 10:20:15 -07:00
parent bf4ab26f7e
commit 55b98a9421
15 changed files with 28 additions and 36 deletions

View file

@ -10,12 +10,12 @@ class Binutils <Formula
end
def install
ENV.append 'CPPFLAGS', "-I#{prefix}/include"
ENV.append 'CPPFLAGS', "-I#{include}"
args = ["--prefix=#{prefix}",
"--disable-debug",
"--disable-dependency-tracking",
"--infodir=#{prefix}/share/info",
"--infodir=#{info}",
"--mandir=#{man}",
"--disable-werror" ]
args << "--program-prefix=g" unless ARGV.include? '--default-names'

View file

@ -12,7 +12,7 @@ class Calcurse <Formula
end
def install
ENV.append 'CFLAGS', "-I#{prefix}/include -fnested-functions"
ENV.append 'CFLAGS', "-I#{include} -fnested-functions"
ENV.append 'LDFLAGS', "-lintl"
ENV.O3
system "./configure", "--disable-dependency-tracking",

View file

@ -28,7 +28,7 @@ You can enable couchdb-lucene to automatically load on login with:
sudo launchctl load -w /Library/LaunchDaemons/couchdb-lucene.plist
Or start it manually with:
#{prefix}/bin/run
#{bin}/run
EOS
end
@ -63,7 +63,7 @@ EOS
</dict>
<key>ProgramArguments</key>
<array>
<string>#{prefix}/bin/run</string>
<string>#{bin}/run</string>
</array>
<key>UserName</key>
<string>#{`whoami`.chomp}</string>

View file

@ -21,7 +21,6 @@ class DBus <Formula
system "make install"
# Generate D-Bus's UUID for this machine
system "#{prefix}/bin/dbus-uuidgen",
"--ensure=#{prefix}/var/lib/dbus/machine-id"
system "#{bin}/dbus-uuidgen", "--ensure=#{prefix}/var/lib/dbus/machine-id"
end
end

View file

@ -26,11 +26,11 @@ class Dmd <Formula
(prefix+'src/dmd').rmtree # we don't need the dmd sources thanks
man5.install man1+'dmd.conf.5' # oops
(prefix+'share/d/examples').install Dir['samples/d/*.d']
(share+'d/examples').install Dir['samples/d/*.d']
(prefix+'bin/dmd.conf').open('w') do |f|
(bin+'dmd.conf').open('w') do |f|
f.puts "[Environment]"
f.puts "DFLAGS=-I#{prefix}/src/phobos -L-L#{prefix}/lib"
f.puts "DFLAGS=-I#{prefix}/src/phobos -L#{lib}"
end
end
end

View file

@ -33,7 +33,7 @@ class EttercapNg < Formula
system "./configure", "--disable-debug", "--disable-dependency-tracking",
"--prefix=#{prefix}",
"--mandir=#{man}",
"--infodir=#{prefix}/share/info",
"--infodir=#{info}",
"--disable-gtk",
"--disable-plugins",
"--with-openssl=/usr",

View file

@ -22,7 +22,7 @@ class Falcon <Formula
depends_on 'pcre'
def install
cmake_opts = "-DCMAKE_INSTALL_NAME_DIR=#{prefix}/lib"
cmake_opts = "-DCMAKE_INSTALL_NAME_DIR=#{lib}"
ENV.append "EXTRA_CMAKE", cmake_opts
system "./build.sh", "-p", "#{prefix}", "-int", "-el"
system "./build.sh", "-i"

View file

@ -27,9 +27,7 @@ class Fftw <Formula
# double precision
# enable-sse2 only works with double precision (default)
system "./configure", "--enable-sse2",
*args
system "./configure", "--enable-sse2", *args
system "make install"
# clean up so we can compile the long-double precision variant
@ -37,12 +35,10 @@ class Fftw <Formula
# long-double precision
# no SIMD optimization available
system "./configure", "--enable-long-double",
*args
system "./configure", "--enable-long-double", *args
system "make install"
#wtf file?
(prefix+'share/info/dir').unlink
(info+'dir').unlink
end
end

View file

@ -46,7 +46,7 @@ class Ghostscript <Formula
GhostscriptFonts.new.brew do
Dir.chdir '..'
(prefix+'share/ghostscript').install 'fonts'
(share+'ghostscript').install 'fonts'
end
(man+'de').rmtree

View file

@ -58,6 +58,6 @@ class Glib <Formula
"Cflags: -I${includedir}/glib-2.0 -I${libdir}/glib-2.0/include -I#{gettext.include}"
end
(prefix+'share/gtk-doc').rmtree
(share+'gtk-doc').rmtree
end
end

View file

@ -6,21 +6,19 @@ class Htop <Formula
def install
system "./autogen.sh"
system "./configure", "--prefix=#{prefix}", "--disable-debug", "--disable-dependency-tracking"
system "./configure", "--disable-debug", "--disable-dependency-tracking",
"--prefix=#{prefix}"
system "make", "install", "DEFAULT_INCLUDES='-iquote .'"
rm_rf "#{share}/applications" # Don't need Gnome support on OS X
rm_rf "#{share}/pixmaps"
end
def caveats; <<-EOS
In order for htop to display correctly all the running processes, it needs to be ran as root.
However, if you do not want to type `sudo htop` every time, you can change the owner and permissions for the executable binary:
$ cd #{prefix}/bin/
$ chmod 6555 htop
$ sudo chown root htop
For htop to display correctly all running processes, it needs to run as root.
If you don't want to `sudo htop` every time, change the owner and permissions:
$ cd #{bin}
$ chmod 6555 htop
$ sudo chown root htop
EOS
end
end

View file

@ -6,7 +6,7 @@ class JsdocToolkit <Formula
sha1 'd8c3977cee202c06a9d6a85b2b9b068d21309fad'
def install
system "/bin/echo '#!/bin/ksh\nJSDOCDIR=\"#{prefix}/libexec/jsdoc-toolkit\"' > jsdoc"
system "/bin/echo '#!/bin/ksh\nJSDOCDIR=\"#{libexec}/jsdoc-toolkit\"' > jsdoc"
system "/usr/bin/grep -v \"^echo \\$CMD$\" jsdoc-toolkit/jsrun.sh >> jsdoc"
bin.install 'jsdoc'

View file

@ -10,8 +10,8 @@ class Metalua <Formula
def install
Dir.chdir "src"
ENV["INSTALL_BIN"] = "#{prefix}/bin"
ENV["INSTALL_LIB"] = "#{prefix}/lib"
ENV["INSTALL_BIN"] = bin
ENV["INSTALL_LIB"] = lib
system "./make.sh"
system "./make-install.sh"

View file

@ -80,7 +80,7 @@ class Mysql <Formula
plist with a version specific program argument.
Or start manually with:
#{prefix}/share/mysql/mysql.server start
mysql.server start
EOS
end

View file

@ -10,10 +10,9 @@ class UtCache <Formula
def install
system "curl -o getdelim.c http://gist.github.com/raw/278167/26eae93b355d443693c1e8922a328d4a61b4a176/getdelim.c"
bin.mkpath
ENV['HOME'] = prefix
system "make"
system "mkdir #{prefix}/bin"
system "make install"
end
end