diff --git a/.travis.yml b/.travis.yml index 96b73031c8..26dadaf8f9 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,7 +6,7 @@ language: c # Make sure build dependencies are installed. install: - - sudo apt-get install mono-gmcs cli-common-dev libgl1-mesa-glx libopenal1 libfreetype6 dpkg rpm nsis markdown + - sudo apt-get install mono-gmcs cli-common-dev libgl1-mesa-glx libopenal1 libfreetype6 cache: apt # Run the build script @@ -35,10 +35,11 @@ notifications: skip_join: true before_deploy: + - sudo apt-get install nsis markdown dpkg rpm - DOTVERSION=`echo $TRAVIS_TAG | sed "s/-/\\./g"` - cd packaging - mkdir build - - ./package-all.sh $TRAVIS_TAG build + - ./package-all.sh $TRAVIS_TAG $PWD/build/ deploy: provider: releases api_key: @@ -50,6 +51,6 @@ deploy: - build/openra_$DOTVERSION_all.deb skip_cleanup: true on: - all_branches: true + all_branches: false tags: true repo: OpenRA/OpenRA diff --git a/packaging/linux/buildpackage.sh b/packaging/linux/buildpackage.sh index baf2c87d2d..928b9474e1 100755 --- a/packaging/linux/buildpackage.sh +++ b/packaging/linux/buildpackage.sh @@ -40,7 +40,7 @@ cd packaging/linux pushd deb echo "Building Debian package." -./buildpackage.sh "$TAG" ../$ROOTDIR "$PACKAGEDIR" +bash buildpackage.sh "$TAG" ../$ROOTDIR "$PACKAGEDIR" if [ $? -ne 0 ]; then echo "Debian package build failed." fi @@ -48,7 +48,7 @@ popd pushd pkgbuild echo "Building Arch-Linux package." -sh buildpackage.sh "$TAG" ../$ROOTDIR "$PACKAGEDIR" +bash buildpackage.sh "$TAG" ../$ROOTDIR "$PACKAGEDIR" if [ $? -ne 0 ]; then echo "Arch-Linux package build failed." fi @@ -56,11 +56,9 @@ popd pushd rpm echo "Building RPM package." -sh buildpackage.sh "$TAG" ../$ROOTDIR ~/rpmbuild "$PACKAGEDIR" +bash buildpackage.sh "$TAG" ../$ROOTDIR ~/rpmbuild "$PACKAGEDIR" if [ $? -ne 0 ]; then echo "RPM package build failed." fi popd -wait - diff --git a/packaging/linux/rpm/buildpackage.sh b/packaging/linux/rpm/buildpackage.sh index b5e88ee430..e11fbe49d8 100755 --- a/packaging/linux/rpm/buildpackage.sh +++ b/packaging/linux/rpm/buildpackage.sh @@ -6,6 +6,8 @@ then exit $E_BADARGS fi +mkdir ~/rpmbuild/ + # Replace any dashes in the version string with periods PKGVERSION=`echo $1 | sed "s/-/\\./g"` diff --git a/packaging/package-all.sh b/packaging/package-all.sh index 642897aebb..ea1f4f4aea 100755 --- a/packaging/package-all.sh +++ b/packaging/package-all.sh @@ -89,7 +89,7 @@ popd pushd osx echo "Zipping OS X package" -sh buildpackage.sh "$TAG" "$BUILTDIR" "${SRCDIR}/thirdparty/osx" "$OUTPUTDIR" +bash buildpackage.sh "$TAG" "$BUILTDIR" "${SRCDIR}/thirdparty/osx" "$OUTPUTDIR" if [ $? -ne 0 ]; then echo "OS X package build failed." fi @@ -97,7 +97,7 @@ popd pushd linux echo "Building Linux packages" -sh buildpackage.sh "$TAG" "$BUILTDIR" "${SRCDIR}/thirdparty/linux" "$OUTPUTDIR" +bash buildpackage.sh "$TAG" "$BUILTDIR" "${SRCDIR}/thirdparty/linux" "$OUTPUTDIR" if [ $? -ne 0 ]; then echo "Linux package build failed." fi