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
db020fb3
Commit
db020fb3
authored
May 11, 2009
by
unknown
Browse files
Options
Browse Files
Download
Plain Diff
Merge Toby Thain's Solaris fixes.
parents
b125770a
13c45ccb
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
102 additions
and
161 deletions
+102
-161
BUILD/SETUP.sh
BUILD/SETUP.sh
+7
-1
BUILD/compile-solaris-amd64
BUILD/compile-solaris-amd64
+27
-50
BUILD/compile-solaris-amd64-debug
BUILD/compile-solaris-amd64-debug
+7
-6
BUILD/compile-solaris-amd64-forte
BUILD/compile-solaris-amd64-forte
+23
-47
BUILD/compile-solaris-amd64-forte-debug
BUILD/compile-solaris-amd64-forte-debug
+19
-46
storage/innobase/include/univ.i
storage/innobase/include/univ.i
+3
-3
storage/pbxt/src/Makefile.am
storage/pbxt/src/Makefile.am
+1
-1
storage/pbxt/src/lock_xt.h
storage/pbxt/src/lock_xt.h
+2
-2
storage/pbxt/src/pbms.h
storage/pbxt/src/pbms.h
+13
-5
No files found.
BUILD/SETUP.sh
View file @
db020fb3
...
@@ -80,7 +80,13 @@ path=`dirname $0`
...
@@ -80,7 +80,13 @@ path=`dirname $0`
.
"
$path
/check-cpu"
.
"
$path
/check-cpu"
export
AM_MAKEFLAGS
export
AM_MAKEFLAGS
AM_MAKEFLAGS
=
"-j 6"
# Default to a parallel build, but only if AM_MAKEFLAGS is not set.
# (So buildbots can easily disable this behaviour if required.)
if
test
-z
"
$AM_MAKEFLAGS
"
then
AM_MAKEFLAGS
=
"-j 6"
fi
# SSL library to use.--with-ssl will select our bundled yaSSL
# SSL library to use.--with-ssl will select our bundled yaSSL
# implementation of SSL. To use openSSl you will nee too point out
# implementation of SSL. To use openSSl you will nee too point out
...
...
BUILD/compile-solaris-amd64
View file @
db020fb3
#!/
usr/bin/ba
sh
#!/
bin/
sh
function
_find_mysql_root
()
(
# Build setup for Solaris 10
while
[
"x
$PWD
"
!=
"x/"
]
;
do
# Check if some directories are present
# Make the Sun Freeware packages use the bundled Perl, instead of their own:
if
[
-d
BUILD
-a
-d
sql
-a
-d
mysys
]
;
then
# ln -s `which perl` /usr/local/bin
echo
"
$PWD
"
# Your $PATH needs to include (in this order):
return
0
# /usr/local/bin:/usr/sfw/bin:/usr/ccs/bin
fi
# (For Sun Freeware, bundled GNU utilities, Solaris ar, etc.)
cd
..
#
done
# Required packages from http://sunfreeware.com/indexintel10.html :
return
1
# (The GNU m4 bundled with Solaris is too old.)
)
# automake-1.10.2-sol10-x86-local.gz
# autoconf-2.63-sol10-x86-local.gz
# m4-1.4.12-sol10-x86-local.gz
# libsigsegv-2.6-sol10-x86-local.gz
# libtool-1.5.24-sol10-x86-local.gz
# ( how to install these packages:
# wget ftp://ftp.sunfreeware.com/pub/freeware/intel/10/automake-1.10.2-sol10-x86-local.gz
# gunzip automake-1.10.2-sol10-x86-local.gz
# pkgadd -d automake-1.10.2-sol10-x86-local
# )
make
-k
clean
||
true
/bin/rm
-f
*
/.deps/
*
.P config.cache
path
=
`
dirname
$0
`
path
=
`
dirname
$0
`
.
"
$path
/autorun.sh"
.
"
$path
/SETUP.sh"
extra_flags
=
"
$amd64_cflags
-D__sun -m64 -mtune=athlon64"
warning_flags
=
"-Wimplicit -Wreturn-type -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wparentheses -Wsign-compare -Wwrite-strings -Wunused"
extra_configs
=
"
$amd64_configs
$max_configs
--with-libevent"
compiler_flags
=
"-g -O3 -fno-omit-frame-pointer"
export
CC CXX CFLAGS CXXFLAGS LDFLAGS LIBS
LDFLAGS
=
"-lmtmalloc -static-libgcc"
CC
=
"gcc"
export
LDFLAGS
CXX
=
"gcc"
CFLAGS
=
"
$warning_flags
$compiler_flags
"
CXXFLAGS
=
""
LDFLAGS
=
"-O3 -g -static-libgcc"
LIBS
=
-lmtmalloc
root
=
$(
_find_mysql_root
)
$root
/configure
\
.
"
$path
/FINISH.sh"
--prefix
=
/usr/local/mysql
\
--localstatedir
=
/usr/local/mysql/data
\
--libexecdir
=
/usr/local/mysql/bin
\
--with-extra-charsets
=
complex
\
--enable-thread-safe-client
\
--enable-local-infile
\
--with-zlib-dir
=
bundled
\
--with-big-tables
\
--with-readline
\
--with-archive-storage-engine
\
--with-named-curses
=
-lcurses
\
--with-big-tables
\
--with-innodb
\
--with-berkeley-db
\
--with-example-storage-engine
\
--with-blackhole-storage-engine
\
--with-ndbcluster
\
--with-federated-storage-engine
\
--with-csv-storage-engine
\
--with-ssl
\
--with-embedded-server
\
--disable-shared
BUILD/compile-solaris-amd64-debug
100644 → 100755
View file @
db020fb3
#! /bin/sh
#!/bin/sh
path
=
`
dirname
$0
`
path
=
`
dirname
$0
`
.
"
$path
/SETUP.sh"
.
"
$path
/SETUP.sh"
amd64_cflags
=
"-m64 -mtune=athlon64
"
extra_flags
=
"
$amd64_cflags
-D__sun -m64 -mtune=athlon64
$debug_cflags
"
extra_
flags
=
"
$amd64_cflags
$debug_cflags
$max_cflags
"
extra_
configs
=
"
$amd64_configs
$debug_configs
$max_configs
--with-libevent
"
c_warnings
=
"
$c_warnings
$debug_extra_warnings
"
cxx_warnings
=
"
$cxx_warnings
$debug_extra_warnings
"
LDFLAGS
=
"-lmtmalloc -static-libgcc
"
ex
tra_configs
=
"
$amd64_configs
$debug_configs
$max_configs
--enable-thread-safe-client"
ex
port
LDFLAGS
.
"
$path
/FINISH.sh"
.
"
$path
/FINISH.sh"
BUILD/compile-solaris-amd64-forte
View file @
db020fb3
#!
/bin/sh
#!/bin/sh
gmake
-k
clean
||
true
# See file compile-solaris-amd64 for basic pre-requisites.
/bin/rm
-f
*
/.deps/
*
.P config.cache
# This build uses the Sun Studio compilers (cc, CC), available from:
path
=
`
dirname
$0
`
# http://developers.sun.com/sunstudio/downloads/index.jsp
.
"
$path
/autorun.sh"
# Note that you may want to apply current patches, as the downloaded version
# is typically out of date. Download the PKG version if you intend to patch!
# After installing, add /opt/SUNWspro/bin to your $PATH
# For "optimal" code for this computer add -fast to EXTRA
# To compile 64 bit, add -m64 to EXTRA_64_BIT
EXTRA_64_BIT
=
"-m64"
path
=
`
dirname
$0
`
EXTRA
=
"-fast"
.
"
$path
/SETUP.sh"
extra_flags
=
"-m64 -mt -D_FORTEC_ -xbuiltin=%all -xlibmil -xlibmopt -fns=no -xprefetch=auto -xprefetch_level=3"
extra_configs
=
"
$max_configs
--with-libevent"
#
warnings
=
""
# The following should not need to be touched
c_warnings
=
""
#
cxx_warnings
=
""
base_cxxflags
=
"-noex"
export
CC CXX CFLAGS CXXFLAGS LIBS
CC
=
cc
STD
=
"-g -mt -D_FORTEC_
$EXTRA
$EXTRA_64_BIT
"
CFLAGS
=
"-xstrconst"
ASFLAGS
=
"
$EXTRA_64_BIT
"
CC
=
cc-5.0
CFLAGS
=
"-Xa -xstrconst
$STD
"
CXX
=
CC
CXX
=
CC
CXXFLAGS
=
"-noex
$STD
"
LDFLAGS
=
"-lmtmalloc"
LIBS
=
-lmtmalloc
./configure
\
.
"
$path
/FINISH.sh"
--prefix
=
/usr/local/mysql
\
--localstatedir
=
/usr/local/mysql/data
\
--libexecdir
=
/usr/local/mysql/bin
\
--with-extra-charsets
=
complex
\
--enable-thread-safe-client
\
--enable-local-infile
\
--with-zlib-dir
=
bundled
\
--with-big-tables
\
--with-readline
\
--with-archive-storage-engine
\
--with-named-curses
=
-lcurses
\
--with-big-tables
\
--with-innodb
\
--with-example-storage-engine
\
--with-blackhole-storage-engine
\
--with-federated-storage-engine
\
--with-csv-storage-engine
\
--with-ssl
\
--enable-assembler
# Not including:
# --with-ndbcluster
# --with-berkeley-db
gmake
-j4
test
$?
=
0
&&
make
test
BUILD/compile-solaris-amd64-forte-debug
100644 → 100755
View file @
db020fb3
#!
/bin/sh
#!/bin/sh
gmake
-k
clean
||
true
/bin/rm
-f
*
/.deps/
*
.P config.cache
path
=
`
dirname
$0
`
path
=
`
dirname
$0
`
.
"
$path
/
autorun
.sh"
.
"
$path
/
SETUP
.sh"
# To compile 64 bit, add -m64 to EXTRA_64_BIT
# Take only #define options - the others are gcc specific.
EXTRA_64_BIT
=
"-m64"
# (real fix is for SETUP.sh not to put gcc specific options in $debug_cflags)
DEFS
=
""
for
F
in
$debug_cflags
;
do
expr
"
$F
"
:
"^-D"
&&
DEFS
=
"
$DEFS
$F
"
done
debug_cflags
=
"-O0 -g
$DEFS
"
# For "optimal" code for this computer add -fast to EXTRA. Note that
extra_flags
=
"-m64 -mt -D_FORTEC_ -xlibmopt -fns=no
$debug_cflags
"
# this causes problem with debugging the program since -fast implies
extra_configs
=
"
$max_configs
--with-libevent
$debug_configs
"
# -xO5.
EXTRA
=
""
#
warnings
=
""
# The following should not need to be touched
c_warnings
=
""
#
cxx_warnings
=
""
base_cxxflags
=
"-noex"
export
CC CXX CFLAGS CXXFLAGS
CC
=
cc
STD
=
"-g -mt -D_FORTEC_
$EXTRA
$EXTRA_64_BIT
$debug_cflags
"
CFLAGS
=
"-xstrconst"
ASFLAGS
=
"
$EXTRA_64_BIT
"
CC
=
cc-5.0
CFLAGS
=
"-Xa -xstrconst
$STD
"
CXX
=
CC
CXX
=
CC
CXXFLAGS
=
"-noex
$STD
"
LDFLAGS
=
"-lmtmalloc"
./configure
\
--prefix
=
/usr/local/mysql
\
--localstatedir
=
/usr/local/mysql/data
\
--libexecdir
=
/usr/local/mysql/bin
\
--with-extra-charsets
=
complex
\
--enable-thread-safe-client
\
--enable-local-infile
\
--with-zlib-dir
=
bundled
\
--with-big-tables
\
--with-readline
\
--with-archive-storage-engine
\
--with-named-curses
=
-lcurses
\
--with-big-tables
\
--with-innodb
\
--with-example-storage-engine
\
--with-blackhole-storage-engine
\
--with-federated-storage-engine
\
--with-csv-storage-engine
\
--with-ssl
\
--with-debug
\
--enable-assembler
# Not including:
.
"
$path
/FINISH.sh"
# --with-ndbcluster
# --with-berkeley-db
gmake
-j4
storage/innobase/include/univ.i
View file @
db020fb3
...
@@ -55,10 +55,10 @@ of the 32-bit x86 assembler in mutex operations. */
...
@@ -55,10 +55,10 @@ of the 32-bit x86 assembler in mutex operations. */
#
define
UNIV_CAN_USE_X86_ASSEMBLER
#
define
UNIV_CAN_USE_X86_ASSEMBLER
#
endif
#
endif
/*
We only try to do explicit inlining of functions with gcc and
/*
Enable explicit inlining of functions only for compilers known to
Microsoft Visual C++
*/
support it.
*/
#
if
!
defined
(
__GNUC__
)
#
if
!
defined
(
__GNUC__
)
&
&
!defined(__SUNPRO_C)
#
undef
UNIV_MUST_NOT_INLINE
/* Remove compiler warning */
#
undef
UNIV_MUST_NOT_INLINE
/* Remove compiler warning */
#
define
UNIV_MUST_NOT_INLINE
#
define
UNIV_MUST_NOT_INLINE
#
endif
#
endif
...
...
storage/pbxt/src/Makefile.am
View file @
db020fb3
...
@@ -46,7 +46,7 @@ libpbxt_la_CFLAGS = $(AM_CFLAGS) -DMYSQL_DYNAMIC_PLUGIN -std=c99
...
@@ -46,7 +46,7 @@ libpbxt_la_CFLAGS = $(AM_CFLAGS) -DMYSQL_DYNAMIC_PLUGIN -std=c99
EXTRA_LIBRARIES
=
libpbxt.a
EXTRA_LIBRARIES
=
libpbxt.a
noinst_LIBRARIES
=
libpbxt.a
noinst_LIBRARIES
=
libpbxt.a
libpbxt_a_SOURCES
=
$(libpbxt_la_SOURCES)
libpbxt_a_SOURCES
=
$(libpbxt_la_SOURCES)
libpbxt_a_CXXFLAGS
=
$(AM_CXXFLAGS)
-Wno-long-long
libpbxt_a_CXXFLAGS
=
$(AM_CXXFLAGS)
libpbxt_a_CFLAGS
=
$(AM_CFLAGS)
-std
=
c99
libpbxt_a_CFLAGS
=
$(AM_CFLAGS)
-std
=
c99
EXTRA_DIST
=
CMakeLists.txt
EXTRA_DIST
=
CMakeLists.txt
storage/pbxt/src/lock_xt.h
View file @
db020fb3
...
@@ -208,9 +208,9 @@ inline void xt_atomic_dec2(volatile xtWord2 *mptr)
...
@@ -208,9 +208,9 @@ inline void xt_atomic_dec2(volatile xtWord2 *mptr)
#elif defined(__GNUC__)
#elif defined(__GNUC__)
__sync_fetch_and_sub
(
mptr
,
1
);
__sync_fetch_and_sub
(
mptr
,
1
);
#elif defined(XT_SPL_SOLARIS_LIB)
#elif defined(XT_SPL_SOLARIS_LIB)
val1
=
atomic_dec_16_nv
(
mptr
);
atomic_dec_16_nv
(
mptr
);
#else
#else
val1
=
--
(
*
mptr
);
--
(
*
mptr
);
#endif
#endif
}
}
...
...
storage/pbxt/src/pbms.h
View file @
db020fb3
...
@@ -782,21 +782,28 @@ private:
...
@@ -782,21 +782,28 @@ private:
void
deleteTempFiles
()
void
deleteTempFiles
()
{
{
struct
dirent
entry
;
struct
dirent
*
entry
;
struct
dirent
*
result
;
struct
dirent
*
result
;
DIR
*
odir
;
DIR
*
odir
;
int
err
;
int
err
;
size_t
sz
;
char
temp_file
[
100
];
char
temp_file
[
100
];
#ifdef XT_SOLARIS
sz
=
sizeof
(
struct
dirent
)
+
pathconf
(
"/tmp/"
,
_PC_NAME_MAX
);
// Solaris, see readdir(3C)
#else
sz
=
sizeof
(
struct
dirent
);
#endif
entry
=
(
struct
dirent
*
)
malloc
(
sz
);
if
(
!
(
odir
=
opendir
(
"/tmp/"
)))
if
(
!
(
odir
=
opendir
(
"/tmp/"
)))
return
;
return
;
err
=
readdir_r
(
odir
,
&
entry
,
&
result
);
err
=
readdir_r
(
odir
,
entry
,
&
result
);
while
(
!
err
&&
result
)
{
while
(
!
err
&&
result
)
{
const
char
**
prefix
=
temp_prefix
;
const
char
**
prefix
=
temp_prefix
;
while
(
*
prefix
)
{
while
(
*
prefix
)
{
if
(
startsWith
(
entry
.
d_name
,
*
prefix
))
{
if
(
startsWith
(
entry
->
d_name
,
*
prefix
))
{
int
pid
=
atoi
(
entry
.
d_name
+
strlen
(
*
prefix
));
int
pid
=
atoi
(
entry
->
d_name
+
strlen
(
*
prefix
));
/* If the process does not exist: */
/* If the process does not exist: */
if
(
kill
(
pid
,
0
)
==
-
1
&&
errno
==
ESRCH
)
{
if
(
kill
(
pid
,
0
)
==
-
1
&&
errno
==
ESRCH
)
{
...
@@ -807,9 +814,10 @@ private:
...
@@ -807,9 +814,10 @@ private:
prefix
++
;
prefix
++
;
}
}
err
=
readdir_r
(
odir
,
&
entry
,
&
result
);
err
=
readdir_r
(
odir
,
entry
,
&
result
);
}
}
closedir
(
odir
);
closedir
(
odir
);
free
(
entry
);
}
}
};
};
#endif // PBMS_API
#endif // PBMS_API
...
...
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