Fix Archlinux package creation #425

Merged
rakoo merged 1 commits from fix-archpackage into master 2013-08-25 22:15:06 +02:00

17
arch.sh
View File

@ -1,5 +1,6 @@
#!/bin/bash #!/bin/bash
GIT_APP=PyBitmessage
APP=pybitmessage APP=pybitmessage
PREV_VERSION=0.3.5 PREV_VERSION=0.3.5
VERSION=0.3.5 VERSION=0.3.5
@ -25,24 +26,12 @@ make clean
rm -f archpackage/*.gz rm -f archpackage/*.gz
# having the root directory called name-version seems essential # having the root directory called name-version seems essential
mv ../${APP} ../${APP}-${VERSION} mv ../${GIT_APP} ../${APP}-${VERSION}
tar -cvzf ${SOURCE} ../${APP}-${VERSION} --exclude-vcs tar -cvzf ${SOURCE} ../${APP}-${VERSION} --exclude-vcs
# rename the root directory without the version number # rename the root directory without the version number
mv ../${APP}-${VERSION} ../${APP} mv ../${APP}-${VERSION} ../${GIT_APP}
# calculate the MD5 checksum # calculate the MD5 checksum
CHECKSM=$(md5sum ${SOURCE}) CHECKSM=$(md5sum ${SOURCE})
sed -i "s/md5sums[^)]*)/md5sums=(${CHECKSM%% *})/g" archpackage/PKGBUILD sed -i "s/md5sums[^)]*)/md5sums=(${CHECKSM%% *})/g" archpackage/PKGBUILD
cd archpackage
# Create the package
tar -c -f ${APP}-${VERSION}.pkg.tar .
sync
xz ${APP}-${VERSION}.pkg.tar
sync
# Move back to the original directory
cd ${CURRDIR}