Commit 534c3f32 authored by tsmith@ramayana.hindu.god's avatar tsmith@ramayana.hindu.god
Browse files

Merge tsmith@bk-internal.mysql.com:/home/bk/mysql-5.0-opt

into  ramayana.hindu.god:/home/tsmith/m/bk/maint/50
parents 0233a793 181da565
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -6,6 +6,7 @@
*.bin
*.vcproj.cmake
cmake_install.cmake
*.cdf
*.core
*.d
*.da
+32 −6
Original line number Diff line number Diff line
@@ -139,21 +139,47 @@ ENDIF(CMAKE_GENERATOR MATCHES "Visual Studio 7" OR
ADD_DEFINITIONS("-D_WINDOWS -D__WIN__ -D _CRT_SECURE_NO_DEPRECATE")

IF(EMBED_MANIFESTS)
    # Search for the Manifest tool.  CMake will first search it's defaults
    # (CMAKE_FRAMEWORK_PATH, CMAKE_APPBUNDLE_PATH, CMAKE_PROGRAM_PATH and
    # the system PATH) followed by the listed paths which are the current
    # possible defaults and should be updated when necessary.  The custom
    # manifests are designed to be compatible with all mt versions.
    # Search for the tools (mt, makecat, signtool) necessary for embedding
    # manifests and signing executables with the MySQL AB authenticode cert.
    #
    # CMake will first search it's defaults (CMAKE_FRAMEWORK_PATH, 
    # CMAKE_APPBUNDLE_PATH, CMAKE_PROGRAM_PATH and the system PATH) followed 
    # by the listed paths which are the current possible defaults and should be
    # updated when necessary.  
    # 
    # The custom manifests are designed to be compatible with all mt versions.
    # The MySQL AB Authenticode certificate is available only internally.  
    # Others should store a single signing certificate in a local cryptographic
    # service provider and alter the signtool command as necessary.
    FIND_PROGRAM(HAVE_MANIFEST_TOOL NAMES mt
                 PATHS
                 "$ENV{PROGRAMFILES}/Microsoft Visual Studio 8/VC/bin"
                 "$ENV{PROGRAMFILES}/Microsoft Visual Studio 8/Common7/Tools/Bin"
                 "$ENV{PROGRAMFILES}/Microsoft Visual Studio 8/SDK/v2.0/Bin")
    FIND_PROGRAM(HAVE_CATALOG_TOOL NAMES makecat
                 PATHS
                 "$ENV{PROGRAMFILES}/Microsoft Visual Studio 8/Common7/Tools/Bin")
    FIND_PROGRAM(HAVE_SIGN_TOOL NAMES signtool
                 PATHS
                 "$ENV{PROGRAMFILES}/Microsoft Visual Studio 8/Common7/Tools/Bin"
                 "$ENV{PROGRAMFILES}/Microsoft Visual Studio 8/SDK/v2.0/Bin")

    IF(HAVE_MANIFEST_TOOL)
        MESSAGE(STATUS "Found Mainfest Tool. Embedding custom manifests.")
        MESSAGE(STATUS "Found Mainfest Tool.")
    ELSE(HAVE_MANIFEST_TOOL)
        MESSAGE(FATAL_ERROR "Manifest tool, mt.exe, can't be found.")
    ENDIF(HAVE_MANIFEST_TOOL)
    IF(HAVE_CATALOG_TOOL)
        MESSAGE(STATUS "Found Catalog Tool.")
    ELSE(HAVE_CATALOG_TOOL)
        MESSAGE(FATAL_ERROR "Catalog tool, makecat.exe, can't be found.")
    ENDIF(HAVE_CATALOG_TOOL)
    IF(HAVE_SIGN_TOOL)
        MESSAGE(STATUS "Found Sign Tool. Embedding custom manifests and signing executables.")
    ELSE(HAVE_SIGN_TOOL)
        MESSAGE(FATAL_ERROR "Sign tool, signtool.exe, can't be found.")
    ENDIF(HAVE_SIGN_TOOL)

    # Disable automatic manifest generation.
    STRING(REPLACE "/MANIFEST" "/MANIFEST:NO" CMAKE_EXE_LINKER_FLAGS 
    	   ${CMAKE_EXE_LINKER_FLAGS})
+1 −2
Original line number Diff line number Diff line
@@ -20,6 +20,7 @@ AUTOMAKE_OPTIONS = foreign
# These are built from source in the Docs directory
EXTRA_DIST =		INSTALL-SOURCE INSTALL-WIN-SOURCE \
			README COPYING EXCEPTIONS-CLIENT CMakeLists.txt

SUBDIRS =		. include @docs_dirs@ @zlib_dir@ @yassl_dir@ \
			@readline_topdir@ sql-common scripts \
			@thread_dirs@ pstack \
@@ -157,8 +158,6 @@ test-bt:
	@PERL@ ./mysql-test-run.pl --force --comment=funcs1_ps --ps-protocol --suite=funcs_1
	-cd mysql-test ; MTR_BUILD_THREAD=auto \
	@PERL@ ./mysql-test-run.pl --force --comment=funcs2 --suite=funcs_2
	-cd mysql-test ; MTR_BUILD_THREAD=auto \
	@PERL@ ./mysql-test-run.pl --force --comment=rowlock --suite=row_lock
	-if [ -d mysql-test/suite/nist ] ; then \
	  cd mysql-test ; MTR_BUILD_THREAD=auto \
	  @PERL@ ./mysql-test-run.pl --comment=NIST+normal --force --suite=nist ; \
+1 −3
Original line number Diff line number Diff line
@@ -15,9 +15,7 @@

## Process this file with automake to create Makefile.in

EXTRA_DIST=	NOTES cacert.pem client-cert.pem client-key.pem \
		run-client run-server server-cert.pem \
		server-key.pem
EXTRA_DIST= NOTES run-client run-server

# Don't update the files from bitkeeper
%::SCCS/s.%
+27 −3
Original line number Diff line number Diff line
@@ -992,6 +992,21 @@ static int mysql_query_with_error_report(MYSQL *mysql_con, MYSQL_RES **res,
  return 0;
}


static int switch_character_set_results(MYSQL *mysql, const char *cs_name)
{
  char query_buffer[QUERY_LENGTH];
  size_t query_length;

  query_length= my_snprintf(query_buffer,
                            sizeof (query_buffer),
                            "SET SESSION character_set_results = '%s'",
                            (const char *) cs_name);

  return mysql_real_query(mysql, query_buffer, query_length);
}


/*
  Open a new .sql file to dump the table or view into

@@ -1671,7 +1686,10 @@ static uint get_table_structure(char *table, char *db, char *table_type,
      MYSQL_FIELD *field;

      my_snprintf(buff, sizeof(buff), "show create table %s", result_table);
      if (mysql_query_with_error_report(mysql, 0, buff))

      if (switch_character_set_results(mysql, "binary") ||
          mysql_query_with_error_report(mysql, &result, buff) ||
          switch_character_set_results(mysql, default_charset))
        DBUG_RETURN(0);

      if (path)
@@ -1702,7 +1720,6 @@ static uint get_table_structure(char *table, char *db, char *table_type,
        check_io(sql_file);
      }

      result= mysql_store_result(mysql);
      field= mysql_fetch_field_direct(result, 0);
      if (strcmp(field->name, "View") == 0)
      {
@@ -1794,7 +1811,14 @@ static uint get_table_structure(char *table, char *db, char *table_type,
      }

      row= mysql_fetch_row(result);
      fprintf(sql_file, "%s;\n", row[1]);

      fprintf(sql_file,
              "SET @saved_cs_client     = @@character_set_client;\n"
              "SET character_set_client = utf8;\n"
              "%s;\n"
              "SET character_set_client = @saved_cs_client;\n",
              row[1]);

      check_io(sql_file);
      mysql_free_result(result);
    }
Loading