8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-02-02 08:00:39 +01:00

Allowing using SERVICE_THREAD in CLASSIC server as platform option

This commit is contained in:
kkuznetsov 2005-08-24 12:12:23 +00:00
parent f54415ab37
commit d65fb07878
7 changed files with 37 additions and 5 deletions

View File

@ -271,6 +271,11 @@ global:
isc_service_detach;
isc_service_query;
isc_service_start;
#functions called by utils
SVC_putc;
SVC_finish;
SVC_output;
CMD_UTIL_put_svc_status;
# Transaction control functions

View File

@ -1,4 +1,4 @@
CS_SRV_TH=@service_thread_CS@
#________________________________________________________________________
#
@ -136,6 +136,11 @@ GPRELIB_Objects = $(addprefix $(OBJ)/, $(addsuffix .o, $(basename $(GPRELIB_Sour
ALICE_Files=
ifeq ($(ArchType),super)
ALICE_Files=alice.cpp all.cpp exe.cpp alice_meta.epp tdr.cpp
else
ifeq ($(CS_SRV_TH),true)
ALICE_Files=alice.cpp all.cpp exe.cpp alice_meta.epp tdr.cpp
endif
endif
ALICE_Sources = $(addprefix alice/, $(ALICE_Files))
@ -148,6 +153,10 @@ ALICE_Objects = $(addprefix $(OBJ)/, $(addsuffix .o, $(basename $(ALICE_Sources)
BURP_Files=
ifeq ($(ArchType),super)
BURP_Files=burp.cpp backup.epp restore.epp mvol.cpp misc.cpp canonical.cpp
else
ifeq ($(CS_SRV_TH),true)
BURP_Files=burp.cpp backup.epp restore.epp mvol.cpp misc.cpp canonical.cpp
endif
endif
BURP_Sources = $(addprefix burp/, $(BURP_Files))
@ -168,6 +177,13 @@ ifeq ($(ArchType),super)
SECURITY_ServerFiles_gsec:= $(SECURITY_ServerFiles_gsec) gsec.cpp
SECURITY_ServerFiles_gstat:= $(SECURITY_ServerFiles_gstat) dba.epp ppg.cpp
SECURITY_ServerFiles_common:= $(SECURITY_ServerFiles_common) cmd_util.cpp
else
ifeq ($(CS_SRV_TH),true)
SECURITY_ServerFiles_gsec:= $(SECURITY_ServerFiles_gsec) gsec.cpp
SECURITY_ServerFiles_gstat:= $(SECURITY_ServerFiles_gstat) dba.epp ppg.cpp
SECURITY_ServerFiles_common:= $(SECURITY_ServerFiles_common) cmd_util.cpp
endif
endif
SECURITY_Files_gsec = $(SECURITY_ClientFiles_gsec) $(SECURITY_ServerFiles_gsec)

View File

@ -54,7 +54,7 @@ DEV_FLAGS= $(CFLAGS_COMMON) $(SFIO_FLAGS) $(COMMON_GCC_FLAGS) $(DEBUG_GCC_FLAGS)
$(LOCAL_CFLAGS)
# extra modules needed on this platform during bootstrap phase
JRDBOOT_Extra_Files=isc_sync.cpp ThreadData.cpp
JRDBOOT_Extra_Files=isc_sync.cpp ThreadData.cpp os/posix/isc_ipc.cpp
OS_ServerFiles=inet_server.cpp

View File

@ -35,6 +35,11 @@ dnl Use /usr/lib for library links on most platforms except some 64-bit ones
libdir=/usr/lib
ICU_PLATFORM=LinuxRedHat
dnl Should Classic Server run services as thread or as process?
dnl Default - run as processes (empty value).
service_thread_CS=""
case "$target" in
*-*-darwin*)
MAKEFILE_PREFIX=darwin
@ -124,6 +129,7 @@ case "$target" in
PTHREAD_CFLAGS=-threads
PTHREAD_LIBS=-lthread
ICU_PLATFORM=SOLARISX86GCC
service_thread_CS=true
;;
sparc-sun-solaris*)
@ -137,6 +143,7 @@ case "$target" in
PTHREAD_CFLAGS=-threads
PTHREAD_LIBS=-lthread
ICU_PLATFORM=SOLARISGCC
service_thread_CS=true
;;
i*-sni-sysv4)
@ -173,6 +180,7 @@ AC_SUBST(MAKEFILE_PREFIX)
AC_SUBST(PLATFORM)
AC_SUBST(SHRLIB_EXT)
AC_SUBST(ICU_PLATFORM)
AC_SUBST(service_thread_CS)
AC_DEFINE(CASE_SENSITIVITY, false, [Define this if paths are case sensitive])

View File

@ -31,6 +31,7 @@ namespace Jrd {
class thread_db;
}
extern "C" {
Jrd::Service* SVC_attach(USHORT, const TEXT*, USHORT, const SCHAR*);
void SVC_cleanup(Jrd::Service*);
void SVC_detach(Jrd::Service*);
@ -50,6 +51,7 @@ int SVC_output(Jrd::Service*, const UCHAR*);
typedef void (*shutdown_fct_t) (ULONG);
void SVC_shutdown_init(shutdown_fct_t, ULONG);
#endif /* SERVER_SHUTDOWN */
} //extern "C"
#endif /* JRD_SVC_PROTO_H */

View File

@ -43,7 +43,7 @@
#include "../jrd/svc.h"
#include "../jrd/svc_proto.h"
#include "cmd_util_proto.h"
void CMD_UTIL_put_svc_status(ISC_STATUS* svc_status,
USHORT facility,

View File

@ -25,7 +25,8 @@
#define UTILITIES_CMD_UTIL_PROTO_H
void CMD_UTIL_put_svc_status(ISC_STATUS* svc_status,
extern "C" {
void CMD_UTIL_put_svc_status(ISC_STATUS* svc_status,
USHORT facility,
USHORT errcode,
USHORT arg1_t, const void* arg1,
@ -34,6 +35,6 @@ void CMD_UTIL_put_svc_status(ISC_STATUS* svc_status,
USHORT arg4_t, const void* arg4,
USHORT arg5_t, const void* arg5);
}
#endif /* UTILITIES_CMD_UTIL_PROTO_H */