mirror of
https://github.com/FirebirdSQL/firebird.git
synced 2025-02-02 10:40:38 +01:00
Allowing using SERVICE_THREAD in CLASSIC server as platform option
This commit is contained in:
parent
f54415ab37
commit
d65fb07878
@ -271,6 +271,11 @@ global:
|
|||||||
isc_service_detach;
|
isc_service_detach;
|
||||||
isc_service_query;
|
isc_service_query;
|
||||||
isc_service_start;
|
isc_service_start;
|
||||||
|
#functions called by utils
|
||||||
|
SVC_putc;
|
||||||
|
SVC_finish;
|
||||||
|
SVC_output;
|
||||||
|
CMD_UTIL_put_svc_status;
|
||||||
|
|
||||||
# Transaction control functions
|
# Transaction control functions
|
||||||
|
|
||||||
|
@ -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=
|
ALICE_Files=
|
||||||
ifeq ($(ArchType),super)
|
ifeq ($(ArchType),super)
|
||||||
ALICE_Files=alice.cpp all.cpp exe.cpp alice_meta.epp tdr.cpp
|
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
|
endif
|
||||||
|
|
||||||
ALICE_Sources = $(addprefix alice/, $(ALICE_Files))
|
ALICE_Sources = $(addprefix alice/, $(ALICE_Files))
|
||||||
@ -148,6 +153,10 @@ ALICE_Objects = $(addprefix $(OBJ)/, $(addsuffix .o, $(basename $(ALICE_Sources)
|
|||||||
BURP_Files=
|
BURP_Files=
|
||||||
ifeq ($(ArchType),super)
|
ifeq ($(ArchType),super)
|
||||||
BURP_Files=burp.cpp backup.epp restore.epp mvol.cpp misc.cpp canonical.cpp
|
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
|
endif
|
||||||
|
|
||||||
BURP_Sources = $(addprefix burp/, $(BURP_Files))
|
BURP_Sources = $(addprefix burp/, $(BURP_Files))
|
||||||
@ -168,6 +177,13 @@ ifeq ($(ArchType),super)
|
|||||||
SECURITY_ServerFiles_gsec:= $(SECURITY_ServerFiles_gsec) gsec.cpp
|
SECURITY_ServerFiles_gsec:= $(SECURITY_ServerFiles_gsec) gsec.cpp
|
||||||
SECURITY_ServerFiles_gstat:= $(SECURITY_ServerFiles_gstat) dba.epp ppg.cpp
|
SECURITY_ServerFiles_gstat:= $(SECURITY_ServerFiles_gstat) dba.epp ppg.cpp
|
||||||
SECURITY_ServerFiles_common:= $(SECURITY_ServerFiles_common) cmd_util.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
|
endif
|
||||||
|
|
||||||
SECURITY_Files_gsec = $(SECURITY_ClientFiles_gsec) $(SECURITY_ServerFiles_gsec)
|
SECURITY_Files_gsec = $(SECURITY_ClientFiles_gsec) $(SECURITY_ServerFiles_gsec)
|
||||||
|
@ -54,7 +54,7 @@ DEV_FLAGS= $(CFLAGS_COMMON) $(SFIO_FLAGS) $(COMMON_GCC_FLAGS) $(DEBUG_GCC_FLAGS)
|
|||||||
$(LOCAL_CFLAGS)
|
$(LOCAL_CFLAGS)
|
||||||
|
|
||||||
# extra modules needed on this platform during bootstrap phase
|
# 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
|
OS_ServerFiles=inet_server.cpp
|
||||||
|
|
||||||
|
@ -35,6 +35,11 @@ dnl Use /usr/lib for library links on most platforms except some 64-bit ones
|
|||||||
libdir=/usr/lib
|
libdir=/usr/lib
|
||||||
ICU_PLATFORM=LinuxRedHat
|
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
|
case "$target" in
|
||||||
*-*-darwin*)
|
*-*-darwin*)
|
||||||
MAKEFILE_PREFIX=darwin
|
MAKEFILE_PREFIX=darwin
|
||||||
@ -124,6 +129,7 @@ case "$target" in
|
|||||||
PTHREAD_CFLAGS=-threads
|
PTHREAD_CFLAGS=-threads
|
||||||
PTHREAD_LIBS=-lthread
|
PTHREAD_LIBS=-lthread
|
||||||
ICU_PLATFORM=SOLARISX86GCC
|
ICU_PLATFORM=SOLARISX86GCC
|
||||||
|
service_thread_CS=true
|
||||||
;;
|
;;
|
||||||
|
|
||||||
sparc-sun-solaris*)
|
sparc-sun-solaris*)
|
||||||
@ -137,6 +143,7 @@ case "$target" in
|
|||||||
PTHREAD_CFLAGS=-threads
|
PTHREAD_CFLAGS=-threads
|
||||||
PTHREAD_LIBS=-lthread
|
PTHREAD_LIBS=-lthread
|
||||||
ICU_PLATFORM=SOLARISGCC
|
ICU_PLATFORM=SOLARISGCC
|
||||||
|
service_thread_CS=true
|
||||||
;;
|
;;
|
||||||
|
|
||||||
i*-sni-sysv4)
|
i*-sni-sysv4)
|
||||||
@ -173,6 +180,7 @@ AC_SUBST(MAKEFILE_PREFIX)
|
|||||||
AC_SUBST(PLATFORM)
|
AC_SUBST(PLATFORM)
|
||||||
AC_SUBST(SHRLIB_EXT)
|
AC_SUBST(SHRLIB_EXT)
|
||||||
AC_SUBST(ICU_PLATFORM)
|
AC_SUBST(ICU_PLATFORM)
|
||||||
|
AC_SUBST(service_thread_CS)
|
||||||
AC_DEFINE(CASE_SENSITIVITY, false, [Define this if paths are case sensitive])
|
AC_DEFINE(CASE_SENSITIVITY, false, [Define this if paths are case sensitive])
|
||||||
|
|
||||||
|
|
||||||
|
@ -31,6 +31,7 @@ namespace Jrd {
|
|||||||
class thread_db;
|
class thread_db;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
extern "C" {
|
||||||
Jrd::Service* SVC_attach(USHORT, const TEXT*, USHORT, const SCHAR*);
|
Jrd::Service* SVC_attach(USHORT, const TEXT*, USHORT, const SCHAR*);
|
||||||
void SVC_cleanup(Jrd::Service*);
|
void SVC_cleanup(Jrd::Service*);
|
||||||
void SVC_detach(Jrd::Service*);
|
void SVC_detach(Jrd::Service*);
|
||||||
@ -50,6 +51,7 @@ int SVC_output(Jrd::Service*, const UCHAR*);
|
|||||||
typedef void (*shutdown_fct_t) (ULONG);
|
typedef void (*shutdown_fct_t) (ULONG);
|
||||||
void SVC_shutdown_init(shutdown_fct_t, ULONG);
|
void SVC_shutdown_init(shutdown_fct_t, ULONG);
|
||||||
#endif /* SERVER_SHUTDOWN */
|
#endif /* SERVER_SHUTDOWN */
|
||||||
|
} //extern "C"
|
||||||
|
|
||||||
#endif /* JRD_SVC_PROTO_H */
|
#endif /* JRD_SVC_PROTO_H */
|
||||||
|
|
||||||
|
@ -43,7 +43,7 @@
|
|||||||
|
|
||||||
#include "../jrd/svc.h"
|
#include "../jrd/svc.h"
|
||||||
#include "../jrd/svc_proto.h"
|
#include "../jrd/svc_proto.h"
|
||||||
|
#include "cmd_util_proto.h"
|
||||||
|
|
||||||
void CMD_UTIL_put_svc_status(ISC_STATUS* svc_status,
|
void CMD_UTIL_put_svc_status(ISC_STATUS* svc_status,
|
||||||
USHORT facility,
|
USHORT facility,
|
||||||
|
@ -25,7 +25,8 @@
|
|||||||
#define UTILITIES_CMD_UTIL_PROTO_H
|
#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 facility,
|
||||||
USHORT errcode,
|
USHORT errcode,
|
||||||
USHORT arg1_t, const void* arg1,
|
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 arg4_t, const void* arg4,
|
||||||
USHORT arg5_t, const void* arg5);
|
USHORT arg5_t, const void* arg5);
|
||||||
|
|
||||||
|
}
|
||||||
#endif /* UTILITIES_CMD_UTIL_PROTO_H */
|
#endif /* UTILITIES_CMD_UTIL_PROTO_H */
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user