1.1 --- a/AMBuildScript Mon Dec 30 17:50:59 2013 -0500
1.2 +++ b/AMBuildScript Mon Dec 30 17:51:00 2013 -0500
1.3 @@ -68,6 +68,7 @@
1.4 self.mysql_root = None
1.5 self.spcomp = None
1.6 self.smx_files = {}
1.7 + self.versionlib = None
1.8
1.9 def detectProductVersion(self):
1.10 builder.AddConfigureFile('product.version')
1.11 @@ -245,8 +246,10 @@
1.12 cfg.defines += [
1.13 'SOURCEMOD_BUILD',
1.14 'SM_GENERATED_BUILD',
1.15 + 'SM_USE_VERSIONLIB',
1.16 ]
1.17 cfg.includes += [os.path.join(builder.buildPath, 'includes')]
1.18 + cfg.includes += [os.path.join(builder.sourcePath, 'versionlib')]
1.19
1.20 def LibraryBuilder(self, compiler, name):
1.21 binary = compiler.Library(name)
1.22 @@ -261,6 +264,7 @@
1.23 '-compatibility_version', '1.0.0',
1.24 '-current_version', self.productVersion
1.25 ]
1.26 + binary.compiler.linkflags += [self.versionlib]
1.27 binary.compiler.sourcedeps += SM.generated_headers
1.28 return binary
1.29
1.30 @@ -272,6 +276,7 @@
1.31 'BINARY_NAME="{0}"'.format(binary.outputFile),
1.32 'SM_GENERATED_BUILD'
1.33 ]
1.34 + binary.compiler.linkflags += [self.versionlib]
1.35 binary.compiler.sourcedeps += SM.generated_headers
1.36 return binary
1.37
1.38 @@ -432,6 +437,10 @@
1.39 'tools/buildbot/Versioning',
1.40 { 'SM': SM }
1.41 )
1.42 +SM.versionlib = builder.RunScript(
1.43 + 'versionlib/AMBuilder',
1.44 + { 'SM': SM }
1.45 +)
1.46
1.47 builder.RunBuildScripts(
1.48 [