From 626d2997bac40c45b93bfce6d3235480dc4bebae Mon Sep 17 00:00:00 2001 From: idk Date: Tue, 6 Sep 2022 19:25:43 -0400 Subject: [PATCH] Document package builds Former-commit-id: 54b427e5328fcedb284225f58ce9389a63ac2070 Former-commit-id: a8312e38a534575c4d37d4fea4fddfc21eef2f24 --- Dockerfile | 2 +- PACKAGES.md | 69 +++++++++++++++++++ build.xml | 7 ++ fedora-docker.sh | 13 ++++ fedora.sh | 5 +- release.sh | 10 ++- ...p.chromium.base.profile.zip.REMOVED.git-id | 2 +- ...2p.firefox.base.profile.zip.REMOVED.git-id | 2 +- ...refox.usability.profile.zip.REMOVED.git-id | 2 +- 9 files changed, 105 insertions(+), 7 deletions(-) create mode 100644 PACKAGES.md mode change 100644 => 100755 fedora-docker.sh diff --git a/Dockerfile b/Dockerfile index 33c465a..480e7ec 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ FROM fedora RUN yum -y update -RUN yum -y install java-latest-openjdk rpm-build +RUN yum -y install rpm-build ADD . /src/i2p.plugins.firefox WORKDIR /src/i2p.plugins.firefox CMD ./fedora-docker.sh diff --git a/PACKAGES.md b/PACKAGES.md new file mode 100644 index 0000000..2dac0fe --- /dev/null +++ b/PACKAGES.md @@ -0,0 +1,69 @@ +Packages for various operating systems +====================================== + +Windows +------- + +All Windows packages require building on a Windows machine. In order to build +them, check out i2p.firefox in an adjacent directory and `source` i2p.firefox/config.sh +to set the path to the Java toolchain you want to use. + +run: `ant jar` before any of these scripts. + +run: `windows-release.sh` only *after* release.sh on a Linux machine. + +### MSI + +#### Status: Works. Maintained. + +Requires the Wixl toolset. + +run: `./windows.sh` + +### EXE: Works. Maintained. + +No special requirements. + +run: `./windows-exe.sh` + +### Portable(.zip): Unknown. Maintained. + +No special requirements. + +run: `./windows-portable.sh` + +Linux +----- + +All Linux packages require building on a Linux machines. Debian packages must +be built on Debian, Fedora packages must be built on Fedora. Some leeway for +derivative distros. Portable can be b build anywhere with a jpackage. Have +Java tools in your `PATH`. + +### Debian: Works. Maintained. + +Make sure you have a recent Java and jpackage. + +run: `ant debian` + +### Fedora: Unknown. Maintained. + +I'm a Debian user and don't have a Fedora machine set up right now. Therefore, +I build Fedora packages in a container. + +Fedora doesn't have a jpackage in their repositories as far as I can tell so I use +Adoptium's third-party repository to supply the JDK I use to build the fedora +package. + +run: `ant fedora` + +### Portable(.zip): Works. Maintained. + +Details are platform dependent. Same build-deps as everything else. + +run: `ant jpackage` + +OSX +--- + +### TODO \ No newline at end of file diff --git a/build.xml b/build.xml index e1b398e..045f57e 100755 --- a/build.xml +++ b/build.xml @@ -441,4 +441,11 @@ Linux(because the top command will be run and the script will exit).\n\nBoth det + + + + + + + diff --git a/fedora-docker.sh b/fedora-docker.sh old mode 100644 new mode 100755 index 93e0091..4ed1c18 --- a/fedora-docker.sh +++ b/fedora-docker.sh @@ -1,6 +1,18 @@ #! /usr/bin/env sh . ./config.sh + +cat < /etc/yum.repos.d/adoptium.repo +[Adoptium] +name=Adoptium +baseurl=https://packages.adoptium.net/artifactory/rpm/${DISTRIBUTION_NAME:-$(. /etc/os-release; echo $ID)}/\$releasever/\$basearch +enabled=1 +gpgcheck=1 +gpgkey=https://packages.adoptium.net/artifactory/api/gpg/key/public +EOF +yum -y update +yum -y install temurin-18-jdk + jpackage --verbose \ --type rpm \ --linux-menu-group "Network;WebBrowser;P2P" \ @@ -13,3 +25,4 @@ jpackage --verbose \ --input src/build \ --main-jar i2pfirefox.jar \ --main-class net.i2p.i2pfirefox.I2PBrowser +ls *.rpm \ No newline at end of file diff --git a/fedora.sh b/fedora.sh index 2df6493..aeb3b53 100755 --- a/fedora.sh +++ b/fedora.sh @@ -2,5 +2,6 @@ . ./config.sh docker build -t eyedeekay/i2p.plugins.firefox . -docker run --name i2pbrowser-fedora i2p.plugins.firefox -docker cp i2pbrowser-fedora:/src/i2p.plugins.firefox/i2pbrowser-${GITHUB_TAG}.rpm . +docker rm -f i2pbrowser-fedora +docker run --name i2pbrowser-fedora eyedeekay/i2p.plugins.firefox +docker cp i2pbrowser-fedora:/src/i2p.plugins.firefox/i2pbrowser-${GITHUB_TAG}.x86_64.rpm . diff --git a/release.sh b/release.sh index 3d7c749..bfac726 100755 --- a/release.sh +++ b/release.sh @@ -50,6 +50,14 @@ github-release upload --user "${GITHUB_USER}" \ --name "i2pbrowser_${GITHUB_TAG}_.deb" \ --file "i2pbrowser_${GITHUB_TAG}_amd64.deb" \ --replace -echo "Uploaded debian zip" +echo "Uploaded debian package" +github-release upload --user "${GITHUB_USER}" \ + --repo "${GITHUB_REPO}" \ + --tag "${GITHUB_TAG}" \ + --label "I2P Browser launcher as a Jpackage inside of a Fedora package." \ + --name "i2pbrowser_${GITHUB_TAG}_.rpm" \ + --file "i2pbrowser_${GITHUB_TAG}.x86_64.rpm" \ + --replace +echo "Uploaded fedora package" git pull github --tags git push --all diff --git a/src/i2p.chromium.base.profile.zip.REMOVED.git-id b/src/i2p.chromium.base.profile.zip.REMOVED.git-id index 7552c5d..b02222d 100644 --- a/src/i2p.chromium.base.profile.zip.REMOVED.git-id +++ b/src/i2p.chromium.base.profile.zip.REMOVED.git-id @@ -1 +1 @@ -29ba489bc3ba44da7fc9619d4f4d8ae0766227b7 \ No newline at end of file +8489c91da08801160dcbb05e22e8da62c4cf8002 \ No newline at end of file diff --git a/src/i2p.firefox.base.profile.zip.REMOVED.git-id b/src/i2p.firefox.base.profile.zip.REMOVED.git-id index 7dd3788..c0d074a 100644 --- a/src/i2p.firefox.base.profile.zip.REMOVED.git-id +++ b/src/i2p.firefox.base.profile.zip.REMOVED.git-id @@ -1 +1 @@ -8a1da6dd7f7709f8151a71c3ff88b60b2999572e \ No newline at end of file +decfbc8ba17d12aad4bb53e653ba9e3930f682da \ No newline at end of file diff --git a/src/i2p.firefox.usability.profile.zip.REMOVED.git-id b/src/i2p.firefox.usability.profile.zip.REMOVED.git-id index 67f5387..aa7912d 100644 --- a/src/i2p.firefox.usability.profile.zip.REMOVED.git-id +++ b/src/i2p.firefox.usability.profile.zip.REMOVED.git-id @@ -1 +1 @@ -0abfce1f580b4d0b18debc318bc776af85a74955 \ No newline at end of file +008ae44f5accf4385dcc682a0c27b5b6516b5bb4 \ No newline at end of file