Navigation Menu

Skip to content

Commit

Permalink
yum: don't require rpmdev-setuptree
Browse files Browse the repository at this point in the history
  • Loading branch information
kou committed Jul 28, 2012
1 parent f08ff61 commit 96a4790
Showing 1 changed file with 15 additions and 2 deletions.
17 changes: 15 additions & 2 deletions packages/yum/build-rpm.sh
Expand Up @@ -111,8 +111,21 @@ run yum clean ${yum_options} packages
cat <<EOF > $BUILD_SCRIPT
#!/bin/sh
rm -rf .rpmmacros
rpmdev-setuptree
if [ -x /usr/bin/rpmdev-setuptree ]; then
rm -rf .rpmmacros
rpmdev-setuptree
else
cat <<EOM > ~/.rpmmacros
%_topdir \$HOME/rpmbuild
EOM
# rm -rf rpmbuild
mkdir -p rpmbuild/SOURCES
mkdir -p rpmbuild/SPECS
mkdir -p rpmbuild/BUILD
mkdir -p rpmbuild/RPMS
mkdir -p rpmbuild/SRPMS
fi
if test -f /tmp/${SOURCE_BASE_NAME}-$VERSION-*.src.rpm; then
if ! rpm -Uvh /tmp/${SOURCE_BASE_NAME}-$VERSION-*.src.rpm; then
Expand Down

0 comments on commit 96a4790

Please sign in to comment.