From ae21f29ad9f7fd6e69887075b2994c14a30cc8b6 Mon Sep 17 00:00:00 2001 From: David Anderson Date: Mon, 30 Dec 2013 17:51:00 -0500 Subject: [PATCH] Port the PDB log to AMBuild 2 (bug 5997 part 11, r=ds). --- AMBuildScript | 7 +------ tools/buildbot/PackageScript | 8 ++++++++ 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/AMBuildScript b/AMBuildScript index 584337e4..4d454897 100644 --- a/AMBuildScript +++ b/AMBuildScript @@ -141,7 +141,6 @@ class SMConfig(object): '-Wno-switch', '-msse', '-m32', - '-g3', ] have_gcc = cxx.name is 'gcc' @@ -178,7 +177,6 @@ class SMConfig(object): ] cfg.cflags += [ '/W3', - '/Zi', ] cfg.cxxflags += [ '/EHsc', @@ -186,7 +184,6 @@ class SMConfig(object): '/TP', ] cfg.linkflags += [ - '/DEBUG', '/MACHINE:X86', '/SUBSYSTEM:WINDOWS', 'kernel32.lib', @@ -215,9 +212,7 @@ class SMConfig(object): # Debugging if builder.options.debug == '1': cfg.defines += ['DEBUG', '_DEBUG'] - if cxx.behavior == 'gcc': - cfg.cflags += ['-g3'] - elif cxx.behavior == 'msvc': + if cxx.behavior == 'msvc': cfg.cflags += ['/Od', '/RTC1'] # This needs to be after our optimization flags which could otherwise disable it. diff --git a/tools/buildbot/PackageScript b/tools/buildbot/PackageScript index 1ae710b5..871011f5 100644 --- a/tools/buildbot/PackageScript +++ b/tools/buildbot/PackageScript @@ -51,6 +51,14 @@ for cxx_task in SM.extensions: builder.AddCopy(cxx_task.binary, folder_map['addons/sourcemod/extensions']) builder.AddCopy(SM.spcomp.binary, folder_map['addons/sourcemod/scripting']) +# Export PDB files. We write to a file in the build folder which is pretty +# verboten, but it's okay if it's in the root since AMBuild will never try +# to rmdir the root. +full_binary_list = SM.binaries + SM.extensions + [SM.spcomp] +with open(os.path.join(builder.buildPath, 'pdblog.txt'), 'w') as fp: + for task in full_binary_list: + fp.write(task.debug.path + '\n') + # Copy plugins. disabled_plugins = set([ 'admin-sql-prefetch.smx',