From d92288d6cc2f12dc3bd556196fbd2461d051d6f7 Mon Sep 17 00:00:00 2001 From: Christian Muehlhaeuser Date: Thu, 18 Nov 2010 01:39:07 +0100 Subject: [PATCH] * Cross compiling build fixes. --- admin/win/revision.txt | 2 +- admin/win/tomahawk.nsi | 99 +++++++++++++++++++++------------------- src/CMakeLists.txt | 2 +- src/CMakeLists.win32.txt | 4 +- 4 files changed, 57 insertions(+), 50 deletions(-) mode change 100755 => 100644 admin/win/revision.txt diff --git a/admin/win/revision.txt b/admin/win/revision.txt old mode 100755 new mode 100644 index 368f89cee..7c091989d --- a/admin/win/revision.txt +++ b/admin/win/revision.txt @@ -1 +1 @@ -28 \ No newline at end of file +37 \ No newline at end of file diff --git a/admin/win/tomahawk.nsi b/admin/win/tomahawk.nsi index 691d7e7b8..694e3ae48 100755 --- a/admin/win/tomahawk.nsi +++ b/admin/win/tomahawk.nsi @@ -16,12 +16,13 @@ ;----------------------------------------------------------------------------- !define MING_PATH "/usr/i686-pc-mingw32/sys-root/mingw" !define MING_BIN "${MING_PATH}/bin" -!define MING_DLL_PATH "dlls" ; "${MING_BIN}" +!define MING_DLL_PATH "${MING_BIN}" +!define MING_LIB "${MING_PATH}/lib" !define ROOT_PATH "..\.." ; assuming the script is in ROOT/admin/win/ -!define QT_DLL_PATH "dlls" -!define SQLITE_DLL_PATH "dlls\sqldrivers" ; "${MING_PATH}/lib/qt4/plugins/sqldrivers/" -!define RTAUDIO_DLL_PATH "dlls" ; "../../rtaudio/" -!define QXTWEB_DLL_PATH "dlls" ; "../../qxtweb-standalone/" +!define QT_DLL_PATH "${MING_BIN}" +!define SQLITE_DLL_PATH "${MING_LIB}/qt4/plugins/sqldrivers" +!define RTAUDIO_DLL_PATH "../../rtaudio/" +!define QXTWEB_DLL_PATH "../../qxt/qxtweb-standalone/" ;----------------------------------------------------------------------------- ; Increment installer revision number as part of this script. @@ -56,7 +57,7 @@ InstType Full InstType Minimal CRCCheck On SetCompressor /SOLID lzma -RequestExecutionLevel user ;Using the UAC plugin. +;RequestExecutionLevel user ;Using the UAC plugin. ReserveFile tomahawk.ini ReserveFile "${NSISDIR}\Plugins\InstallOptions.dll" @@ -70,7 +71,7 @@ ReserveFile "${NSISDIR}\Plugins\InstallOptions.dll" !include Memento.nsh ;Remember user selections. !include WinVer.nsh ;Windows version detection. !include WordFunc.nsh ;Used by VersionCompare macro function. -!include UAC.nsh ;Used by the UAC elevation to install as user or admin. +;!include UAC.nsh ;Used by the UAC elevation to install as user or admin. ;----------------------------------------------------------------------------- ; Memento selections stored in registry. @@ -135,7 +136,7 @@ UninstPage custom un.UnPageUserAppData un.UnPageUserAppDataLeave ############################################################################## Function LaunchTomahawk - ${UAC.CallFunctionAsUser} LaunchTomahawkAsUser + ;${UAC.CallFunctionAsUser} LaunchTomahawkAsUser FunctionEnd Function LaunchTomahawkAsUser @@ -210,7 +211,7 @@ Function PageLeaveReinstall RMDir $INSTDIR no_remove_uninstaller: StrCmp $R0 "2" 0 +3 - UAC::Unload + ;UAC::Unload Quit BringToFront reinst_done: @@ -260,6 +261,10 @@ Section "Tomahawk Player" SEC_TOMAHAWK_PLAYER ;Audio stuff ;File "${MING_DLL_PATH}\libmad.dll" ;File "${MING_DLL_PATH}\librtaudio.dll" + File "${RTAUDIO_DLL_PATH}\librtaudio.dll" + File "${MING_DLL_PATH}\libogg-0.dll" + File "${MING_DLL_PATH}\libvorbisfile-3.dll" + File "${MING_DLL_PATH}\libvorbis-0.dll" ;Other File "${MING_DLL_PATH}\libqjson.dll" @@ -267,8 +272,10 @@ Section "Tomahawk Player" SEC_TOMAHAWK_PLAYER File "${MING_DLL_PATH}\libgloox-8.dll" File "${MING_DLL_PATH}\libpng14-14.dll" File "${MING_DLL_PATH}\zlib1.dll" + File "${MING_DLL_PATH}\libechonest.dll" - File "${RTAUDIO_DLL_PATH}\librtaudio.dll" + File "${MING_DLL_PATH}\liblastfm.dll" + File "${QXTWEB_DLL_PATH}\libqxtweb-standalone.dll" SectionEnd @@ -466,25 +473,25 @@ Function .onInit ${MementoSectionRestore} - UAC_Elevate: - UAC::RunElevated - StrCmp 1223 $0 UAC_ElevationAborted ; UAC dialog aborted by user? - StrCmp 0 $0 0 UAC_Err ; Error? - StrCmp 1 $1 0 UAC_Success ;Are we the real deal or just the wrapper? - Quit + ;UAC_Elevate: + ;UAC::RunElevated + ;StrCmp 1223 $0 UAC_ElevationAborted ; UAC dialog aborted by user? + ;StrCmp 0 $0 0 UAC_Err ; Error? + ;StrCmp 1 $1 0 UAC_Success ;Are we the real deal or just the wrapper? + ;Quit - UAC_Err: - MessageBox MB_ICONSTOP "Unable to elevate, error $0" - Abort + ;UAC_Err: + ;MessageBox MB_ICONSTOP "Unable to elevate, error $0" + ;Abort - UAC_ElevationAborted: - Abort + ;UAC_ElevationAborted: + ;Abort - UAC_Success: - StrCmp 1 $3 +4 ;Admin? - StrCmp 3 $1 0 UAC_ElevationAborted ;Try again? - MessageBox MB_ICONSTOP "This installer requires admin access, try again" - goto UAC_Elevate + ;UAC_Success: + ;StrCmp 1 $3 +4 ;Admin? + ;StrCmp 3 $1 0 UAC_ElevationAborted ;Try again? + ;MessageBox MB_ICONSTOP "This installer requires admin access, try again" + ;goto UAC_Elevate ;Prevent multiple instances. System::Call 'kernel32::CreateMutexA(i 0, i 0, t "tomahawkInstaller") i .r1 ?e' @@ -496,11 +503,11 @@ FunctionEnd Function .onInstSuccess ${MementoSectionSave} - UAC::Unload ;Must call unload! + ;UAC::Unload ;Must call unload! FunctionEnd Function .onInstFailed - UAC::Unload ;Must call unload! + ;UAC::Unload ;Must call unload! FunctionEnd ############################################################################## @@ -511,25 +518,25 @@ FunctionEnd Function un.onInit - UAC_Elevate: - UAC::RunElevated - StrCmp 1223 $0 UAC_ElevationAborted ; UAC dialog aborted by user? - StrCmp 0 $0 0 UAC_Err ; Error? - StrCmp 1 $1 0 UAC_Success ;Are we the real deal or just the wrapper? - Quit + ;UAC_Elevate: + ;UAC::RunElevated + ;StrCmp 1223 $0 UAC_ElevationAborted ; UAC dialog aborted by user? + ;StrCmp 0 $0 0 UAC_Err ; Error? + ;StrCmp 1 $1 0 UAC_Success ;Are we the real deal or just the wrapper? + ;Quit - UAC_Err: - MessageBox MB_ICONSTOP "Unable to elevate, error $0" - Abort + ;UAC_Err: + ;MessageBox MB_ICONSTOP "Unable to elevate, error $0" + ;Abort - UAC_ElevationAborted: - Abort + ;UAC_ElevationAborted: + ;Abort - UAC_Success: - StrCmp 1 $3 +4 ;Admin? - StrCmp 3 $1 0 UAC_ElevationAborted ;Try again? - MessageBox MB_ICONSTOP "This uninstaller requires admin access, try again" - goto UAC_Elevate + ;UAC_Success: + ;StrCmp 1 $3 +4 ;Admin? + ;StrCmp 3 $1 0 UAC_ElevationAborted ;Try again? + ;MessageBox MB_ICONSTOP "This uninstaller requires admin access, try again" + ;goto UAC_Elevate ;Prevent multiple instances. System::Call 'kernel32::CreateMutexA(i 0, i 0, t "tomahawkUninstaller") i .r1 ?e' @@ -540,9 +547,9 @@ Function un.onInit FunctionEnd Function un.onUnInstSuccess - UAC::Unload ;Must call unload! + ;UAC::Unload ;Must call unload! FunctionEnd Function un.onUnInstFailed - UAC::Unload ;Must call unload! + ;UAC::Unload ;Must call unload! FunctionEnd diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 751324fc1..18e5c2b46 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -347,8 +347,8 @@ MESSAGE( STATUS "OS_SPECIFIC_LINK_LIBRARIES: ${OS_SPECIFIC_LINK_LIBRARIES}" ) TARGET_LINK_LIBRARIES( tomahawk ${QT_LIBRARIES} ${MAC_EXTRA_LIBS} - ${OS_SPECIFIC_LINK_LIBRARIES} portfwd + ${OS_SPECIFIC_LINK_LIBRARIES} echonest qjson tag diff --git a/src/CMakeLists.win32.txt b/src/CMakeLists.win32.txt index 44d53325a..5652d47a8 100644 --- a/src/CMakeLists.win32.txt +++ b/src/CMakeLists.win32.txt @@ -1,8 +1,8 @@ ADD_DEFINITIONS( /DNOMINMAX ) ADD_DEFINITIONS( /DWIN32_LEAN_AND_MEAN ) ADD_DEFINITIONS( -static-libgcc ) -ADD_DEFINITIONS( /DNO_LIBLASTFM ) -ADD_DEFINITIONS( -DNO_OGG ) +#ADD_DEFINITIONS( /DNO_LIBLASTFM ) +#ADD_DEFINITIONS( -DNO_OGG ) # Add manual locations to stuff: INCLUDE_DIRECTORIES(