1 2set(DEUTIL_SRCS 3 deClock.c 4 deClock.h 5 deCommandLine.c 6 deCommandLine.h 7 deDynamicLibrary.c 8 deDynamicLibrary.h 9 deFile.c 10 deFile.h 11 deProcess.h 12 deSocket.c 13 deSocket.h 14 deTimer.c 15 deTimer.h 16 deTimerTest.c 17 deTimerTest.h 18 ) 19 20set(DEUTIL_LIBS debase dethread depool) 21 22if (DE_OS_IS_FUCHSIA) 23 # Process launching isn't currently supported on Fuchsia in this library. 24 # Building executor and execserver will fail. 25else () 26 set(DEUTIL_SRCS ${DEUTIL_SRCS} deProcess.c) 27endif () 28 29include_directories( 30 ../debase 31 ../dethread 32 ../depool 33 ) 34 35if (DE_OS_IS_UNIX) 36 set(DEUTIL_LIBS ${DEUTIL_LIBS} rt dl) 37endif () 38 39if (DE_OS_IS_ANDROID) 40 # inline keyword in headers... 41 set_source_files_properties(deSocket.c COMPILE_FLAGS -std=c99) 42endif () 43 44if (DE_OS_IS_WIN32) 45 set(DEUTIL_LIBS ${DEUTIL_LIBS} ws2_32) 46endif () 47 48if (DE_OS_IS_UNIX OR DE_OS_IS_QNX) 49 add_definitions(-D_XOPEN_SOURCE=600) 50endif () 51 52add_library(deutil STATIC ${DEUTIL_SRCS}) 53target_link_libraries(deutil ${DEUTIL_LIBS}) 54