Skip to content

Commit

Permalink
add D_XOPEN_SOURCE flag for compile on mac, linux
Browse files Browse the repository at this point in the history
  • Loading branch information
fschloesser committed Aug 13, 2021
1 parent 518622c commit 5d5bd88
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG
Expand Up @@ -47,6 +47,8 @@ Build system

### Cmake

- add -D_XOPEN_SOURCE=600 cflag for compilation on systems other than windows

### Makefile

Fixed bugs
Expand Down
5 changes: 5 additions & 0 deletions src/CMakeLists.txt
Expand Up @@ -9,6 +9,11 @@ endfunction(setLibProperties)

set(CMAKE_C_STANDARD 99)
set(CMAKE_C_STANDARD_REQUIRED on)
set(CMAKE_C_EXTENSIONS OFF)

if(NOT WIN32)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_XOPEN_SOURCE=600")
endif()

#configure the scipbuildflags.c source file for the build tree
configure_file(${PROJECT_SOURCE_DIR}/src/scipbuildflags.c.in
Expand Down

0 comments on commit 5d5bd88

Please sign in to comment.