homebrew-core/Formula/snap7.rb

26 lines
978 B
Ruby
Raw Normal View History

2014-03-19 11:24:16 +00:00
class Snap7 < Formula
desc "Ethernet communication suite that works natively with Siemens S7 PLCs"
2014-03-19 11:24:16 +00:00
homepage "http://snap7.sourceforge.net/"
url "https://downloads.sourceforge.net/project/snap7/1.3.0/snap7-full-1.3.0.tar.gz"
sha256 "41f972133abd12b8bda9f0cd51a6beae68824f69c2a0740e4c157a4a8e3c1558"
2014-05-02 20:15:00 +00:00
bottle do
cellar :any
2015-03-31 12:26:34 +00:00
sha256 "9b3b9fbef28833a9d147f0188f157d6c5f7ccf15e1dcacbbf0da49d356e8d532" => :yosemite
sha256 "dc9f328d48db101c5982be8bdfbbc71894215f07c695e6f1b59a9ed3eeea4752" => :mavericks
sha256 "c1917deec7552252498d192c4c05fe4e569cff8d2058756bcc04d92504ed356a" => :mountain_lion
2014-05-02 20:15:00 +00:00
end
2014-03-19 11:24:16 +00:00
def install
lib.mkpath
2014-05-04 18:45:47 +00:00
system "make", "-C", "build/osx",
"-f", "#{MacOS.preferred_arch}_osx.mk",
"install", "LibInstall=#{lib}"
2014-03-19 11:24:16 +00:00
include.install "release/Wrappers/c-cpp/snap7.h"
end
test do
system "python", "-c", "import ctypes.util,sys;ctypes.util.find_library('snap7') or sys.exit(1)"
end
end