2017-03-12 09:36:41 +00:00
|
|
|
class Libcds < Formula
|
|
|
|
desc "C++ library of Concurrent Data Structures"
|
|
|
|
homepage "https://libcds.sourceforge.io/doc/cds-api/index.html"
|
2017-09-01 07:48:28 +00:00
|
|
|
url "https://github.com/khizmax/libcds/archive/v2.3.1.tar.gz"
|
|
|
|
sha256 "3754718beafc973fa6a7af9fbb43a4c3d031de86ab793cd439b897e2747e95bc"
|
2017-03-12 09:36:41 +00:00
|
|
|
|
2017-03-14 12:25:51 +00:00
|
|
|
bottle do
|
|
|
|
cellar :any
|
2017-09-18 23:50:12 +00:00
|
|
|
sha256 "316f5b50f424b1a2dec276d788bc1439329f38ea09c2fc75da47f4384af96efc" => :high_sierra
|
2017-09-01 07:53:07 +00:00
|
|
|
sha256 "e2835b0a3b41618da31392fc35e62556e5e1bac35248b126e830fccde5817109" => :sierra
|
|
|
|
sha256 "587c4a2874cf3484591fba7a31654486b9d76d264e02e7b5e38e81bec507df30" => :el_capitan
|
|
|
|
sha256 "3a179bcaf925ea852fe737b899ab97941c7ca11709e9afda9c97524739ee7a30" => :yosemite
|
2017-03-14 12:25:51 +00:00
|
|
|
end
|
|
|
|
|
2017-03-12 09:36:41 +00:00
|
|
|
depends_on "cmake" => :build
|
|
|
|
depends_on "boost"
|
|
|
|
if DevelopmentTools.clang_build_version < 800
|
|
|
|
depends_on "gcc"
|
|
|
|
fails_with :clang
|
|
|
|
end
|
|
|
|
|
|
|
|
def install
|
|
|
|
system "cmake", ".", *std_cmake_args
|
|
|
|
system "make", "install"
|
|
|
|
end
|
|
|
|
|
|
|
|
test do
|
|
|
|
(testpath/"test.cpp").write <<-EOS.undent
|
|
|
|
#include <cds/init.h>
|
|
|
|
int main() {
|
|
|
|
cds::Initialize();
|
|
|
|
cds::threading::Manager::attachThread();
|
|
|
|
cds::Terminate();
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
EOS
|
|
|
|
system ENV.cxx, "-o", "test", "test.cpp", "-L#{lib}64", "-lcds", "-std=c++11"
|
|
|
|
system "./test"
|
|
|
|
end
|
|
|
|
end
|