I'm trying to compile a Qt project with Portaudio library and Steinberg's ASIO SDK. I managed to compile Portaudio without ASIO, but when doing it with both libraries I get 7 errors like this (with different functions):
asiolist.obj:-1: error: LNK2019: unresolved external symbol
__imp__RegCloseKey@4 referenced in function "public: __thiscall
AsioDriverList::AsioDriverList(void)" (??0AsioDriverList@@QAE@XZ)
I followed these instructions carefully: http://portaudio.com/docs/v19-doxydocs/compile_windows_asio_msvc.html, and I'm using Qt with MSVS compiler.
Here is my .pro file
#-------------------------------------------------
#
# Project created by QtCreator 2015-06-16T11:52:41
#
#-------------------------------------------------
QT += core
QT -= gui
TARGET = audio
CONFIG += console
CONFIG -= app_bundle
TEMPLATE = app
INCLUDEPATH += ../portaudio/include \
../portaudio/src/common \
../portaudio/src/os/win \
../ASIOSDK2.3/common \
../ASIOSDK2.3/host \
../ASIOSDK2.3/host/pc
HEADERS += \
../portaudio/include/pa_asio.h \
../portaudio/include/portaudio.h
SOURCES+= main.cpp \
../ASIOSDK2.3/common/asio.cpp \
../ASIOSDK2.3/host/pc/asiolist.cpp \
../portaudio/src/hostapi/asio/pa_asio.cpp \
../portaudio/src/common/pa_allocation.c \
../portaudio/src/common/pa_converters.c \
../portaudio/src/common/pa_cpuload.c \
../portaudio/src/common/pa_debugprint.c \
../portaudio/src/common/pa_dither.c \
../portaudio/src/common/pa_front.c \
../portaudio/src/common/pa_process.c \
../portaudio/src/common/pa_ringbuffer.c \
../portaudio/src/common/pa_stream.c \
../portaudio/src/common/pa_trace.c \
../portaudio/src/os/win/pa_win_coinitialize.c \
../portaudio/src/os/win/pa_win_hostapis.c \
../portaudio/src/os/win/pa_win_util.c \
../portaudio/src/os/win/pa_win_waveformat.c \
../portaudio/src/os/win/pa_win_wdmks_utils.c \
../portaudio/src/os/win/pa_x86_plain_converters.c \
../ASIOSDK2.3/host/asiodrivers.cpp
DEFINES += PA_USE_ASIO=1
Does anyone have a clue? It seems as if ASIOSDK were not properly linked, but I have no idea how to fix it. Thank's so much!
I found out what was happening:
The problem was with some WINAPI functions, just had to add: