You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by av...@apache.org on 2016/11/24 13:24:28 UTC

[18/50] [abbrv] ignite git commit: IGNITE-3873: Added WiX script to generate ODBC installer.

IGNITE-3873: Added WiX script to generate ODBC installer.


Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/cdae2ab7
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/cdae2ab7
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/cdae2ab7

Branch: refs/heads/ignite-4242
Commit: cdae2ab76d403aef9a0bd209fc7497dc6cfdfc08
Parents: ac660dc
Author: Igor Sapego <is...@gridgain.com>
Authored: Wed Nov 9 16:25:30 2016 +0300
Committer: Igor Sapego <is...@gridgain.com>
Committed: Wed Nov 9 16:25:30 2016 +0300

----------------------------------------------------------------------
 modules/platforms/cpp/DEVNOTES.txt              |  12 ++
 modules/platforms/cpp/odbc/README.txt           |  23 ++--
 .../cpp/odbc/install/ignite-odbc-amd64.wxs      | 114 +++++++++++++++++++
 .../cpp/odbc/install/ignite-odbc-x86.wxs        | 114 +++++++++++++++++++
 pom.xml                                         |   8 ++
 5 files changed, 263 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/cdae2ab7/modules/platforms/cpp/DEVNOTES.txt
----------------------------------------------------------------------
diff --git a/modules/platforms/cpp/DEVNOTES.txt b/modules/platforms/cpp/DEVNOTES.txt
index cd0a154..924b0d8 100644
--- a/modules/platforms/cpp/DEVNOTES.txt
+++ b/modules/platforms/cpp/DEVNOTES.txt
@@ -58,6 +58,18 @@ Building binaries:
  * If you want to build ODBC driver then you should explicitly build it as it is disabled
    in the solution file by default. In IDE it can be done by clicking on the ODBC project
    with the right mouse button and choosing "Build" option.
+   
+Building installers:
+ * Install WiX Toolset if you do not have it yet.
+ * Add WiX Toolset "bin" directory to your PATH environmental variable.
+ * Build ODBC drivers: Release|x64 for 64-bit version and Release|Win32 for 32-bit version.
+ * Open terminal and navigate to the directory $IGNITE_HOME/platforms/cpp/odbc/install
+ * Execute the following commands one by one to build 32-bit driver:
+    * candle.exe ignite-odbc-x86.wxs
+    * light.exe -ext WixUIExtension ignite-odbc-x86.wixobj
+ * Execute the following commands one by one to build 64-bit driver:
+    * candle.exe ignite-odbc-amd64.wxs
+    * light.exe -ext WixUIExtension ignite-odbc-amd64.wixobj
 
 Building in later versions of Visual Studio:
  * Open project\vs\ignite.sln or project\vs\ignite_86.sln in Visual Studio

http://git-wip-us.apache.org/repos/asf/ignite/blob/cdae2ab7/modules/platforms/cpp/odbc/README.txt
----------------------------------------------------------------------
diff --git a/modules/platforms/cpp/odbc/README.txt b/modules/platforms/cpp/odbc/README.txt
index 8f0c805..fe40a5c 100644
--- a/modules/platforms/cpp/odbc/README.txt
+++ b/modules/platforms/cpp/odbc/README.txt
@@ -58,14 +58,21 @@ ODBC driver you should perfrom the following steps:
 Installing ODBC driver on Windows
 =======================================
 
-For 32-bit Windows you should use 32-bit version of the driver while for the
-64-bit Windows you can use 64-bit driver as well as 32-bit.
-
-To install driver on Windows you should first choose a directory on your
-filesystem where your driver or drivers will be located. Once you have
-choosen the place you should put your driver there and ensure that all driver
-dependencies can be resolved i.e. they can be found either in the %PATH% or
-in the same directory as the driver.
+Note, that for 32-bit Windows you should use 32-bit version of the driver
+while for the 64-bit Windows you can use both 64-bit and 32-bit versions of the
+driver. You may want to use 32-bit driver on 64-bit system for 32-bit
+applications.
+
+There are two ways to install ODBC driver currently. The first one is to use
+32-bit or 64-bit installer. This is the most simple way and you are recommended
+to stick to it by default.
+
+However there is also another way to install driver manually using scripts. If
+you choose this method you should first choose a directory on your filesystem
+where your driver or drivers will be located. Once you have choosen the place
+you should put your driver there and ensure that all driver dependencies can be
+resolved i.e. they can be found either in the %PATH% or in the same directory
+as the driver.
 
 After that you should use one of the install scripts from the directory 
 %IGNITE_HOME%/platforms/cpp/odbc/install. Note that most likely you will

