mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-04-13 04:21:51 +02:00
* Fixed headless mode. Enabled AudioEngine and decoders in headless mode.
This commit is contained in:
parent
2a5c5f3562
commit
b4245f58f6
@ -16,14 +16,11 @@ ENDIF()
|
||||
FIND_PACKAGE( Taglib 1.6.0 REQUIRED )
|
||||
FIND_PACKAGE( LibLastFm REQUIRED )
|
||||
|
||||
IF( "${gui}" STREQUAL "no" )
|
||||
IF( UNIX AND NOT APPLE )
|
||||
ADD_SUBDIRECTORY( alsa-playback )
|
||||
ELSE()
|
||||
IF( UNIX AND NOT APPLE )
|
||||
ADD_SUBDIRECTORY( alsa-playback )
|
||||
ELSE()
|
||||
ADD_SUBDIRECTORY( rtaudio )
|
||||
ENDIF( UNIX AND NOT APPLE )
|
||||
ENDIF()
|
||||
ADD_SUBDIRECTORY( rtaudio )
|
||||
ENDIF( UNIX AND NOT APPLE )
|
||||
|
||||
ADD_SUBDIRECTORY( libportfwd )
|
||||
ADD_SUBDIRECTORY( qxtweb-standalone )
|
||||
|
@ -27,6 +27,7 @@
|
||||
#include "sourcelist.h"
|
||||
#include "servent.h"
|
||||
|
||||
class AudioEngine;
|
||||
class Database;
|
||||
class Jabber;
|
||||
class XMPPBot;
|
||||
@ -42,7 +43,6 @@ namespace Tomahawk
|
||||
}
|
||||
|
||||
#ifndef TOMAHAWK_HEADLESS
|
||||
class AudioEngine;
|
||||
class TomahawkWindow;
|
||||
class PlaylistManager;
|
||||
#include <QStackedWidget>
|
||||
@ -69,6 +69,7 @@ public:
|
||||
static TomahawkApp* instance();
|
||||
|
||||
Tomahawk::Pipeline* pipeline() { return &m_pipeline; }
|
||||
AudioEngine* audioEngine() { return m_audioEngine; }
|
||||
Database* database() { return m_db; }
|
||||
SourceList& sourcelist() { return m_sources; }
|
||||
Servent& servent() { return m_servent; }
|
||||
@ -78,10 +79,10 @@ public:
|
||||
XMPPBot* xmppBot() { return m_xmppBot; }
|
||||
const QString& nodeID() const;
|
||||
|
||||
|
||||
#ifndef TOMAHAWK_HEADLESS
|
||||
AudioControls* audioControls();
|
||||
PlaylistManager* playlistManager();
|
||||
AudioEngine* audioEngine() { return m_audioEngine; }
|
||||
#endif
|
||||
|
||||
void registerIODeviceFactory( const QString &proto, boost::function<QSharedPointer<QIODevice>(Tomahawk::result_ptr)> fac );
|
||||
@ -121,6 +122,7 @@ private:
|
||||
QList<TomahawkPlugin*> m_plugins;
|
||||
|
||||
Tomahawk::Pipeline m_pipeline;
|
||||
AudioEngine* m_audioEngine;
|
||||
Database* m_db;
|
||||
Servent m_servent;
|
||||
SourceList m_sources;
|
||||
@ -130,7 +132,6 @@ private:
|
||||
|
||||
#ifndef TOMAHAWK_HEADLESS
|
||||
TomahawkWindow* m_mainwindow;
|
||||
AudioEngine* m_audioEngine;
|
||||
#ifndef NO_LIBLASTFM
|
||||
Scrobbler* m_scrobbler;
|
||||
#endif
|
||||
|
@ -1,8 +1,12 @@
|
||||
SET( OS_SPECIFIC_LINK_LIBRARIES
|
||||
${OS_SPECIFIC_LINK_LIBRARIES}
|
||||
alsaplayback
|
||||
)
|
||||
|
||||
IF( "${gui}" STREQUAL "no" )
|
||||
ELSE()
|
||||
SET( OS_SPECIFIC_LINK_LIBRARIES
|
||||
${OS_SPECIFIC_LINK_LIBRARIES}
|
||||
alsaplayback
|
||||
gnutls
|
||||
)
|
||||
ENDIF()
|
||||
|
@ -1,21 +1,13 @@
|
||||
IF( "${gui}" STREQUAL "no" )
|
||||
ELSE()
|
||||
SET( tomahawkSourcesGui ${tomahawkSourcesGui}
|
||||
audio/rtaudiooutput.cpp
|
||||
)
|
||||
SET( tomahawkSourcesGui ${tomahawkSourcesGui} audio/rtaudiooutput.cpp )
|
||||
SET( tomahawkHeadersGui ${tomahawkHeadersGui} audio/rtaudiooutput.h )
|
||||
|
||||
SET( tomahawkHeadersGui ${tomahawkHeadersGui}
|
||||
audio/rtaudiooutput.h
|
||||
)
|
||||
FIND_LIBRARY( COREAUDIO_LIBRARY CoreAudio )
|
||||
FIND_LIBRARY( COREFOUNDATION_LIBRARY CoreFoundation )
|
||||
MARK_AS_ADVANCED( COREAUDIO_LIBRARY COREFOUNDATION_LIBRARY )
|
||||
|
||||
FIND_LIBRARY( COREAUDIO_LIBRARY CoreAudio )
|
||||
FIND_LIBRARY( COREFOUNDATION_LIBRARY CoreFoundation )
|
||||
MARK_AS_ADVANCED( COREAUDIO_LIBRARY COREFOUNDATION_LIBRARY )
|
||||
|
||||
SET( OS_SPECIFIC_LINK_LIBRARIES
|
||||
${OS_SPECIFIC_LINK_LIBRARIES}
|
||||
${COREAUDIO_LIBRARY}
|
||||
${COREFOUNDATION_LIBRARY}
|
||||
rtaudio
|
||||
)
|
||||
ENDIF()
|
||||
SET( OS_SPECIFIC_LINK_LIBRARIES
|
||||
${OS_SPECIFIC_LINK_LIBRARIES}
|
||||
${COREAUDIO_LIBRARY}
|
||||
${COREFOUNDATION_LIBRARY}
|
||||
rtaudio
|
||||
)
|
||||
|
@ -35,6 +35,10 @@ SET( tomahawkSources ${tomahawkSources}
|
||||
source.cpp
|
||||
sourcelist.cpp
|
||||
|
||||
audio/madtranscode.cpp
|
||||
audio/vorbistranscode.cpp
|
||||
audio/audioengine.cpp
|
||||
|
||||
utils/tomahawkutils.cpp
|
||||
jabber/jabber_p.cpp
|
||||
|
||||
@ -81,8 +85,9 @@ SET( tomahawkSources ${tomahawkSources}
|
||||
database/databasecommand_updatesearchindex.cpp
|
||||
database/databasecollection.cpp
|
||||
|
||||
xmppbot/xmppbot.cpp
|
||||
scrobbler.cpp
|
||||
|
||||
xmppbot/xmppbot.cpp
|
||||
web/api_v1.cpp
|
||||
|
||||
tomahawksettings.cpp
|
||||
@ -98,9 +103,6 @@ SET( tomahawkSourcesGui ${tomahawkSourcesGui}
|
||||
utils/proxystyle.cpp
|
||||
utils/widgetdragfilter.cpp
|
||||
|
||||
audio/madtranscode.cpp
|
||||
audio/audioengine.cpp
|
||||
|
||||
playlist/collectionmodel.cpp
|
||||
playlist/collectionproxymodel.cpp
|
||||
playlist/collectionflatmodel.cpp
|
||||
@ -153,6 +155,11 @@ SET( tomahawkHeaders ${tomahawkHeaders}
|
||||
"${TOMAHAWK_INC_DIR}/tomahawk/functimeout.h"
|
||||
# "${TOMAHAWK_INC_DIR}/tomahawk/tomahawkplugin.h"
|
||||
|
||||
audio/transcodeinterface.h
|
||||
audio/madtranscode.h
|
||||
audio/vorbistranscode.h
|
||||
audio/audioengine.h
|
||||
|
||||
database/fuzzyindex.h
|
||||
database/database.h
|
||||
database/databaseworker.h
|
||||
@ -199,8 +206,9 @@ SET( tomahawkHeaders ${tomahawkHeaders}
|
||||
network/filetransferconnection.h
|
||||
network/dbsyncconnection.h
|
||||
|
||||
xmppbot/xmppbot.h
|
||||
scrobbler.h
|
||||
|
||||
xmppbot/xmppbot.h
|
||||
web/api_v1.h
|
||||
)
|
||||
|
||||
@ -212,10 +220,6 @@ SET( tomahawkHeadersGui ${tomahawkHeadersGui}
|
||||
utils/progresstreeview.h
|
||||
utils/widgetdragfilter.h
|
||||
|
||||
audio/transcodeinterface.h
|
||||
audio/madtranscode.h
|
||||
audio/audioengine.h
|
||||
|
||||
playlist/collectionmodel.h
|
||||
playlist/collectionproxymodel.h
|
||||
playlist/collectionflatmodel.h
|
||||
|
@ -12,15 +12,9 @@ SET( OS_SPECIFIC_LINK_LIBRARIES
|
||||
qxtweb-standalone
|
||||
)
|
||||
|
||||
IF( "${gui}" STREQUAL "no" )
|
||||
ELSE()
|
||||
SET( OS_SPECIFIC_LINK_LIBRARIES
|
||||
${OS_SPECIFIC_LINK_LIBRARIES}
|
||||
mad
|
||||
vorbisfile
|
||||
ogg
|
||||
)
|
||||
|
||||
SET( tomahawkSourcesGui ${tomahawkSourcesGui} audio/vorbistranscode.cpp scrobbler.cpp )
|
||||
SET( tomahawkHeadersGui ${tomahawkHeadersGui} audio/vorbistranscode.h scrobbler.h )
|
||||
ENDIF()
|
||||
SET( OS_SPECIFIC_LINK_LIBRARIES
|
||||
${OS_SPECIFIC_LINK_LIBRARIES}
|
||||
mad
|
||||
vorbisfile
|
||||
ogg
|
||||
)
|
||||
|
@ -31,22 +31,17 @@ SET( OS_SPECIFIC_LINK_LIBRARIES
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/../qxtweb-standalone/libqxtweb-standalone.dll"
|
||||
)
|
||||
|
||||
IF( "${gui}" STREQUAL "no" )
|
||||
ELSE()
|
||||
SET( tomahawkSourcesGui ${tomahawkSourcesGui}
|
||||
audio/rtaudiooutput.cpp
|
||||
)
|
||||
SET( tomahawkHeadersGui ${tomahawkHeadersGui} audio/rtaudiooutput.h )
|
||||
SET( tomahawkSourcesGui ${tomahawkSourcesGui} audio/rtaudiooutput.cpp )
|
||||
SET( tomahawkHeadersGui ${tomahawkHeadersGui} audio/rtaudiooutput.h )
|
||||
|
||||
SET( OS_SPECIFIC_LINK_LIBRARIES
|
||||
${OS_SPECIFIC_LINK_LIBRARIES}
|
||||
"dsound.dll"
|
||||
"winmm.dll"
|
||||
"iphlpapi.a"
|
||||
"mad"
|
||||
"vorbisfile"
|
||||
"ogg"
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/../rtaudio/librtaudio.dll"
|
||||
)
|
||||
ENDIF()
|
||||
SET( OS_SPECIFIC_LINK_LIBRARIES
|
||||
${OS_SPECIFIC_LINK_LIBRARIES}
|
||||
"dsound.dll"
|
||||
"winmm.dll"
|
||||
"iphlpapi.a"
|
||||
"mad"
|
||||
"vorbisfile"
|
||||
"ogg"
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/../rtaudio/librtaudio.dll"
|
||||
)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user