1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-03-20 07:49:42 +01:00

Move Tomahawk version info out of config.h, should reduce code recompilation/increase ccache cache hits

This commit is contained in:
Dominik Schmidt 2012-11-03 02:15:12 +01:00
parent 4557eb6b1b
commit 997c77ca18
7 changed files with 15 additions and 48 deletions

View File

@ -155,6 +155,8 @@ ENDIF(QCA2_FOUND)
INCLUDE(GNUInstallDirs)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/Config.h.in
${CMAKE_CURRENT_BINARY_DIR}/config.h)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/TomahawkVersion.h.in
${CMAKE_CURRENT_BINARY_DIR}/TomahawkVersion.h)
# translations
include( ${CMAKE_SOURCE_DIR}/lang/translations.cmake )

View File

@ -1,11 +1,6 @@
#ifndef CONFIG_H_IN
#define CONFIG_H_IN
#cmakedefine TOMAHAWK_ORGANIZATION_NAME "${TOMAHAWK_ORGANIZATION_NAME}"
#cmakedefine TOMAHAWK_ORGANIZATION_DOMAIN "${TOMAHAWK_ORGANIZATION_DOMAIN}"
#cmakedefine TOMAHAWK_APPLICATION_NAME "${TOMAHAWK_APPLICATION_NAME}"
#cmakedefine TOMAHAWK_VERSION "${TOMAHAWK_VERSION}"
#cmakedefine DEBUG_BUILD
#define CMAKE_INSTALL_PREFIX "${CMAKE_INSTALL_PREFIX}"

View File

@ -21,6 +21,7 @@
#include "ui_DiagnosticsDialog.h"
#include "config.h"
#include "TomahawkVersion.h"
#include <QLabel>
#include <QTextEdit>

View File

@ -20,6 +20,8 @@
#include "TomahawkApp.h"
#include "TomahawkVersion.h"
#include <iostream>
#include <QtCore/QPluginLoader>

9
src/TomahawkVersion.h.in Normal file
View File

@ -0,0 +1,9 @@
#ifndef TOMAHAWK_VERSION_H
#define TOMAHAWK_VERSION_H
#cmakedefine TOMAHAWK_ORGANIZATION_NAME "${TOMAHAWK_ORGANIZATION_NAME}"
#cmakedefine TOMAHAWK_ORGANIZATION_DOMAIN "${TOMAHAWK_ORGANIZATION_DOMAIN}"
#cmakedefine TOMAHAWK_APPLICATION_NAME "${TOMAHAWK_APPLICATION_NAME}"
#cmakedefine TOMAHAWK_VERSION "${TOMAHAWK_VERSION}"
#endif // TOMAHAWK_VERSION_H

View File

@ -1,43 +0,0 @@
project( tomahawk )
include( ${QT_USE_FILE} )
add_definitions( ${QT_DEFINITIONS} )
add_definitions( -DQT_PLUGIN )
add_definitions( -DQT_SHARED )
add_definitions( -DINFOPLUGINDLLEXPORT_PRO )
set( chartsInfoPluginSources
ChartsPlugin.cpp
)
set( chartsInfoPluginHeaders
ChartsPlugin.h
)
include_directories(
${QT_INCLUDE_DIR}
)
qt4_wrap_cpp( chartsInfoPluginMoc ${chartsInfoPluginHeaders} )
add_library( tomahawk_infoplugin_charts SHARED ${chartsInfoPluginSources} ${chartsInfoPluginMoc} ${RC_SRCS} )
IF( WIN32 )
SET( OS_SPECIFIC_LINK_LIBRARIES
${OS_SPECIFIC_LINK_LIBRARIES}
"winmm.dll"
"iphlpapi.a"
)
ENDIF( WIN32 )
target_link_libraries( tomahawk_infoplugin_charts
${TOMAHAWK_LIBRARIES}
${QT_LIBRARIES}
${OS_SPECIFIC_LINK_LIBRARIES}
)
IF( APPLE )
# SET( CMAKE_SHARED_LINKER_FLAGS ${CMAKE_SHARED_LINKER_FLAGS} "-undefined dynamic_lookup" )
ENDIF( APPLE )
install( TARGETS tomahawk_infoplugin_charts DESTINATION ${CMAKE_INSTALL_LIBDIR} )

View File

@ -18,6 +18,7 @@
* along with Tomahawk. If not, see <http://www.gnu.org/licenses/>.
*/
#include "TomahawkVersion.h"
#include "config.h"
#include "HeadlessCheck.h"
#include "TomahawkSettings.h"