Skip to content

Commit

Permalink
Modify procedure to use a single source for the "pristine" tarball
Browse files Browse the repository at this point in the history
  • Loading branch information
speth committed Jul 17, 2023
1 parent 2bbc786 commit 027babb
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 3 deletions.
12 changes: 11 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ Cantera packages for the Ubuntu PPA.
you will need to send it using the command:
`gpg --keyserver keyserver.ubuntu.com --send-keys <yourkeyID>`
- Then go through the process of updating the key on Launchpad.
- Check out a copy of this repository in `~/src/cantera-ubuntu`
- Install Docker in "rootless" mode, or otherwise set it up so your user can run the
`docker build` command

Expand All @@ -41,6 +42,15 @@ Cantera packages for the Ubuntu PPA.

*Using Cantera 2.6.0 release as an example*

- Create the "pristine" tar file corresponding to the release
- From the `cantera` repo, run:
`git archive v2.6.0 --output=../cantera-ubuntu/cantera_2.6.0.orig.tar.gz --prefix=cantera-2.6.0/`
- Note the trailing slash on the `prefix`
- For pre-release versions, format the version as `2.6.0~b2`
- Once this file has been uploaded to Launchpad for a particular version, that *exact*
file must be used for all subsequent uploads (for example, for builds targeting
different Ubuntu releases). If you lose this file, download it again from a
different Launchpad build rather than trying to recreate it.
- Check out the branch for the most recent Ubuntu release supported by the previous
Cantera release, e.g. `git checkout ubuntu20.04-ct2.6`
- Create a new branch for the new Cantera version, e.g.
Expand All @@ -57,7 +67,7 @@ Cantera packages for the Ubuntu PPA.
- `focal0` names the series, with a suffix that is incremented for each build for
that series. This number must be incremented each time the package is uploaded to
Launchpad, even if the build fails.
- For alpha/beta releases, the a `~` needs to be inserted before the alpha/beta suffix
- For alpha/beta releases, a `~` needs to be inserted before the alpha/beta suffix
so they will be seen as coming before the stable release, for example
`2.5.0~b2-1+focal0`.
- Add a message, e.g. `New upstream release`
Expand Down
1 change: 1 addition & 0 deletions run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ die () {
docker run -it \
--mount type=bind,source=$HOME/src/cantera,target=/src/cantera,readonly \
--mount type=bind,source=$HOME/.gnupg,target=/root/gnupg-remote,readonly \
--mount type=bind,source=$HOME/src/cantera-ubuntu,target=/src/cantera-ubuntu,readonly \
-e "FULL_VERSION=$FULL_VERSION" \
-e "BASE_REF=$BASE_REF" \
-e "PACKAGING_BRANCH=ubuntu${1}-ct${SHORT_VERSION}" \
Expand Down
4 changes: 2 additions & 2 deletions scripts/prepare.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ die () {
exit 1
}

mkdir /src/packaging
mkdir -p /src/packaging
cd /src/cantera
git archive $BASE_REF --output=../packaging/cantera_${FULL_VERSION}.orig.tar.gz --prefix=cantera-${FULL_VERSION}/ || die "Tag '$BASE_REF' not found"
git archive $PACKAGING_BRANCH --output=../packaging/tmp.tar --prefix=cantera/ || die "Branch ${PACKAGING_BRANCH} not found"
cd /src/packaging
rm -rf cantera
cp /src/cantera-ubuntu/cantera_${FULL_VERSION}.orig.tar.gz . || die "Pristine tarball not found"
tar xf tmp.tar

0 comments on commit 027babb

Please sign in to comment.