Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
en:developer:windows_source_install [2018/09/07 15:14]
anupama [Current instructions]
en:developer:windows_source_install [2019/05/10 21:21] (current)
anupama [Current instructions]
Line 10: Line 10:
   * An SVN client installed, which can be downloaded from http://​subversion.apache.org/​packages.html. The instructions below assume a command-line SVN client. ​   * An SVN client installed, which can be downloaded from http://​subversion.apache.org/​packages.html. The instructions below assume a command-line SVN client. ​
   * Java JDK 6.x or later. For compiling on Windows 64 bit, need the 64 bit version of JDK. For compiling Greenstone 3.06 and onwards, need JDK 7.x or later.   * Java JDK 6.x or later. For compiling on Windows 64 bit, need the 64 bit version of JDK. For compiling Greenstone 3.06 and onwards, need JDK 7.x or later.
-  * PERL (ActivePerl for Windows)+  * PERL: we used to use ActivePerl for Windows. Now we provide our own modified version of [[http://​trac.greenstone.org/​browser/​main/​trunk/​release-kits/​shared/​windows/​perl.zip|Strawberry Perl]] that has everything we need so far.
   * **Visual Studio** 8 or later for compiling C++ code. (We haven'​t tried it with Microsoft'​s free Visual Studio Express yet.) For 64-bit Windows, we found that Visual Studio versions 9 and 12 worked to compile GS3 from SVN.   * **Visual Studio** 8 or later for compiling C++ code. (We haven'​t tried it with Microsoft'​s free Visual Studio Express yet.) For 64-bit Windows, we found that Visual Studio versions 9 and 12 worked to compile GS3 from SVN.
   * If you want to compile GS2 or GS3 with debugging on, you will also need Microsoft SDK   * If you want to compile GS2 or GS3 with debugging on, you will also need Microsoft SDK
Line 36: Line 36:
 (The gs3-devel.bat will print a file not found error on Windows, since gs3-devel.bat runs gs3-setup.bat which refers to some files that the ant prepare step has yet to checkout.) (The gs3-devel.bat will print a file not found error on Windows, since gs3-devel.bat runs gs3-setup.bat which refers to some files that the ant prepare step has yet to checkout.)
  
-Once the ''​ant prepare''​ step has //​finished//, ​open a new terminal, go back to into the SVN Greenstone 3 checkout directory and run the devel script again before running the actual compile command:+Once the ''​ant prepare''​ step has //​finished//​
 + 
 +
 +If you're using Visual Studio 14 ([[https://​en.wikipedia.org/​wiki/​Microsoft_Visual_Studio#​History|a.k.a. Visual Studio 2015]]; seems to also work with VS15/​VS2017),​ then before proceeding, backup your windows iconv.zip and rename iconv-winVS14-VS2015-plus.zip as the new iconv.zip, as below. (For details on which libiconv this uses and how it was modified to get it to work with VS14refer [[http://​trac.greenstone.org/​browser/​main/​trunk/​greenstone2/​common-src/​indexers/​packages/​windows/​iconv/​GS-README-VS14-VS2015-AND-LATER.txt|to this]].) 
 +<​code>​ 
 +pushd gs2build\common-src\indexers\packages\windows\iconv 
 +move iconv.zip iconv_preVS14.zip 
 +move iconv-winVS14-VS2015-plus.zip iconv.zip 
 +rmdir /s /q iconv 
 +popd 
 +</​code>​ 
 +
 + 
 +Open **a new terminal**, go back to into the SVN Greenstone 3 checkout directory and run the devel script again before running the actual compile command:
 <​code>​ <​code>​
 gs3-devel.bat gs3-devel.bat
Line 62: Line 75:
   * If you want to compile GS2 with debugging on, you will also need Microsoft SDK   * If you want to compile GS2 with debugging on, you will also need Microsoft SDK
  
-  - Checkout greenstone2 from SVN:\\ <​code>​ svn co http://​svn.greenstone.org/​main/​trunk/​greenstone3 gs3-svn</​code>​+  - Checkout greenstone2 from SVN:\\ <​code>​ svn co http://​svn.greenstone.org/​main/​trunk/​greenstone2 gs2-svn</​code>​ 
 +  - **NOTE:** If you're using Visual Studio 14 ([[https://​en.wikipedia.org/​wiki/​Microsoft_Visual_Studio#​History|a.k.a. Visual Studio 2015]]), then before proceeding, backup your windows iconv.zip and rename iconv-winVS14-VS2015-plus.zip as the new iconv.zip, as below. (For details on which libiconv this uses and how it was modified to get it to work with VS14, refer [[http://​trac.greenstone.org/​browser/​main/​trunk/​greenstone2/​common-src/​indexers/​packages/​windows/​iconv/​GS-README-VS14-VS2015-AND-LATER.txt|to this]].)\\ <​code>​ 
 +cd gs2-svn 
 +pushd common-src\indexers\packages\windows\iconv 
 +move iconv.zip iconv_preVS14.zip 
 +move iconv-winVS14-VS2015-plus.zip iconv.zip 
 +rmdir /s /q iconv 
 +popd 
 +</​code>​
   - Checkout the appropriate subfolder for your OS and bit architecture from http://​svn.greenstone.org/​local/​greenstone2/​ into your greenstone 2 checkout'​s toplevel folder. Name the downloaded subfolder ''​local''​. If you're on Windows 64 bit, then you'd do:\\ <​code>​svn co http://​svn.greenstone.org/​local/​greenstone2/​windows-64bit local</​code>​   - Checkout the appropriate subfolder for your OS and bit architecture from http://​svn.greenstone.org/​local/​greenstone2/​ into your greenstone 2 checkout'​s toplevel folder. Name the downloaded subfolder ''​local''​. If you're on Windows 64 bit, then you'd do:\\ <​code>​svn co http://​svn.greenstone.org/​local/​greenstone2/​windows-64bit local</​code>​
   - On 64 bit Windows, edit ''​local/​setup.bat''​ to set the environment variables to where you have got the following installed on your system: SVN, Java SDK 7+, the Greenstone customised Strawberry Perl (download it from [[http://​trac.greenstone.org/​browser/​main/​trunk/​release-kits/​shared/​windows/​perl.zip?​rev=head|here]]),​ Visual Studio 9+ (Microsoft SDK is no longer needed even when the debug flag is turned on).\\ On 32 bit Windows, rename the ''​local/​setup32.bat''​ script to ''​local/​setup.bat'',​ then edit it to set the environment variables according to your system.   - On 64 bit Windows, edit ''​local/​setup.bat''​ to set the environment variables to where you have got the following installed on your system: SVN, Java SDK 7+, the Greenstone customised Strawberry Perl (download it from [[http://​trac.greenstone.org/​browser/​main/​trunk/​release-kits/​shared/​windows/​perl.zip?​rev=head|here]]),​ Visual Studio 9+ (Microsoft SDK is no longer needed even when the debug flag is turned on).\\ On 32 bit Windows, rename the ''​local/​setup32.bat''​ script to ''​local/​setup.bat'',​ then edit it to set the environment variables according to your system.
Line 70: Line 91:
  
  
-In GS2 SVN checkouts from **before changeset [[http://​trac.greenstone.org/​changeset/​31428|31428]]**,​ compilation on 64 bit Windows could still fail with error messages as described [[http://​wiki.greenstone.org/​doku.php?​id=en:​developer:​compiling_apache&#​compiling_the_apache-httpd_included_with_gs2_on_64_bit_windows_7|here]],​ which indicates that the race condition has struck. In that case, try deleting the ''​apache-httpd\windows\error''​ folder if it has been generated, or all of the ''​apache-httpd''​ folder and run ''​makegs2x64.bat''​ again, choosing the same options as before. If the '​error'​ folder or ''​apache-httpd''​ folder did not exist and therefore can't be deleted, then just re-run makegs2x64.bat again. If that fails, run ''​makegs2x64.bat''​ and select the ''​clean''​ command (option 6) and then re-run ''​makegs2x64.bat''​ to re-compile from scratch. If doing so in a fresh command prompt, remember to run the '​devel64-in32mode.bat''​ script in ''​local''​ before running ''​makegs2x64.bat''​.+In GS2 SVN checkouts from **before changeset [[http://​trac.greenstone.org/​changeset/​31428|31428]]**,​ compilation on 64 bit Windows could still fail with error messages as described [[http://​wiki.greenstone.org/​doku.php?​id=en:​developer:​compiling_apache&#​compiling_the_apache-httpd_included_with_gs2_on_64_bit_windows_7|here]],​ which indicates that the race condition has struck. In that case, try deleting the ''​apache-httpd\windows\error''​ folder if it has been generated, or all of the ''​apache-httpd''​ folder and run ''​makegs2x64.bat''​ again, choosing the same options as before. If the '​error'​ folder or ''​apache-httpd''​ folder did not exist and therefore can't be deleted, then just re-run makegs2x64.bat again. If that fails, run ''​makegs2x64.bat''​ and select the ''​clean''​ command (option 6) and then re-run ''​makegs2x64.bat''​ to re-compile from scratch. If doing so in a fresh command prompt, remember to run the <​del>'​'​devel64-in32mode.bat''</​del>​ ''​setup.bat''​ script in ''​local''​ before running ''​makegs2x64.bat''​.
  
 </​TAB>​ </​TAB>​