Skip to content
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions libgeotiff/bin/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ INCLUDE_DIRECTORIES(
IF(WIN32 AND MSVC)
SET(GETOPT_SOURCE getopt.c)
ENDIF()

# avoid warnings of "This function or variable may be unsafe"
if(MSVC)
add_definitions(-D_CRT_SECURE_NO_WARNINGS)
endif()

Comment thread
jmckenna marked this conversation as resolved.
Outdated
###############################################################################
# Collect programs to build

Expand All @@ -23,6 +29,21 @@ MESSAGE(STATUS "Adding GeoTIFF utilities to build")
FOREACH(utility ${GEOTIFF_UTILITIES})
ADD_EXECUTABLE(${utility} ${utility}.c ${GETOPT_SOURCE})
TARGET_LINK_LIBRARIES(${utility} PRIVATE ${GEOTIFF_LIBRARY_TARGET})

###############################################################################
# Collect programs to build

SET(GEOTIFF_UTILITIES makegeo listgeo applygeo)

MESSAGE(STATUS "Adding GeoTIFF utilities to build")

FOREACH(utility ${GEOTIFF_UTILITIES})
ADD_EXECUTABLE(${utility} ${utility}.c ${GETOPT_SOURCE})
TARGET_LINK_LIBRARIES(${utility} PRIVATE ${GEOTIFF_LIBRARY_TARGET})
# avoid warnings of "This function or variable may be unsafe"
if(MSVC)
target_compile_definitions(${utility} PRIVATE -D_CRT_SECURE_NO_WARNINGS)
endif()
ENDFOREACH()
Comment thread
jmckenna marked this conversation as resolved.
Outdated
Comment thread
rouault marked this conversation as resolved.

ADD_EXECUTABLE(geotifcp geotifcp.c ${GETOPT_SOURCE})
Expand Down
Loading