[DEFAULT]
archivedir = /usr/src/debian-repository
archive_style = flat
+ architectures = "all, amd64"
verify_sigs = 0
Subkey-Length: 2048
Name-Real: FusionForge
Expire-Date: 0
+ %no-protection
%commit
EOF
fi
gpg --export FusionForge -a > /usr/src/debian-repository/key.asc
apt-key add /usr/src/debian-repository/key.asc
- mini-dinstall -b
+ mini-dinstall -bv
# Configure debian package building tools so as to use the local repo
if [ ! -f /root/.dput.cf ]; then
method = local
run_dinstall = 0
allow_unsigned_uploads = yes
- post_upload_command = mini-dinstall -b
+ post_upload_command = mini-dinstall -bv
allowed_distributions = local
EOF
fi
cd $(dirname $0)/../src/
cp -a debian/changelog $f
- version=$(dpkg-parsechangelog | sed -n 's/^Version: \([0-9.]\+\(\~\(rc\|beta\|alpha\)[0-9]\)\?\).*/\1/p')+$(date +%Y%m%d%H%M)
+ version=$(dpkg-parsechangelog | sed -n 's/^Version: \([0-9.]\+\(\~\(rc\|beta\|alpha\)[0-9]\)\?\).*/\1/p')+autobuilt$(date +%Y%m%d%H%M)
make dist VERSION=$version
mv fusionforge-$version.tar.bz2 ../fusionforge_$version.orig.tar.bz2
cd ..
yum install -y php-cli # rpm/gen_spec.sh
# Build package
- cd /usr/src/fusionforge/src/
+ cd $(dirname $0)/../src/
base_version=$(make version)
snapshot=$(date +%Y%m%d%H%M)
version=$base_version+$snapshot
rpmbuild ../build/SPECS/fusionforge.spec --define "_topdir $(pwd)/../build" -ba
(cd ../build/RPMS/ && createrepo .)
- cat <<-EOF > /etc/yum.repos.d/local.repo
+ repopath=$(readlink ../build/RPMS/)
+ cat <<-EOF | sed 's,@PATH@,$repopath,g' > /etc/yum.repos.d/local.repo
[local]
name=local
- baseurl=file:///usr/src/fusionforge/build/RPMS/
+ baseurl=file://@PATH@
enabled=1
gpgcheck=0
EOF
function build_suse_rpm {
suse_check_release
suse_install_repos
- suse_install_rpms make gettext-runtime gettext-tools tar bzip2 rpm-build createrepo php5
+ suse_install_rpms make gettext-runtime gettext-tools tar bzip2 rpm-build createrepo php7
# Build package
cd $(dirname $0)/../src/
build_deb
elif [ -e /etc/redhat-release ]; then
build_rpm
-elif [ -e /etc/SuSE-release ]; then
+elif [[ ! -z `cat /etc/os-release | grep 'SUSE'` ]]; then
build_suse_rpm
else
echo "Automated package building is not supported for this distribution."