mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
config-win.h, os0proc.h, os0proc.c, srv0start.c:
Make AWE compilation depend on __WIN2000__ innobase/srv/srv0start.c: Make AWE compilation depend on __WIN2000__ innobase/os/os0proc.c: Make AWE compilation depend on __WIN2000__ innobase/include/os0proc.h: Make AWE compilation depend on __WIN2000__ include/config-win.h: Make AWE compilation depend on __WIN2000__
This commit is contained in:
@ -16,6 +16,12 @@
|
|||||||
|
|
||||||
/* Defines for Win32 to make it compatible for MySQL */
|
/* Defines for Win32 to make it compatible for MySQL */
|
||||||
|
|
||||||
|
#ifdef __WIN2000__
|
||||||
|
/* We have to do this define before including windows.h to get the AWE API
|
||||||
|
functions */
|
||||||
|
#define _WIN32_WINNT 0x0500
|
||||||
|
#endif
|
||||||
|
|
||||||
#include <sys/locking.h>
|
#include <sys/locking.h>
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
#include <math.h> /* Because of rint() */
|
#include <math.h> /* Because of rint() */
|
||||||
|
@ -16,7 +16,7 @@ typedef void* os_process_t;
|
|||||||
typedef unsigned long int os_process_id_t;
|
typedef unsigned long int os_process_id_t;
|
||||||
|
|
||||||
/* The cell type in os_awe_allocate_mem page info */
|
/* The cell type in os_awe_allocate_mem page info */
|
||||||
#if defined(__NT__) && defined(ULONG_PTR)
|
#if defined(__WIN2000__) && defined(ULONG_PTR)
|
||||||
typedef ULONG_PTR os_awe_t;
|
typedef ULONG_PTR os_awe_t;
|
||||||
#else
|
#else
|
||||||
typedef ulint os_awe_t;
|
typedef ulint os_awe_t;
|
||||||
|
@ -20,14 +20,14 @@ Created 9/30/1995 Heikki Tuuri
|
|||||||
How to get AWE to compile on Windows?
|
How to get AWE to compile on Windows?
|
||||||
-------------------------------------
|
-------------------------------------
|
||||||
|
|
||||||
the Visual C++ has to be relatively recent and _WIN32_WINNT has to be
|
In the project settings of the innobase project the Visual C++ source,
|
||||||
defined to a value >= 0x0500 when windows.h is included. An easy way
|
__WIN2000__ has to be defined.
|
||||||
to accomplish that is to put
|
|
||||||
|
The Visual C++ has to be relatively recent and _WIN32_WINNT has to be
|
||||||
|
defined to a value >= 0x0500 when windows.h is included.
|
||||||
|
|
||||||
#define _WIN32_WINNT 0x0500
|
#define _WIN32_WINNT 0x0500
|
||||||
|
|
||||||
to the start of file \mysql\include\config-win.h
|
|
||||||
|
|
||||||
Where does AWE work?
|
Where does AWE work?
|
||||||
-------------------
|
-------------------
|
||||||
|
|
||||||
@ -62,7 +62,7 @@ to a mapped 'physical page' for each 4 kB page in the AWE window */
|
|||||||
byte** os_awe_simulate_map;
|
byte** os_awe_simulate_map;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef __NT__
|
#ifdef __WIN2000__
|
||||||
os_awe_t* os_awe_page_info;
|
os_awe_t* os_awe_page_info;
|
||||||
ulint os_awe_n_pages;
|
ulint os_awe_n_pages;
|
||||||
byte* os_awe_window;
|
byte* os_awe_window;
|
||||||
@ -84,7 +84,7 @@ os_awe_enable_lock_pages_in_mem(void)
|
|||||||
|
|
||||||
return(TRUE);
|
return(TRUE);
|
||||||
|
|
||||||
#elif defined(__NT__)
|
#elif defined(__WIN2000__)
|
||||||
struct {
|
struct {
|
||||||
DWORD Count;
|
DWORD Count;
|
||||||
LUID_AND_ATTRIBUTES Privilege[1];
|
LUID_AND_ATTRIBUTES Privilege[1];
|
||||||
@ -187,7 +187,7 @@ os_awe_allocate_physical_mem(
|
|||||||
|
|
||||||
return(TRUE);
|
return(TRUE);
|
||||||
|
|
||||||
#elif defined(__NT__)
|
#elif defined(__WIN2000__)
|
||||||
BOOL bResult;
|
BOOL bResult;
|
||||||
os_awe_t NumberOfPages; /* Question: why does Windows
|
os_awe_t NumberOfPages; /* Question: why does Windows
|
||||||
use the name ULONG_PTR for
|
use the name ULONG_PTR for
|
||||||
@ -318,7 +318,7 @@ os_awe_allocate_virtual_mem_window(
|
|||||||
|
|
||||||
return(os_awe_simulate_window);
|
return(os_awe_simulate_window);
|
||||||
|
|
||||||
#elif defined(__NT__)
|
#elif defined(__WIN2000__)
|
||||||
byte* ptr;
|
byte* ptr;
|
||||||
|
|
||||||
if (size > 0x7FFFFFFFFF) {
|
if (size > 0x7FFFFFFFFF) {
|
||||||
@ -424,7 +424,7 @@ os_awe_map_physical_mem_to_window(
|
|||||||
|
|
||||||
return(TRUE);
|
return(TRUE);
|
||||||
|
|
||||||
#elif defined(__NT__)
|
#elif defined(__WIN2000__)
|
||||||
BOOL bResult;
|
BOOL bResult;
|
||||||
os_awe_t n_pages;
|
os_awe_t n_pages;
|
||||||
|
|
||||||
|
@ -1008,7 +1008,7 @@ innobase_start_or_create_for_mysql(void)
|
|||||||
srv_startup_is_before_trx_rollback_phase = TRUE;
|
srv_startup_is_before_trx_rollback_phase = TRUE;
|
||||||
os_aio_use_native_aio = FALSE;
|
os_aio_use_native_aio = FALSE;
|
||||||
|
|
||||||
#if !defined(__NT__) && !defined(UNIV_SIMULATE_AWE)
|
#if !defined(__WIN2000__) && !defined(UNIV_SIMULATE_AWE)
|
||||||
if (srv_use_awe) {
|
if (srv_use_awe) {
|
||||||
|
|
||||||
fprintf(stderr,
|
fprintf(stderr,
|
||||||
|
Reference in New Issue
Block a user