On 8 February 2011 15:57, David C. Rankin <drankinatty@xxxxxxxxxxxxxxxxxx> wrote: > Guys, > > I'm rewriting a set trinity pkgbuilds to download the trinity/<module> code > in the pkgbuild instead of using the existing source in the local copy of > the complete trinity svn tree. This will also allow the packages to be built > in an archroot and get around the empty src problem I was having with > makechrootpkg using the code in the existing tree. > > My PKGBUILD question is can I use the latest svn revision to build from, or > do I need to use a fixed svn revision for $pkgver? > > The examples I've looked at do something like: > > pkgver=123456 > <snip> > build() { > cd $srcdir > > msg "Connecting to $_svntrunk SVN server...." > if [ -d $_svnmod/.svn ]; then > (cd $_svnmod && svn up -r $pkgver) > else > svn co $_svntrunk --config-dir ./ -r $pkgver $_svnmod > fi > <snip> > > I want to vary this to use the latest revision instead of a fixed revision: > > pkgver=123456 > <snip> > build() { > > cd ${srcdir} > > msg "Connecting to SVN server...." > if [ -d ${_svn_module}/.svn ]; then > (cd ${_svn_module} && svn up) > [[ $? -eq 0 ]] || _co_failed=1 > else > (svn co $_svn_trunk ${_svn_module}) > [[ $? -eq 0 ]] || _co_failed=1 > fi > > cd ${_svn_module} > pkgver=$(getsvnrev) > <snip> > > Is this OK, or should I avoid using the latest version to prevent potential > inconsistencies? Also, if you see anything else that will bite me, let me > know. Thanks. > > > -- > David C. Rankin, J.D.,P.E. > makepkg automatically updates the pkgver to the latest svn revision when you build an svn package, unless you pass --holdver. -- Tavian Barnes