source: main/trunk/release-kits/shared/mac/README@ 35474

Last change on this file since 35474 was 35474, checked in by anupama, 3 years ago

Now that the Mojave/Catalina Mac has been made accessible again by TSG, have regenerated mac jre_bin_x64 as we're now switching to bundling a self-extracting JRE 8u301. The mac release-kits, now being run for testing, are using JDK 8u301 as well. Updated README for generating jre_bin_x64.

File size: 3.8 KB
Line 
1Self-extracting jre instructions
2_________________________________
3
41. We've already committed the compiled up 64 bit versions of 7za and 7zCon.sfx for mac to svn, the 32 bit for Windows (also compatible with 64 bit Windows), and the 32 bit and 64 bit versions for linux.
5On Mac these are now present in release-kits/shared/mac/p7z-essentials folder.
6
7The 7za and 7zCon.sfx from the p7z-essentials folder are needed to generate the self-extracting jre from a jre. Look in the bitness subfolder (32-bit or 64-bit) appropriate to the target bitness of your self-extracting binary.
8
9On a mac or linux, you can compile these two binaries 7za and 7zCon.sfx up yourself by downloading the p7zip source code from online http://p7zip.sourceforge.net/. Compile the source code by first runnng "make" to build the 7za, then run "make sfx" to build the 7zCon.sfx binary.
10
11
122. Need the jre for your java version.
13Java 8 should be used for Expeditee. Since Aug/Sep 2021, we've shifted to Java 8 for Greenstone also.
14The jre should be extracted into a folder named jre. Also, don't make it a tar file for Expeditee. But Greenstone expects the jre to be tarred up first.
15
16If the self-extracting jre_bin binary should run on a 64 bit machine, use the 64 bit 7za compiled up in the 64-bit subfolder (this will use the associated 64 bit 7zCon.sfx library in the same subfolder). For a 32 bit machine, use the 32 bit 7za in the 32-bit subfolder.
17
183. Run:
19./p7z-essentials/[32|64]-bit/7za a -sfx -mx=9 jre_bin[_x64] /path/to/your-jdk-version/jre[.tar]
20
21 e.g. for a 32 bit target, you'd run the following on a 32 bit LSB if creating the self-extracting binary for Expeditee:
22 ./p7z-essentials/32-bit/7za a -sfx -mx=9 jre_bin /path/to/your-jdk-version/jre
23
24 e.g. for a 64 bit target, you'd run the following on a 64 bit LSB, if creating the self-extracting binary for Greenstone:
25 ./p7z-essentials/64-bit/7za a -sfx -mx=9 jre_bin_x64 /path/to/your-jdk-version/jre.tar
26
27* -m0=lzma2 is already done automatically, setting the compression mode to lzma2.
28* -mx=9 set its (compression? speed?) to ultra
29* the output file name expected by the release-kit is jre_bin for 32 bit linux, jre_bin_x64 for 64 bit linux
30* -sfx indicates that it will generate a self-extracting binary out of the input file
31* the "a" indicates it will add the files from the input folder (the /path/to/your-jdk-version/jre in this case) to the output file
32
33If you see the message "Error: jre_bin_x64 is not supported archive", then cd into the p7z-essentials folder and run the ./7za command as above
34
35
36
37To get the JRE for a Mac, do one of the following:
38
39A. Now (at least since jre v 1.7.0_79) the Oracle site has a JRE for Macs available for download as dmg and tar.gz files. If this is available:
40
411. Download the JRE.dmg or JRE.tar.gz for the java version you want and extract it.
422. From the extracted contents, the folder you want is jre<version>.jre/Contents/Home. Rename this Home subfolder to "jre".
433. Tar it up and create the self-extracting jre (the final step of the instructions above):
44 ./p7z-essentials/[64-bit]/7za a -sfx -mx=9 jre_bin_x64 jre.tar
45
46If you see the message "Error: jre_bin_x64 is not supported archive", then cd into the p7z-essentials folder and run the ./7za command as above
47
48
49B. If no JRE.dmg or JRE.tar.gz for Mac is available:
50
511. Download the JDK.dmg for the java version you want.
522. Open the dmg, drag the .pkg out to another folder.
533. Extract the pkg using: xar -xf <file>.pkg
544. Another couple of pkgs should appear, these are actually fake folders (like .app folders)
555. The one you want is the jdk<ver>.pkg. Rightclick > Show package contents to view its contents.
566. Then double click on the Payload item to extract Payload. Alternatively, since it's just a tarfile, you can do
57 tar -xf jdk180.pkg/Payload
587. You get a Contents folder, then browse to Contents > Home > jre. That's the folder you want.
Note: See TracBrowser for help on using the repository browser.