vcpkg/ports/libgo/libgo-config.cmake
yyzybb537 68447ced17 Add libgo library packge (#3394)
* Add libgo library packge

* [libgo] Fix Windows and adjust cmake usage information
2018-05-02 22:36:19 -07:00

26 lines
820 B
CMake

get_filename_component(_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH)
if(NOT LIBGO_FIND_COMPONENTS)
set(LIBGO_FIND_COMPONENTS libgo libgo)
if(LIBGO_FIND_REQUIRED)
set(LIBGO_FIND_REQUIRED_libgo TRUE)
endif()
set(LIBGO_FOUND TRUE)
endif()
set(LIBGO_INCLUDE_DIRS ${_DIR}/../../include)
set(LIBGO_LIBRARIES)
if (EXISTS ${_DIR}/../../lib/liblibgo.a)
list(APPEND LIBGO_LIBRARIES optimized ${_DIR}/../../lib/liblibgo.a)
endif()
if (EXISTS ${_DIR}/../../debug/lib/liblibgo.a)
list(APPEND LIBGO_LIBRARIES debug ${_DIR}/../../debug/lib/liblibgo.a)
endif()
if (EXISTS ${_DIR}/../../lib/libgo.lib)
list(APPEND LIBGO_LIBRARIES optimized ${_DIR}/../../lib/libgo.lib)
endif()
if (EXISTS ${_DIR}/../../debug/lib/libgo.lib)
list(APPEND LIBGO_LIBRARIES debug ${_DIR}/../../debug/lib/libgo.lib)
endif()