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
f586a85b
Commit
f586a85b
authored
May 12, 2004
by
tomas@mc05.(none)
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
portability/autoconf fixes
parent
6fb4bea1
Changes
14
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
36 additions
and
61 deletions
+36
-61
ndb/config/Defs.LINUX.x86.GCC.mk
ndb/config/Defs.LINUX.x86.GCC.mk
+7
-3
ndb/include/portlib/NdbMutex.h
ndb/include/portlib/NdbMutex.h
+0
-1
ndb/src/common/editline/unix.h
ndb/src/common/editline/unix.h
+1
-2
ndb/src/common/portlib/Makefile
ndb/src/common/portlib/Makefile
+5
-27
ndb/src/common/portlib/memtest/memtest.c
ndb/src/common/portlib/memtest/memtest.c
+1
-2
ndb/src/common/portlib/unix/NdbTCP.c
ndb/src/common/portlib/unix/NdbTCP.c
+16
-10
ndb/src/common/portlib/unix/NdbThread.c
ndb/src/common/portlib/unix/NdbThread.c
+1
-1
ndb/src/common/transporter/Makefile
ndb/src/common/transporter/Makefile
+1
-1
ndb/src/common/transporter/SHM_Transporter.cpp
ndb/src/common/transporter/SHM_Transporter.cpp
+1
-3
ndb/src/kernel/ndb-main/Main.cpp
ndb/src/kernel/ndb-main/Main.cpp
+0
-5
ndb/src/mgmsrv/Makefile
ndb/src/mgmsrv/Makefile
+0
-2
ndb/src/mgmsrv/MgmtSrvr.cpp
ndb/src/mgmsrv/MgmtSrvr.cpp
+1
-1
ndb/src/ndbapi/Ndb.cpp
ndb/src/ndbapi/Ndb.cpp
+2
-1
ndb/src/rep/Makefile
ndb/src/rep/Makefile
+0
-2
No files found.
ndb/config/Defs.LINUX.x86.GCC.mk
View file @
f586a85b
...
@@ -6,9 +6,11 @@ SHELL := /bin/sh
...
@@ -6,9 +6,11 @@ SHELL := /bin/sh
C++
:
= gcc$(GCC_VERSION)
C++
:
= gcc$(GCC_VERSION)
CC
:=
gcc
$(GCC_VERSION)
CC
:=
gcc
$(GCC_VERSION)
AR_RCS
:=
$(PURE)
ar rcs
AR_RCS
:=
$(PURE)
ar rcs
SO
:=
gcc
$(GCC_VERSION)
-shared
-lpthread
-o
SO
:=
gcc
$(GCC_VERSION)
-shared
-lpthread
-o
#SO := gcc$(GCC_VERSION) -shared -o
MAKEDEPEND
:=
gcc
$(GCC_VERSION)
-M
MAKEDEPEND
:=
gcc
$(GCC_VERSION)
-M
#MAKEDEPEND := gcc$(GCC_VERSION) -M -nostdinc -nostdinc++
PIC
:=
-fPIC
PIC
:=
-fPIC
RPCGENFLAGS
:=
-M
-C
-N
RPCGENFLAGS
:=
-M
-C
-N
...
@@ -27,7 +29,8 @@ else
...
@@ -27,7 +29,8 @@ else
CCFLAGS_WARNINGS
=
-Wno-long-long
-Wall
CCFLAGS_WARNINGS
=
-Wno-long-long
-Wall
endif
endif
# Add these for more warnings -Weffc++ -W
# Add these for more warnings -Weffc++ -W
CCFLAGS_TOP
=
-D_REENTRANT
-D_POSIX_PTHREAD_SEMANTICS
CCFLAGS_TOP
=
#CCFLAGS_TOP = -DSAFE_MUTEX
CCFLAGS_TOP
+=
-fno-rtti
-fno-exceptions
CCFLAGS_TOP
+=
-fno-rtti
-fno-exceptions
ifeq
(RELEASE, $(NDB_VERSION))
ifeq
(RELEASE, $(NDB_VERSION))
...
@@ -53,4 +56,5 @@ LINK.cc = $(PURE) $(CC) $(CCFLAGS) $(LDFLAGS)
...
@@ -53,4 +56,5 @@ LINK.cc = $(PURE) $(CC) $(CCFLAGS) $(LDFLAGS)
LINK.c
=
$(PURE)
$(CC)
$(CFLAGS)
$(LDFLAGS)
LINK.c
=
$(PURE)
$(CC)
$(CFLAGS)
$(LDFLAGS)
LDFLAGS_LAST
=
-lpthread
-lrt
$(NDB_TOP)
/src/common/portlib/gcc.cpp
LDFLAGS_LAST
=
-lrt
-lpthread
$(NDB_TOP)
/src/common/portlib/gcc.cpp
#LDFLAGS_LAST = -lrt $(NDB_TOP)/src/common/portlib/gcc.cpp $(NDB_TOP)/../mysys/libmysys.a $(NDB_TOP)/../dbug/libdbug.a $(NDB_TOP)/../regex/libregex.a $(NDB_TOP)/../strings/libmystrings.a -lpthread
ndb/include/portlib/NdbMutex.h
View file @
f586a85b
...
@@ -22,7 +22,6 @@
...
@@ -22,7 +22,6 @@
#ifdef NDB_WIN32
#ifdef NDB_WIN32
#include <winsock2.h>
#include <winsock2.h>
#include <ws2tcpip.h>
#include <ws2tcpip.h>
#include <windows.h>
#endif
#endif
#ifdef __cplusplus
#ifdef __cplusplus
...
...
ndb/src/common/editline/unix.h
View file @
f586a85b
...
@@ -21,6 +21,5 @@
...
@@ -21,6 +21,5 @@
#define CRLF "\r\n"
#define CRLF "\r\n"
#include <sys/types.h>
#include <ndb_global.h>
#include <sys/stat.h>
#include <dirent.h>
#include <dirent.h>
ndb/src/common/portlib/Makefile
View file @
f586a85b
...
@@ -4,38 +4,16 @@ DIRS :=
...
@@ -4,38 +4,16 @@ DIRS :=
ifeq
($(NDB_OS), SOFTOSE)
ifeq
($(NDB_OS), SOFTOSE)
DIRS
+=
ose
DIRS
+=
ose
endif
else
ifeq
($(NDB_OS), OSE)
ifeq
($(NDB_OS), OSE)
DIRS
+=
ose
DIRS
+=
ose
endif
else
ifeq
($(NDB_OS), WIN32)
ifeq
($(NDB_OS), SIMCELLO)
DIRS
+=
win32
DIRS
+=
ose
else
endif
ifeq
($(NDB_OS), LINUX)
DIRS
+=
unix
endif
ifeq
($(NDB_OS), MACOSX)
DIRS
+=
unix
endif
ifeq
($(NDB_OS), SOLARIS)
DIRS
+=
unix
DIRS
+=
unix
endif
endif
ifeq
($(NDB_OS), SOLARIS6)
DIRS
+=
unix
endif
endif
ifeq
($(NDB_OS), HPUX)
DIRS
+=
unix
endif
ifeq
($(NDB_OS), WIN32)
DIRS
+=
win32
endif
endif
...
...
ndb/src/common/portlib/memtest/memtest.c
View file @
f586a85b
...
@@ -17,8 +17,7 @@
...
@@ -17,8 +17,7 @@
#include <ndb_global.h>
#include <ndb_global.h>
#include <sys/time.h>
#include <sys/mman.h>
long
long
getMilli
();
long
long
getMilli
();
long
long
getMicro
();
long
long
getMicro
();
void
malloctest
(
int
loopcount
,
int
memsize
,
int
touch
);
void
malloctest
(
int
loopcount
,
int
memsize
,
int
touch
);
...
...
ndb/src/common/portlib/unix/NdbTCP.c
View file @
f586a85b
...
@@ -15,20 +15,26 @@
...
@@ -15,20 +15,26 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <NdbMutex.h>
#include "NdbTCP.h"
#include "NdbTCP.h"
#ifdef NDB_WIN32
static
NdbMutex
&
LOCK_gethostbyname
=
*
NdbMutex_Create
();
#else
static
NdbMutex
LOCK_gethostbyname
=
NDB_MUTEX_INITIALIZER
;
#endif
#ifdef NDB_SOLARIS
int
int
Ndb_getInAddr
(
struct
in_addr
*
dst
,
const
char
*
address
)
{
Ndb_getInAddr
(
struct
in_addr
*
dst
,
const
char
*
address
)
{
struct
hostent
host
,
*
hostPtr
;
struct
hostent
*
hostPtr
;
char
buf
[
1024
];
NdbMutex_Lock
(
&
LOCK_gethostbyname
);
int
h_errno
;
hostPtr
=
gethostbyname
(
address
);
hostPtr
=
gethostbyname_r
(
address
,
&
host
,
&
buf
[
0
],
1024
,
&
h_errno
);
if
(
hostPtr
!=
NULL
)
{
if
(
hostPtr
!=
NULL
)
{
dst
->
s_addr
=
((
struct
in_addr
*
)
*
hostPtr
->
h_addr_list
)
->
s_addr
;
dst
->
s_addr
=
((
struct
in_addr
*
)
*
hostPtr
->
h_addr_list
)
->
s_addr
;
NdbMutex_Unlock
(
&
LOCK_gethostbyname
);
return
0
;
return
0
;
}
}
NdbMutex_Unlock
(
&
LOCK_gethostbyname
);
/* Try it as aaa.bbb.ccc.ddd. */
/* Try it as aaa.bbb.ccc.ddd. */
dst
->
s_addr
=
inet_addr
(
address
);
dst
->
s_addr
=
inet_addr
(
address
);
...
@@ -37,13 +43,14 @@ Ndb_getInAddr(struct in_addr * dst, const char *address) {
...
@@ -37,13 +43,14 @@ Ndb_getInAddr(struct in_addr * dst, const char *address) {
}
}
return
-
1
;
return
-
1
;
}
}
#endif
#if
defined NDB_LINUX || defined NDB_HPUX || defined NDB_MACOSX
#if
0
int
int
Ndb_getInAddr(struct in_addr * dst, const char *address) {
Ndb_getInAddr(struct in_addr * dst, const char *address) {
struct
hostent
*
hostPtr
;
struct hostent host, * hostPtr;
hostPtr
=
gethostbyname
(
address
);
char buf[1024];
int h_errno;
hostPtr = gethostbyname_r(address, &host, &buf[0], 1024, &h_errno);
if (hostPtr != NULL) {
if (hostPtr != NULL) {
dst->s_addr = ((struct in_addr *) *hostPtr->h_addr_list)->s_addr;
dst->s_addr = ((struct in_addr *) *hostPtr->h_addr_list)->s_addr;
return 0;
return 0;
...
@@ -57,4 +64,3 @@ Ndb_getInAddr(struct in_addr * dst, const char *address) {
...
@@ -57,4 +64,3 @@ Ndb_getInAddr(struct in_addr * dst, const char *address) {
return -1;
return -1;
}
}
#endif
#endif
ndb/src/common/portlib/unix/NdbThread.c
View file @
f586a85b
...
@@ -17,7 +17,7 @@
...
@@ -17,7 +17,7 @@
#include <ndb_global.h>
#include <ndb_global.h>
#include <NdbThread.h>
#include <NdbThread.h>
#include <
my_
pthread.h>
#include <pthread.h>
#define MAX_THREAD_NAME 16
#define MAX_THREAD_NAME 16
...
...
ndb/src/common/transporter/Makefile
View file @
f586a85b
...
@@ -10,7 +10,6 @@ DIRS := basictest perftest
...
@@ -10,7 +10,6 @@ DIRS := basictest perftest
SOURCES
=
\
SOURCES
=
\
Transporter.cpp
\
Transporter.cpp
\
SendBuffer.cpp
\
SendBuffer.cpp
\
SHM_Transporter.cpp
\
TCP_Transporter.cpp
\
TCP_Transporter.cpp
\
TransporterRegistry.cpp
\
TransporterRegistry.cpp
\
Packer.cpp
Packer.cpp
...
@@ -22,6 +21,7 @@ CCFLAGS_LOC += -I$(call fixpath,$(NDB_TOP)/include/kernel) \
...
@@ -22,6 +21,7 @@ CCFLAGS_LOC += -I$(call fixpath,$(NDB_TOP)/include/kernel) \
ifeq
($(NDB_SHM), Y)
ifeq
($(NDB_SHM), Y)
SOURCES
+=
SHM_Transporter.cpp
ifeq
($(NDB_OS), WIN32)
ifeq
($(NDB_OS), WIN32)
SOURCES
+=
SHM_Transporter.win32.cpp
SOURCES
+=
SHM_Transporter.win32.cpp
else
else
...
...
ndb/src/common/transporter/SHM_Transporter.cpp
View file @
f586a85b
...
@@ -23,9 +23,7 @@
...
@@ -23,9 +23,7 @@
#include <NdbSleep.h>
#include <NdbSleep.h>
#include <NdbOut.hpp>
#include <NdbOut.hpp>
#ifdef NDB_WIN32
#ifndef NDB_WIN32
#include <windows.h>
#else
#include <sys/ipc.h>
#include <sys/ipc.h>
#include <sys/shm.h>
#include <sys/shm.h>
#endif
#endif
...
...
ndb/src/kernel/ndb-main/Main.cpp
View file @
f586a85b
...
@@ -78,10 +78,6 @@ NDB_MAIN(ndb_kernel){
...
@@ -78,10 +78,6 @@ NDB_MAIN(ndb_kernel){
char
homePath
[
255
];
char
homePath
[
255
];
NdbConfig_HomePath
(
homePath
,
255
);
NdbConfig_HomePath
(
homePath
,
255
);
#if defined (NDB_LINUX) || defined (NDB_SOLARIS)
/**
* This has only been tested with linux & solaris
*/
if
(
theConfig
->
getDaemonMode
())
{
if
(
theConfig
->
getDaemonMode
())
{
// Become a daemon
// Become a daemon
char
lockfile
[
255
],
logfile
[
255
];
char
lockfile
[
255
],
logfile
[
255
];
...
@@ -134,7 +130,6 @@ NDB_MAIN(ndb_kernel){
...
@@ -134,7 +130,6 @@ NDB_MAIN(ndb_kernel){
}
}
g_eventLogger
.
info
(
"Angel pid: %d ndb pid: %d"
,
getppid
(),
getpid
());
g_eventLogger
.
info
(
"Angel pid: %d ndb pid: %d"
,
getppid
(),
getpid
());
#endif
systemInfo
(
*
theConfig
,
systemInfo
(
*
theConfig
,
theConfig
->
clusterConfigurationData
().
SizeAltData
.
logLevel
);
theConfig
->
clusterConfigurationData
().
SizeAltData
.
logLevel
);
...
...
ndb/src/mgmsrv/Makefile
View file @
f586a85b
...
@@ -6,8 +6,6 @@ BIN_TARGET := mgmtsrvr
...
@@ -6,8 +6,6 @@ BIN_TARGET := mgmtsrvr
BIN_TARGET_LIBS
:=
BIN_TARGET_LIBS
:=
BIN_TARGET_ARCHIVES
:=
mgmapi NDB_API mgmsrvcommon
BIN_TARGET_ARCHIVES
:=
mgmapi NDB_API mgmsrvcommon
LDFLAGS_LOC
=
-lpthread
ifneq
($(USE_EDITLINE), N)
ifneq
($(USE_EDITLINE), N)
BIN_TARGET_ARCHIVES
+=
editline
BIN_TARGET_ARCHIVES
+=
editline
DIRS
:=
mkconfig
DIRS
:=
mkconfig
...
...
ndb/src/mgmsrv/MgmtSrvr.cpp
View file @
f586a85b
...
@@ -15,7 +15,7 @@
...
@@ -15,7 +15,7 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_global.h>
#include <ndb_global.h>
#include <
my_
pthread.h>
#include <pthread.h>
#include "MgmtSrvr.hpp"
#include "MgmtSrvr.hpp"
#include "MgmtErrorReporter.hpp"
#include "MgmtErrorReporter.hpp"
...
...
ndb/src/ndbapi/Ndb.cpp
View file @
f586a85b
...
@@ -22,6 +22,7 @@ Name: Ndb.cpp
...
@@ -22,6 +22,7 @@ Name: Ndb.cpp
******************************************************************************/
******************************************************************************/
#include <ndb_global.h>
#include <ndb_global.h>
#include <pthread.h>
#include "NdbApiSignal.hpp"
#include "NdbApiSignal.hpp"
#include "NdbImpl.hpp"
#include "NdbImpl.hpp"
...
@@ -1244,7 +1245,7 @@ Ndb::printState(const char* fmt, ...)
...
@@ -1244,7 +1245,7 @@ Ndb::printState(const char* fmt, ...)
NdbMutex_Lock
(
&
print_state_mutex
);
NdbMutex_Lock
(
&
print_state_mutex
);
bool
dups
=
false
;
bool
dups
=
false
;
ndbout
<<
buf
<<
" ndb="
<<
hex
<<
this
<<
dec
;
ndbout
<<
buf
<<
" ndb="
<<
hex
<<
this
<<
dec
;
#if
def NDB_LINUX
#if
ndef NDB_WIN32
ndbout
<<
" thread="
<<
(
int
)
pthread_self
();
ndbout
<<
" thread="
<<
(
int
)
pthread_self
();
#endif
#endif
ndbout
<<
endl
;
ndbout
<<
endl
;
...
...
ndb/src/rep/Makefile
View file @
f586a85b
...
@@ -12,8 +12,6 @@ BIN_TARGET := ndb_rep
...
@@ -12,8 +12,6 @@ BIN_TARGET := ndb_rep
BIN_TARGET_LIBS
:=
BIN_TARGET_LIBS
:=
BIN_TARGET_ARCHIVES
+=
editline repstorage repadapters reprequestor reptransfer mgmapi NDB_API mgmsrvcommon
BIN_TARGET_ARCHIVES
+=
editline repstorage repadapters reprequestor reptransfer mgmapi NDB_API mgmsrvcommon
LDFLAGS_LOC
=
-lpthread
SOURCES
=
\
SOURCES
=
\
RepMain.cpp
\
RepMain.cpp
\
Requestor.cpp
\
Requestor.cpp
\
...
...
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