* [tarantool-patches] [tarantool-patches] [PATCH 1/1] travis-ci: fixed Mojave mac build with CMAKE_OSX_DEPLOYMENT_TARGET @ 2019-02-19 14:05 Alexander Tikhonov 2019-02-20 14:58 ` [tarantool-patches] " Alexander Turenko 0 siblings, 1 reply; 5+ messages in thread From: Alexander Tikhonov @ 2019-02-19 14:05 UTC (permalink / raw) To: tarantool-patches [-- Attachment #1: Type: text/plain, Size: 4513 bytes --] 1. Changed the Travis-CI testing default OSX image from 'xcode9' to 'xcode10.1', also added Travis-CI's default 'xcode9.4' image to the '2.1' branch testing. 2. Corrected virtualenv setup for OSX images where it is not installed by default. 3. Corrected the minimum version of OSX image on which the target binaries are to be deployed. CMake uses this value for the -mmacosx-version-min flag and to help choose the default SDK. The CMAKE_OSX_DEPLOYMENT_TARGET depends on DARWIN_VERSION: DARWIN_VERSION <= 10.12 -> CMAKE_OSX_DEPLOYMENT_TARGET = 10.6 DARWIN_VERSION >= 10.13 -> CMAKE_OSX_DEPLOYMENT_TARGET = 10.14 Closes #3797 --- Travis-CI: https://travis-ci.org/tarantool/tarantool/builds/495448673 Travis-CI(checked all OSX): https://travis-ci.org/tarantool/tarantool/builds/495415195 Branch: https://github.com/tarantool/tarantool/tree/remotes/origin/avtikhon/gh-3797-fix-mojave-mac-build diff --git a/.travis.mk b/.travis.mk index edd94cd7d..181bab438 100644 --- a/.travis.mk +++ b/.travis.mk @@ -47,6 +47,10 @@ test_ubuntu: deps_ubuntu deps_osx: brew update brew install openssl readline curl icu4c --force + virtualenv -h >/dev/null 2>&1 || \ + ( pip -h >/dev/null 2>&1 || ( curl --silent --show-error --retry 5 https://bootstrap.pypa.io/get-pip.py | python && pip --version ) && \ + brew install pyenv-virtualenv --force && \ + pip install virtualenv ) test_osx: deps_osx cmake . -DCMAKE_BUILD_TYPE=RelWithDebInfoWError ${CMAKE_EXTRA_PARAMS} diff --git a/.travis.yml b/.travis.yml index ffe2e8247..e03bd3185 100644 --- a/.travis.yml +++ b/.travis.yml @@ -8,7 +8,7 @@ language: cpp os: linux compiler: gcc -osx_image: xcode9 +osx_image: xcode10.1 cache: directories: @@ -27,6 +27,11 @@ jobs: - name: RelWithDebInfoWError build + test (OS X) env: TARGET=test os: osx + - name: RelWithDebInfoWError build + test (OS X 9.4) + env: TARGET=test + os: osx + osx_image: xcode9.4 + if: branch = "2.1" - name: Debug build + test + coverage (Linux, gcc) env: TARGET=coverage - name: LTO build + test (Linux, gcc) diff --git a/cmake/luajit.cmake b/cmake/luajit.cmake index ea4878a93..d2253a0f9 100644 --- a/cmake/luajit.cmake +++ b/cmake/luajit.cmake @@ -194,9 +194,28 @@ macro(luajit_build) endif() # Pass deployment target if ("${CMAKE_OSX_DEPLOYMENT_TARGET}" STREQUAL "") - # Default to 10.6 since @rpath support is NOT available in - # earlier versions, needed by AddressSanitizer. - set (luajit_osx_deployment_target 10.6) + # DARWIN_VERSION <= 10.12 -> CMAKE_OSX_DEPLOYMENT_TARGET = 10.6 + # DARWIN_VERSION >= 10.13 -> CMAKE_OSX_DEPLOYMENT_TARGET = 10.14 + execute_process(COMMAND sw_vers -productVersion + OUTPUT_VARIABLE PRODUCT_VERSION) + message(STATUS "PRODUCT_VERSION=${PRODUCT_VERSION}") + string(REGEX MATCH "[0-9]+.[0-9]+" DARWIN_VERSION ${PRODUCT_VERSION}) + message(STATUS "DARWIN_VERSION=${DARWIN_VERSION}") + string(REGEX MATCH "^[0-9]+" MAJOR_VERSION ${DARWIN_VERSION}) + message(STATUS "MAJOR_VERSION=${MAJOR_VERSION}") + if (MAJOR_VERSION GREATER 10) + set (luajit_osx_deployment_target 10.14) + elseif (MAJOR_VERSION LESS 10) + set (luajit_osx_deployment_target 10.6) + elseif (MAJOR_VERSION EQUAL 10) + string(REGEX MATCH "[0-9]+$" MINOR_VERSION ${DARWIN_VERSION}) + message(STATUS "MINOR_VERSION=${MINOR_VERSION}") + if (MINOR_VERSION GREATER 12) + set (luajit_osx_deployment_target 10.14) + else () + set (luajit_osx_deployment_target 10.6) + endif () + endif () else() set (luajit_osx_deployment_target ${CMAKE_OSX_DEPLOYMENT_TARGET}) endif() -- Alexander Tikhonov [-- Attachment #2: Type: text/html, Size: 7227 bytes --] ^ permalink raw reply [flat|nested] 5+ messages in thread
* [tarantool-patches] Re: [PATCH 1/1] travis-ci: fixed Mojave mac build with CMAKE_OSX_DEPLOYMENT_TARGET 2019-02-19 14:05 [tarantool-patches] [tarantool-patches] [PATCH 1/1] travis-ci: fixed Mojave mac build with CMAKE_OSX_DEPLOYMENT_TARGET Alexander Tikhonov @ 2019-02-20 14:58 ` Alexander Turenko 2019-02-21 10:39 ` [tarantool-patches] Re[2]: [tarantool-patches] [tarantool-patches] " Alexander Tikhonov [not found] ` <1550951995.54875386@f494.i.mail.ru> 0 siblings, 2 replies; 5+ messages in thread From: Alexander Turenko @ 2019-02-20 14:58 UTC (permalink / raw) To: Alexander Tikhonov; +Cc: tarantool-patches Hi! Common notes: * Please, squash your patches before send (into 1, 2, several meaningful patches, w/o temporary commits). * Your branch is named remotes/origin/avtikhon/gh-3797-fix-mojave-mac-build (with extra 'remotes/origin/' prefix). * Please, add me to 'To' or 'CC' header when ask a review from me, so I'll not miss it. * Work hard to fit a commit message header within 50 symbols and a commit message within 72 symbols (see our guidelines). Other comments are below. Feel free to engage me into discussions / investigations if needed. WBR, Alexander Turenko. On Tue, Feb 19, 2019 at 05:05:35PM +0300, Alexander Tikhonov wrote: > > 1. Changed the Travis-CI testing default OSX image from 'xcode9' to 'xcode10.1', > also added Travis-CI's default 'xcode9.4' image to the '2.1' branch testing. > 2. Corrected virtualenv setup for OSX images where it is not installed by default. > 3. Corrected the minimum version of OSX image on which the target binaries are to be > deployed. CMake uses this value for the -mmacosx-version-min flag and to help choose the > default SDK. The CMAKE_OSX_DEPLOYMENT_TARGET depends on DARWIN_VERSION: > DARWIN_VERSION <= 10.12 -> CMAKE_OSX_DEPLOYMENT_TARGET = 10.6 > DARWIN_VERSION >= 10.13 -> CMAKE_OSX_DEPLOYMENT_TARGET = 10.14 > > Closes #3797 > --- > Travis-CI: https://travis-ci.org/tarantool/tarantool/builds/495448673 > Travis-CI(checked all OSX): https://travis-ci.org/tarantool/tarantool/builds/495415195 > Branch: https://github.com/tarantool/tarantool/tree/remotes/origin/avtikhon/gh-3797-fix-mojave-mac-build > > diff --git a/.travis.mk b/.travis.mk > index edd94cd7d..181bab438 100644 > --- a/.travis.mk > +++ b/.travis.mk > @@ -47,6 +47,10 @@ test_ubuntu: deps_ubuntu > deps_osx: > brew update > brew install openssl readline curl icu4c --force > + virtualenv -h >/dev/null 2>&1 || \ > + ( pip -h >/dev/null 2>&1 || ( curl --silent --show-error --retry 5 https://bootstrap.pypa.io/get-pip.py | python && pip --version ) && \ > + brew install pyenv-virtualenv --force && \ > + pip install virtualenv ) It seems that we install pip twice: here and in test_osx. I wonder whether all problems are resolved if we just add pyenv-virtualenv into 'brew install' command in deps_osx? > > test_osx: deps_osx > cmake . -DCMAKE_BUILD_TYPE=RelWithDebInfoWError ${CMAKE_EXTRA_PARAMS} > diff --git a/.travis.yml b/.travis.yml > index ffe2e8247..e03bd3185 100644 > --- a/.travis.yml > +++ b/.travis.yml > @@ -8,7 +8,7 @@ language: cpp > os: linux > compiler: gcc > > -osx_image: xcode9 > +osx_image: xcode10.1 > > cache: > directories: > @@ -27,6 +27,11 @@ jobs: > - name: RelWithDebInfoWError build + test (OS X) > env: TARGET=test > os: osx > + - name: RelWithDebInfoWError build + test (OS X 9.4) > + env: TARGET=test > + os: osx > + osx_image: xcode9.4 > + if: branch = "2.1" 9.4 is not OS X version, it is xcode version. Proposed name: RelWithDebInfoWError build + test (OS X 10.13 High Sierra) See the following links to match os_image values into OS X versions and names: https://docs.travis-ci.com/user/reference/osx/#macos-version https://en.wikipedia.org/wiki/MacOS_version_history#toc Now I see both versions are High Sierra. I don't see a reason to have two target of the same Mac OS versions (even despite different xcode versions). Also consider: Travis-CI added Mojave builds: https://blog.travis-ci.com/2019-02-12-xcode-10-2-beta-2-is-now-available Also I still think fix cmakes for Mojave and tweak travis targets should be in the separate commits. > - name: Debug build + test + coverage (Linux, gcc) > env: TARGET=coverage > - name: LTO build + test (Linux, gcc) > diff --git a/cmake/luajit.cmake b/cmake/luajit.cmake > index ea4878a93..d2253a0f9 100644 > --- a/cmake/luajit.cmake > +++ b/cmake/luajit.cmake > @@ -194,9 +194,28 @@ macro(luajit_build) > endif() > # Pass deployment target > if ("${CMAKE_OSX_DEPLOYMENT_TARGET}" STREQUAL "") > - # Default to 10.6 since @rpath support is NOT available in > - # earlier versions, needed by AddressSanitizer. > - set (luajit_osx_deployment_target 10.6) Since we set 10.6 for some targets, the comment seems to be still actual. I don't think we should remove it. > + # DARWIN_VERSION <= 10.12 -> CMAKE_OSX_DEPLOYMENT_TARGET = 10.6 > + # DARWIN_VERSION >= 10.13 -> CMAKE_OSX_DEPLOYMENT_TARGET = 10.14 > + execute_process(COMMAND sw_vers -productVersion > + OUTPUT_VARIABLE PRODUCT_VERSION) > + message(STATUS "PRODUCT_VERSION=${PRODUCT_VERSION}") > + string(REGEX MATCH "[0-9]+.[0-9]+" DARWIN_VERSION ${PRODUCT_VERSION}) > + message(STATUS "DARWIN_VERSION=${DARWIN_VERSION}") > + string(REGEX MATCH "^[0-9]+" MAJOR_VERSION ${DARWIN_VERSION}) > + message(STATUS "MAJOR_VERSION=${MAJOR_VERSION}") > + if (MAJOR_VERSION GREATER 10) > + set (luajit_osx_deployment_target 10.14) > + elseif (MAJOR_VERSION LESS 10) > + set (luajit_osx_deployment_target 10.6) > + elseif (MAJOR_VERSION EQUAL 10) > + string(REGEX MATCH "[0-9]+$" MINOR_VERSION ${DARWIN_VERSION}) > + message(STATUS "MINOR_VERSION=${MINOR_VERSION}") > + if (MINOR_VERSION GREATER 12) > + set (luajit_osx_deployment_target 10.14) > + else () > + set (luajit_osx_deployment_target 10.6) > + endif () > + endif () Can we use VERSION_LESS operation to simplify the code? I think only the first 'message' directive is useful, others are redundant. Why the edge is between 10.12-10.13, while a problem we trying to solve appears only on 10.14 (Mojave)? > else() > set (luajit_osx_deployment_target ${CMAKE_OSX_DEPLOYMENT_TARGET}) > endif() > > > -- > Alexander Tikhonov ^ permalink raw reply [flat|nested] 5+ messages in thread
* [tarantool-patches] Re[2]: [tarantool-patches] [tarantool-patches] [PATCH 1/1] travis-ci: fixed Mojave mac build with CMAKE_OSX_DEPLOYMENT_TARGET 2019-02-20 14:58 ` [tarantool-patches] " Alexander Turenko @ 2019-02-21 10:39 ` Alexander Tikhonov [not found] ` <1550951995.54875386@f494.i.mail.ru> 1 sibling, 0 replies; 5+ messages in thread From: Alexander Tikhonov @ 2019-02-21 10:39 UTC (permalink / raw) To: Alexander Turenko, tarantool-patches [-- Attachment #1: Type: text/plain, Size: 9791 bytes --] travis-ci: added fix for mojave mac build Corrected the minimum version of OSX image on which the target binaries are to be deployed. CMake uses this value for the -mmacosx-version-min flag and to help choose the default SDK. The CMAKE_OSX_DEPLOYMENT_TARGET depends on DARWIN_VERSION: DARWIN_VERSION <= 10.12 -> CMAKE_OSX_DEPLOYMENT_TARGET = 10.6 DARWIN_VERSION >= 10.13 -> CMAKE_OSX_DEPLOYMENT_TARGET = 10.14 Fixes #3797 --- Travis-CI: https://travis-ci.org/tarantool/tarantool/builds/496394051 Branch: remotes/origin/avtikhon/gh-3797-fix-target-mojave-mac-build cmake/luajit.cmake | 25 ++++++++++++++++++++++--- 1 file changed, 22 insertions(+), 3 deletions(-) diff --git a/cmake/luajit.cmake b/cmake/luajit.cmake index ea4878a93..d2253a0f9 100644 --- a/cmake/luajit.cmake +++ b/cmake/luajit.cmake @@ -194,9 +194,28 @@ macro(luajit_build) endif() # Pass deployment target if ("${CMAKE_OSX_DEPLOYMENT_TARGET}" STREQUAL "") - # Default to 10.6 since @rpath support is NOT available in - # earlier versions, needed by AddressSanitizer. - set (luajit_osx_deployment_target 10.6) + # DARWIN_VERSION <= 10.12 -> CMAKE_OSX_DEPLOYMENT_TARGET = 10.6 + # DARWIN_VERSION >= 10.13 -> CMAKE_OSX_DEPLOYMENT_TARGET = 10.14 + execute_process(COMMAND sw_vers -productVersion + OUTPUT_VARIABLE PRODUCT_VERSION) + message(STATUS "PRODUCT_VERSION=${PRODUCT_VERSION}") + string(REGEX MATCH "[0-9]+.[0-9]+" DARWIN_VERSION ${PRODUCT_VERSION}) + message(STATUS "DARWIN_VERSION=${DARWIN_VERSION}") + string(REGEX MATCH "^[0-9]+" MAJOR_VERSION ${DARWIN_VERSION}) + message(STATUS "MAJOR_VERSION=${MAJOR_VERSION}") + if (MAJOR_VERSION GREATER 10) + set (luajit_osx_deployment_target 10.14) + elseif (MAJOR_VERSION LESS 10) + set (luajit_osx_deployment_target 10.6) + elseif (MAJOR_VERSION EQUAL 10) + string(REGEX MATCH "[0-9]+$" MINOR_VERSION ${DARWIN_VERSION}) + message(STATUS "MINOR_VERSION=${MINOR_VERSION}") + if (MINOR_VERSION GREATER 12) + set (luajit_osx_deployment_target 10.14) + else () + set (luajit_osx_deployment_target 10.6) + endif () + endif () else() set (luajit_osx_deployment_target ${CMAKE_OSX_DEPLOYMENT_TARGET}) endif() -- 2.17.1 >Среда, 20 февраля 2019, 17:58 +03:00 от Alexander Turenko <alexander.turenko@tarantool.org>: > >Hi! > >Common notes: > >* Please, squash your patches before send (into 1, 2, several meaningful > patches, w/o temporary commits). >* Your branch is named > remotes/origin/avtikhon/gh-3797-fix-mojave-mac-build (with extra > 'remotes/origin/' prefix). >* Please, add me to 'To' or 'CC' header when ask a review from me, so > I'll not miss it. >* Work hard to fit a commit message header within 50 symbols and a > commit message within 72 symbols (see our guidelines). > >Other comments are below. > >Feel free to engage me into discussions / investigations if needed. > >WBR, Alexander Turenko. > >On Tue, Feb 19, 2019 at 05:05:35PM +0300, Alexander Tikhonov wrote: >> >> 1. Changed the Travis-CI testing default OSX image from 'xcode9' to 'xcode10.1', >> also added Travis-CI's default 'xcode9.4' image to the '2.1' branch testing. >> 2. Corrected virtualenv setup for OSX images where it is not installed by default. >> 3. Corrected the minimum version of OSX image on which the target binaries are to be >> deployed. CMake uses this value for the -mmacosx-version-min flag and to help choose the >> default SDK. The CMAKE_OSX_DEPLOYMENT_TARGET depends on DARWIN_VERSION: >> DARWIN_VERSION <= 10.12 -> CMAKE_OSX_DEPLOYMENT_TARGET = 10.6 >> DARWIN_VERSION >= 10.13 -> CMAKE_OSX_DEPLOYMENT_TARGET = 10.14 >> >> Closes #3797 >> --- >> Travis-CI: https://travis-ci.org/tarantool/tarantool/builds/495448673 >> Travis-CI(checked all OSX): https://travis-ci.org/tarantool/tarantool/builds/495415195 >> Branch: https://github.com/tarantool/tarantool/tree/remotes/origin/avtikhon/gh-3797-fix-mojave-mac-build >> >> diff --git a/.travis.mk b/.travis.mk >> index edd94cd7d..181bab438 100644 >> --- a/.travis.mk >> +++ b/.travis.mk >> @@ -47,6 +47,10 @@ test_ubuntu: deps_ubuntu >> deps_osx: >> brew update >> brew install openssl readline curl icu4c --force >> + virtualenv -h >/dev/null 2>&1 || \ >> + ( pip -h >/dev/null 2>&1 || ( curl --silent --show-error --retry 5 https://bootstrap.pypa.io/get-pip.py | python && pip --version ) && \ >> + brew install pyenv-virtualenv --force && \ >> + pip install virtualenv ) > >It seems that we install pip twice: here and in test_osx. > >I wonder whether all problems are resolved if we just add >pyenv-virtualenv into 'brew install' command in deps_osx? > >> >> test_osx: deps_osx >> cmake . -DCMAKE_BUILD_TYPE=RelWithDebInfoWError ${CMAKE_EXTRA_PARAMS} >> diff --git a/.travis.yml b/.travis.yml >> index ffe2e8247..e03bd3185 100644 >> --- a/.travis.yml >> +++ b/.travis.yml >> @@ -8,7 +8,7 @@ language: cpp >> os: linux >> compiler: gcc >> >> -osx_image: xcode9 >> +osx_image: xcode10.1 >> >> cache: >> directories: >> @@ -27,6 +27,11 @@ jobs: >> - name: RelWithDebInfoWError build + test (OS X) >> env: TARGET=test >> os: osx >> + - name: RelWithDebInfoWError build + test (OS X 9.4) >> + env: TARGET=test >> + os: osx >> + osx_image: xcode9.4 >> + if: branch = "2.1" > >9.4 is not OS X version, it is xcode version. Proposed name: > >RelWithDebInfoWError build + test (OS X 10.13 High Sierra) > >See the following links to match os_image values into OS X versions and >names: > >https://docs.travis-ci.com/user/reference/osx/#macos-version >https://en.wikipedia.org/wiki/MacOS_version_history#toc > >Now I see both versions are High Sierra. I don't see a reason to have >two target of the same Mac OS versions (even despite different xcode >versions). > >Also consider: Travis-CI added Mojave builds: >https://blog.travis-ci.com/2019-02-12-xcode-10-2-beta-2-is-now-available > >Also I still think fix cmakes for Mojave and tweak travis targets should >be in the separate commits. > >> - name: Debug build + test + coverage (Linux, gcc) >> env: TARGET=coverage >> - name: LTO build + test (Linux, gcc) >> diff --git a/cmake/luajit.cmake b/cmake/luajit.cmake >> index ea4878a93..d2253a0f9 100644 >> --- a/cmake/luajit.cmake >> +++ b/cmake/luajit.cmake >> @@ -194,9 +194,28 @@ macro(luajit_build) >> endif() >> # Pass deployment target >> if ("${CMAKE_OSX_DEPLOYMENT_TARGET}" STREQUAL "") >> - # Default to 10.6 since @rpath support is NOT available in >> - # earlier versions, needed by AddressSanitizer. >> - set (luajit_osx_deployment_target 10.6) > >Since we set 10.6 for some targets, the comment seems to be still >actual. I don't think we should remove it. > >> + # DARWIN_VERSION <= 10.12 -> CMAKE_OSX_DEPLOYMENT_TARGET = 10.6 >> + # DARWIN_VERSION >= 10.13 -> CMAKE_OSX_DEPLOYMENT_TARGET = 10.14 >> + execute_process(COMMAND sw_vers -productVersion >> + OUTPUT_VARIABLE PRODUCT_VERSION) >> + message(STATUS "PRODUCT_VERSION=${PRODUCT_VERSION}") >> + string(REGEX MATCH "[0-9]+.[0-9]+" DARWIN_VERSION ${PRODUCT_VERSION}) >> + message(STATUS "DARWIN_VERSION=${DARWIN_VERSION}") >> + string(REGEX MATCH "^[0-9]+" MAJOR_VERSION ${DARWIN_VERSION}) >> + message(STATUS "MAJOR_VERSION=${MAJOR_VERSION}") >> + if (MAJOR_VERSION GREATER 10) >> + set (luajit_osx_deployment_target 10.14) >> + elseif (MAJOR_VERSION LESS 10) >> + set (luajit_osx_deployment_target 10.6) >> + elseif (MAJOR_VERSION EQUAL 10) >> + string(REGEX MATCH "[0-9]+$" MINOR_VERSION ${DARWIN_VERSION}) >> + message(STATUS "MINOR_VERSION=${MINOR_VERSION}") >> + if (MINOR_VERSION GREATER 12) >> + set (luajit_osx_deployment_target 10.14) >> + else () >> + set (luajit_osx_deployment_target 10.6) >> + endif () >> + endif () > >Can we use VERSION_LESS operation to simplify the code? > >I think only the first 'message' directive is useful, others are >redundant. > >Why the edge is between 10.12-10.13, while a problem we trying to solve >appears only on 10.14 (Mojave)? > >> else() >> set (luajit_osx_deployment_target ${CMAKE_OSX_DEPLOYMENT_TARGET}) >> endif() >> >> >> -- >> Alexander Tikhonov > -- Alexander Tikhonov [-- Attachment #2: Type: text/html, Size: 15758 bytes --] ^ permalink raw reply [flat|nested] 5+ messages in thread
[parent not found: <1550951995.54875386@f494.i.mail.ru>]
* [tarantool-patches] Re: [PATCH 1/1] travis-ci: fixed Mojave mac build with CMAKE_OSX_DEPLOYMENT_TARGET [not found] ` <1550951995.54875386@f494.i.mail.ru> @ 2019-03-05 20:27 ` Alexander Turenko 2019-03-12 7:27 ` [tarantool-patches] " Alexander Tikhonov 0 siblings, 1 reply; 5+ messages in thread From: Alexander Turenko @ 2019-03-05 20:27 UTC (permalink / raw) To: Alexander Tikhonov; +Cc: tarantool-patches On Sat, Feb 23, 2019 at 10:59:55PM +0300, Alexander Tikhonov wrote: > > Hi! > > Once more time sorry, that I didn't see your comments from the first time )) > > 1) > > It seems that we install pip twice: here and in test_osx. > > Right, pip is needed twice: > - for virtualenv to be installed while easy_install is depricated > - inside the virtualenv > > I wonder whether all problems are resolved if we just add > > pyenv-virtualenv into 'brew install' command in deps_osx? > > pyenv-virtualenv into 'brew install' command in deps_osx can be installed - I'll do it > > but the virtualenv on the new OSX versions is not installed by default and it > needs additional pip routine installation for 'pip install virtualenv' final install, > otherwise check the following bugus build without additional pip install command: > https://travis-ci.org/tarantool/tarantool/jobs/497450467 > ld: library not found for -lgcc_s.10.4 clang: error: linker command failed with exit code 1 (use -v to see invocation) I don't understood how it is related to pip. I don't understood your description too to be honest. Let's discuss it tommorow voicely. > 2) > > 9.4 is not OS X version, it is xcode version. Proposed name: > > > RelWithDebInfoWError build + test (OS X 10.13 High Sierra) > > > Now I see both versions are High Sierra. I don't see a reason to have > > two target of the same Mac OS versions (even despite different xcode > > versions). > > Right, I'll do your suggestion > > > Also consider: Travis-CI added Mojave builds: > > https://blog.travis-ci.com/2019-02-12-xcode-10-2-beta-2-is-now-available > > I missed it, thanks! > > > Also I still think fix cmakes for Mojave and tweak travis targets should > > be in the separate commits. > > Right, I'll do it in this way > > 3) > > Since we set 10.6 for some targets, the comment seems to be still > > actual. I don't think we should remove it. > Restored back. > > 4) > > Can we use VERSION_LESS operation to simplify the code? > > Right, changed as suggested > > > I think only the first 'message' directive is useful, others are > > redundant. > > Ok, sure > > > Why the edge is between 10.12-10.13, while a problem we trying to solve > > appears only on 10.14 (Mojave)? > > Right, corrected > > Patches below to check the changes made on suggestions: > https://github.com/tarantool/tarantool/compare/2.1...e4beb12d7d3e > https://travis-ci.org/tarantool/tarantool/builds/497561631 > https://travis-ci.org/tarantool/tarantool/builds/497554600 > I'll paste your commits below as plaintext to comment them per line. > commit e265d6686761471301a1de2bf0ca7eab157527cc > Author: Alexander V. Tikhonov <avtikhon@tarantool.org> > Date: Sun Feb 24 05:18:58 2019 -0500 > > travis-ci: OSX version image updated > > Changed the OSX image from 9.4 to 10.2, > added 9.4 version image to 2.1 release criteria The commit message assumes this a reading person has xcode version -> mac os version mapping in a head. 9.4 is not 'OSX image', it is xcode version. I think nobody is interested in xcode versions, so it is better to use Mac OS version in messages. I would also say 'CI for 2.1 branch' instead of vague '2.1 release criteria'. Note: 'OS X' should be written with a whitespace as I see. > > diff --git a/.travis.mk b/.travis.mk > index edd94cd7d..35ed2612f 100644 > --- a/.travis.mk > +++ b/.travis.mk > @@ -46,7 +46,12 @@ test_ubuntu: deps_ubuntu > > deps_osx: > brew update > - brew install openssl readline curl icu4c --force > + brew install openssl readline curl icu4c pyenv-virtualenv --force > + virtualenv -h >/dev/null 2>&1 || \ > + ( pip -h >/dev/null 2>&1 || \ > + ( curl --silent --show-error --retry 5 https://bootstrap.pypa.io/get-pip.py | python && \ > + pip --version ) && \ > + pip install virtualenv ) > Answered above. > test_osx: deps_osx > cmake . -DCMAKE_BUILD_TYPE=RelWithDebInfoWError ${CMAKE_EXTRA_PARAMS} > diff --git a/.travis.yml b/.travis.yml > index ffe2e8247..90af044ff 100644 > --- a/.travis.yml > +++ b/.travis.yml > @@ -8,7 +8,7 @@ language: cpp > os: linux > compiler: gcc > > -osx_image: xcode9 > +osx_image: xcode10.2 Please, add comment like 'Max OS 10.14' > > cache: > directories: > @@ -24,11 +24,16 @@ jobs: > - name: RelWithDebInfoWError build + test (Linux, clang) > env: TARGET=test > compiler: clang > - - name: RelWithDebInfoWError build + test (OS X) > - env: TARGET=test > + - name: RelWithDebInfoWError build + test (OS X 10.14 Mojave) > + env: TARGET=test MACOSX_DEPLOYMENT_TARGET=10.14 Other targets are named like 'Ubuntu Trusty (14.04) build + deploy DEB': name of a release, then release number. So I think it should be 'OS X Mojave 10.14'. Why do you add MACOSX_DEPLOYMENT_TARGET=10.14 here? As I understand your work is about allowing to don't set it. > os: osx > - name: Debug build + test + coverage (Linux, gcc) > env: TARGET=coverage > + - name: RelWithDebInfoWError build + test (OS X 10.13 High Sierra) > + env: TARGET=test > + os: osx > + osx_image: xcode9.4 > + if: branch = "2.1" OS X High Sierra 10.13. > - name: LTO build + test (Linux, gcc) > env: TARGET=test CMAKE_EXTRA_PARAMS=-DENABLE_LTO=ON > if: branch = "2.1" > @@ -36,9 +41,9 @@ jobs: > env: TARGET=test CMAKE_EXTRA_PARAMS=-DENABLE_LTO=ON > if: branch = "2.1" > compiler: clang > - - name: LTO build + test (OS X) > + - name: LTO build + test (OS X 10.14 Mojave) > os: osx > - env: TARGET=test CMAKE_EXTRA_PARAMS=-DENABLE_LTO=ON > + env: TARGET=test CMAKE_EXTRA_PARAMS=-DENABLE_LTO=ON MACOSX_DEPLOYMENT_TARGET=10.14 The same: 'OS X Mojave 10.14' and why MACOSX_DEPLOYMENT_TARGET=10.14 is added? > if: branch = "2.1" > - name: Create and deploy tarball > env: TARGET=source > > commit 0e703e04704de59a29f2f38f2bcb2ec0f028f046 > Author: Alexander V. Tikhonov <avtikhon@tarantool.org> > Date: Sun Feb 24 02:38:07 2019 -0500 > > travis-ci: fixed Mojave mac build > > Fixed Mojave Mac build with CMAKE_OSX_DEPLOYMENT_TARGET. > Specified the minimum version of OS X on which the target > binaries are to be deployed. CMake uses this value for the > -mmacosx-version-min flag and to help choose the default SDK > > diff --git a/cmake/luajit.cmake b/cmake/luajit.cmake > index ea4878a93..40f2472ef 100644 > --- a/cmake/luajit.cmake > +++ b/cmake/luajit.cmake > @@ -196,10 +196,20 @@ macro(luajit_build) > if ("${CMAKE_OSX_DEPLOYMENT_TARGET}" STREQUAL "") > # Default to 10.6 since @rpath support is NOT available in > # earlier versions, needed by AddressSanitizer. Hm. Now the comment is only partially valid. We need to expand it. > - set (luajit_osx_deployment_target 10.6) > + execute_process(COMMAND sw_vers -productVersion > + OUTPUT_VARIABLE PRODUCT_VERSION) > + message(STATUS "PRODUCT_VERSION=${PRODUCT_VERSION}") > + if (${PRODUCT_VERSION} VERSION_LESS 10.14) > + set (luajit_osx_deployment_target 10.6) > + else () > + set (luajit_osx_deployment_target 10.14) > + endif () > + set(CMAKE_OSX_DEPLOYMENT_TARGET "${luajit_osx_deployment_target}" > + CACHE STRING "Minimum OS X deployment version") Please, don't mix whitespaces and tabs. BTW, why we're set CMAKE_OSX_DEPLOYMENT_TARGET if it is not used anywhere else? > else() > set (luajit_osx_deployment_target ${CMAKE_OSX_DEPLOYMENT_TARGET}) > endif() > + message(STATUS "LUAJIT_OSX_DEPLOYMENT_TARGET=${luajit_osx_deployment_target}") > set(luajit_ldflags > ${luajit_ldflags} -Wl,-macosx_version_min,${luajit_osx_deployment_target}) > endif () ^ permalink raw reply [flat|nested] 5+ messages in thread
* [tarantool-patches] Re: [tarantool-patches] Re: [PATCH 1/1] travis-ci: fixed Mojave mac build with CMAKE_OSX_DEPLOYMENT_TARGET 2019-03-05 20:27 ` [tarantool-patches] " Alexander Turenko @ 2019-03-12 7:27 ` Alexander Tikhonov 0 siblings, 0 replies; 5+ messages in thread From: Alexander Tikhonov @ 2019-03-12 7:27 UTC (permalink / raw) To: tarantool-patches, Alexander Turenko [-- Attachment #1: Type: text/plain, Size: 13124 bytes --] Fixed Mojave Mac build with MACOSX_DEPLOYMENT_TARGET environment setup. Specified the minimum version of OS X on which the target binaries are to be deployed. CMake uses this value for the make environment and the -mmacosx-version-min flag to help choose the default SDK Fixed #3757 --- .travis.mk | 5 +++++ .travis.yml | 11 ++++++++--- cmake/luajit.cmake | 15 ++++++++++++--- 3 files changed, 25 insertions(+), 6 deletions(-) diff --git a/.travis.mk b/.travis.mk index edd94cd7d..fd93ef1b9 100644 --- a/.travis.mk +++ b/.travis.mk @@ -47,6 +47,11 @@ test_ubuntu: deps_ubuntu deps_osx: brew update brew install openssl readline curl icu4c --force + virtualenv -h >/dev/null 2>&1 || \ + ( pip -h >/dev/null 2>&1 || \ + ( curl --silent --show-error --retry 5 https://bootstrap.pypa.io/get-pip.py | python && \ + pip --version ) && \ + pip install virtualenv ) test_osx: deps_osx cmake . -DCMAKE_BUILD_TYPE=RelWithDebInfoWError ${CMAKE_EXTRA_PARAMS} diff --git a/.travis.yml b/.travis.yml index ffe2e8247..8a118a7f2 100644 --- a/.travis.yml +++ b/.travis.yml @@ -8,7 +8,7 @@ language: cpp os: linux compiler: gcc -osx_image: xcode9 +osx_image: xcode10.2 cache: directories: @@ -24,11 +24,16 @@ jobs: - name: RelWithDebInfoWError build + test (Linux, clang) env: TARGET=test compiler: clang - - name: RelWithDebInfoWError build + test (OS X) + - name: RelWithDebInfoWError build + test (OS X Mojave 10.14) env: TARGET=test os: osx - name: Debug build + test + coverage (Linux, gcc) env: TARGET=coverage + - name: RelWithDebInfoWError build + test (OS X High Sierra 10.13) + env: TARGET=test + os: osx + osx_image: xcode9.4 + if: branch = "2.1" - name: LTO build + test (Linux, gcc) env: TARGET=test CMAKE_EXTRA_PARAMS=-DENABLE_LTO=ON if: branch = "2.1" @@ -36,7 +41,7 @@ jobs: env: TARGET=test CMAKE_EXTRA_PARAMS=-DENABLE_LTO=ON if: branch = "2.1" compiler: clang - - name: LTO build + test (OS X) + - name: LTO build + test (OS X Mojave 10.14) os: osx env: TARGET=test CMAKE_EXTRA_PARAMS=-DENABLE_LTO=ON if: branch = "2.1" diff --git a/cmake/luajit.cmake b/cmake/luajit.cmake index ea4878a93..e84fb21aa 100644 --- a/cmake/luajit.cmake +++ b/cmake/luajit.cmake @@ -196,10 +196,19 @@ macro(luajit_build) if ("${CMAKE_OSX_DEPLOYMENT_TARGET}" STREQUAL "") # Default to 10.6 since @rpath support is NOT available in # earlier versions, needed by AddressSanitizer. - set (luajit_osx_deployment_target 10.6) + execute_process(COMMAND sw_vers -productVersion + OUTPUT_VARIABLE PRODUCT_VERSION) + message(STATUS "PRODUCT_VERSION=${PRODUCT_VERSION}") + if (${PRODUCT_VERSION} VERSION_LESS 10.14) + set (luajit_osx_deployment_target 10.6) + else () + set (luajit_osx_deployment_target 10.14) + endif () else() set (luajit_osx_deployment_target ${CMAKE_OSX_DEPLOYMENT_TARGET}) endif() + set(macosx_deployment_target_env MACOSX_DEPLOYMENT_TARGET=${luajit_osx_deployment_target}) + message(STATUS "${macosx_deployment_target_env}") set(luajit_ldflags ${luajit_ldflags} -Wl,-macosx_version_min,${luajit_osx_deployment_target}) endif () @@ -238,7 +247,7 @@ macro(luajit_build) add_custom_command(OUTPUT ${PROJECT_BINARY_DIR}/third_party/luajit/src/libluajit.a WORKING_DIRECTORY ${PROJECT_BINARY_DIR}/third_party/luajit COMMAND $(MAKE) ${luajit_buildoptions} clean - COMMAND $(MAKE) -C src ${luajit_buildoptions} jit/vmdef.lua libluajit.a + COMMAND ${macosx_deployment_target_env} $(MAKE) -C src ${luajit_buildoptions} jit/vmdef.lua libluajit.a DEPENDS ${CMAKE_SOURCE_DIR}/CMakeCache.txt ) else() @@ -249,7 +258,7 @@ macro(luajit_build) WORKING_DIRECTORY ${PROJECT_BINARY_DIR}/third_party/luajit COMMAND ${CMAKE_COMMAND} -E copy_directory ${PROJECT_SOURCE_DIR}/third_party/luajit ${PROJECT_BINARY_DIR}/third_party/luajit COMMAND $(MAKE) ${luajit_buildoptions} clean - COMMAND $(MAKE) -C src ${luajit_buildoptions} jit/vmdef.lua libluajit.a + COMMAND ${macosx_deployment_target_env} $(MAKE) -C src ${luajit_buildoptions} jit/vmdef.lua libluajit.a DEPENDS ${PROJECT_BINARY_DIR}/CMakeCache.txt ${PROJECT_BINARY_DIR}/third_party/luajit ) endif() -- 2.17.1 >Вторник, 5 марта 2019, 23:27 +03:00 от Alexander Turenko <alexander.turenko@tarantool.org>: > >On Sat, Feb 23, 2019 at 10:59:55PM +0300, Alexander Tikhonov wrote: >> >> Hi! >> >> Once more time sorry, that I didn't see your comments from the first time )) >> >> 1) >> > It seems that we install pip twice: here and in test_osx. >> >> Right, pip is needed twice: >> - for virtualenv to be installed while easy_install is depricated >> - inside the virtualenv >> > I wonder whether all problems are resolved if we just add >> > pyenv-virtualenv into 'brew install' command in deps_osx? >> >> pyenv-virtualenv into 'brew install' command in deps_osx can be installed - I'll do it >> >> but the virtualenv on the new OSX versions is not installed by default and it >> needs additional pip routine installation for 'pip install virtualenv' final install, >> otherwise check the following bugus build without additional pip install command: >> https://travis-ci.org/tarantool/tarantool/jobs/497450467 >> > >ld: library not found for -lgcc_s.10.4 >clang: error: linker command failed with exit code 1 (use -v to see invocation) > >I don't understood how it is related to pip. > >I don't understood your description too to be honest. Let's discuss it >tommorow voicely. > >> 2) >> > 9.4 is not OS X version, it is xcode version. Proposed name: >> >> > RelWithDebInfoWError build + test (OS X 10.13 High Sierra) >> >> > Now I see both versions are High Sierra. I don't see a reason to have >> > two target of the same Mac OS versions (even despite different xcode >> > versions). >> >> Right, I'll do your suggestion >> >> > Also consider: Travis-CI added Mojave builds: >> > https://blog.travis-ci.com/2019-02-12-xcode-10-2-beta-2-is-now-available >> >> I missed it, thanks! >> >> > Also I still think fix cmakes for Mojave and tweak travis targets should >> > be in the separate commits. >> >> Right, I'll do it in this way >> >> 3) >> > Since we set 10.6 for some targets, the comment seems to be still >> > actual. I don't think we should remove it. >> Restored back. >> >> 4) >> > Can we use VERSION_LESS operation to simplify the code? >> >> Right, changed as suggested >> >> > I think only the first 'message' directive is useful, others are >> > redundant. >> >> Ok, sure >> >> > Why the edge is between 10.12-10.13, while a problem we trying to solve >> > appears only on 10.14 (Mojave)? >> >> Right, corrected >> >> Patches below to check the changes made on suggestions: >> https://github.com/tarantool/tarantool/compare/2.1...e4beb12d7d3e >> https://travis-ci.org/tarantool/tarantool/builds/497561631 >> https://travis-ci.org/tarantool/tarantool/builds/497554600 >> > >I'll paste your commits below as plaintext to comment them per line. > >> commit e265d6686761471301a1de2bf0ca7eab157527cc >> Author: Alexander V. Tikhonov < avtikhon@tarantool.org > >> Date: Sun Feb 24 05:18:58 2019 -0500 >> >> travis-ci: OSX version image updated >> >> Changed the OSX image from 9.4 to 10.2, >> added 9.4 version image to 2.1 release criteria > >The commit message assumes this a reading person has xcode version -> >mac os version mapping in a head. 9.4 is not 'OSX image', it is xcode >version. I think nobody is interested in xcode versions, so it is better >to use Mac OS version in messages. > >I would also say 'CI for 2.1 branch' instead of vague '2.1 release >criteria'. > >Note: 'OS X' should be written with a whitespace as I see. > >> >> diff --git a/.travis.mk b/.travis.mk >> index edd94cd7d..35ed2612f 100644 >> --- a/.travis.mk >> +++ b/.travis.mk >> @@ -46,7 +46,12 @@ test_ubuntu: deps_ubuntu >> >> deps_osx: >> brew update >> - brew install openssl readline curl icu4c --force >> + brew install openssl readline curl icu4c pyenv-virtualenv --force >> + virtualenv -h >/dev/null 2>&1 || \ >> + ( pip -h >/dev/null 2>&1 || \ >> + ( curl --silent --show-error --retry 5 https://bootstrap.pypa.io/get-pip.py | python && \ >> + pip --version ) && \ >> + pip install virtualenv ) >> > >Answered above. > >> test_osx: deps_osx >> cmake . -DCMAKE_BUILD_TYPE=RelWithDebInfoWError ${CMAKE_EXTRA_PARAMS} >> diff --git a/.travis.yml b/.travis.yml >> index ffe2e8247..90af044ff 100644 >> --- a/.travis.yml >> +++ b/.travis.yml >> @@ -8,7 +8,7 @@ language: cpp >> os: linux >> compiler: gcc >> >> -osx_image: xcode9 >> +osx_image: xcode10.2 > >Please, add comment like 'Max OS 10.14' > >> >> cache: >> directories: >> @@ -24,11 +24,16 @@ jobs: >> - name: RelWithDebInfoWError build + test (Linux, clang) >> env: TARGET=test >> compiler: clang >> - - name: RelWithDebInfoWError build + test (OS X) >> - env: TARGET=test >> + - name: RelWithDebInfoWError build + test (OS X 10.14 Mojave) >> + env: TARGET=test MACOSX_DEPLOYMENT_TARGET=10.14 > >Other targets are named like 'Ubuntu Trusty (14.04) build + deploy DEB': >name of a release, then release number. So I think it should be 'OS X >Mojave 10.14'. > >Why do you add MACOSX_DEPLOYMENT_TARGET=10.14 here? As I understand your >work is about allowing to don't set it. > >> os: osx >> - name: Debug build + test + coverage (Linux, gcc) >> env: TARGET=coverage >> + - name: RelWithDebInfoWError build + test (OS X 10.13 High Sierra) >> + env: TARGET=test >> + os: osx >> + osx_image: xcode9.4 >> + if: branch = "2.1" > >OS X High Sierra 10.13. > >> - name: LTO build + test (Linux, gcc) >> env: TARGET=test CMAKE_EXTRA_PARAMS=-DENABLE_LTO=ON >> if: branch = "2.1" >> @@ -36,9 +41,9 @@ jobs: >> env: TARGET=test CMAKE_EXTRA_PARAMS=-DENABLE_LTO=ON >> if: branch = "2.1" >> compiler: clang >> - - name: LTO build + test (OS X) >> + - name: LTO build + test (OS X 10.14 Mojave) >> os: osx >> - env: TARGET=test CMAKE_EXTRA_PARAMS=-DENABLE_LTO=ON >> + env: TARGET=test CMAKE_EXTRA_PARAMS=-DENABLE_LTO=ON MACOSX_DEPLOYMENT_TARGET=10.14 > >The same: 'OS X Mojave 10.14' and why MACOSX_DEPLOYMENT_TARGET=10.14 is >added? > >> if: branch = "2.1" >> - name: Create and deploy tarball >> env: TARGET=source >> >> commit 0e703e04704de59a29f2f38f2bcb2ec0f028f046 >> Author: Alexander V. Tikhonov < avtikhon@tarantool.org > >> Date: Sun Feb 24 02:38:07 2019 -0500 >> >> travis-ci: fixed Mojave mac build >> >> Fixed Mojave Mac build with CMAKE_OSX_DEPLOYMENT_TARGET. >> Specified the minimum version of OS X on which the target >> binaries are to be deployed. CMake uses this value for the >> -mmacosx-version-min flag and to help choose the default SDK >> >> diff --git a/cmake/luajit.cmake b/cmake/luajit.cmake >> index ea4878a93..40f2472ef 100644 >> --- a/cmake/luajit.cmake >> +++ b/cmake/luajit.cmake >> @@ -196,10 +196,20 @@ macro(luajit_build) >> if ("${CMAKE_OSX_DEPLOYMENT_TARGET}" STREQUAL "") >> # Default to 10.6 since @rpath support is NOT available in >> # earlier versions, needed by AddressSanitizer. > >Hm. Now the comment is only partially valid. We need to expand it. > >> - set (luajit_osx_deployment_target 10.6) >> + execute_process(COMMAND sw_vers -productVersion >> + OUTPUT_VARIABLE PRODUCT_VERSION) >> + message(STATUS "PRODUCT_VERSION=${PRODUCT_VERSION}") >> + if (${PRODUCT_VERSION} VERSION_LESS 10.14) >> + set (luajit_osx_deployment_target 10.6) >> + else () >> + set (luajit_osx_deployment_target 10.14) >> + endif () >> + set(CMAKE_OSX_DEPLOYMENT_TARGET "${luajit_osx_deployment_target}" >> + CACHE STRING "Minimum OS X deployment version") > >Please, don't mix whitespaces and tabs. > >BTW, why we're set CMAKE_OSX_DEPLOYMENT_TARGET if it is not used >anywhere else? > >> else() >> set (luajit_osx_deployment_target ${CMAKE_OSX_DEPLOYMENT_TARGET}) >> endif() >> + message(STATUS "LUAJIT_OSX_DEPLOYMENT_TARGET=${luajit_osx_deployment_target}") >> set(luajit_ldflags >> ${luajit_ldflags} -Wl,-macosx_version_min,${luajit_osx_deployment_target}) >> endif () > -- Alexander Tikhonov [-- Attachment #2: Type: text/html, Size: 17676 bytes --] ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2019-03-12 7:27 UTC | newest] Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2019-02-19 14:05 [tarantool-patches] [tarantool-patches] [PATCH 1/1] travis-ci: fixed Mojave mac build with CMAKE_OSX_DEPLOYMENT_TARGET Alexander Tikhonov 2019-02-20 14:58 ` [tarantool-patches] " Alexander Turenko 2019-02-21 10:39 ` [tarantool-patches] Re[2]: [tarantool-patches] [tarantool-patches] " Alexander Tikhonov [not found] ` <1550951995.54875386@f494.i.mail.ru> 2019-03-05 20:27 ` [tarantool-patches] " Alexander Turenko 2019-03-12 7:27 ` [tarantool-patches] " Alexander Tikhonov
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox