2013/5/31 Allan McRae <allan@archlinux.org>:
On 31/05/13 09:12, 郑文辉(Techlive Zheng) wrote:
I have an iden, since you don't want these variables change with $BUILDDIR, how about append $pkgbase to the path if the value of these variables is the same as $BUILDDIR but not with the $startdir?
E.g.:
+ if [[ $SRCDEST = $BUILDDIR ]] && [[ $SRCDEST != "$startdir" ]]; then + SRCDEST="$BUILDDIR/$pkgbase" + fi + if [[ $PKGDEST = $BUILDDIR ]] && [[ $PKGDEST != "$startdir" ]]; then + PKGDEST="$BUILDDIR/$pkgbase" + fi + if [[ $SRCPKGDEST = $BUILDDIR ]] && [[ $SRCPKGDEST != "$startdir" ]]; then + SRCPKGDEST="$BUILDDIR/$pkgbase" + fi
That seems an awful hack.
Is this not something that you can achieve using "makepkg -p" or symlinking the files into your build directory.
Allan
With recent introduced commit 3d3c7eb ''makepkg: allow make-style environment var overrides" and my two patches [1587](https://patchwork.archlinux.org/patch/1587/ and [1588](https://patchwork.archlinux.org/patch/1588/), I can now achieve this with `makepkg SRCDEST='$BUILDDIR/$pkgbase'`. This patch ticket could be colsed, I think.