Skip to content

Commit

Permalink
Travis macosx fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Adam Reif committed Sep 2, 2017
1 parent ddd76c8 commit 20e591e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ branches:
env:
global:
- GITHUB_REPO: pfcrender
- QT_ROOT: 'usr/local/qt5'


#additional deps
addons:
Expand Down Expand Up @@ -47,7 +47,7 @@ install:
- if [[ $TRAVIS_OS_NAME == 'linux' ]] ; then sudo apt-get install qt59-meta-full ; fi
- if [[ $TRAVIS_OS_NAME == 'linux' ]] ; then source /opt/qt59/bin/qt59-env.sh ; fi
- if [[ $TRAVIS_OS_NAME == 'osx' ]] ; then brew install qt5 ; fi
- if [[ $TRAVIS_OS_NAME == 'osx' ]] ; then brew link qt5 --force ; fi
# - if [[ $TRAVIS_OS_NAME == 'osx' ]] ; then brew link --force qt5 && ln -s /usr/local/Cellar/qt5/5.9.1/mkspecs /usr/local/mkspecs && ln -s /usr/local/Cellar/qt5/5.9.1/plugins /usr/local/plugins ; fi

script:
- cd bin && cmake .. && make && make test
Expand Down
8 changes: 8 additions & 0 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,14 @@ set(CMAKE_INCLUDE_CURRENT_DIR ON)

set(CMAKE_AUTOMOC ON)

if(APPLE AND EXISTS /usr/local/opt/qt5)
# Homebrew installs Qt5 (up to at least 5.9.1) in
# /usr/local/qt5, ensure it can be found by CMake since
# it is not in the default /usr/local prefix.
list(APPEND CMAKE_PREFIX_PATH "/usr/local/opt/qt5")
endif()


#Check for Qt5
find_package(Qt5Core REQUIRED)

Expand Down

0 comments on commit 20e591e

Please sign in to comment.