http://git-wip-us.apache.org/repos/asf/ignite/blob/cdae2ab7/modules/platforms/cpp/odbc/install/ignite-odbc-amd64.wxs
----------------------------------------------------------------------
diff --git a/modules/platforms/cpp/odbc/install/ignite-odbc-amd64.wxs b/modules/platforms/cpp/odbc/install/ignite-odbc-amd64.wxs
new file mode 100644
index 0000000..cb6ab54
--- /dev/null
+++ b/modules/platforms/cpp/odbc/install/ignite-odbc-amd64.wxs
@@ -0,0 +1,114 @@
+<?xml version='1.0' encoding='windows-1252'?>
+
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+
+<Wix xmlns='http://schemas.microsoft.com/wix/2006/wi'>
+	<Product Name='Apache Ignite ODBC 64-bit Driver' Manufacturer='The Apache Software Foundation'
+		Id='F3E308E4-910C-4AF5-82DE-2ACF4D64830E' 
+		UpgradeCode='1D7AEFDF-6CD2-4FB5-88F2-811A89832D6D'
+		Language='1033' Codepage='1252' Version='1.6.7.0'>
+		
+		<Package Id='*' Keywords='Installer' Description="Apache Ignite ODBC 64-bit Driver Installer"
+			Comments='Apache, Apache Ignite, the Apache feather and the Apache Ignite logo are trademarks of The Apache Software Foundation.'
+			Platform="x64" InstallerVersion='200' Languages='1033' Compressed='yes' SummaryCodepage='1252' />
+
+		<Media Id='1' Cabinet='package.cab' EmbedCab='yes' DiskPrompt='CD-ROM #1' />
+		<Property Id='DiskPrompt' Value="Apache Ignite ODBC 64-bit Driver Installation [1]" />
+		
+		<Directory Id='TARGETDIR' Name='SourceDir'>
+			<Directory Id='ProgramFiles64Folder' Name='ProgramFiles'>
+				<Directory Id='ApacheIgnite' Name='Apache Ignite'>
+					<Directory Id='INSTALLDIR' Name='ODBC Driver'>
+						<Component Id='Driver' Guid='E5F0DDF2-DD3C-4196-8A08-70921858A52F' Win64='yes'>
+							<File Id='IgniteOdbcDll' Name='ignite.odbc.dll' DiskId='1' Source='../../project/vs/x64/Release/ignite.odbc.dll' KeyPath='yes'/>
+							
+							<RegistryValue Root='HKLM' Key='Software\ODBC\ODBCINST.INI\ODBC Drivers' Name='Apache Ignite' Type='string' Value='Installed'/>
+							
+							<RegistryKey Id='OdbcDriverRegInfo' Root='HKLM' Key='Software\ODBC\ODBCINST.INI\Apache Ignite' ForceCreateOnInstall='yes' ForceDeleteOnUninstall='yes'>
+								<RegistryValue Type='string' Name='DriverODBCVer' Value='03.00'/>
+								<RegistryValue Type='string' Name='Driver' Value='[#IgniteOdbcDll]'/>
+								<RegistryValue Type='string' Name='Setup' Value='[#IgniteOdbcDll]'/>
+								<RegistryValue Type='integer' Name='UsageCount' Value='1'/>
+							</RegistryKey>
+							
+						</Component>
+					</Directory>
+				</Directory>
+			</Directory>
+		</Directory>
+		
+		<Feature Id='Complete' Title='ODBC Driver' Description='Apache Ignite ODBC Driver.' Level='1'
+			ConfigurableDirectory='INSTALLDIR' Absent='disallow' AllowAdvertise='no' InstallDefault='local'>
+			<ComponentRef Id='Driver' />
+		</Feature>
+		
+		<Property Id="WIXUI_INSTALLDIR" Value="INSTALLDIR" />
+		
+		<UI Id="WixUI_InstallDir">
+            <TextStyle Id="WixUI_Font_Normal" FaceName="Tahoma" Size="8" />
+            <TextStyle Id="WixUI_Font_Bigger" FaceName="Tahoma" Size="12" />
+            <TextStyle Id="WixUI_Font_Title" FaceName="Tahoma" Size="9" Bold="yes" />
+
+            <Property Id="DefaultUIFont" Value="WixUI_Font_Normal" />
+            <Property Id="WixUI_Mode" Value="InstallDir" />
+
+            <DialogRef Id="BrowseDlg" />
+            <DialogRef Id="DiskCostDlg" />
+            <DialogRef Id="ErrorDlg" />
+            <DialogRef Id="FatalError" />
+            <DialogRef Id="FilesInUse" />
+            <DialogRef Id="MsiRMFilesInUse" />
+            <DialogRef Id="PrepareDlg" />
+            <DialogRef Id="ProgressDlg" />
+            <DialogRef Id="ResumeDlg" />
+            <DialogRef Id="UserExit" />
+            
+            <Publish Dialog="BrowseDlg" Control="OK" Event="DoAction" Value="WixUIValidatePath" Order="3">1</Publish>
+            <Publish Dialog="BrowseDlg" Control="OK" Event="SpawnDialog" Value="InvalidDirDlg" Order="4"><![CDATA[WIXUI_INSTALLDIR_VALID<>"1"]]></Publish>
+
+            <Publish Dialog="ExitDialog" Control="Finish" Event="EndDialog" Value="Return" Order="999">1</Publish>
+
+            <Publish Dialog="WelcomeDlg" Control="Next" Event="NewDialog" Value="InstallDirDlg">NOT Installed</Publish>
+            <Publish Dialog="WelcomeDlg" Control="Next" Event="NewDialog" Value="VerifyReadyDlg">Installed AND PATCH</Publish>
+
+            <Publish Dialog="InstallDirDlg" Control="Back" Event="NewDialog" Value="WelcomeDlg">1</Publish>
+            <Publish Dialog="InstallDirDlg" Control="Next" Event="SetTargetPath" Value="[WIXUI_INSTALLDIR]" Order="1">1</Publish>
+            <Publish Dialog="InstallDirDlg" Control="Next" Event="DoAction" Value="WixUIValidatePath" Order="2">NOT WIXUI_DONTVALIDATEPATH</Publish>
+            <Publish Dialog="InstallDirDlg" Control="Next" Event="SpawnDialog" Value="InvalidDirDlg" Order="3"><![CDATA[NOT WIXUI_DONTVALIDATEPATH AND WIXUI_INSTALLDIR_VALID<>"1"]]></Publish>
+            <Publish Dialog="InstallDirDlg" Control="Next" Event="NewDialog" Value="VerifyReadyDlg" Order="4">WIXUI_DONTVALIDATEPATH OR WIXUI_INSTALLDIR_VALID="1"</Publish>
+            <Publish Dialog="InstallDirDlg" Control="ChangeFolder" Property="_BrowseProperty" Value="[WIXUI_INSTALLDIR]" Order="1">1</Publish>
+            <Publish Dialog="InstallDirDlg" Control="ChangeFolder" Event="SpawnDialog" Value="BrowseDlg" Order="2">1</Publish>
+            
+            <Publish Dialog="VerifyReadyDlg" Control="Back" Event="NewDialog" Value="InstallDirDlg" Order="1">NOT Installed</Publish>
+            <Publish Dialog="VerifyReadyDlg" Control="Back" Event="NewDialog" Value="MaintenanceTypeDlg" Order="2">Installed AND NOT PATCH</Publish>
+            <Publish Dialog="VerifyReadyDlg" Control="Back" Event="NewDialog" Value="WelcomeDlg" Order="2">Installed AND PATCH</Publish>
+
+            <Publish Dialog="MaintenanceWelcomeDlg" Control="Next" Event="NewDialog" Value="MaintenanceTypeDlg">1</Publish>
+
+            <Publish Dialog="MaintenanceTypeDlg" Control="RepairButton" Event="NewDialog" Value="VerifyReadyDlg">1</Publish>
+            <Publish Dialog="MaintenanceTypeDlg" Control="RemoveButton" Event="NewDialog" Value="VerifyReadyDlg">1</Publish>
+            <Publish Dialog="MaintenanceTypeDlg" Control="Back" Event="NewDialog" Value="MaintenanceWelcomeDlg">1</Publish>
+
+            <Property Id="ARPNOMODIFY" Value="1" />
+        </UI>
+
+        <UIRef Id="WixUI_Common" />
+		<UIRef Id="WixUI_ErrorProgressText" />
+		
+	</Product>
+</Wix>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ignite/blob/cdae2ab7/modules/platforms/cpp/odbc/install/ignite-odbc-x86.wxs
----------------------------------------------------------------------
diff --git a/modules/platforms/cpp/odbc/install/ignite-odbc-x86.wxs b/modules/platforms/cpp/odbc/install/ignite-odbc-x86.wxs
new file mode 100644
index 0000000..6ee1cdf
--- /dev/null
+++ b/modules/platforms/cpp/odbc/install/ignite-odbc-x86.wxs
@@ -0,0 +1,114 @@
+<?xml version='1.0' encoding='windows-1252'?>
+
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+
+<Wix xmlns='http://schemas.microsoft.com/wix/2006/wi'>
+	<Product Name='Apache Ignite ODBC 32-bit Driver' Manufacturer='The Apache Software Foundation'
+		Id='D39CBABA-1E21-4701-AA5C-91EDA07B383B' 
+		UpgradeCode='743902A4-365C-424E-B226-5B2898A3941E'
+		Language='1033' Codepage='1252' Version='1.6.7.0'>
+		
+		<Package Id='*' Keywords='Installer' Description="Apache Ignite ODBC 32-bit Driver Installer"
+			Comments='Apache, Apache Ignite, the Apache feather and the Apache Ignite logo are trademarks of The Apache Software Foundation.'
+			InstallerVersion='100' Languages='1033' Compressed='yes' SummaryCodepage='1252' />
+
+		<Media Id='1' Cabinet='package.cab' EmbedCab='yes' DiskPrompt='CD-ROM #1' />
+		<Property Id='DiskPrompt' Value="Apache Ignite ODBC 32-bit Driver Installation [1]" />
+		
+		<Directory Id='TARGETDIR' Name='SourceDir'>
+			<Directory Id='ProgramFilesFolder' Name='ProgramFiles'>
+				<Directory Id='ApacheIgnite' Name='Apache Ignite'>
+					<Directory Id='INSTALLDIR' Name='ODBC Driver'>
+						<Component Id='Driver' Guid='4AFA26EE-C639-4EF2-A9B2-281119BB4BB5'>
+							<File Id='IgniteOdbcDll' Name='ignite.odbc.dll' DiskId='1' Source='../../project/vs/Win32/Release/ignite.odbc.dll' KeyPath='yes'/>
+							
+							<RegistryValue Root='HKLM' Key='Software\ODBC\ODBCINST.INI\ODBC Drivers' Name='Apache Ignite' Type='string' Value='Installed'/>
+							
+							<RegistryKey Id='OdbcDriverRegInfo' Root='HKLM' Key='Software\ODBC\ODBCINST.INI\Apache Ignite' ForceCreateOnInstall='yes' ForceDeleteOnUninstall='yes'>
+								<RegistryValue Type='string' Name='DriverODBCVer' Value='03.00'/>
+								<RegistryValue Type='string' Name='Driver' Value='[#IgniteOdbcDll]'/>
+								<RegistryValue Type='string' Name='Setup' Value='[#IgniteOdbcDll]'/>
+								<RegistryValue Type='integer' Name='UsageCount' Value='1'/>
+							</RegistryKey>
+							
+						</Component>
+					</Directory>
+				</Directory>
+			</Directory>
+		</Directory>
+		
+		<Feature Id='Complete' Title='ODBC Driver' Description='Apache Ignite ODBC Driver.' Level='1'
+			ConfigurableDirectory='INSTALLDIR' Absent='disallow' AllowAdvertise='no' InstallDefault='local'>
+			<ComponentRef Id='Driver' />
+		</Feature>
+		
+		<Property Id="WIXUI_INSTALLDIR" Value="INSTALLDIR" />
+		
+		<UI Id="WixUI_InstallDir">
+            <TextStyle Id="WixUI_Font_Normal" FaceName="Tahoma" Size="8" />
+            <TextStyle Id="WixUI_Font_Bigger" FaceName="Tahoma" Size="12" />
+            <TextStyle Id="WixUI_Font_Title" FaceName="Tahoma" Size="9" Bold="yes" />
+
+            <Property Id="DefaultUIFont" Value="WixUI_Font_Normal" />
+            <Property Id="WixUI_Mode" Value="InstallDir" />
+
+            <DialogRef Id="BrowseDlg" />
+            <DialogRef Id="DiskCostDlg" />
+            <DialogRef Id="ErrorDlg" />
+            <DialogRef Id="FatalError" />
+            <DialogRef Id="FilesInUse" />
+            <DialogRef Id="MsiRMFilesInUse" />
+            <DialogRef Id="PrepareDlg" />
+            <DialogRef Id="ProgressDlg" />
+            <DialogRef Id="ResumeDlg" />
+            <DialogRef Id="UserExit" />
+            
+            <Publish Dialog="BrowseDlg" Control="OK" Event="DoAction" Value="WixUIValidatePath" Order="3">1</Publish>
+            <Publish Dialog="BrowseDlg" Control="OK" Event="SpawnDialog" Value="InvalidDirDlg" Order="4"><![CDATA[WIXUI_INSTALLDIR_VALID<>"1"]]></Publish>
+
+            <Publish Dialog="ExitDialog" Control="Finish" Event="EndDialog" Value="Return" Order="999">1</Publish>
+
+            <Publish Dialog="WelcomeDlg" Control="Next" Event="NewDialog" Value="InstallDirDlg">NOT Installed</Publish>
+            <Publish Dialog="WelcomeDlg" Control="Next" Event="NewDialog" Value="VerifyReadyDlg">Installed AND PATCH</Publish>
+
+            <Publish Dialog="InstallDirDlg" Control="Back" Event="NewDialog" Value="WelcomeDlg">1</Publish>
+            <Publish Dialog="InstallDirDlg" Control="Next" Event="SetTargetPath" Value="[WIXUI_INSTALLDIR]" Order="1">1</Publish>
+            <Publish Dialog="InstallDirDlg" Control="Next" Event="DoAction" Value="WixUIValidatePath" Order="2">NOT WIXUI_DONTVALIDATEPATH</Publish>
+            <Publish Dialog="InstallDirDlg" Control="Next" Event="SpawnDialog" Value="InvalidDirDlg" Order="3"><![CDATA[NOT WIXUI_DONTVALIDATEPATH AND WIXUI_INSTALLDIR_VALID<>"1"]]></Publish>
+            <Publish Dialog="InstallDirDlg" Control="Next" Event="NewDialog" Value="VerifyReadyDlg" Order="4">WIXUI_DONTVALIDATEPATH OR WIXUI_INSTALLDIR_VALID="1"</Publish>
+            <Publish Dialog="InstallDirDlg" Control="ChangeFolder" Property="_BrowseProperty" Value="[WIXUI_INSTALLDIR]" Order="1">1</Publish>
+            <Publish Dialog="InstallDirDlg" Control="ChangeFolder" Event="SpawnDialog" Value="BrowseDlg" Order="2">1</Publish>
+            
+            <Publish Dialog="VerifyReadyDlg" Control="Back" Event="NewDialog" Value="InstallDirDlg" Order="1">NOT Installed</Publish>
+            <Publish Dialog="VerifyReadyDlg" Control="Back" Event="NewDialog" Value="MaintenanceTypeDlg" Order="2">Installed AND NOT PATCH</Publish>
+            <Publish Dialog="VerifyReadyDlg" Control="Back" Event="NewDialog" Value="WelcomeDlg" Order="2">Installed AND PATCH</Publish>
+
+            <Publish Dialog="MaintenanceWelcomeDlg" Control="Next" Event="NewDialog" Value="MaintenanceTypeDlg">1</Publish>
+
+            <Publish Dialog="MaintenanceTypeDlg" Control="RepairButton" Event="NewDialog" Value="VerifyReadyDlg">1</Publish>
+            <Publish Dialog="MaintenanceTypeDlg" Control="RemoveButton" Event="NewDialog" Value="VerifyReadyDlg">1</Publish>
+            <Publish Dialog="MaintenanceTypeDlg" Control="Back" Event="NewDialog" Value="MaintenanceWelcomeDlg">1</Publish>
+
+            <Property Id="ARPNOMODIFY" Value="1" />
+        </UI>
+
+        <UIRef Id="WixUI_Common" />
+		<UIRef Id="WixUI_ErrorProgressText" />
+		
+	</Product>
+</Wix>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ignite/blob/cdae2ab7/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index 36051b4..8069e38 100644
--- a/pom.xml
+++ b/pom.xml
@@ -892,6 +892,14 @@
                                         </replaceregexp>
 
                                         <replaceregexp byline="true" encoding="UTF-8">
+                                            <regexp pattern="(Version=.+)\d+\.\d+\.\d+\.\d+(.+)" />
+                                            <substitution expression="\1${new.client.version}\2" />
+                                            <fileset dir="${basedir}/">
+                                                <include name="**/*.wxs" />
+                                            </fileset>
+                                        </replaceregexp>
+
+                                        <replaceregexp byline="true" encoding="UTF-8">
                                             <regexp pattern="(define GG_VERSION_STR_WIN &quot;)\d+\.\d+\.\d+(\.\d+)?(&quot;)" />
                                             <substitution expression="\1${new.client.version}\3" />
                                             <fileset dir="${basedir}/">