Merge pull request #792 from yegorich/ftdi-fix-deprecated-call

avrftdi: don't use the deprecated ftdi_usb_purge_buffers routine
This commit is contained in:
Jörg Wunsch
2022-01-05 17:41:08 +01:00
committed by GitHub
4 changed files with 12 additions and 0 deletions

View File

@@ -36,6 +36,7 @@ option(DEBUG_CMAKE "Enable debugging output for this CMake project" OFF)
include(CheckIncludeFile)
include(CheckFunctionExists)
include(CheckSymbolExists)
include(GNUInstallDirs)
include(FindPackageMessage)
@@ -238,6 +239,8 @@ find_library(HAVE_LIBFTDI1 NAMES ${PREFERRED_LIBFTDI1})
if(HAVE_LIBFTDI1)
set(LIB_LIBFTDI1 ${HAVE_LIBFTDI1})
set(HAVE_LIBFTDI_TYPE_232H 1)
set(CMAKE_REQUIRED_LIBRARIES ${LIB_LIBFTDI1} ${LIB_LIBUSB} ${LIB_LIBUSB_1_0})
check_symbol_exists(ftdi_tcioflush "libftdi1/ftdi.h" HAVE_FTDI_TCIOFLUSH)
endif()
# -------------------------------------