ENDIF(HAVE_RLIM_T)
# Windows need lib wsock32
-IF(CMAKE_SYSTEM_NAME EQUAL "Windows")
+IF(CMAKE_SYSTEM_NAME STREQUAL "Windows")
CHECK_INCLUDE_FILE(windows.h HAVE_WINDOWS_H)
CHECK_INCLUDE_FILE(winsock.h HAVE_WINSOCK_H)
FIND_LIBRARY(WSOCK_LIB NAMES wsock32 PATHS /usr/lib /usr/local/lib DOC "The winsock library")
#set_target_properties(sarg PROPERTIES LINK_FLAGS "${LINK_FLAGS} -lwsock32")
TARGET_LINK_LIBRARIES(sarg wsock32)
ENDIF(WSOCK_LIB)
-ENDIF(CMAKE_SYSTEM_NAME EQUAL "Windows")
+ENDIF(CMAKE_SYSTEM_NAME STREQUAL "Windows")
CHECK_FUNCTION_EXISTS(mkstemp HAVE_MKSTEMP)
-IF(!HAVE_MKSTEMP)
+IF(NOT HAVE_MKSTEMP)
# MingW provide mkstemps in libiberty but doesn't declare it in any header file
FIND_LIBRARY(IBERTY_LIB NAMES iberty PATHS /mingw/lib DOC "The library of mingw containing mkstemps")
IF(IBERTY_LIB)
TARGET_LINK_LIBRARIES(sarg iberty)
ENDIF(IBERTY_LIB)
-ENDIF(!HAVE_MKSTEMP)
+ENDIF(NOT HAVE_MKSTEMP)
# System particularities
-IF(CMAKE_SYSTEM_NAME EQUAL "solaris")
+IF(CMAKE_SYSTEM_NAME STREQUAL "solaris")
TARGET_LINK_LIBRARIES(sarg socket nsl)
#SET_TARGET_PROPERTIES(sarg PROPERTIES COMPILE_DEFINITIONS="-DSOLARIS ${COMPILE_DEFINITIONS}")
ADD_DEFINITIONS(-DSOLARIS)
-ENDIF(CMAKE_SYSTEM_NAME EQUAL "solaris")
+ENDIF(CMAKE_SYSTEM_NAME STREQUAL "solaris")
# Save the configuration for the project
CONFIGURE_FILE("${CMAKE_SOURCE_DIR}/include/config.h.in" "${CMAKE_BINARY_DIR}/config.h" @ONLY)
struct tm *t;
off_t recs1=0;
unsigned long recs2=0;
- struct rlimit rl;
int OutputNonZero = REPORT_EVERY_X_LINES ;
int download_flag;
char download_url[MAXLEN];
if(debug)
debuga("sarg %s: %s",text[73],VERSION);
+#ifdef HAVE_RLIM_T
if (Ulimit[0] != '\0') {
+ struct rlimit rl;
long l1, l2;
int rc=0;
if(debug)
debuga("Maximum file descriptor: cur=%ld max=%ld, changed to cur="RLIM_STRING" max="RLIM_STRING,l1,l2,rl.rlim_cur,rl.rlim_max);
}
+#endif
read_usertab(UserTabFile);