parameters: (self)
docstring: Besides the configuration options, the environment variable QT5_ROOT may be used
  	to give the location of the qt5 libraries (absolute path).
  
  	The detection uses the program ``pkg-config`` through :py:func:`waflib.Tools.config_c.check_cfg`
docstring_summary: Besides the configuration options, the environment variable QT5_ROOT may be used
  	to give the location of the qt5 libraries (absolute path).
docstring_tokens: Besides the configuration options the environment variable QT5_ROOT may be used to give the location of the qt5 libraries ( absolute path ) .
function: def configure(self):
  	"""
  	Besides the configuration options, the environment variable QT5_ROOT may be used
  	to give the location of the qt5 libraries (absolute path).
  
  	The detection uses the program ``pkg-config`` through :py:func:`waflib.Tools.config_c.check_cfg`
  	"""
  	if 'COMPILER_CXX' not in self.env:
  		self.fatal('No CXX compiler defined: did you forget to configure compiler_cxx first?')
  
  	self.find_qt5_binaries()
  	self.set_qt5_libs_dir()
  	self.set_qt5_libs_to_check()
  	self.set_qt5_defines()
  	self.find_qt5_libraries()
  	self.add_qt5_rpath()
  	self.simplify_qt5_libs()
  
  	# warn about this during the configuration too
  	if not has_xml:
  		Logs.error('No xml.sax support was found, rcc dependencies will be incomplete!')
  
  	# Qt5 may be compiled with '-reduce-relocations' which requires dependent programs to have -fPIE or -fPIC?
  	frag = '#include <QMap>\nint main(int argc, char **argv) {QMap<int,int> m;return m.keys().size();}\n'
  	uses = 'QT5CORE'
  	for flag in [[], '-fPIE', '-fPIC', '-std=c++11' , ['-std=c++11', '-fPIE'], ['-std=c++11', '-fPIC']]:
  		msg = 'See if Qt files compile '
  		if flag:
  			msg += 'with %s' % flag
  		try:
  			self.check(features='qt5 cxx', use=uses, uselib_store='qt5', cxxflags=flag, fragment=frag, msg=msg)
  		except self.errors.ConfigurationError:
  			pass
  		else:
  			break
  	else:
  		self.fatal('Could not build a simple Qt application')
  
  	# FreeBSD does not add /usr/local/lib and the pkg-config files do not provide it either :-/
  	if Utils.unversioned_sys_platform() == 'freebsd':
  		frag = '#include <QMap>\nint main(int argc, char **argv) {QMap<int,int> m;return m.keys().size();}\n'
  		try:
  			self.check(features='qt5 cxx cxxprogram', use=uses, fragment=frag, msg='Can we link Qt programs on FreeBSD directly?')
  		except self.errors.ConfigurationError:
  			self.check(features='qt5 cxx cxxprogram', use=uses, uselib_store='qt5', libpath='/usr/local/lib', fragment=frag, msg='Is /usr/local/lib required?')
function_tokens: def configure ( self ) : if 'COMPILER_CXX' not in self . env : self . fatal ( 'No CXX compiler defined: did you forget to configure compiler_cxx first?' ) self . find_qt5_binaries ( ) self . set_qt5_libs_dir ( ) self . set_qt5_libs_to_check ( ) self . set_qt5_defines ( ) self . find_qt5_libraries ( ) self . add_qt5_rpath ( ) self . simplify_qt5_libs ( ) # warn about this during the configuration too if not has_xml : Logs . error ( 'No xml.sax support was found, rcc dependencies will be incomplete!' ) # Qt5 may be compiled with '-reduce-relocations' which requires dependent programs to have -fPIE or -fPIC? frag = '#include <QMap>\nint main(int argc, char **argv) {QMap<int,int> m;return m.keys().size();}\n' uses = 'QT5CORE' for flag in [ [ ] , '-fPIE' , '-fPIC' , '-std=c++11' , [ '-std=c++11' , '-fPIE' ] , [ '-std=c++11' , '-fPIC' ] ] : msg = 'See if Qt files compile ' if flag : msg += 'with %s' % flag try : self . check ( features = 'qt5 cxx' , use = uses , uselib_store = 'qt5' , cxxflags = flag , fragment = frag , msg = msg ) except self . errors . ConfigurationError : pass else : break else : self . fatal ( 'Could not build a simple Qt application' ) # FreeBSD does not add /usr/local/lib and the pkg-config files do not provide it either :-/ if Utils . unversioned_sys_platform ( ) == 'freebsd' : frag = '#include <QMap>\nint main(int argc, char **argv) {QMap<int,int> m;return m.keys().size();}\n' try : self . check ( features = 'qt5 cxx cxxprogram' , use = uses , fragment = frag , msg = 'Can we link Qt programs on FreeBSD directly?' ) except self . errors . ConfigurationError : self . check ( features = 'qt5 cxx cxxprogram' , use = uses , uselib_store = 'qt5' , libpath = '/usr/local/lib' , fragment = frag , msg = 'Is /usr/local/lib required?' )