diff --git a/lib/whereami/CMakeLists.txt b/lib/whereami/CMakeLists.txt index 22e1646..e352523 100644 --- a/lib/whereami/CMakeLists.txt +++ b/lib/whereami/CMakeLists.txt @@ -5,14 +5,6 @@ set(LIBARY_NAME ${PROJECT_NAME}) # Create static library add_library(${LIBARY_NAME} STATIC whereami.c whereami.h) -# Add X/Open definition for realpath -#target_compile_definitions(${LIBARY_NAME} PUBLIC _XOPEN_SOURCE=500) - -# MacOS specific compile flag -#if(APPLE) -# target_compile_definitions(${LIBARY_NAME} PUBLIC _DARWIN_C_SOURCE) -#endif() - # Use PUBLIC iso INTERFACE, so the library itself also finds it's own header file target_include_directories( ${LIBARY_NAME} diff --git a/lib/whereami/whereami.c b/lib/whereami/whereami.c index 05874bc..97f7f85 100644 --- a/lib/whereami/whereami.c +++ b/lib/whereami/whereami.c @@ -13,8 +13,8 @@ extern "C" { #endif #if defined(__linux__) || defined(__CYGWIN__) -#undef _BSD_SOURCE -#define _BSD_SOURCE +#undef _DEFAULT_SOURCE +#define _DEFAULT_SOURCE #elif defined(__APPLE__) #undef _DARWIN_C_SOURCE #define _DARWIN_C_SOURCE