Add compile definition to indicate using of libtorrent 2.0 (#15297)

The compile definition is temporary which will be removed when qbt
ditches libtorrent 1.x.
This commit is contained in:
Chocobo1 2021-08-08 13:27:22 +08:00 committed by GitHub
commit 138c911ef4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
23 changed files with 85 additions and 93 deletions

View file

@ -178,7 +178,7 @@ AC_COMPILE_IFELSE([DETECT_BOOST_VERSION_PROGRAM(106000)], [],
PKG_CHECK_MODULES(libtorrent,
[libtorrent-rasterbar >= 2.0.4],
[CXXFLAGS="$libtorrent_CFLAGS $CXXFLAGS" LIBS="$libtorrent_LIBS $LIBS"],
[CXXFLAGS="$libtorrent_CFLAGS $CXXFLAGS" LIBS="$libtorrent_LIBS $LIBS" QBT_ADD_DEFINES="$QBT_ADD_DEFINES QBT_USES_LIBTORRENT2"],
[PKG_CHECK_MODULES(libtorrent,
[libtorrent-rasterbar >= 1.2.14 libtorrent-rasterbar < 2],
[CXXFLAGS="$libtorrent_CFLAGS $CXXFLAGS" LIBS="$libtorrent_LIBS $LIBS"])])