Setting SWT windows native build setup
Software needed for setting up windows native build
Microsoft 'Visual Studio - Community 2019' and 'Windows 10 SDK', link to download page
- Run the web installer.
- Go to "Desktop development with C++".
- Select/turn the check-box ON for below items from the list:
- VC++ 2019 v141 toolset(x86, x64)
- Windows 10 SDK (10.0.16299.0) for Desktop C++
Note: [Version numbers (v141, 10.0.16299.0) mentioned above get revised as per latest Microsoft 'Visual Studio' update.]
JDK8 64bit link to Oracle JDK or IBM JDK
- Cygwin [Optional for local setup]
Note: [Eclipse SWT Windows moved to latest "Win10 SDK" and "Visual Studio 2019 community edition" via bugzilla bug 572308]
Steps to set up Windows native build:
- [Optional for local setup] Install and configure Cygwin SSH Server on Windows.
Note: Make sure 'openssh' package is also installed.
For more details on how to configuring SSH refer: link
- [Optional for local setup] Configure the machine for password-less SSH authentication with the Hudson machine.
For more details you can refer: public guide
Sharing some key steps below(which I recall):
Generate the 'dsa' public/private key from your "swtbuild" account from windows machine.
Now login to the Hudson machine with "swtbuild" account.
Copy the public keys and register then on the Hudson machine.. this should enable password-less authentication.
'SWT_BUILDDIR' root directory contain various libraries like Visual Studio libraries, JDK, etc..
Setup your own 'SWT_BUILDDIR' with below like directory structure:
Install Visual Studio Community 2019 libraries in default location or in: 'SWT_BUILDDIR\Microsoft\Visual Studio\2019'
Windows10 SDK gets installed in "Program Files (x86)" directory by default like: 'C:\Program Files (x86)\Windows Kits\10'
Install/Unzip JDK8 64bit in 'SWT_BUILDDIR\Java\Oracle\jdk1.8.0-latest\x64'
-
For local testing, Run as Ant build below file with 'build_libraries' as target(assuming SWT setup is in place):
${workspace_loc:/org.eclipse.swt.win32.win32.x86_64/build.xml}
- [Optional for local setup] Now you can point the Windows hudson job to this machine and trigger a native build.
Note: For testing purpose from hudson, temporarily turn the nativeChanges flag to 'true' to force a native build compilation.