Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mariadb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
a20976ff
Commit
a20976ff
authored
Feb 07, 2006
by
jmiller@mysql.com
Browse files
Options
Browse Files
Download
Plain Diff
Merge jmiller@bk-internal.mysql.com:/home/bk/mysql-5.1-new
into mysql.com:/home/ndbdev/jmiller/clones/mysql-5.1-new
parents
54e07cea
e0553b78
Changes
25
Show whitespace changes
Inline
Side-by-side
Showing
25 changed files
with
212 additions
and
94 deletions
+212
-94
mysql-test/r/information_schema.result
mysql-test/r/information_schema.result
+1
-1
mysql-test/r/information_schema_db.result
mysql-test/r/information_schema_db.result
+1
-1
mysql-test/r/join_nested.result
mysql-test/r/join_nested.result
+23
-0
mysql-test/r/rpl_ignore_table.result
mysql-test/r/rpl_ignore_table.result
+16
-0
mysql-test/t/join_nested.test
mysql-test/t/join_nested.test
+28
-0
mysql-test/t/rpl_ignore_table-slave.opt
mysql-test/t/rpl_ignore_table-slave.opt
+1
-0
mysql-test/t/rpl_ignore_table.test
mysql-test/t/rpl_ignore_table.test
+28
-0
mysys/my_init.c
mysys/my_init.c
+1
-0
sql/ha_archive.cc
sql/ha_archive.cc
+8
-11
sql/ha_ndbcluster.cc
sql/ha_ndbcluster.cc
+1
-0
sql/sql_partition.cc
sql/sql_partition.cc
+14
-8
sql/sql_select.cc
sql/sql_select.cc
+2
-1
sql/sql_show.cc
sql/sql_show.cc
+2
-2
sql/table.h
sql/table.h
+2
-2
win/cmakefiles/base
win/cmakefiles/base
+21
-6
win/cmakefiles/client
win/cmakefiles/client
+3
-1
win/cmakefiles/dbug
win/cmakefiles/dbug
+2
-2
win/cmakefiles/extra
win/cmakefiles/extra
+2
-2
win/cmakefiles/myisam
win/cmakefiles/myisam
+2
-2
win/cmakefiles/myisammrg
win/cmakefiles/myisammrg
+2
-2
win/cmakefiles/regex
win/cmakefiles/regex
+2
-4
win/cmakefiles/sql
win/cmakefiles/sql
+42
-39
win/cmakefiles/taocrypt
win/cmakefiles/taocrypt
+4
-0
win/cmakefiles/vio
win/cmakefiles/vio
+2
-5
win/cmakefiles/zlib
win/cmakefiles/zlib
+2
-5
No files found.
mysql-test/r/information_schema.result
View file @
a20976ff
...
...
@@ -57,8 +57,8 @@ TABLES
TABLE_CONSTRAINTS
TABLE_PRIVILEGES
TRIGGERS
VIEWS
USER_PRIVILEGES
VIEWS
binlog_index
columns_priv
db
...
...
mysql-test/r/information_schema_db.result
View file @
a20976ff
...
...
@@ -20,8 +20,8 @@ TABLES
TABLE_CONSTRAINTS
TABLE_PRIVILEGES
TRIGGERS
VIEWS
USER_PRIVILEGES
VIEWS
show tables from INFORMATION_SCHEMA like 'T%';
Tables_in_information_schema (T%)
TABLES
...
...
mysql-test/r/join_nested.result
View file @
a20976ff
...
...
@@ -1481,3 +1481,26 @@ id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t2 ref a a 5 test.t1.a 1
1 SIMPLE t3 ref a a 5 test.t2.a 1
drop table t1, t2, t3;
CREATE TABLE t1 (id int NOT NULL PRIMARY KEY, type varchar(10));
CREATE TABLE t2 (pid int NOT NULL PRIMARY KEY, type varchar(10));
CREATE TABLE t3 (cid int NOT NULL PRIMARY KEY,
id int NOT NULL,
pid int NOT NULL);
INSERT INTO t1 VALUES (1, 'A'), (3, 'C');
INSERT INTO t2 VALUES (1, 'A'), (3, 'C');
INSERT INTO t3 VALUES (1, 1, 1), (3, 3, 3);
SELECT * FROM t1 p LEFT JOIN (t3 JOIN t1)
ON (t1.id=t3.id AND t1.type='B' AND p.id=t3.id)
LEFT JOIN t2 ON (t3.pid=t2.pid)
WHERE p.id=1;
id type cid id pid id type pid type
1 A NULL NULL NULL NULL NULL NULL NULL
CREATE VIEW v1 AS
SELECT t3.* FROM t3 JOIN t1 ON t1.id=t3.id AND t1.type='B';
SELECT * FROM t1 p LEFT JOIN v1 ON p.id=v1.id
LEFT JOIN t2 ON v1.pid=t2.pid
WHERE p.id=1;
id type cid id pid pid type
1 A NULL NULL NULL NULL NULL
DROP VIEW v1;
DROP TABLE t1,t2,t3;
mysql-test/r/rpl_ignore_table.result
0 → 100644
View file @
a20976ff
stop slave;
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
reset master;
reset slave;
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
start slave;
**** Test case for BUG#16487 ****
**** Master ****
CREATE TABLE test.t4 (a int);
CREATE TABLE test.t1 (a int);
UPDATE test.t4 NATURAL JOIN test.t1 SET t1.a=5;
**** Slave ****
SELECT * FROM t4;
a
DROP TABLE t1;
DROP TABLE t4;
mysql-test/t/join_nested.test
View file @
a20976ff
...
...
@@ -914,3 +914,31 @@ explain select * from t1 left join
on
(
t1
.
a
=
t2
.
a
);
drop
table
t1
,
t2
,
t3
;
#
# Bug #16260: single row table in the inner nest of an outer join
#
CREATE
TABLE
t1
(
id
int
NOT
NULL
PRIMARY
KEY
,
type
varchar
(
10
));
CREATE
TABLE
t2
(
pid
int
NOT
NULL
PRIMARY
KEY
,
type
varchar
(
10
));
CREATE
TABLE
t3
(
cid
int
NOT
NULL
PRIMARY
KEY
,
id
int
NOT
NULL
,
pid
int
NOT
NULL
);
INSERT
INTO
t1
VALUES
(
1
,
'A'
),
(
3
,
'C'
);
INSERT
INTO
t2
VALUES
(
1
,
'A'
),
(
3
,
'C'
);
INSERT
INTO
t3
VALUES
(
1
,
1
,
1
),
(
3
,
3
,
3
);
SELECT
*
FROM
t1
p
LEFT
JOIN
(
t3
JOIN
t1
)
ON
(
t1
.
id
=
t3
.
id
AND
t1
.
type
=
'B'
AND
p
.
id
=
t3
.
id
)
LEFT
JOIN
t2
ON
(
t3
.
pid
=
t2
.
pid
)
WHERE
p
.
id
=
1
;
CREATE
VIEW
v1
AS
SELECT
t3
.*
FROM
t3
JOIN
t1
ON
t1
.
id
=
t3
.
id
AND
t1
.
type
=
'B'
;
SELECT
*
FROM
t1
p
LEFT
JOIN
v1
ON
p
.
id
=
v1
.
id
LEFT
JOIN
t2
ON
v1
.
pid
=
t2
.
pid
WHERE
p
.
id
=
1
;
DROP
VIEW
v1
;
DROP
TABLE
t1
,
t2
,
t3
;
mysql-test/t/rpl_ignore_table-slave.opt
0 → 100644
View file @
a20976ff
--replicate-ignore-table=test.t1 --replicate-ignore-table=test.t2 --replicate-ignore-table=test.t3
mysql-test/t/rpl_ignore_table.test
0 → 100644
View file @
a20976ff
source
include
/
master
-
slave
.
inc
;
#
# BUG#16487
#
# Requirement:
# Multi-updates on ignored tables should not fail even if the slave does
# not have the ignored tables.
#
# Note table t1, t2, and t3 are ignored in the option file to this test.
#
--
echo
****
Test
case
for
BUG
#16487 ****
--
echo
****
Master
****
connection
master
;
CREATE
TABLE
test
.
t4
(
a
int
);
CREATE
TABLE
test
.
t1
(
a
int
);
# Expect: The row must *not* by updated on slave, since t1 is ignored
UPDATE
test
.
t4
NATURAL
JOIN
test
.
t1
SET
t1
.
a
=
5
;
--
echo
****
Slave
****
sync_slave_with_master
;
SELECT
*
FROM
t4
;
connection
master
;
DROP
TABLE
t1
;
DROP
TABLE
t4
;
mysys/my_init.c
View file @
a20976ff
...
...
@@ -152,6 +152,7 @@ void my_end(int infoflag)
DBUG_PRINT
(
"error"
,(
"%s"
,
errbuff
[
0
]));
}
}
free_charsets
();
my_once_free
();
if
((
infoflag
&
MY_GIVE_INFO
)
||
print_info
)
...
...
sql/ha_archive.cc
View file @
a20976ff
...
...
@@ -520,7 +520,7 @@ const char **ha_archive::bas_ext() const
Init out lock.
We open the file we will read from.
*/
int
ha_archive
::
open
(
const
char
*
name
,
int
mode
,
uint
test_if_locked
)
int
ha_archive
::
open
(
const
char
*
name
,
int
mode
,
uint
open_options
)
{
DBUG_ENTER
(
"ha_archive::open"
);
...
...
@@ -535,7 +535,10 @@ int ha_archive::open(const char *name, int mode, uint test_if_locked)
DBUG_RETURN
(
HA_ERR_CRASHED_ON_USAGE
);
}
if
(
open_options
&
HA_OPEN_FOR_REPAIR
)
DBUG_RETURN
(
0
);
DBUG_RETURN
(
share
->
crashed
?
HA_ERR_CRASHED_ON_USAGE
:
0
);
}
...
...
@@ -1340,7 +1343,8 @@ int ha_archive::delete_all_rows()
*/
bool
ha_archive
::
is_crashed
()
const
{
return
share
->
crashed
;
DBUG_ENTER
(
"ha_archive::is_crashed"
);
DBUG_RETURN
(
share
->
crashed
);
}
/*
...
...
@@ -1402,12 +1406,5 @@ bool ha_archive::check_and_repair(THD *thd)
check_opt
.
init
();
if
(
check
(
thd
,
&
check_opt
)
==
HA_ADMIN_CORRUPT
)
{
DBUG_RETURN
(
repair
(
thd
,
&
check_opt
));
}
else
{
DBUG_RETURN
(
HA_ADMIN_OK
);
}
}
sql/ha_ndbcluster.cc
View file @
a20976ff
...
...
@@ -9592,6 +9592,7 @@ bool ha_ndbcluster::get_no_parts(const char *name, uint *no_parts)
break
;
}
ndb
=
get_ndb
();
ndb
->
setDatabaseName
(
m_dbname
);
dict
=
ndb
->
getDictionary
();
if
(
!
(
tab
=
dict
->
getTable
(
m_tabname
)))
ERR_BREAK
(
dict
->
getNdbError
(),
err
);
...
...
sql/sql_partition.cc
View file @
a20976ff
...
...
@@ -250,14 +250,14 @@ char *are_partitions_in_table(partition_info *new_part_info,
FALSE Success
*/
bool
partition_default_handling
(
TABLE
*
table
,
partition_info
*
part_info
)
bool
partition_default_handling
(
TABLE
*
table
,
partition_info
*
part_info
,
const
char
*
normalized_path
)
{
DBUG_ENTER
(
"partition_default_handling"
);
if
(
part_info
->
use_default_no_partitions
)
{
if
(
table
->
file
->
get_no_parts
(
table
->
s
->
normalized_path
.
str
,
&
part_info
->
no_parts
))
if
(
table
->
file
->
get_no_parts
(
normalized_path
,
&
part_info
->
no_parts
))
{
DBUG_RETURN
(
TRUE
);
}
...
...
@@ -266,8 +266,7 @@ bool partition_default_handling(TABLE *table, partition_info *part_info)
part_info
->
use_default_no_subpartitions
)
{
uint
no_parts
;
if
(
table
->
file
->
get_no_parts
(
table
->
s
->
normalized_path
.
str
,
&
no_parts
))
if
(
table
->
file
->
get_no_parts
(
normalized_path
,
&
no_parts
))
{
DBUG_RETURN
(
TRUE
);
}
...
...
@@ -2005,7 +2004,8 @@ bool fix_partition_func(THD *thd, const char* name, TABLE *table,
if
(
!
is_create_table_ind
)
{
if
(
partition_default_handling
(
table
,
part_info
))
if
(
partition_default_handling
(
table
,
part_info
,
table
->
s
->
normalized_path
.
str
))
{
DBUG_RETURN
(
TRUE
);
}
...
...
@@ -3901,9 +3901,15 @@ bool mysql_unpack_partition(THD *thd, const uchar *part_buf,
old_lex->name contains the t2 and the table we are opening has
name t1.
*/
if
(
partition_default_handling
(
table
,
part_info
))
Table_ident
*
table_ident
=
(
Table_ident
*
)
old_lex
->
name
;
char
*
src_db
=
table_ident
->
db
.
str
?
table_ident
->
db
.
str
:
thd
->
db
;
char
*
src_table
=
table_ident
->
table
.
str
;
char
buf
[
FN_REFLEN
];
build_table_filename
(
buf
,
sizeof
(
buf
),
src_db
,
src_table
,
""
);
if
(
partition_default_handling
(
table
,
part_info
,
buf
))
{
DBUG_RETURN
(
TRUE
);
result
=
TRUE
;
goto
end
;
}
}
else
...
...
sql/sql_select.cc
View file @
a20976ff
...
...
@@ -2214,7 +2214,8 @@ make_join_statistics(JOIN *join, TABLE_LIST *tables, COND *conds,
if
(
eq_part
.
is_prefix
(
table
->
key_info
[
key
].
key_parts
)
&&
((
table
->
key_info
[
key
].
flags
&
(
HA_NOSAME
|
HA_END_SPACE_KEY
))
==
HA_NOSAME
)
&&
!
table
->
fulltext_searched
)
!
table
->
fulltext_searched
&&
!
table
->
pos_in_table_list
->
embedding
)
{
if
(
const_ref
==
eq_part
)
{
// Found everything for ref.
...
...
sql/sql_show.cc
View file @
a20976ff
...
...
@@ -5073,12 +5073,12 @@ ST_SCHEMA_TABLE schema_tables[]=
fill_schema_table_privileges
,
0
,
0
,
-
1
,
-
1
,
0
},
{
"TRIGGERS"
,
triggers_fields_info
,
create_schema_table
,
get_all_tables
,
make_old_format
,
get_schema_triggers_record
,
5
,
6
,
0
},
{
"USER_PRIVILEGES"
,
user_privileges_fields_info
,
create_schema_table
,
fill_schema_user_privileges
,
0
,
0
,
-
1
,
-
1
,
0
},
{
"VARIABLES"
,
variables_fields_info
,
create_schema_table
,
fill_variables
,
make_old_format
,
0
,
-
1
,
-
1
,
1
},
{
"VIEWS"
,
view_fields_info
,
create_schema_table
,
get_all_tables
,
0
,
get_schema_views_record
,
1
,
2
,
0
},
{
"USER_PRIVILEGES"
,
user_privileges_fields_info
,
create_schema_table
,
fill_schema_user_privileges
,
0
,
0
,
-
1
,
-
1
,
0
},
{
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
}
};
...
...
sql/table.h
View file @
a20976ff
...
...
@@ -354,9 +354,9 @@ enum enum_schema_tables
SCH_TABLE_NAMES
,
SCH_TABLE_PRIVILEGES
,
SCH_TRIGGERS
,
SCH_USER_PRIVILEGES
,
SCH_VARIABLES
,
SCH_VIEWS
,
SCH_USER_PRIVILEGES
SCH_VIEWS
};
...
...
win/cmakefiles/base
View file @
a20976ff
...
...
@@ -2,12 +2,27 @@ PROJECT(MySql)
EXEC_PROGRAM(cscript.exe win ARGS config-version.js OUT_VARIABLE out)
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /wd4996 -D_DEBUG")
SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} /wd4996 -D_DEBUG")
# in some places we use DBUG_OFF
SET(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -D DBUG_OFF")
SET(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} -D DBUG_OFF")
IF(CMAKE_GENERATOR MATCHES "Visual Studio 7" OR CMAKE_GENERATOR MATCHES "Visual Studio 8")
# replace /MDd with /MTd
STRING(REPLACE "/MDd" "/MTd" CMAKE_CXX_FLAGS_DEBUG_INIT ${CMAKE_CXX_FLAGS_DEBUG_INIT})
STRING(REPLACE "/MDd" "/MTd" CMAKE_C_FLAGS_DEBUG_INIT ${CMAKE_C_FLAGS_DEBUG_INIT})
STRING(REPLACE "/MD" "/MT" CMAKE_C_FLAGS_RELEASE ${CMAKE_C_FLAGS_RELEASE})
STRING(REPLACE "/MDd" "/MTd" CMAKE_C_FLAGS_DEBUG ${CMAKE_C_FLAGS_DEBUG})
STRING(REPLACE "/MD" "/MT" CMAKE_CXX_FLAGS_RELEASE ${CMAKE_CXX_FLAGS_RELEASE})
STRING(REPLACE "/MDd" "/MTd" CMAKE_CXX_FLAGS_DEBUG ${CMAKE_CXX_FLAGS_DEBUG})
# remove support for Exception handling
STRING(REPLACE "/GX" "" CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS})
STRING(REPLACE "/EHsc" "" CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS})
STRING(REPLACE "/EHsc" "" CMAKE_CXX_FLAGS_INIT ${CMAKE_CXX_FLAGS_INIT})
STRING(REPLACE "/EHsc" "" CMAKE_CXX_FLAGS_DEBUG_INIT ${CMAKE_CXX_FLAGS_DEBUG_INIT})
ENDIF(CMAKE_GENERATOR MATCHES "Visual Studio 7" OR CMAKE_GENERATOR MATCHES "Visual Studio 8")
SET(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /wd4996 -DDBUG_OFF -DNDEBUG")
SET(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} /wd4996 -DDBUG_OFF -DNDEBUG")
ADD_DEFINITIONS("-D_WINDOWS -D__WIN__")
SUBDIRS(vio dbug strings regex mysys zlib storage/innobase storage/heap storage/myisam storage/myisammrg
extra
extra
/yassl extra/yassl/taocrypt client sql)
SUBDIRS(vio dbug strings regex mysys
extra
zlib storage/innobase storage/heap storage/myisam storage/myisammrg
extra/yassl extra/yassl/taocrypt client sql)
win/cmakefiles/client
View file @
a20976ff
...
...
@@ -3,6 +3,7 @@ SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX")
ADD_DEFINITIONS(-DUSE_TLS -DMYSQL_CLIENT)
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include ${CMAKE_SOURCE_DIR}/zlib ${CMAKE_SOURCE_DIR}/extra/yassl/include ${CMAKE_SOURCE_DIR}/libmysql)
ADD_LIBRARY(mysqlclient ../mysys/array.c ../strings/bchange.c ../strings/bmove.c
../strings/bmove_upp.c ../mysys/charset-def.c ../mysys/charset.c
../sql-common/client.c ../strings/ctype-big5.c ../strings/ctype-bin.c
...
...
@@ -38,8 +39,9 @@ ADD_LIBRARY(mysqlclient ../mysys/array.c ../strings/bchange.c ../strings/bmove.c
../strings/strtoll.c ../strings/strtoull.c ../strings/strxmov.c ../strings/strxnmov.c
../mysys/thr_mutex.c ../mysys/typelib.c ../vio/vio.c ../vio/viosocket.c
../vio/viossl.c ../vio/viosslfactories.c ../strings/xml.c
${
CMAKE
_SOURCE_DIR}/include/mysql_version.h)
${
PROJECT
_SOURCE_DIR}/include/mysql_version.h)
ADD_DEPENDENCIES(mysqlclient comp_err)
ADD_EXECUTABLE(mysql completion_hash.cc mysql.cc readline.cc sql_string.cc)
LINK_DIRECTORIES(${MYSQL_BINARY_DIR}/mysys ${MYSQL_BINARY_DIR}/zlib)
TARGET_LINK_LIBRARIES(mysql mysqlclient mysys yassl zlib dbug yassl taocrypt wsock32)
win/cmakefiles/dbug
View file @
a20976ff
SET(CMAKE_CXX_FLAGS_DEBUG "-DSAFEMALLOC -DSAFE_MUTEX -D__WIN32__")
SET(CMAKE_C_FLAGS_DEBUG "-DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_CXX_FLAGS_DEBUG "
${CMAKE_CXX_FLAGS_DEBUG}
-DSAFEMALLOC -DSAFE_MUTEX -D__WIN32__")
SET(CMAKE_C_FLAGS_DEBUG "
${CMAKE_C_FLAGS_DEBUG}
-DSAFEMALLOC -DSAFE_MUTEX")
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include)
ADD_LIBRARY(dbug dbug.c factorial.c sanity.c)
win/cmakefiles/extra
View file @
a20976ff
SET(CMAKE_CXX_FLAGS_DEBUG "-DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_C_FLAGS_DEBUG "-DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_CXX_FLAGS_DEBUG "
${CMAKE_CXX_FLAGS_DEBUG}
-DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_C_FLAGS_DEBUG "
${CMAKE_C_FLAGS_DEBUG}
-DSAFEMALLOC -DSAFE_MUTEX")
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include)
...
...
win/cmakefiles/myisam
View file @
a20976ff
SET(CMAKE_CXX_FLAGS_DEBUG "-DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_C_FLAGS_DEBUG "-DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_CXX_FLAGS_DEBUG "
${CMAKE_CXX_FLAGS_DEBUG}
-DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_C_FLAGS_DEBUG "
${CMAKE_C_FLAGS_DEBUG}
-DSAFEMALLOC -DSAFE_MUTEX")
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include)
ADD_LIBRARY(myisam ft_boolean_search.c ft_nlq_search.c ft_parser.c ft_static.c ft_stem.c
...
...
win/cmakefiles/myisammrg
View file @
a20976ff
SET(CMAKE_CXX_FLAGS_DEBUG "-DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_C_FLAGS_DEBUG "-DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_CXX_FLAGS_DEBUG "
${CMAKE_CXX_FLAGS_DEBUG}
-DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_C_FLAGS_DEBUG "
${CMAKE_C_FLAGS_DEBUG}
-DSAFEMALLOC -DSAFE_MUTEX")
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include)
ADD_LIBRARY(myisammrg myrg_close.c myrg_create.c myrg_delete.c myrg_extra.c myrg_info.c
...
...
win/cmakefiles/regex
View file @
a20976ff
SET(CMAKE_C_FLAGS_DEBUG "-D_DEBUG -DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_CXX_FLAGS_DEBUG "-D_DEBUG -DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_C_FLAGS_RELEASE "-DDBUG_OFF -DNDEBUG")
SET(CMAKE_CXX_FLAGS_RELEASE "-DDBUG_OFF -DNDEBUG")
SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -D_DEBUG -DSAFEMALLOC -DSAFE_MUTEX")
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -D_DEBUG -DSAFEMALLOC -DSAFE_MUTEX")
ADD_DEFINITIONS(-D_WINDOWS -D__WIN__)
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include)
...
...
win/cmakefiles/sql
View file @
a20976ff
...
...
@@ -7,12 +7,13 @@ SET_SOURCE_FILES_PROPERTIES(${CMAKE_SOURCE_DIR}/sql/message.rc
${CMAKE_SOURCE_DIR}/sql/message.h
${CMAKE_SOURCE_DIR}/sql/sql_yacc.h
${CMAKE_SOURCE_DIR}/sql/sql_yacc.cc
${CMAKE_SOURCE_DIR}/include/mysqld_error.h
${CMAKE_SOURCE_DIR}/include/mysqld_ername.h
${CMAKE_SOURCE_DIR}/include/sql_state.h
${CMAKE_SOURCE_DIR}/include/mysql_version.h
${CMAKE_SOURCE_DIR}/sql/handlerton.cc
${CMAKE_SOURCE_DIR}/sql/lex_hash.h PROPERTIES GENERATED 1)
${CMAKE_SOURCE_DIR}/sql/lex_hash.h
${PROJECT_SOURCE_DIR}/include/mysqld_error.h
${PROJECT_SOURCE_DIR}/include/mysqld_ername.h
${PROJECT_SOURCE_DIR}/include/sql_state.h PROPERTIES GENERATED 1)
ADD_DEFINITIONS(-DWITH_INNOBASE_STORAGE_ENGINE -DHAVE_ARCHIVE_DB -DHAVE_BLACKHOLE_DB -DHAVE_EXAMPLE_DB)
ADD_DEFINITIONS(-DHAVE_ROW_BASED_REPLICATION -DHAVE_FEDERATED_DB -DMYSQL_SERVER -D_CONSOLE -DHAVE_DLOPEN -DWITH_PARTITION_STORAGE_ENGINE -D_CRT_SECURE_NO_DEPRECATE)
...
...
@@ -36,27 +37,27 @@ ADD_EXECUTABLE(mysqld ../sql-common/client.c derror.cc des_key_file.cc discover.
sql_update.cc sql_view.cc sql_yacc.h sql_yacc.cc strfunc.cc table.cc thr_malloc.cc time.cc tztime.cc
uniques.cc unireg.cc item_xmlfunc.cc rpl_tblmap.cc sql_binlog.cc event_executor.cc
event_timed.cc sql_tablespace.cc event.cc ../sql-common/my_user.c
${
CMAKE
_SOURCE_DIR}/sql/sql_yacc.cc
${
CMAKE
_SOURCE_DIR}/sql/sql_yacc.h
${
CMAKE
_SOURCE_DIR}/include/mysqld_error.h
${
CMAKE
_SOURCE_DIR}/include/mysqld_ername.h
${
CMAKE
_SOURCE_DIR}/include/sql_state.h
${
CMAKE
_SOURCE_DIR}/include/mysql_version.h
${
CMAKE
_SOURCE_DIR}/sql/handlerton.cc
${
CMAKE
_SOURCE_DIR}/sql/lex_hash.h)
${
PROJECT
_SOURCE_DIR}/sql/sql_yacc.cc
${
PROJECT
_SOURCE_DIR}/sql/sql_yacc.h
${
PROJECT
_SOURCE_DIR}/include/mysqld_error.h
${
PROJECT
_SOURCE_DIR}/include/mysqld_ername.h
${
PROJECT
_SOURCE_DIR}/include/sql_state.h
${
PROJECT
_SOURCE_DIR}/include/mysql_version.h
${
PROJECT
_SOURCE_DIR}/sql/handlerton.cc
${
PROJECT
_SOURCE_DIR}/sql/lex_hash.h)
TARGET_LINK_LIBRARIES(mysqld heap myisam myisammrg innobase mysys yassl zlib dbug yassl taocrypt strings vio regex wsock32)
# Sql Parser custom command
ADD_CUSTOM_COMMAND(
SOURCE ${
CMAKE
_SOURCE_DIR}/sql/sql_yacc.yy
OUTPUT ${
CMAKE
_SOURCE_DIR}/sql/sql_yacc.cc
SOURCE ${
PROJECT
_SOURCE_DIR}/sql/sql_yacc.yy
OUTPUT ${
PROJECT
_SOURCE_DIR}/sql/sql_yacc.cc
COMMAND bison.exe ARGS --defines=sql_yacc.h --output=sql_yacc.cc sql_yacc.yy
DEPENDS ${
CMAKE
_SOURCE_DIR}/sql/sql_yacc.yy)
DEPENDS ${
PROJECT
_SOURCE_DIR}/sql/sql_yacc.yy)
ADD_CUSTOM_COMMAND(
OUTPUT ${
CMAKE
_SOURCE_DIR}/sql/sql_yacc.h
OUTPUT ${
PROJECT
_SOURCE_DIR}/sql/sql_yacc.h
COMMAND echo
DEPENDS ${
CMAKE
_SOURCE_DIR}/sql/sql_yacc.cc
DEPENDS ${
PROJECT
_SOURCE_DIR}/sql/sql_yacc.cc
)
# Windows message file
...
...
@@ -67,43 +68,43 @@ ADD_CUSTOM_COMMAND(
DEPENDS ../VC++Files/sql/message.mc)
# MySql_version.h.
ADD_CUSTOM_COMMAND(
SOURCE ${CMAKE
_SOURCE_DIR}/include/mysql_version.h.in
OUTPUT ${CMAKE
_SOURCE_DIR}/include/mysql_version.h
COMMAND ${CMAKE
_SOURCE_DIR}/win/config-version.js
DEPENDS ${CMAKE
_SOURCE_DIR}/include/mysql_version.h.in)
#
ADD_CUSTOM_COMMAND(
# SOURCE ${PROJECT
_SOURCE_DIR}/include/mysql_version.h.in
# OUTPUT ${PROJECT
_SOURCE_DIR}/include/mysql_version.h
# COMMAND ${PROJECT
_SOURCE_DIR}/win/config-version.js
# DEPENDS ${PROJECT
_SOURCE_DIR}/include/mysql_version.h.in)
# Handlerton file
ADD_CUSTOM_COMMAND(
SOURCE ${
CMAKE
_SOURCE_DIR}/sql/handlerton.cc.in
OUTPUT ${
CMAKE
_SOURCE_DIR}/sql/handlerton.cc
COMMAND ${
CMAKE_SOURCE_DIR}/win/config-handlerton.js ARGS ${CMAKE
_SOURCE_DIR}/win/configure.data
DEPENDS ${
CMAKE
_SOURCE_DIR}/sql/handlerton.cc.in)
SOURCE ${
PROJECT
_SOURCE_DIR}/sql/handlerton.cc.in
OUTPUT ${
PROJECT
_SOURCE_DIR}/sql/handlerton.cc
COMMAND ${
PROJECT_SOURCE_DIR}/win/config-handlerton.js ARGS ${PROJECT
_SOURCE_DIR}/win/configure.data
DEPENDS ${
PROJECT
_SOURCE_DIR}/sql/handlerton.cc.in)
# Error file
GET_TARGET_PROPERTY(COMP_ERR_EXE comp_err LOCATION)
ADD_CUSTOM_COMMAND(
SOURCE ${
CMAKE
_SOURCE_DIR}/sql/share/errmsg.txt
OUTPUT ${
CMAKE
_SOURCE_DIR}/include/mysqld_error.h
SOURCE ${
PROJECT
_SOURCE_DIR}/sql/share/errmsg.txt
OUTPUT ${
PROJECT
_SOURCE_DIR}/include/mysqld_error.h
COMMAND ${COMP_ERR_EXE}
ARGS --charset=${
CMAKE
_SOURCE_DIR}/sql/share/charsets
--out-dir=${
CMAKE
_SOURCE_DIR}/sql/share/
--header_file=${
CMAKE
_SOURCE_DIR}/include/mysqld_error.h
--name_file=${
CMAKE
_SOURCE_DIR}/include/mysqld_ername.h
--state_file=${
CMAKE
_SOURCE_DIR}/include/sql_state.h
--in_file=${
CMAKE
_SOURCE_DIR}/sql/share/errmsg.txt
ARGS --charset=${
PROJECT
_SOURCE_DIR}/sql/share/charsets
--out-dir=${
PROJECT
_SOURCE_DIR}/sql/share/
--header_file=${
PROJECT
_SOURCE_DIR}/include/mysqld_error.h
--name_file=${
PROJECT
_SOURCE_DIR}/include/mysqld_ername.h
--state_file=${
PROJECT
_SOURCE_DIR}/include/sql_state.h
--in_file=${
PROJECT
_SOURCE_DIR}/sql/share/errmsg.txt
DEPENDS ${COMP_ERR_EXE} share/errmsg.txt)
ADD_CUSTOM_COMMAND(
OUTPUT ${
CMAKE
_SOURCE_DIR}/include/mysqld_ername.h
OUTPUT ${
PROJECT
_SOURCE_DIR}/include/mysqld_ername.h
COMMAND echo
DEPENDS ${
CMAKE
_SOURCE_DIR}/include/mysqld_error.h
DEPENDS ${
PROJECT
_SOURCE_DIR}/include/mysqld_error.h
)
ADD_CUSTOM_COMMAND(
OUTPUT ${
CMAKE
_SOURCE_DIR}/include/sql_state.h
OUTPUT ${
PROJECT
_SOURCE_DIR}/include/sql_state.h
COMMAND echo
DEPENDS ${
CMAKE
_SOURCE_DIR}/include/mysqld_ername.h
DEPENDS ${
PROJECT
_SOURCE_DIR}/include/mysqld_ername.h
)
...
...
@@ -112,7 +113,9 @@ ADD_EXECUTABLE(gen_lex_hash gen_lex_hash.cc)
TARGET_LINK_LIBRARIES(gen_lex_hash dbug mysqlclient wsock32)
GET_TARGET_PROPERTY(GEN_LEX_HASH_EXE gen_lex_hash LOCATION)
ADD_CUSTOM_COMMAND(
OUTPUT ${
CMAKE
_SOURCE_DIR}/sql/lex_hash.h
OUTPUT ${
PROJECT
_SOURCE_DIR}/sql/lex_hash.h
COMMAND ${GEN_LEX_HASH_EXE} ARGS > lex_hash.h
DEPENDS ${GEN_LEX_HASH_EXE}
)
ADD_DEPENDENCIES(mysqld gen_lex_hash)
win/cmakefiles/taocrypt
View file @
a20976ff
INCLUDE_DIRECTORIES(../mySTL include)
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /GX-")
SET(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /GX-")
ADD_LIBRARY(taocrypt src/aes.cpp src/aestables.cpp src/algebra.cpp src/arc4.cpp src/asn.cpp src/coding.cpp
src/des.cpp src/dh.cpp src/dsa.cpp src/file.cpp src/hash.cpp src/integer.cpp src/md2.cpp
src/md5.cpp src/misc.cpp src/random.cpp src/ripemd.cpp src/rsa.cpp src/sha.cpp
...
...
win/cmakefiles/vio
View file @
a20976ff
SET(CMAKE_CXX_FLAGS_DEBUG "-D_DEBUG -DSAFEMALLOC -DSAFE_MUTEX -DUSE_SYMDIR")
SET(CMAKE_C_FLAGS_DEBUG "-D_DEBUG -DSAFEMALLOC -DSAFE_MUTEX -DUSE_SYMDIR")
SET(CMAKE_CXX_FLAGS_RELEASE "-DDBUG_OFF -DNDEBUG")
SET(CMAKE_C_FLAGS_RELEASE "-DDBUG_OFF -DNDEBUG")
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -D_DEBUG -DSAFEMALLOC -DSAFE_MUTEX -DUSE_SYMDIR")
SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -D_DEBUG -DSAFEMALLOC -DSAFE_MUTEX -DUSE_SYMDIR")
ADD_DEFINITIONS(-D_WINDOWS -D__WIN__)
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include ${CMAKE_SOURCE_DIR}/extra/yassl/include)
...
...
win/cmakefiles/zlib
View file @
a20976ff
SET(CMAKE_CXX_FLAGS_DEBUG "-D_DEBUG __WIN32__")
SET(CMAKE_C_FLAGS_DEBUG "-D_DEBUG __WIN32__")
SET(CMAKE_CXX_FLAGS_RELEASE "-DDBUG_OFF -DNDEBUG")
SET(CMAKE_C_FLAGS_RELEASE "-DDBUG_OFF -DNDEBUG")
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -D_DEBUG -D __WIN32__")
SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -D_DEBUG -D __WIN32__")
ADD_DEFINITIONS(-DUSE_TLS -DMYSQL_CLIENT -D_WINDOWS -D__WIN__)
ADD_LIBRARY(zlib adler32.c compress.c crc32.c crc32.h deflate.c deflate.h gzio.c infback.c inffast.c inffast.h
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment