Commit af231daf authored by Vitaly Lipatov's avatar Vitaly Lipatov

epm-repack: fix rpm package arch (add --target to rpmbuild)

parent b1e02a44
......@@ -362,11 +362,14 @@ __epm_repack_to_rpm()
__apply_fix_code $pkgname $tmpbuilddir/$subdir $spec $pkgname
# TODO: we need these dirs to be created
to_remove_pkg_dirs="$to_remove_pkg_dirs $HOME/RPM/BUILD $HOME/RPM"
showcmd rpmbuild --buildroot $tmpbuilddir/$subdir -bb $spec
TARGETARCH=$(epm print info -a | sed -e 's|^x86$|i586|')
showcmd rpmbuild --buildroot $tmpbuilddir/$subdir --target $TARGETARCH -bb $spec
if [ -n "$verbose" ] ; then
a='' rpmbuild --buildroot $tmpbuilddir/$subdir -bb $spec || fatal
a='' rpmbuild --buildroot $tmpbuilddir/$subdir --target $TARGETARCH -bb $spec || fatal
else
a='' rpmbuild --buildroot $tmpbuilddir/$subdir -bb $spec >/dev/null || fatal
a='' rpmbuild --buildroot $tmpbuilddir/$subdir --target $TARGETARCH -bb $spec >/dev/null || fatal
fi
# remove copy of source binary package (don't mix with generated)
rm -f $tmpbuilddir/../$alpkg
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment