diff --git a/CMakeLists.txt b/CMakeLists.txt index 59779316..37ad5f02 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -108,7 +108,7 @@ set(FLAGS "\ -D PUBNUB_USE_GRANT_TOKEN_API=${USE_GRANT_TOKEN_API} \ -D PUBNUB_USE_REVOKE_TOKEN_API=${USE_REVOKE_TOKEN_API} \ -D PUBNUB_USE_FETCH_HISTORY=${USE_FETCH_HISTORY} \ - -D PUBNUB_USE_CRYPTO_API=${USE_CRYPTO_API} \ + -D PUBNUB_CRYPTO_API=${USE_CRYPTO_API} \ -D PUBNUB_RAND_INIT_VECTOR=${USE_LEGACY_CRYPTO_RANDOM_IV} \ -D PUBNUB_MBEDTLS=${MBEDTLS}") diff --git a/core/pubnub_crypto.h b/core/pubnub_crypto.h index 5331e3a4..a28fe7f7 100644 --- a/core/pubnub_crypto.h +++ b/core/pubnub_crypto.h @@ -1,7 +1,7 @@ /* -*- c-file-style:"stroustrup"; indent-tabs-mode: nil -*- */ #if !defined INC_PUBNUB_CRYPTO #define INC_PUBNUB_CRYPTO -#if PUBNUB_USE_CRYPTO_API +#if PUBNUB_CRYPTO_API #include "lib/pb_deprecated.h" #include "core/pubnub_api_types.h" #include "core/pubnub_memory_block.h" @@ -235,5 +235,5 @@ PUBNUB_EXTERN void pubnub_set_crypto_module(pubnub_t *pubnub, struct pubnub_cryp @return Pointer to the crypto provider used by the pubnub context. */ PUBNUB_EXTERN pubnub_crypto_provider_t *pubnub_get_crypto_module(pubnub_t *pubnub); -#endif // #if PUBNUB_USE_CRYPTO_API +#endif // #if PUBNUB_CRYPTO_API #endif /* defined INC_PUBNUB_CRYPTO */ \ No newline at end of file diff --git a/core/pubnub_pubsubapi.c b/core/pubnub_pubsubapi.c index e681c735..ac9b027d 100644 --- a/core/pubnub_pubsubapi.c +++ b/core/pubnub_pubsubapi.c @@ -304,6 +304,7 @@ int pubnub_last_http_code(pubnub_t* pb) return result; } +#if PUBNUB_USE_RETRY_CONFIGURATION uint16_t pubnub_last_http_retry_header(pubnub_t* pb) { PUBNUB_ASSERT(pb_valid_ctx_ptr(pb)); @@ -312,7 +313,7 @@ uint16_t pubnub_last_http_retry_header(pubnub_t* pb) pubnub_mutex_unlock(pb->monitor); return retry_after; } - +#endif // #if PUBNUB_USE_RETRY_CONFIGURATION char const* pubnub_last_time_token(pubnub_t* pb) { diff --git a/core/pubnub_pubsubapi.h b/core/pubnub_pubsubapi.h index 82c0d1b8..b7af7a87 100644 --- a/core/pubnub_pubsubapi.h +++ b/core/pubnub_pubsubapi.h @@ -296,9 +296,11 @@ PUBNUB_EXTERN enum pubnub_res pubnub_last_result(pubnub_t* p); * context. */ PUBNUB_EXTERN int pubnub_last_http_code(pubnub_t* p); +#if PUBNUB_USE_RETRY_CONFIGURATION /** Returns the HTTP reply `Retry-After` header value of the last transaction in * the @p p context. */ PUBNUB_EXTERN uint16_t pubnub_last_http_retry_header(pubnub_t* pb); +#endif // #if PUBNUB_USE_RETRY_CONFIGURATION /** Returns the string of the result of the last `publish` transaction, as returned from Pubnub. If the last transaction is not a publish, diff --git a/openssl/posix.mk b/openssl/posix.mk index 289476ef..c68c88c3 100644 --- a/openssl/posix.mk +++ b/openssl/posix.mk @@ -10,6 +10,10 @@ ifndef USE_PROXY USE_PROXY = 1 endif +ifndef USE_RETRY_CONFIGURATION +USE_RETRY_CONFIGURATION = 0 +endif + ifndef USE_GZIP_COMPRESSION USE_GZIP_COMPRESSION = 1 endif @@ -114,7 +118,7 @@ SOURCEFILES += ../core/pbcc_crypto.c ../core/pbcc_crypto_aes_cbc.c ../core/pbcc_ OBJFILES += pbcc_crypto.o pbcc_crypto_aes_cbc.o pbcc_crypto_legacy.o pubnub_crypto.o pbaes256.o endif -CFLAGS = -g -D PUBNUB_THREADSAFE -D PUBNUB_LOG_LEVEL=PUBNUB_LOG_LEVEL_WARNING -Wall -D PUBNUB_ONLY_PUBSUB_API=$(ONLY_PUBSUB_API) -D PUBNUB_PROXY_API=$(USE_PROXY) -D PUBNUB_USE_GZIP_COMPRESSION=$(USE_GZIP_COMPRESSION) -D PUBNUB_RECEIVE_GZIP_RESPONSE=$(RECEIVE_GZIP_RESPONSE) -D PUBNUB_USE_SUBSCRIBE_V2=$(USE_SUBSCRIBE_V2) -D PUBNUB_USE_OBJECTS_API=$(USE_OBJECTS_API) -D PUBNUB_USE_ACTIONS_API=$(USE_ACTIONS_API) -D PUBNUB_USE_AUTO_HEARTBEAT=$(USE_AUTO_HEARTBEAT) -D PUBNUB_USE_GRANT_TOKEN_API=$(USE_GRANT_TOKEN) -D PUBNUB_USE_REVOKE_TOKEN_API=$(USE_REVOKE_TOKEN) -D PUBNUB_USE_FETCH_HISTORY=$(USE_FETCH_HISTORY) -D PUBNUB_USE_CRYPTO_API=$(USE_CRYPTO_API) +CFLAGS = -g -D PUBNUB_THREADSAFE -D PUBNUB_LOG_LEVEL=PUBNUB_LOG_LEVEL_WARNING -Wall -D PUBNUB_ONLY_PUBSUB_API=$(ONLY_PUBSUB_API) -D PUBNUB_PROXY_API=$(USE_PROXY) -D PUBNUB_USE_RETRY_CONFIGURATION=$(USE_RETRY_CONFIGURATION) -D PUBNUB_USE_GZIP_COMPRESSION=$(USE_GZIP_COMPRESSION) -D PUBNUB_RECEIVE_GZIP_RESPONSE=$(RECEIVE_GZIP_RESPONSE) -D PUBNUB_USE_SUBSCRIBE_V2=$(USE_SUBSCRIBE_V2) -D PUBNUB_USE_OBJECTS_API=$(USE_OBJECTS_API) -D PUBNUB_USE_ACTIONS_API=$(USE_ACTIONS_API) -D PUBNUB_USE_AUTO_HEARTBEAT=$(USE_AUTO_HEARTBEAT) -D PUBNUB_USE_GRANT_TOKEN_API=$(USE_GRANT_TOKEN) -D PUBNUB_USE_REVOKE_TOKEN_API=$(USE_REVOKE_TOKEN) -D PUBNUB_USE_FETCH_HISTORY=$(USE_FETCH_HISTORY) -D PUBNUB_CRYPTO_API=$(USE_CRYPTO_API) # -g enables debugging, remove to get a smaller executable # -fsanitize=address Use AddressSanitizer # -fsanitize=thread Use ThreadSanitizer diff --git a/openssl/uwp.mk b/openssl/uwp.mk index 81dc7470..d535c682 100644 --- a/openssl/uwp.mk +++ b/openssl/uwp.mk @@ -23,11 +23,20 @@ ONLY_PUBSUB_API = 0 USE_PROXY = 0 !endif +!ifndef USE_RETRY_CONFIGURATION +USE_RETRY_CONFIGURATION = 0 +!endif + !if $(USE_PROXY) PROXY_INTF_SOURCEFILES = ..\core\pubnub_proxy.c ..\core\pubnub_proxy_core.c ..\core\pbhttp_digest.c ..\core\pbntlm_core.c ..\core\pbntlm_packer_sspi.c ..\windows\pubnub_set_proxy_from_system_windows.c PROXY_INTF_OBJFILES = pubnub_proxy.obj pubnub_proxy_core.obj pbhttp_digest.obj pbntlm_core.obj pbntlm_packer_sspi.obj pubnub_set_proxy_from_system_windows.obj !endif +!if $(USE_RETRY_CONFIGURATION) +PROXY_INTF_SOURCEFILES += ..\core\pbcc_request_retry_timer.c ..\core\pubnub_retry_configuration.c +PROXY_INTF_OBJFILES += pbcc_request_retry_timer.obj pubnub_retry_configuration.obj +!endif + !ifndef USE_REVOKE_TOKEN USE_REVOKE_TOKEN = 1 !endif @@ -59,13 +68,12 @@ FETCH_HIST_SOURCEFILES = ..\core\pubnub_fetch_history.c ..\core\pbcc_fetch_histo FETCH_HIST_OBJFILES = pubnub_fetch_history.obj pbcc_fetch_history.obj !endif - !if $(USE_CRYPTO_API) FETCH_HIST_SOURCEFILES += ..\core\pbcc_crypto.c ..\core\pbcc_crypto_aes_cbc.c ..\core\pbcc_crypto_legacy.c ..\core\pubnub_crypto.c ..\openssl\pbaes256.c FETCH_HIST_OBJFILES += pbcc_crypto.obj pbcc_crypto_aes_cbc.obj pbcc_crypto_legacy.obj pubnub_crypto.obj pbaes256.obj !endif -DEFINES=-D PUBNUB_THREADSAFE -D PUBNUB_LOG_LEVEL=PUBNUB_LOG_LEVEL_WARNING -D HAVE_STRERROR_S -D PUBNUB_ONLY_PUBSUB_API=$(ONLY_PUBSUB_API) -D PUBNUB_PROXY_API=$(USE_PROXY) -D PUBNUB_USE_WIN_SSPI=0 -D PUBNUB_CRYPTO_API=1 -D PUBNUB_USE_GRANT_TOKEN_API=$(USE_GRANT_TOKEN) -D PUBNUB_USE_REVOKE_TOKEN_API=$(USE_REVOKE_TOKEN) -D PUBNUB_USE_FETCH_HISTORY=$(USE_FETCH_HISTORY) -D PUBNUB_USE_CRYPTO_API=$(USE_CRYPTO_API) +DEFINES=-D PUBNUB_THREADSAFE -D PUBNUB_LOG_LEVEL=PUBNUB_LOG_LEVEL_WARNING -D HAVE_STRERROR_S -D PUBNUB_ONLY_PUBSUB_API=$(ONLY_PUBSUB_API) -D PUBNUB_PROXY_API=$(USE_PROXY) -D PUBNUB_USE_RETRY_CONFIGURATION=$(USE_RETRY_CONFIGURATION) -D PUBNUB_USE_WIN_SSPI=0 -D PUBNUB_CRYPTO_API=1 -D PUBNUB_USE_GRANT_TOKEN_API=$(USE_GRANT_TOKEN) -D PUBNUB_USE_REVOKE_TOKEN_API=$(USE_REVOKE_TOKEN) -D PUBNUB_USE_FETCH_HISTORY=$(USE_FETCH_HISTORY) -D PUBNUB_CRYPTO_API=$(USE_CRYPTO_API) UDEFINES=-D "_UNICODE" -D "UNICODE" -D "WINAPI_FAMILY=WINAPI_FAMILY_APP" -D "__WRL_NO_DEFAULT_LIB__" -D "_CRT_SECURE_NO_WARNINGS" -D "_WINSOCK_DEPRECATED_NO_WARNINGS" -D "__UWP__" -D "HAVE_STRUCT_TIMESPEC" CFLAGS = -Yu"pch.h" -Zi -Y- -MP -W3 -Gy -Zc:wchar_t $(UDEFINES) $(DEFINES) -Gm- -O2 -sdl -errorReport:prompt -WX- -Zc:forScope /Gd /Oy- /Oi /MD /FC -FU"C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29333\lib\x86\store\references\platform.winmd" # /Zi enables debugging, remove to get a smaller .exe and no .pdb diff --git a/openssl/windows.mk b/openssl/windows.mk index beb600c5..a0f31360 100644 --- a/openssl/windows.mk +++ b/openssl/windows.mk @@ -44,11 +44,20 @@ USE_FETCH_HISTORY = 1 USE_CRYPTO_API = 0 !endif +!ifndef USE_RETRY_CONFIGURATION +USE_RETRY_CONFIGURATION = 0 +!endif + !if $(USE_PROXY) PROXY_INTF_SOURCEFILES = ..\core\pubnub_proxy.c ..\core\pubnub_proxy_core.c ..\core\pbhttp_digest.c ..\core\pbntlm_core.c ..\core\pbntlm_packer_sspi.c ..\windows\pubnub_set_proxy_from_system_windows.c PROXY_INTF_OBJFILES = pubnub_proxy.obj pubnub_proxy_core.obj pbhttp_digest.obj pbntlm_core.obj pbntlm_packer_sspi.obj pubnub_set_proxy_from_system_windows.obj !endif +!if $(USE_RETRY_CONFIGURATION) +PROXY_INTF_SOURCEFILES += ..\core\pbcc_request_retry_timer.c ..\core\pubnub_retry_configuration.c +PROXY_INTF_OBJFILES += pbcc_request_retry_timer.obj pubnub_retry_configuration.obj +!endif + !if $(USE_REVOKE_TOKEN) REVOKE_TOKEN_SOURCEFILES = ..\core\pubnub_revoke_token_api.c ..\core\pbcc_revoke_token_api.c REVOKE_TOKEN_OBJFILES = pubnub_revoke_token_api.obj pbcc_revoke_token_api.obj @@ -64,7 +73,7 @@ FETCH_HIST_SOURCEFILES = ..\core\pubnub_fetch_history.c ..\core\pbcc_fetch_histo FETCH_HIST_OBJFILES = pubnub_fetch_history.obj pbcc_fetch_history.obj !endif -CFLAGS = /Zi /MP -D PUBNUB_THREADSAFE /D PUBNUB_LOG_LEVEL=PUBNUB_LOG_LEVEL_WARNING /W3 /D PUBNUB_USE_WIN_SSPI=1 /D PUBNUB_ONLY_PUBSUB_API=$(ONLY_PUBSUB_API) /D PUBNUB_PROXY_API=$(USE_PROXY) /D PUBNUB_USE_SUBSCRIBE_V2=$(USE_SUBSCRIBE_V2) /D _CRT_SECURE_NO_WARNINGS /D PUBNUB_CRYPTO_API=1 /D PUBNUB_USE_GRANT_TOKEN_API=$(USE_GRANT_TOKEN) /D PUBNUB_USE_REVOKE_TOKEN_API=$(USE_REVOKE_TOKEN) /D PUBNUB_USE_FETCH_HISTORY=$(USE_FETCH_HISTORY) +CFLAGS = /Zi /MP -D PUBNUB_THREADSAFE /D PUBNUB_LOG_LEVEL=PUBNUB_LOG_LEVEL_WARNING /W3 /D PUBNUB_USE_WIN_SSPI=1 /D PUBNUB_ONLY_PUBSUB_API=$(ONLY_PUBSUB_API) /D PUBNUB_PROXY_API=$(USE_PROXY) /D PUBNUB_USE_RETRY_CONFIGURATION=$(USE_RETRY_CONFIGURATION) /D PUBNUB_USE_SUBSCRIBE_V2=$(USE_SUBSCRIBE_V2) /D _CRT_SECURE_NO_WARNINGS /D PUBNUB_CRYPTO_API=$(USE_CRYPTO_API) /D PUBNUB_USE_GRANT_TOKEN_API=$(USE_GRANT_TOKEN) /D PUBNUB_USE_REVOKE_TOKEN_API=$(USE_REVOKE_TOKEN) /D PUBNUB_USE_FETCH_HISTORY=$(USE_FETCH_HISTORY) # /Zi enables debugging, remove to get a smaller .exe and no .pdb # /MP uses one compiler (`cl`) process for each input file, enabling faster build # /analyze To run the static analyzer (not compatible w/clang-cl) diff --git a/posix/posix.mk b/posix/posix.mk index 67d59f2a..8ef08873 100644 --- a/posix/posix.mk +++ b/posix/posix.mk @@ -58,10 +58,6 @@ ifndef USE_FETCH_HISTORY USE_FETCH_HISTORY = 1 endif -ifndef USE_CRYPTO_API -USE_CRYPTO_API = 0 -endif - ifeq ($(USE_PROXY), 1) SOURCEFILES += ../core/pubnub_proxy.c ../core/pubnub_proxy_core.c ../core/pbhttp_digest.c ../core/pbntlm_core.c ../core/pbntlm_packer_std.c OBJFILES += pubnub_proxy.o pubnub_proxy_core.o pbhttp_digest.o pbntlm_core.o pbntlm_packer_std.o @@ -128,7 +124,7 @@ OBJFILES += monotonic_clock_get_time_posix.o LDLIBS=-lrt -lpthread endif -CFLAGS =-g -Wall -D PUBNUB_THREADSAFE -D PUBNUB_LOG_LEVEL=PUBNUB_LOG_LEVEL_WARNING -D PUBNUB_ONLY_PUBSUB_API=$(ONLY_PUBSUB_API) -D PUBNUB_PROXY_API=$(USE_PROXY) -D PUBNUB_USE_RETRY_CONFIGURATION=$(USE_RETRY_CONFIGURATION) -D PUBNUB_USE_GZIP_COMPRESSION=$(USE_GZIP_COMPRESSION) -D PUBNUB_RECEIVE_GZIP_RESPONSE=$(RECEIVE_GZIP_RESPONSE) -D PUBNUB_USE_SUBSCRIBE_V2=$(USE_SUBSCRIBE_V2) -D PUBNUB_USE_SUBSCRIBE_EVENT_ENGINE=$(USE_SUBSCRIBE_EVENT_ENGINE) -D PUBNUB_USE_OBJECTS_API=$(USE_OBJECTS_API) -D PUBNUB_USE_ACTIONS_API=$(USE_ACTIONS_API) -D PUBNUB_USE_AUTO_HEARTBEAT=$(USE_AUTO_HEARTBEAT) -D PUBNUB_USE_GRANT_TOKEN_API=$(USE_GRANT_TOKEN) -D PUBNUB_USE_REVOKE_TOKEN_API=$(USE_REVOKE_TOKEN) -D PUBNUB_USE_FETCH_HISTORY=$(USE_FETCH_HISTORY) -D PUBNUB_USE_CRYPTO_API=$(USE_CRYPTO_API) +CFLAGS =-g -Wall -D PUBNUB_THREADSAFE -D PUBNUB_LOG_LEVEL=PUBNUB_LOG_LEVEL_WARNING -D PUBNUB_ONLY_PUBSUB_API=$(ONLY_PUBSUB_API) -D PUBNUB_PROXY_API=$(USE_PROXY) -D PUBNUB_USE_RETRY_CONFIGURATION=$(USE_RETRY_CONFIGURATION) -D PUBNUB_USE_GZIP_COMPRESSION=$(USE_GZIP_COMPRESSION) -D PUBNUB_RECEIVE_GZIP_RESPONSE=$(RECEIVE_GZIP_RESPONSE) -D PUBNUB_USE_SUBSCRIBE_V2=$(USE_SUBSCRIBE_V2) -D PUBNUB_USE_SUBSCRIBE_EVENT_ENGINE=$(USE_SUBSCRIBE_EVENT_ENGINE) -D PUBNUB_USE_OBJECTS_API=$(USE_OBJECTS_API) -D PUBNUB_USE_ACTIONS_API=$(USE_ACTIONS_API) -D PUBNUB_USE_AUTO_HEARTBEAT=$(USE_AUTO_HEARTBEAT) -D PUBNUB_USE_GRANT_TOKEN_API=$(USE_GRANT_TOKEN) -D PUBNUB_USE_REVOKE_TOKEN_API=$(USE_REVOKE_TOKEN) -D PUBNUB_USE_FETCH_HISTORY=$(USE_FETCH_HISTORY) # -g enables debugging, remove to get a smaller executable # -fsanitize-address Use AddressSanitizer diff --git a/windows/uwp.mk b/windows/uwp.mk index da6068f9..dcbbde9a 100644 --- a/windows/uwp.mk +++ b/windows/uwp.mk @@ -24,17 +24,30 @@ USE_FETCH_HISTORY = 1 USE_PROXY = 1 !endif +!ifndef USE_RETRY_CONFIGURATION +USE_RETRY_CONFIGURATION = 0 +!endif + +!ifndef USE_CRYPTO_API +USE_CRYPTO_API = 0 +!endif + !if $(USE_PROXY) PROXY_INTF_SOURCEFILES = ..\core\pubnub_proxy.c ..\core\pubnub_proxy_core.c ..\core\pbhttp_digest.c ..\core\pbntlm_core.c ..\core\pbntlm_packer_std.c PROXY_INTF_OBJFILES = pubnub_proxy.obj pubnub_proxy_core.obj pbhttp_digest.obj pbntlm_core.obj pbntlm_packer_std.obj !endif +!if $(USE_RETRY_CONFIGURATION) +PROXY_INTF_SOURCEFILES += ..\core\pbcc_request_retry_timer.c ..\core\pubnub_retry_configuration.c +PROXY_INTF_OBJFILES += pbcc_request_retry_timer.obj pubnub_retry_configuration.obj +!endif + !if $(USE_FETCH_HISTORY) FETCH_HIST_SOURCEFILES = ..\core\pubnub_fetch_history.c ..\core\pbcc_fetch_history.c FETCH_HIST_OBJFILES = pubnub_fetch_history.obj pbcc_fetch_history.obj !endif -DEFINES=-D PUBNUB_THREADSAFE -D PUBNUB_LOG_LEVEL=PUBNUB_LOG_LEVEL_WARNING -D HAVE_STRERROR_S -D PUBNUB_ONLY_PUBSUB_API=$(ONLY_PUBSUB_API) -D PUBNUB_PROXY_API=$(USE_PROXY) -D PUBNUB_USE_WIN_SSPI=0 -D PUBNUB_USE_GRANT_TOKEN_API=$(USE_GRANT_TOKEN) -D PUBNUB_USE_REVOKE_TOKEN_API=$(USE_REVOKE_TOKEN) -D PUBNUB_USE_FETCH_HISTORY=$(USE_FETCH_HISTORY) +DEFINES=-D PUBNUB_THREADSAFE -D PUBNUB_LOG_LEVEL=PUBNUB_LOG_LEVEL_WARNING -D HAVE_STRERROR_S -D PUBNUB_ONLY_PUBSUB_API=$(ONLY_PUBSUB_API) -D PUBNUB_PROXY_API=$(USE_PROXY) -D PUBNUB_USE_RETRY_CONFIGURATION=$(USE_RETRY_CONFIGURATION) -D PUBNUB_USE_WIN_SSPI=0 -D PUBNUB_USE_GRANT_TOKEN_API=$(USE_GRANT_TOKEN) -D PUBNUB_USE_REVOKE_TOKEN_API=$(USE_REVOKE_TOKEN) -D PUBNUB_USE_FETCH_HISTORY=$(USE_FETCH_HISTORY) UDEFINES=-D "_UNICODE" -D "UNICODE" -D "WINAPI_FAMILY=WINAPI_FAMILY_APP" -D "__WRL_NO_DEFAULT_LIB__" -D "_CRT_SECURE_NO_WARNINGS" -D "_WINSOCK_DEPRECATED_NO_WARNINGS" -D "__UWP__" -D "HAVE_STRUCT_TIMESPEC" CFLAGS = -Yu"pch.h" -Zi -Y- -MP -W3 -Gy -Zc:wchar_t $(UDEFINES) $(DEFINES) -Gm- -O2 -sdl -errorReport:prompt -WX- -Zc:forScope /Gd /Oy- /Oi /MD /FC -FU"C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29333\lib\x86\store\references\platform.winmd" # -Zi enables debugging, remove to get a smaller .exe and no .pdb diff --git a/windows/windows.mk b/windows/windows.mk index fcc7b899..426fc1f6 100644 --- a/windows/windows.mk +++ b/windows/windows.mk @@ -24,17 +24,26 @@ USE_FETCH_HISTORY = 1 USE_PROXY = 1 !endif +!ifndef USE_RETRY_CONFIGURATION +USE_RETRY_CONFIGURATION = 0 +!endif + !if $(USE_PROXY) PROXY_INTF_SOURCEFILES = ..\core\pubnub_proxy.c ..\core\pubnub_proxy_core.c ..\core\pbhttp_digest.c ..\core\pbntlm_core.c ..\core\pbntlm_packer_sspi.c pubnub_set_proxy_from_system_windows.c PROXY_INTF_OBJFILES = pubnub_proxy.obj pubnub_proxy_core.obj pbhttp_digest.obj pbntlm_core.obj pbntlm_packer_sspi.obj pubnub_set_proxy_from_system_windows.obj !endif +!if $(USE_RETRY_CONFIGURATION) +PROXY_INTF_SOURCEFILES += ..\core\pbcc_request_retry_timer.c ..\core\pubnub_retry_configuration.c +PROXY_INTF_OBJFILES += pbcc_request_retry_timer.obj pubnub_retry_configuration.obj +!endif + !if $(USE_FETCH_HISTORY) FETCH_HIST_SOURCEFILES = ..\core\pubnub_fetch_history.c ..\core\pbcc_fetch_history.c FETCH_HIST_OBJFILES = pubnub_fetch_history.obj pbcc_fetch_history.obj !endif -DEFINES=-D PUBNUB_THREADSAFE -D PUBNUB_LOG_LEVEL=PUBNUB_LOG_LEVEL_WARNING -D HAVE_STRERROR_S -D PUBNUB_ONLY_PUBSUB_API=$(ONLY_PUBSUB_API) -D PUBNUB_PROXY_API=$(USE_PROXY) -D PUBNUB_USE_GRANT_TOKEN_API=$(USE_GRANT_TOKEN) -D PUBNUB_USE_REVOKE_TOKEN_API=$(USE_REVOKE_TOKEN) -D PUBNUB_USE_FETCH_HISTORY=$(USE_FETCH_HISTORY) +DEFINES=-D PUBNUB_THREADSAFE -D PUBNUB_LOG_LEVEL=PUBNUB_LOG_LEVEL_WARNING -D HAVE_STRERROR_S -D PUBNUB_ONLY_PUBSUB_API=$(ONLY_PUBSUB_API) -D PUBNUB_PROXY_API=$(USE_PROXY) -D PUBNUB_USE_RETRY_CONFIGURATION=$(USE_RETRY_CONFIGURATION) -D PUBNUB_USE_GRANT_TOKEN_API=$(USE_GRANT_TOKEN) -D PUBNUB_USE_REVOKE_TOKEN_API=$(USE_REVOKE_TOKEN) -D PUBNUB_USE_FETCH_HISTORY=$(USE_FETCH_HISTORY) CFLAGS = -Zi -MP -W3 $(DEFINES) # -Zi enables debugging, remove to get a smaller .exe and no .pdb # -MP use one compiler process for each input, faster on multi-core (ignored by clang-cl)