From 0bcdabc0f3ca18fc878f1a686d58fd95b5fa515d Mon Sep 17 00:00:00 2001 From: James Turner Date: Sun, 23 Jan 2011 19:57:32 +0000 Subject: [PATCH] Further work on Win release packaging. --- .gitignore | 5 +++++ FlightGear.iss | 20 ++++++++++++++------ hudson_win_build32.bat | 12 ++++++++++++ hudson_win_build64.bat | 13 +++++++++++++ hudson_win_package_release.bat | 30 ++++++++++++++++++++++++++++++ 5 files changed, 74 insertions(+), 6 deletions(-) create mode 100644 hudson_win_build32.bat create mode 100644 hudson_win_build64.bat create mode 100644 hudson_win_package_release.bat diff --git a/.gitignore b/.gitignore index 36d3a9c..6380c51 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,7 @@ dist .DS_Store +install +3rdParty +boost_1_44_0 +InstallConfig.iss +Output diff --git a/FlightGear.iss b/FlightGear.iss index 14cbb91..cf3834d 100755 --- a/FlightGear.iss +++ b/FlightGear.iss @@ -18,12 +18,16 @@ ; C:\> subst X: F:\ ; -#define FGVersion "2.2.0" -;#define VCInstallDir GetEnv(VCINSTALLDIR) -#define VCInstallDir "C:\Program Files\Microsoft Visual Studio 9.0\VC" -#define OSGSoNumber "66" +#include "InstallConfig.iss" + +#if GetEnv("VSINSTALLDIR") == "" + #define VSInstallDir "C:\Program Files\Microsoft Visual Studio 9.0" +#else + #define VSInstallDir GetEnv("VSINSTALLDIR") +#endif + +#define VCInstallDir VSInstallDir + "\VC" #define OSGInstallDir "X:\install\msvc90\OpenSceneGraph" -#define OSGVersion "2.9.9" #define OSGPluginsDir OSGInstallDir + "\bin\osgPlugins-" + OSGVersion [Setup] @@ -55,14 +59,18 @@ Name: "desktopicon"; Description: "Create a &desktop icon"; GroupDescription: "A ; NOTE: run subst X: F:\ (or whatever path the expanded tree resides at) ;Source: "X:\*.txt"; DestDir: "{app}"; Flags: ignoreversion Source: "X:\flightgear\projects\VC90\Win32\Release\*.exe"; DestDir: "{app}\bin\Win32"; Flags: ignoreversion +Source: "X:\flightgear\projects\VC90\x64\Release\*.exe"; DestDir: "{app}\bin\Win64"; Flags: ignoreversion skipifsourcedoesntexist Source: "X:\fgrun\msvc\9.0\Win32\Release\fgrun.exe"; DestDir: "{app}\bin\Win32"; Flags: ignoreversion Source: "X:\fgrun\msvc\9.0\Win32\Release\locale\*"; DestDir: "{app}\bin\Win32\locale"; Flags: ignoreversion recursesubdirs +Source: "X:\fgrun\msvc\9.0\x64\Release\fgrun.exe"; DestDir: "{app}\bin\Win64"; Flags: ignoreversion +Source: "X:\fgrun\msvc\9.0\Win32\Release\locale\*"; DestDir: "{app}\bin\Win64\locale"; Flags: ignoreversion recursesubdirs + Source: "X:\3rdParty\bin\*.dll"; DestDir: "{app}\bin\Win32" Source: "{#VCInstallDir}\redist\x86\Microsoft.VC90.CRT\*.dll"; DestDir: "{app}\bin\Win32" -Source: "X:\data\*.*"; DestDir: "{app}\data"; Flags: ignoreversion recursesubdirs +Source: "X:\data\*.*"; DestDir: "{app}\data"; Flags: ignoreversion recursesubdirs skipifsourcedoesntexist Source: "{#OSGInstallDir}\bin\osg{#OSGSoNumber}-osg.dll"; DestDir: "{app}\bin\Win32" Source: "{#OSGInstallDir}\bin\osg{#OSGSoNumber}-osgDB.dll"; DestDir: "{app}\bin\Win32" diff --git a/hudson_win_build32.bat b/hudson_win_build32.bat new file mode 100644 index 0000000..77669d5 --- /dev/null +++ b/hudson_win_build32.bat @@ -0,0 +1,12 @@ + +IF NOT DEFINED WORKSPACE SET WORKSPACE=%~dp0 + +ECHO #define SIMGEAR_VERSION "2.2.0" > %WORKSPACE%\simgear\simgear\version.h +cd %WORKSPACE%\simgear\projects\VC90 +msbuild SimGear.vcproj /p:Configuration=Release /m + +cd %WORKSPACE%\flightgear +call scripts\tools\version.bat +SET HAVE_VERSION_H=1 +cd %WORKSPACE%\flightgear\projects\VC90 +msbuild FlightGear.sln /p:Configuration=Release /m diff --git a/hudson_win_build64.bat b/hudson_win_build64.bat new file mode 100644 index 0000000..4d235de --- /dev/null +++ b/hudson_win_build64.bat @@ -0,0 +1,13 @@ + +IF NOT DEFINED WORKSPACE SET WORKSPACE=%~dp0 + +ECHO #define SIMGEAR_VERSION "2.2.0" > %WORKSPACE%\simgear\simgear\version.h +cd %WORKSPACE%\simgear\projects\VC90 +msbuild SimGear.vcproj /p:Configuration=Release /p:Platform=x64 + +cd %WORKSPACE%\flightgear +call scripts\tools\version.bat +SET HAVE_VERSION_H=1 +cd %WORKSPACE%\flightgear\projects\VC90 +msbuild FlightGear.sln /p:Configuration=Release /p:Platform=x64 + diff --git a/hudson_win_package_release.bat b/hudson_win_package_release.bat new file mode 100644 index 0000000..d058849 --- /dev/null +++ b/hudson_win_package_release.bat @@ -0,0 +1,30 @@ +ECHO OFF + +IF NOT DEFINED WORKSPACE SET WORKSPACE=%~dp0 +ECHO Packaging root is %WORKSPACE% + +subst X: /D +subst X: %WORKSPACE% + +REM construct information file to be read by Inno-setup + + +set PATH=%WORKSPACE%\install\msvc90\OpenSceneGraph\bin;%PATH% +REM indirect way to get command output into an environment variable +osgversion --so-number > %TEMP%\osg-so-number.txt +osgversion --version-number > %TEMP%\osg-version.txt + +SET /P FLIGHTGEAR_VERSION= InstallConfig.iss +ECHO #define OSGVersion "%OSG_VERSION%" >> InstallConfig.iss +ECHO #define OSGSoNumber "%OSG_SO_NUMBER%" >> InstallConfig.iss + +REM run Inno-setup! + +Compil32 /cc FlightGear.iss + + +