mirror of https://github.com/mgba-emu/mgba.git
Qt: Fix Qt::5Multimedia build
This commit is contained in:
parent
e407095389
commit
e25fa272a8
|
@ -5,6 +5,7 @@
|
|||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
#ifndef QGBA_AUDIO_DEVICE
|
||||
#define QGBA_AUDIO_DEVICE
|
||||
|
||||
#include <QAudioFormat>
|
||||
#include <QIODevice>
|
||||
|
||||
|
|
|
@ -7,6 +7,8 @@
|
|||
#define QGBA_AUDIO_PROCESSOR_QT
|
||||
#include "AudioProcessor.h"
|
||||
|
||||
class QAudioOutput;
|
||||
|
||||
namespace QGBA {
|
||||
|
||||
class AudioDevice;
|
||||
|
|
|
@ -54,13 +54,14 @@ qt5_wrap_ui(UI_FILES
|
|||
LogView.ui
|
||||
VideoView.ui)
|
||||
|
||||
set(QT_LIBRARIES)
|
||||
set(CPACK_DEBIAN_PACKAGE_DEPENDS "${CPACK_DEBIAN_PACKAGE_DEPENDS},libqt5widgets5,libqt5opengl5" PARENT_SCOPE)
|
||||
if(BUILD_SDL)
|
||||
list(APPEND SOURCE_FILES AudioProcessorSDL.cpp)
|
||||
elseif(Qt5Multimedia_FOUND)
|
||||
list(APPEND SOURCE_FILES
|
||||
AudioProcessorQt.cpp
|
||||
AudioDevice.cpp)
|
||||
AudioProcessorQt.cpp
|
||||
AudioDevice.cpp)
|
||||
list(APPEND QT_LIBRARIES Qt5::Multimedia)
|
||||
set(CPACK_DEBIAN_PACKAGE_DEPENDS "${CPACK_DEBIAN_PACKAGE_DEPENDS},libqt5multimedia5" PARENT_SCOPE)
|
||||
else()
|
||||
|
@ -85,7 +86,7 @@ endif()
|
|||
add_executable(${BINARY_NAME}-qt WIN32 MACOSX_BUNDLE main.cpp ${CMAKE_SOURCE_DIR}/res/mgba.icns ${SOURCE_FILES} ${PLATFORM_SRC} ${UI_FILES} ${RESOURCES})
|
||||
set_target_properties(${BINARY_NAME}-qt PROPERTIES MACOSX_BUNDLE_INFO_PLIST ${CMAKE_SOURCE_DIR}/res/info.plist.in)
|
||||
|
||||
set(QT_LIBRARIES Qt5::Widgets Qt5::OpenGL)
|
||||
list(APPEND QT_LIBRARIES Qt5::Widgets Qt5::OpenGL)
|
||||
target_link_libraries(${BINARY_NAME}-qt ${PLATFORM_LIBRARY} ${OPENGL_LIBRARY} ${BINARY_NAME} ${QT_LIBRARIES})
|
||||
|
||||
install(TARGETS ${BINARY_NAME}-qt RUNTIME DESTINATION bin BUNDLE DESTINATION /Applications)
|
||||
|
|
Loading…
Reference in New Issue