Answer the question
In order to leave comments, you need to log in
How to include the android boost library in Qt?
I downloaded CrystaX NDK , as I understand it, there are already compiled libraries that you just need to connect.
QT += core gui
greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
TARGET = qt_test
TEMPLATE = app
INCLUDEPATH += C:/qt_projects/-----X-----/boost/1.59.0/include
LIBS += C:/qt_projects/-----X-----/boost/1.59.0/libs
DEFINES += QT_DEPRECATED_WARNINGS
CONFIG += c++14
SOURCES += main.cpp\
mainwindow.cpp \
graph.cpp \
textrank.cpp
HEADERS += mainwindow.h \
graph.hpp \
textrank.hpp
FORMS += mainwindow.ui
contains(ANDROID_TARGET_ARCH,x86) {
ANDROID_EXTRA_LIBS = \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_atomic.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_chrono.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_container.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_context.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_coroutine.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_date_time.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_filesystem.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_graph.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_iostreams.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_locale.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_log.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_log_setup.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_math_c99.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_math_c99f.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_math_c99l.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_math_tr1.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_math_tr1f.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_math_tr1l.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_prg_exec_monitor.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_program_options.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_python.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_python3.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_random.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_regex.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_serialization.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_signals.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_system.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_thread.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_timer.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_unit_test_framework.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_wave.so \
C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/libboost_wserialization.so
}
Answer the question
In order to leave comments, you need to log in
Under android did not work, but apparently the line
LIBS += C:/qt_projects/-----X-----/boost/1.59.0/libs
superfluous. contains(ANDROID_TARGET_ARCH,x86) {
ANDROID_EXTRA_LIBS += \
L"C:/qt_projects/-----X-----/boost/1.59.0/libs/x86/gnu-5/" \
lboost_atomic \
lboost_chrono \
..........
}
by analogy with the standard qmake addition to LIBS (Lpath is the path to the directory with libs, lname is the name of the library without lib and .so) Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question