merlimat closed pull request #2896: Updating libpulsar Homebrew recipe to 2.2.0 URL: https://github.com/apache/pulsar/pull/2896
This is a PR merged from a forked repository. As GitHub hides the original diff on merge, it is displayed below for the sake of provenance: As this is a foreign pull request (from a fork), the diff is supplied below (as it won't show otherwise due to GitHub magic): diff --git a/pulsar-client-cpp/homebrew/libpulsar.rb b/pulsar-client-cpp/homebrew/libpulsar.rb index 9e4f2dea85..426e783031 100644 --- a/pulsar-client-cpp/homebrew/libpulsar.rb +++ b/pulsar-client-cpp/homebrew/libpulsar.rb @@ -23,10 +23,9 @@ class Libpulsar < Formula head "https://github.com/apache/pulsar.git" - # TODO: Switch to official 2.1 version when available - version "2.1.0-incubating-SNAPSHOT" - url "https://s3-us-west-2.amazonaws.com/pulsar-preview/apache-pulsar-#{version}-src.tar.gz" - sha256 "b7ec66c64830f9a0890a145d40a2a28063c056c2d68e9a4e9bdb0cbe7de0bb39" + version "2.2.0" + url "https://www.apache.org/dyn/mirrors/mirrors.cgi?action=download&filename=pulsar/pulsar-#{version}/apache-pulsar-#{version}-src.tar.gz" + sha256 "a3b1940a803043bb2c365ce9df657d15bf9aacb3c9ff5db86a79dc4374033f08" option "with-python3", "Use Boost with Python-3.x" option "with-log4cxx", "Enable Log4cxx logger" @@ -41,6 +40,7 @@ class Libpulsar < Formula if build.with? "python3" depends_on "boost-python3" => :build else + depends_on "python@2" => :build depends_on "boost-python" => :build end @@ -51,10 +51,16 @@ class Libpulsar < Formula def install Dir.chdir('pulsar-client-cpp') + if build.with? "python3" + python_include_dir = '/usr/local/Frameworks/Python.framework/Versions/3.7/include/python3.7m' + else + python_include_dir = '/usr/local/Frameworks/Python.framework/Versions/2.7/include/python2.7/' + end + if build.with? "log4cxx" - system "cmake", ".", "-DBUILD_TESTS=OFF", "-DLINK_STATIC=ON", "-DUSE_LOG4CXX" + system "cmake", ".", "-DBUILD_TESTS=OFF", "-DLINK_STATIC=ON", "-DUSE_LOG4CXX", "-DPYTHON_INCLUDE_DIR=" + python_include_dir else - system "cmake", ".", "-DBUILD_TESTS=OFF", "-DLINK_STATIC=ON" + system "cmake", ".", "-DBUILD_TESTS=OFF", "-DLINK_STATIC=ON", "-DPYTHON_INCLUDE_DIR=" + python_include_dir end system "make", "pulsarShared", "pulsarStatic" ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services
