2
0
mirror of https://gitlab.com/ita1024/waf.git synced 2024-11-25 19:30:04 +01:00

Improve Qt detection with frameworks

This commit is contained in:
Thomas Nagy 2017-03-25 12:51:26 +01:00
parent aa73787f63
commit ee4d91dfce
No known key found for this signature in database
GPG Key ID: 49B4C67C05277AAA
2 changed files with 7 additions and 4 deletions

View File

@ -100,7 +100,7 @@ def fortran_modifier_darwin(conf):
v.LINKFLAGS_fcshlib = ['-dynamiclib']
v.fcshlib_PATTERN = 'lib%s.dylib'
v.FRAMEWORKPATH_ST = '-F%s'
v.FRAMEWORK_ST = '-framework %s'
v.FRAMEWORK_ST = ['-framework']
v.LINKFLAGS_fcstlib = []

View File

@ -642,10 +642,13 @@ def find_qt5_libraries(self):
uselib = i.upper()
if Utils.unversioned_sys_platform() == 'darwin':
# Since at least qt 4.7.3 each library locates in separate directory
frameworkName = i + '.framework'
qtDynamicLib = os.path.join(env.QTLIBS, frameworkName, i)
fwk = i.replace('Qt5', 'Qt')
frameworkName = fwk + '.framework'
qtDynamicLib = os.path.join(env.QTLIBS, frameworkName, fwk)
if os.path.exists(qtDynamicLib):
env.append_unique('FRAMEWORK_' + uselib, i)
env.append_unique('FRAMEWORK_' + uselib, fwk)
env.append_unique('FRAMEWORKPATH_' + uselib, env.QTLIBS)
self.msg('Checking for %s' % i, qtDynamicLib, 'GREEN')
else:
self.msg('Checking for %s' % i, False, 'YELLOW')