s/TCP/ECL_TCP/ among preprocessor defines

This commit is contained in:
Pritam Baral 2020-09-09 20:41:27 +00:00
parent 6ff3b2b86b
commit a1b2909b8a
9 changed files with 15 additions and 15 deletions

View file

@ -76,8 +76,8 @@
#define ECL_LIBATOMIC_OPS_H #define ECL_LIBATOMIC_OPS_H
/* Network streams */ /* Network streams */
#define TCP 1 #define ECL_TCP 1
#if defined(TCP) && (defined(_MSC_VER) || defined(mingw32)) #if defined(ECL_TCP) && (defined(_MSC_VER) || defined(mingw32))
# define ECL_WSOCK # define ECL_WSOCK
#endif #endif

View file

@ -296,7 +296,7 @@ cl_shutdown(void)
#ifdef ENABLE_DLOPEN #ifdef ENABLE_DLOPEN
ecl_library_close_all(); ecl_library_close_all();
#endif #endif
#ifdef TCP #ifdef ECL_TCP
ecl_tcp_close_all(); ecl_tcp_close_all();
#endif #endif
} }

View file

@ -45,7 +45,7 @@ typedef struct {
#else #else
# define IF_MP(x) NULL # define IF_MP(x) NULL
#endif #endif
#ifdef TCP #ifdef ECL_TCP
# define IF_TCP(x) x # define IF_TCP(x) x
#else #else
# define IF_TCP(x) NULL # define IF_TCP(x) NULL
@ -1323,13 +1323,13 @@ cl_symbols[] = {
{SYS_ "DISPLAY-PROFILE", SI_ORDINARY, IF_PROFILE(si_display_profile), -1, OBJNULL}, {SYS_ "DISPLAY-PROFILE", SI_ORDINARY, IF_PROFILE(si_display_profile), -1, OBJNULL},
/* #endif PROFILE */ /* #endif PROFILE */
/* #ifdef TCP */ /* #ifdef ECL_TCP */
{SYS_ "*PROFILE-ARRAY*", SI_SPECIAL, NULL, -1, OBJNULL}, {SYS_ "*PROFILE-ARRAY*", SI_SPECIAL, NULL, -1, OBJNULL},
{SYS_ "OPEN-CLIENT-STREAM", SI_ORDINARY, IF_TCP(si_open_client_stream), 2, OBJNULL}, {SYS_ "OPEN-CLIENT-STREAM", SI_ORDINARY, IF_TCP(si_open_client_stream), 2, OBJNULL},
{SYS_ "OPEN-SERVER-STREAM", SI_ORDINARY, IF_TCP(si_open_server_stream), 1, OBJNULL}, {SYS_ "OPEN-SERVER-STREAM", SI_ORDINARY, IF_TCP(si_open_server_stream), 1, OBJNULL},
{SYS_ "OPEN-UNIX-SOCKET-STREAM", SI_ORDINARY, IF_TCP(si_open_unix_socket_stream), 1, OBJNULL}, {SYS_ "OPEN-UNIX-SOCKET-STREAM", SI_ORDINARY, IF_TCP(si_open_unix_socket_stream), 1, OBJNULL},
{SYS_ "LOOKUP-HOST-ENTRY", SI_ORDINARY, IF_TCP(si_lookup_host_entry), 1, OBJNULL}, {SYS_ "LOOKUP-HOST-ENTRY", SI_ORDINARY, IF_TCP(si_lookup_host_entry), 1, OBJNULL},
/* #endif TCP */ /* #endif ECL_TCP */
{EXT_ "CATCH-SIGNAL", EXT_ORDINARY, si_catch_signal, -3, OBJNULL}, {EXT_ "CATCH-SIGNAL", EXT_ORDINARY, si_catch_signal, -3, OBJNULL},
{EXT_ "GET-SIGNAL-HANDLER", EXT_ORDINARY, si_get_signal_handler, 1, OBJNULL}, {EXT_ "GET-SIGNAL-HANDLER", EXT_ORDINARY, si_get_signal_handler, 1, OBJNULL},

View file

@ -45,7 +45,7 @@ typedef struct {
#else #else
# define IF_MP(x) NULL # define IF_MP(x) NULL
#endif #endif
#ifdef TCP #ifdef ECL_TCP
# define IF_TCP(x) x # define IF_TCP(x) x
#else #else
# define IF_TCP(x) NULL # define IF_TCP(x) NULL
@ -1323,13 +1323,13 @@ cl_symbols[] = {
{SYS_ "DISPLAY-PROFILE",IF_PROFILE("si_display_profile"),-1}, {SYS_ "DISPLAY-PROFILE",IF_PROFILE("si_display_profile"),-1},
/* #endif PROFILE */ /* #endif PROFILE */
/* #ifdef TCP */ /* #ifdef ECL_TCP */
{SYS_ "*PROFILE-ARRAY*",NULL,-1}, {SYS_ "*PROFILE-ARRAY*",NULL,-1},
{SYS_ "OPEN-CLIENT-STREAM",IF_TCP("si_open_client_stream"),2}, {SYS_ "OPEN-CLIENT-STREAM",IF_TCP("si_open_client_stream"),2},
{SYS_ "OPEN-SERVER-STREAM",IF_TCP("si_open_server_stream"),1}, {SYS_ "OPEN-SERVER-STREAM",IF_TCP("si_open_server_stream"),1},
{SYS_ "OPEN-UNIX-SOCKET-STREAM",IF_TCP("si_open_unix_socket_stream"),1}, {SYS_ "OPEN-UNIX-SOCKET-STREAM",IF_TCP("si_open_unix_socket_stream"),1},
{SYS_ "LOOKUP-HOST-ENTRY",IF_TCP("si_lookup_host_entry"),1}, {SYS_ "LOOKUP-HOST-ENTRY",IF_TCP("si_lookup_host_entry"),1},
/* #endif TCP */ /* #endif ECL_TCP */
{EXT_ "CATCH-SIGNAL","si_catch_signal",-3}, {EXT_ "CATCH-SIGNAL","si_catch_signal",-3},
{EXT_ "GET-SIGNAL-HANDLER","si_get_signal_handler",1}, {EXT_ "GET-SIGNAL-HANDLER","si_get_signal_handler",1},

2
src/configure vendored
View file

@ -9951,7 +9951,7 @@ LSP_FEATURES="(cons :builtin-sockets ${LSP_FEATURES})"
fi fi
if test "${with_tcp}" = "yes"; then if test "${with_tcp}" = "yes"; then
$as_echo "#define TCP 1" >>confdefs.h $as_echo "#define ECL_TCP 1" >>confdefs.h
EXTRA_OBJS="${EXTRA_OBJS} tcp.${OBJEXT}" EXTRA_OBJS="${EXTRA_OBJS} tcp.${OBJEXT}"

View file

@ -833,7 +833,7 @@ if test "${with_tcp}" = "builtin"; then
with_tcp=yes with_tcp=yes
fi fi
if test "${with_tcp}" = "yes"; then if test "${with_tcp}" = "yes"; then
AC_DEFINE(TCP, [1], [Network streams]) AC_DEFINE(ECL_TCP, [1], [Network streams])
EXTRA_OBJS="${EXTRA_OBJS} tcp.${OBJEXT}" EXTRA_OBJS="${EXTRA_OBJS} tcp.${OBJEXT}"
ECL_ADD_LISP_MODULE([sockets]) ECL_ADD_LISP_MODULE([sockets])
LIBS="${LIBS} ${TCPLIBS}" LIBS="${LIBS} ${TCPLIBS}"

View file

@ -637,7 +637,7 @@
#undef STDC_HEADERS #undef STDC_HEADERS
/* Network streams */ /* Network streams */
#undef TCP #undef ECL_TCP
/* Define to 1 if you can safely include both <sys/time.h> and <time.h>. */ /* Define to 1 if you can safely include both <sys/time.h> and <time.h>. */
#undef TIME_WITH_SYS_TIME #undef TIME_WITH_SYS_TIME

View file

@ -88,8 +88,8 @@
#undef ECL_LIBATOMIC_OPS_H #undef ECL_LIBATOMIC_OPS_H
/* Network streams */ /* Network streams */
#undef TCP #undef ECL_TCP
#if defined(TCP) && defined(ECL_MS_WINDOWS_HOST) #if defined(ECL_TCP) && defined(ECL_MS_WINDOWS_HOST)
# define ECL_WSOCK # define ECL_WSOCK
#endif #endif

View file

@ -1753,7 +1753,7 @@ extern ECL_API cl_object mp_compare_and_swap_symbol_plist(cl_object x, cl_object
/* tcp.c */ /* tcp.c */
#ifdef TCP #ifdef ECL_TCP
extern ECL_API cl_object si_open_client_stream(cl_object host, cl_object port); extern ECL_API cl_object si_open_client_stream(cl_object host, cl_object port);
extern ECL_API cl_object si_open_server_stream(cl_object port); extern ECL_API cl_object si_open_server_stream(cl_object port);
extern ECL_API cl_object si_open_unix_socket_stream(cl_object path); extern ECL_API cl_object si_open_unix_socket_stream(cl_object path);