diff --git a/build.xml b/build.xml index 17a5d36eb..bc0b4cce7 100644 --- a/build.xml +++ b/build.xml @@ -37,7 +37,8 @@ - + + @@ -236,19 +237,17 @@ - - - - + @@ -924,8 +923,9 @@ - - + + + @@ -934,35 +934,12 @@ - - - + + + - - - - - - - - - - - - - - - - - - - - - - - - - + + @@ -974,9 +951,8 @@ - - - + + diff --git a/debian/buildpackage.sh b/debian/buildpackage.sh new file mode 100755 index 000000000..0bfdffe3b --- /dev/null +++ b/debian/buildpackage.sh @@ -0,0 +1,30 @@ +#!/bin/sh +# This script takes one argument, which is the architecture to build for, +# or "source". + +echo Target architecture: $1 +VERSION=`grep String\ VERSION ../core/java/src/net/i2p/CoreVersion.java | cut -d\" -f2` +echo "I2P Version: ${VERSION}" +builddir="packages/$1/i2p-${VERSION}" + +if [ "$1" = "source" ]; then + cd .. + ant clean + tempdir=../_i2p_copy_temp___ + cp -a . ${tempdir} + mkdir -p debian/packages/$1 + mv ${tempdir} debian/${builddir} + cd debian/${builddir} + dpkg-buildpackage -I_MTN -Idebian/packages -S +else + mkdir -p ${builddir} + cd ${builddir} + find ../../../.. -not -name . -and -not -name .. -maxdepth 1 -exec ln -fs {} \; + dpkg-buildpackage -I_MTN -b -a$1 +fi +if [ "$?" -ne 0 ]; then + exit 1 +fi + +cd ../../.. +rm -rf ${builddir} diff --git a/debian/makerepo.sh b/debian/makerepo.sh index 64d696966..ad845f31d 100755 --- a/debian/makerepo.sh +++ b/debian/makerepo.sh @@ -28,8 +28,9 @@ echo "SignWith: ${SIGNER}" >> ${CONFFILE} # create the repository echo Building the repository... -find ../.. -name i2p_*.deb -maxdepth 1 -exec reprepro --ask-passphrase --outdir ${DIR} includedeb all {} \; -find ../.. -name i2p_*.changes -maxdepth 1 -exec reprepro --ask-passphrase --outdir ${DIR} include all {} \; +find packages/ -name *.deb -exec reprepro --ask-passphrase --outdir ${DIR} includedeb all {} \; +find packages/ -name *.changes -exec reprepro --ask-passphrase --outdir ${DIR} include all {} \; +find packages/ -name *.dsc -exec reprepro --ask-passphrase --outdir ${DIR} includedsc all {} \; # export the public key gpg --armor --export ${SIGNER} > ${DIR}/0x${KEYID}.asc diff --git a/debian/rules b/debian/rules index bf63b845c..ea785e0d6 100755 --- a/debian/rules +++ b/debian/rules @@ -120,9 +120,7 @@ binary-arch: binary-indep: clean: - rm -f debian/build - rm -rf debian/tmp/ - ant distclean + ant clean @exit 0 get-orig-source: