From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtpng3.m.smailru.net (smtpng3.m.smailru.net [94.100.177.149]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id 63C7246970E for ; Tue, 21 Jan 2020 19:03:01 +0300 (MSK) From: "Alexander V. Tikhonov" Date: Tue, 21 Jan 2020 19:02:57 +0300 Message-Id: <013e27e5dd6554a22f6e02b03a2383c5d2102000.1579621530.git.avtikhon@tarantool.org> In-Reply-To: References: In-Reply-To: References: Subject: [Tarantool-patches] [PATCH v4 1/2] build: tune OSX environment List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Oleg Piskunov Cc: tarantool-patches@dev.tarantool.org Added homebrew installation routine as it was suggested in its instructions. Added installation of the cmake tool. Added upgrade of the OSX packages to avoid of fails on already existed packages with the previous versions. Added reinstallation of the python2 with force option to be able to install it to /usr/local/ path to make pip install there too. --- .travis.mk | 37 +++++++++++++++++++++++++++++-------- 1 file changed, 29 insertions(+), 8 deletions(-) diff --git a/.travis.mk b/.travis.mk index 42969ff56..def513713 100644 --- a/.travis.mk +++ b/.travis.mk @@ -127,17 +127,38 @@ test_asan_debian: deps_debian deps_buster_clang_8 test_asan_debian_no_deps # OSX # ####### +# WARNING: installing pip it checks that python2 installed in /usr/local/ +# path while python2 could be installed in /usr/bin path which will be +# the cause that pip installation will be done at /User/tarantool/ path, +# to avoid of it python2 must be reinstalled with force option to be able +# to install it to /usr/local/ path and pip will be installed there too. +OSX_PKGS=openssl readline curl icu4c libiconv zlib autoconf automake libtool cmake python2 + deps_osx: - brew update - brew install openssl readline curl icu4c libiconv zlib autoconf automake libtool --force - python2 -V || brew install python2 --force - curl --silent --show-error --retry 5 https://bootstrap.pypa.io/get-pip.py >get-pip.py - python get-pip.py --user - pip install --user --force-reinstall -r test-run/requirements.txt + # install brew using command from Homebrew repository instructions: + # https://github.com/Homebrew/install + # NOTE: 'echo' command below is required since brew installation + # script obliges the one to enter a newline for confirming the + # installation via Ruby script. + # + # try to install the packages either upgrade it to avoid of fails + # if the package already exists with the previous version + # + # set PATH to /usr/local/bin as the main to be able to use brew + # installed python and tools + export PATH=/usr/local/bin:${PATH} ; \ + brew update || echo | /usr/bin/ruby -e \ + "$$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" && \ + brew install --force ${OSX_PKGS} || brew upgrade ${OSX_PKGS} && \ + curl --silent --show-error --retry 5 https://bootstrap.pypa.io/get-pip.py >get-pip.py && \ + python get-pip.py && \ + pip install --force-reinstall -r test-run/requirements.txt build_osx: - cmake . -DCMAKE_BUILD_TYPE=RelWithDebInfo -DENABLE_WERROR=ON ${CMAKE_EXTRA_PARAMS} - make -j + export PATH=/usr/local/bin:${PATH} ; \ + cmake . -DCMAKE_BUILD_TYPE=RelWithDebInfo \ + -DENABLE_WERROR=ON ${CMAKE_EXTRA_PARAMS} && \ + make -j test_osx_no_deps: build_osx # Limits: Increase the maximum number of open file descriptors on macOS: -- 2.17.1