forked from sjackman/linuxbrew-core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathace.rb
41 lines (35 loc) · 1.49 KB
/
ace.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
require "formula"
class Ace < Formula
homepage "http://www.cse.wustl.edu/~schmidt/ACE.html"
url "http://download.dre.vanderbilt.edu/previous_versions/ACE-6.2.8.tar.bz2"
sha1 "937fb405226a5aee1dd2fad9d67a3218ac830ca2"
bottle do
sha1 "adadd2939fb8f973aff0e96e97d82cf76ddb490e" => :mavericks
sha1 "f1b7a5454d4e1b0b8cc9eb8099b059532507730d" => :mountain_lion
sha1 "1b9dbe41211d0a96ee7634c2d05ab5a816029f74" => :lion
end
def install
# ACE has two methods of compilation, "traditional" and ./configure.
# The "traditional" method has consistently given better results
# for the last 5 years, so although awkward to use on OSX, we use
# it anyway.
# Figure out the names of the header and makefile for this version
# of OSX and link those files to the standard names.
name = MacOS.cat.to_s.delete "_"
ln_sf "config-macosx-#{name}.h", "ace/config.h"
ln_sf "platform_macosx_#{name}.GNU", "include/makeinclude/platform_macros.GNU"
# Set up the environment the way ACE expects during build.
ENV["ACE_ROOT"] = buildpath
ENV["DYLD_LIBRARY_PATH"] = "#{buildpath}/ace:#{buildpath}/lib"
# Done! We go ahead and build.
system "make", "-C", "ace", "-f", "GNUmakefile.ACE",
"INSTALL_PREFIX=#{prefix}",
"LDFLAGS=",
"DESTDIR=",
"INST_DIR=/ace",
"debug=0",
"shared_libs=1",
"static_libs=0",
"install"
end
end