Skip to content

Commit

Permalink
OpenRTM-aist-Java furmula modified. Bottle added.
Browse files Browse the repository at this point in the history
  • Loading branch information
n-ando committed Oct 30, 2020
1 parent 49b46dc commit ed759f7
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions openrtm-aist-java.rb
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,12 @@ class OpenrtmAistJava < Formula
sha256 "f6cb64e746d5c1cdf894c6fa9e3b3904841fd115d0eea31da3220fc871874b5e"
license "LGPL-2.1"

bottle do
root_url "https://github.com/OpenRTM/homebrew-openrtm/releases/download/1.2.2/"
cellar :any_skip_relocation
sha256 "4477710635162c2f0859c138b8bac6a473c6fad832968ed6305af79b053cac05" => :catalina
end

def install
short_ver = "1.2"
# ENV.deparallelize # if your formula fails when building in parallel
Expand All @@ -30,7 +36,7 @@ def install
# installing profile.d script into etc
system "mkdir", "-p", "#{prefix}/etc/profile.d"
File.open("#{prefix}/etc/profile.d/openrtm-aist-java.sh", mode = "w"){|f|
f.write("export RTM_JAVA_ROOT=#{prefix}/openrtm-#{short_ver}")
f.write("export RTM_JAVA_ROOT=#{prefix}/lib/openrtm-#{short_ver}")
}
system "chmod", "755", "#{prefix}/etc/profile.d/openrtm-aist-java.sh"

Expand All @@ -45,7 +51,7 @@ def install
system "mkdir", "-p",
"#{prefix}/share/openrtm-#{short_ver}/components/java"
Dir.chdir("examples") do
FileUtils.cp_r("examples/RTMExamples",
FileUtils.cp_r("RTMExamples",
"#{prefix}/share/openrtm-#{short_ver}/components/java/")
Dir.glob('*.sh').each do |fname|
FileUtils.cp(fname,
Expand Down

0 comments on commit ed759f7

Please sign in to comment.