From 79237ec01c2a0ef34c5dc4b8d2bfde295a859349 Mon Sep 17 00:00:00 2001 From: Bo Peng Date: Thu, 1 Jun 2006 03:01:46 +0000 Subject: [PATCH] Scons: two small bug fixes, and a bit more about msvc git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13975 a592a061-630c-0410-9148-cb99ea01b6c8 --- development/scons/SConscript | 4 ++-- development/scons/SConstruct | 14 +++++++++----- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/development/scons/SConscript b/development/scons/SConscript index fc71962353..d9f990e680 100644 --- a/development/scons/SConscript +++ b/development/scons/SConscript @@ -58,7 +58,7 @@ if rebuild_targets: # sync frontend and env['frontend'] (maybe build qt4 with frontend=qt3) if build_qt3: frontend = 'qt3' - env['frontend'] = 'qt4' + env['frontend'] = 'qt3' elif build_qt4: frontend = 'qt4' env['frontend'] = 'qt4' @@ -145,7 +145,7 @@ if build_intl: intlenv = env.Copy() # we need the original C compiler for these files intlenv['CC'] = intlenv['C_COMPILER'] - intlenv['CCFLAGS'] = intlenv['C_CCFLAGS'] + intlenv['CCFLAGS'] = intlenv['C_CCFLAGS'].split() intlenv['CPPPATH'] += ['intl'] intlenv.Append(CCFLAGS = [ diff --git a/development/scons/SConstruct b/development/scons/SConstruct index e0d84c6c31..e6f2eb537c 100644 --- a/development/scons/SConstruct +++ b/development/scons/SConstruct @@ -521,6 +521,9 @@ else: # in the current code page (number) # C4996: foo was decleared deprecated env.Append(CCFLAGS=['/TP', '/EHsc', '/wd4819', '/wd4996']) + env['LINKFLAGS'] = [env['LINKFLAGS'], '/MANIFEST'] + env['LINKCOM' ] = [env['LINKCOM'], 'mt /manifest ${TARGET}.manifest /outputresource:$TARGET'] + env['SHLINKCOM'] = [env['SHLINKCOM'], 'mt /manifest ${TARGET}.manifest -outputresource:$TARGET;#2'] #---------------------------------------------------------- @@ -551,8 +554,10 @@ else: env['HAS_PKG_CONFIG'] = env_cache['HAS_PKG_CONFIG'] # zlib? This is required. (fast_start assumes the existance of zlib) -if not fast_start and not conf.CheckLibWithHeader('z', 'zlib.h', 'C'): - print 'Did not find libz or zlib.h, exiting!' +if not fast_start: + if (not use_vc and not conf.CheckLibWithHeader('z', 'zlib.h', 'C')) \ + or (use_vc and not conf.CheckLibWithHeader('zdll', 'zlib.h', 'C')): + print 'Did not find zdll.lib or zlib.h, exiting!' Exit(1) # qt libraries? @@ -1124,11 +1129,10 @@ except: if platform_name in ['win32', 'cygwin']: # the final link step needs stdc++ to succeed under mingw # FIXME: shouldn't g++ automatically link to stdc++? - env['SYSTEM_LIBS'] = ['shlwapi', 'z'] if use_vc: - env['SYSTEM_LIBS'].extend(['gdi32', 'shell32', 'advapi32']) + env['SYSTEM_LIBS'] = ['shlwapi', 'gdi32', 'shell32', 'advapi32', 'zdll'] else: - env['SYSTEM_LIBS'].append('stdc++') + env['SYSTEM_LIBS'] = ['shlwapi', 'stdc++', 'z'] else: env['SYSTEM_LIBS'] = ['z']