Attempt at getting webternet extension into build process.

This commit is contained in:
David Anderson 2009-01-12 00:36:36 -05:00
parent e449b8384c
commit 7cef8b7363
4 changed files with 45 additions and 4 deletions

View File

@ -27,7 +27,7 @@ die "Unable to build builder tool!\n" unless -e 'builder.exe';
chdir(Build::PathFormat('../..'));
#Get the source path.
my ($root) = getcwd();
our ($root) = getcwd();
#Create output folder if it doesn't exist.
if (!(-d 'OUTPUT')) {
@ -58,3 +58,34 @@ if ($^O eq "linux")
Build::Command("chmod +x tools/versionchanger.pl");
}
Build::Command(Build::PathFormat('tools/versionchanger.pl') . ' --buildstring="-dev"');
#Bootstrap extensions that have complex dependencies
if ($^O eq "linux")
{
BuildLibCurl_Linux();
}
else
{
BuildLibCurl_Win32();
}
sub BuildLibCurl_Win32
{
chdir("extensions\\curl\\curl-src\\lib");
Build::Command('"' . $ENV{'VC9BUILDER'} . '" /rebuild build_libcurl.vcproj LIB-Release');
die "Unable to find libcurl.lib!\n" unless (-f "LIB-Release\\libcurl.lib");
chdir("..\\..\\..\\..");
}
sub BuildLibCurl_Linux
{
chdir("extensions/curl/curl-src");
Build::Command("mkdir -p Release");
Build::Command("chmod +x configure");
chdir("Release");
Build::Command("../configure --enable-static --disable-shared --disable-ldap --without-ssl --without-zlib");
Build::Command("make");
die "Unable to find libcurl.a!\n" unless (-f "lib/.libs/libcurl.a");
chdir("../../../..");
}

View File

@ -31,10 +31,13 @@ namespace builder
else if (cfg.Platform == BasePlatform.Platform_Windows)
{
bld = new Win32Builder(cfg);
if (cfg.pdb_log_file != null && File.Exists(cfg.pdb_log_file))
/* Do not delete this file anymore. We don't support rebuilds, and thus the file
* is guaranteed to be wiped by buildbot.
*/
/*if (cfg.pdb_log_file != null && File.Exists(cfg.pdb_log_file))
{
File.Delete(cfg.pdb_log_file);
}
}*/
}
try

View File

@ -292,6 +292,13 @@ namespace builder
lib.vcproj_name = "clientprefs";
libraries.Add(lib);
lib = new Library();
lib.package_path = "addons/sourcemod/extensions";
lib.source_path = "extensions/curl";
lib.binary_name = "webternet.ext";
lib.vcproj_name = "curl";
libraries.Add(lib);
return (Library [])libraries.ToArray(typeof(Library));
}

View File

@ -52,7 +52,7 @@ namespace builder
}
else if (lib.build_mode == BuildMode.BuildMode_Left4Dead)
{
config_name = config_name + " - Left 4 Dead";
config_name = config_name + " - Left 4 Dead";
}
string binpath = Config.PathFormat("{0}/{1}/{2}",