console_bridge 0.3.2 (new formula)

Closes #23899.

Signed-off-by: FX Coudert <fxcoudert@gmail.com>
This commit is contained in:
Jeongseok Lee 2018-02-09 10:25:25 -08:00 committed by FX Coudert
parent 1b9a0c605d
commit fa53c539a4

29
Formula/console_bridge.rb Normal file
View file

@ -0,0 +1,29 @@
class ConsoleBridge < Formula
desc "Robot Operating System-independent package for logging"
homepage "https://wiki.ros.org/console_bridge/"
url "https://github.com/ros/console_bridge/archive/0.3.2.tar.gz"
sha256 "fd12e48c672cb9c5d516d90429c4a7ad605859583fc23d98258c3fa7a12d89f4"
depends_on "cmake" => :build
needs :cxx11
def install
ENV.cxx11
system "cmake", ".", *std_cmake_args
system "make", "install"
end
test do
(testpath/"test.cpp").write <<~EOS
#include <console_bridge/console.h>
int main() {
CONSOLE_BRIDGE_logDebug("Testing Log");
return 0;
}
EOS
system ENV.cxx, "test.cpp", "-L#{lib}", "-lconsole_bridge", "-std=c++11",
"-o", "test"
system "./test"
end
end