From 0eb016bb9b7a547457cc207f22bd398080018d0e Mon Sep 17 00:00:00 2001
From: unknown <lenz@mysql.com>
Date: Tue, 3 Aug 2004 02:36:21 +0200
Subject: [PATCH]  - added option "--bundled-zlib" to compile using the
 included    compression library

---
 Build-tools/Do-compile | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/Build-tools/Do-compile b/Build-tools/Do-compile
index e6e71582c74..c17995f5779 100755
--- a/Build-tools/Do-compile
+++ b/Build-tools/Do-compile
@@ -10,12 +10,13 @@ use Sys::Hostname;
 $opt_distribution=$opt_user=$opt_config_env=$opt_config_extra_env="";
 $opt_dbd_options=$opt_perl_options=$opt_config_options=$opt_make_options=$opt_suffix="";
 $opt_tmp=$opt_version_suffix="";
-$opt_help=$opt_delete=$opt_debug=$opt_stage=$opt_no_test=$opt_no_perl=$opt_with_low_memory=$opt_fast_benchmark=$opt_static_client=$opt_static_server=$opt_static_perl=$opt_sur=$opt_with_small_disk=$opt_local_perl=$opt_tcpip=$opt_build_thread=$opt_use_old_distribution=$opt_enable_shared=$opt_no_crash_me=$opt_no_strip=$opt_with_cluster=$opt_with_debug=$opt_no_benchmark=$opt_no_mysqltest=$opt_without_embedded=$opt_readline=0;
+$opt_bundled_zlib=$opt_help=$opt_delete=$opt_debug=$opt_stage=$opt_no_test=$opt_no_perl=$opt_with_low_memory=$opt_fast_benchmark=$opt_static_client=$opt_static_server=$opt_static_perl=$opt_sur=$opt_with_small_disk=$opt_local_perl=$opt_tcpip=$opt_build_thread=$opt_use_old_distribution=$opt_enable_shared=$opt_no_crash_me=$opt_no_strip=$opt_with_cluster=$opt_with_debug=$opt_no_benchmark=$opt_no_mysqltest=$opt_without_embedded=$opt_readline=0;
 $opt_innodb=$opt_bdb=$opt_raid=$opt_libwrap=$opt_clearlogs=0;
 
 GetOptions(
 	"bdb",
 	"build-thread=i",
+	"bundled-zlib",
 	"config-env=s" => \@config_env,
 	"config-extra-env=s" => \@config_extra_env,
 	"config-options=s" => \@config_options,
@@ -255,6 +256,7 @@ if ($opt_stage <= 1)
   log_system("$make clean") if ($opt_use_old_distribution);
   $opt_config_options.= " --disable-shared" if (!$opt_enable_shared); # Default for binary versions
   $opt_config_options.= " --with-berkeley-db" if ($opt_bdb);
+  $opt_config_options.= " --with-zlib-dir=bundled" if ($opt_bundled_zlib);
   $opt_config_options.= " --with-client-ldflags=-all-static" if ($opt_static_client);
 	$opt_config_options.= " --with-debug" if ($opt_with_debug);
   $opt_config_options.= " --with-libwrap" if ($opt_libwrap);