import os Import('env qt_env') def InstallModule(self, arg): # Ensure we install this when built from here, not just from top level build self.Pseudo('install') self.Depends('install', self.Install('${INSTALL_PATH}', filter(lambda x: str(x).endswith('.dll') or str(x).endswith('.pdb') or str(x).endswith('.exe'), arg))) qt_env = qt_env.Clone() qt_env.AddMethod(InstallModule) env = env.Clone() env.AddMethod(InstallModule) Export('env qt_env') for file in env.Glob('*/SConscript'): env.SConscript(file) dll_manifest = 'dlls.manifest' if qt_env['CONFIG'] == 'debug': dll_manifest += '.debug' if qt_env['QT_MAJOR_VERSION'] > 4: dll_manifest += '.q%d' % qt_env['QT_MAJOR_VERSION'] qt_env.InstallAs(os.path.join(qt_env['INSTALL_PATH'], 'DLLs', 'dlls.manifest'), dll_manifest)