I2P JPackage Mac

JPackage scripts for packaging I2P on a Mac.

Requirements

Building

  1. Clone i2p.i2p as a sibling to this module
  2. Build it with ant clean preppkg-osx-only
  3. Set the I2P_SIGNER environment variable to a string identifying the signer.
  4. Set the I2P_BUILD_NUMBER environment variable to some integer >= 1
  5. Run build.sh

How does it work

In order to build an AppBundle that can work from anywhere, it is necessary to use a dedicated main class which determines the current working directory and sets i2p.dir.base to the correct location inside the AppBundle. Therefore the build.sh script:

  1. Compiles the custom main clas and puts it in a launcher.jar
  2. Invokes JPackage with the --app-image switch to create the directory structure of the bundle
  3. Copies the contents of ../i2p.i2p/pkg-temp inside the AppBundle, except for the jars directory
  4. Signs the AppBundle
  5. Invokes JPackage again to build the final .dmg

Notarization

  1. You need an “app-specific password” which you can create at https://appleid.apple.com
  2. Execute
xcrun altool --eval-app --primary-bundle-id net.i2p.router -u <your Apple id> -f <name of the .dmg file>

This will ask you for the password you generated in step 1 and will return a long UUID string you can use to check the progress.

  1. Periodically execute the following to check the progress of the notarisation:
xcrun altool --eval-info <the long UUID string> -u <your Apple id>
  1. If that returns success, staple the notarization to the dmg:
xcrun stapler staple <name of the .dmg>

git repository: ./i2p-jpackage-mac

Git Summary


 project  : i2p-jpackage-mac
 repo age : vor 11 Monaten
 active   : 12 days
 commits  : 40
 files    : 18
 authors  : 
b0cffca 2022-02-11 wait for ClientAppManager like the Windows launcher does
440c67c 2021-12-05 set i2p.dir.lib property
f1dce3c 2021-11-03 do not try to auto-set JAVA_HOME
423cb83 2021-10-21 open packages for java 17
b78b904 2021-10-21 Merge branch 'release-script' into 'master'
9732fb6 2021-10-20 Add a release.sh script and indicate what needs to be done to finish it
984df32 2021-08-03 source the certificates of router signers from resources/
63cd216 2021-08-03 ship a default router.config with correct news urls
97d2558 2021-08-02 only restart i2p if user was restarting router
f3e6e01 2021-08-02 copy -> rename
da6821a 2021-08-02 register only one instance of UPP
71e476c 2021-08-02 add license
8d44408 2021-08-02 fix predicates
81e4fb9 2021-08-02 fix predicates
c83eb7c 2021-08-02 support dev updates
096ede1 2021-08-01 and register the UPP
3444784 2021-08-01 UPP implementation
d8bff1c 2021-08-01 code to wait for UpdateManager to appear
55d3437 2021-08-01 script for mac dmg updates
d160e20 2021-04-02 fix issue on 13-inch screens
35f2750 2021-04-02 try/catch around jni loading and call
57d9b1c 2021-04-02 use a custom dmg setup script
457eea4 2021-04-02 working jni lib :)
de55665 2021-04-02 wip on native library to disable app nap
7c26f48 2021-03-30 set the bundle location and jvm pid.  Javadoc
6d93c8e 2021-03-30 Pass -Xmx512M and allow illegal access to make sure plugins don't break
02b2381 2021-03-21 fix variable name
5804514 2021-03-21 fix formatting
f92958e 2021-03-21 document notarization process
fa0d90e 2021-03-21 sign all libraries in the bundle, incl. jre
107cc71 2021-03-21 WIP on notarisation: sign with entitlements
21b2954 2021-03-21 WIP on notarisation: sign JBigi libs
e12fec3 2021-03-21 * revert to "java --version" because of different output format * use a custom Info.plist * use correct I2P version in the correct place in Info.plist * CFBundleNumber is actually the build number
554fb97 2021-03-21 Improve version detection a little, add JRE license
3b66c66 2021-03-20 remove more stuff from resources
ce99d21 2021-03-20 correct ant target
93ae7fc 2021-03-20 read the location from jpackage.app-path and launch an i2p router
f006ef7 2021-03-20 wip on customizing bundle
cd2196f 2021-03-20 wip on mac-specific readme
4e749a1 2021-03-20 Initial commit```

## Files

LICENSE.txt README.md bash/mac-update.sh build.sh c/net_i2p_router_MacLauncher.c c/net_i2p_router_MacLauncher.h clean.sh java/net/i2p/router/MacLauncher.java java/net/i2p/update/MacUpdateProcess.java java/net/i2p/update/MacUpdateProcessor.java release.sh resources/GPLv2+CE.txt resources/I2P-background.tiff resources/I2P-dmg-setup.scpt.template resources/Info.plist.template resources/entitlements.xml resources/router.config resources/zab_at_mail.i2p.crt


## Branches

## Tags

1.6.1


## Remotes

origin https://github.com/i2p/i2p-jpackage-mac (fetch) origin https://github.com/i2p/i2p-jpackage-mac (push) ```