Add Windows documentation#520
Conversation
| 1. Install [Visual C++ Build Tools](https://visualstudio.microsoft.com/thank-you-downloading-visual-studio/?sku=BuildTools&rel=16): select MSVC Build Tools + Windows 10 SDK | ||
| 2. Install [WIX](https://github.com/wixtoolset/wix3/releases/download/wix3112rtm/wix311.exe) | ||
| 3. Copy [wixgen.jar](https://github.com/akashche/wixgen/releases/download/1.7/wixgen.jar) to `C:\msi-deps` | ||
| 4. Copy all 65 files from `C:\Program Files (x86)\WiX Toolset v3.11\bin` to `C:\msi-deps\wix311-binaries` |
There was a problem hiding this comment.
This hsould not be necessary... If so... why so?
There was a problem hiding this comment.
It is necessary. I don't know why, I have zero knowledge in the rust/cargo stuff but if you don't do this, the build fails as follows:
/cygdrive/c/git/IcedTea-Web/launchers
+ mv C:/git/IcedTea-Web/launchers/target/images/icedtea-web C:/git/IcedTea-Web/launchers/target/images/icedtea-web-2.0.0-win.bin
+ isWindows
++ uname
+ [[ CYGWIN_NT-10.0 == *\N\T* ]]
+ return 0
+ which cargo
/cygdrive/c/Users/vippy/.cargo/bin/cargo
+ '[' '!' xC:/msi-deps/wixgen.jar = x -a '!' x/cygdrive/c/msi-deps/wix311-binaries/ = x ']'
+ splitVersion 2.0.0
+ PACKAGE_VERSION=2.0.0
++ echo 2.0.0
++ cut -d. -f 1
+ MAJOR_VERSION=2
++ echo 2.0.0
++ cut -d. -f 2
+ MINOR_VERSION=0
++ echo 2.0.0
++ cut -d. -f 3
++ sed 's/[^0-9]*//g'
+ MICRO_VERSION=0
+ sed -e 's|../win-installer|C:/git/IcedTea-Web/launchers/win-installer|g' -e 's|[@]PACKAGE_VERSION[@]|2.0.0|g' -e 's|[@]MAJOR_VERSION[@]|2|g' -e 's|[@]MINOR_VERSION[@]|0|g' -e 's|[@]MICRO_VERSION[@]|0|g' -e 's/[@]PACKAGE_VERSION[@]/2.0.0/g' C:/git/IcedTea-Web/launchers/win-installer/installer.json.in
++ imageName win.bin
++ echo icedtea-web-2.0.0-win.bin
+ /cygdrive/c/Java/AdoptOpenJDK/jdk-13.0.0.33-hotspot/bin/java -jar C:/msi-deps/wixgen.jar C:/git/IcedTea-Web/launchers/target/images/icedtea-web-2.0.0-win.bin -c C:/git/IcedTea-Web/launchers/target/tmp/itw-installer.json -o C:/git/IcedTea-Web/launchers/target/tmp/itw-installer.wxs
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by com.sun.xml.bind.v2.runtime.reflect.opt.Injector (file:/C:/msi-deps/wixgen.jar) to method java.lang.ClassLoader.defineClass(java.lang.String,byte[],int,int)
WARNING: Please consider reporting this to the maintainers of com.sun.xml.bind.v2.runtime.reflect.opt.Injector
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
+ pushd C:/git/IcedTea-Web/launchers/target/tmp
/cygdrive/c/git/IcedTea-Web/launchers/target/tmp /cygdrive/c/git/IcedTea-Web/launchers
+ /cygdrive/c/msi-deps/wix311-binaries//candle.exe /nologo itw-installer.wxs
./build.sh: ligne 117: /cygdrive/c/msi-deps/wix311-binaries//candle.exe: No such file or directory
There was a problem hiding this comment.
This error message can be circumvented by setting the WIX_TOOLSET_DIR variable, which is otherwise by default set to /cygdrive/c/msi-deps/wix311-binaries/ here. The default value may be outdated or just plain wrong.
There was a problem hiding this comment.
@AurumTheEnd @judovana How can we solve this issue? Just remove the line? Add an info about the correct value of the env variable?
There was a problem hiding this comment.
Just removing the line wouldn't help anyone. As the WIX_TOOLSET_DIR is supposed to be the intended way and just isn't clearly marked anywhere right now – your documentation should do that.
|
|
||
| # Build using Cygwin64 terminal | ||
|
|
||
| 6. `export JRE=/cygdrive/c/Java/AdoptOpenJDK/jdk-13.0.0.33-hotspot` |
There was a problem hiding this comment.
Jdk13/11/8 ?? Not sure what is now most supported JDK for itw. Maybe the version oculd be wildchar, but I do not insists.
There was a problem hiding this comment.
it was just an example. The proper way would be to not force users to define a "JRE" variable at all, and either rely on JAVA_HOME, or simply on the PATH. I can remove the version number.
There was a problem hiding this comment.
If you don't set the variable you get the following error:
$ ./build.sh 2.0.0
+ set -e
+ set -o pipefail
+ SCRIPT_SOURCE=./build.sh
+ '[' -h ./build.sh ']'
+ isWindows
++ uname
+ [[ CYGWIN_NT-10.0 == *\N\T* ]]
+ return 0
++++ dirname ./build.sh
+++ cd -P .
+++ pwd
++ cygpath -m /cygdrive/c/git/IcedTea-Web/launchers
+ readonly SCRIPT_DIR=C:/git/IcedTea-Web/launchers
+ SCRIPT_DIR=C:/git/IcedTea-Web/launchers
+ source C:/git/IcedTea-Web/launchers/configure.sh
++ VERSION=2.0.0
++ LOCALIZATIONS='en_US.UTF-8 cs_CZ.UTF-8 pl_PL.UTF-8 de_DE.UTF-8'
++ '[' x2.0.0 == x ']'
++ readonly VERSION=2.0.0
++ VERSION=2.0.0
++ '[' x == x ']'
++ echo 'default jre is necessary'
default jre is necessary
++ exit 1
There was a problem hiding this comment.
@don-vip correctly says that you need to set the JRE variable in order to build. Maybe it can be replaced in this documentation by something like export JRE=path to JRE on your system, so that it is not version specific.
There was a problem hiding this comment.
What about defaulting to JAVA_HOME if JRE is not defined ?
|
Otherwise it is great. thank ou very much fot hte PR!!!! |
|
@judovana can we merge this PR? |
|
Hi Team, any news. I have always error with last Icedtea-Web 2.0 compiling. Regards |
|
@patris70 |
|
@hendrikebbers First, we need itw_win_devkit, here is link (we do not need MS VS or other), as Info you can using this Tools for Icedtea-Web 1.8.x compiling: Download MAVEN from here: Download GIT from here: We need WINGEN.JAR File, copy this file in wix\bin Folder, here ist File: For building Javaws.exe x64 (64bit), we need JDK x64, for Javaws.exe x86 (32bit), we need JDK x86 (This Trick works just for Icedtea-Web 1.8.x Version). For Icedtea-Web 2.0 Version, you need just this trick for Javaws.exe x86 building (your msi-installer suggests "Program Files" instead of "Program Files (x86)" as the installation directory for your 32-bit build on a 64-bit Windows and if you follow the suggestion you will have 32-bit launcher in the 64-bit programs directory), Add in Windows %PATH%, ==> C:\maven\bin;c:\git\cmd;c:\64bit\wix\bin Create this Variables with Value: For example, my Source files and Tools are in Folder C:\64bit and Icedtea-Web Source Folder Name is icedtea-web-2, create a Batch file with this content: @echo off Run your Batch File, then start cygwin.bat File. Now Run this Command: Now you compiled withot Error and MSI File is in Path C:\64bit\icedtea-web-2\launchers\target\images: Hope to help other |





As requested here: #392 (comment)