[Mesa-dev] [PATCH 1/1] configure.ac: Fix build with git-svn llvm version string

Jan Vesely jan.vesely at rutgers.edu
Thu Aug 14 08:15:10 PDT 2014


On Thu, 2014-08-14 at 06:35 -0700, Tom Stellard wrote:
> On Wed, Aug 13, 2014 at 04:46:56PM -0400, Jan Vesely wrote:
> > Signed-off-by: Jan Vesely <jan.vesely at rutgers.edu>
> > ---
> > 
> > My llvm-config --version is
> > 3.6.0git-svn-r215564-cd35a3b3
> > 
> > This patch assumes that the interesting part consists of only digits and dots.
> > 
> > 
> >  configure.ac | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/configure.ac b/configure.ac
> > index 4ff87eb..dc5117e 100644
> > --- a/configure.ac
> > +++ b/configure.ac
> > @@ -1697,7 +1697,7 @@ if test "x$enable_gallium_llvm" = xyes; then
> >      fi
> >  
> >      if test "x$LLVM_CONFIG" != xno; then
> > -        LLVM_VERSION=`$LLVM_CONFIG --version | sed 's/svn.*//g'`
> > +        LLVM_VERSION=`$LLVM_CONFIG --version | sed 's/[[^0-9.]].*//g'`
> 
> As long as we are changing this.  I think it would be simpler to use grep:
> 
> `$LLVM_CONFIG --version | grep -o '^[[0-9.]]\+'`

I agree. I didn't know about grep -o.
It fixes my issue.

Reviewed-and-tested-by: Jan Vesely <jan.vesely at rutgers.edu>

jan

> 
> -Tom
> 
> >          LLVM_LDFLAGS=`$LLVM_CONFIG --ldflags`
> >          LLVM_BINDIR=`$LLVM_CONFIG --bindir`
> >          LLVM_CPPFLAGS=`strip_unwanted_llvm_flags "$LLVM_CONFIG --cppflags"`
> > -- 
> > 1.9.3
> > 
> > _______________________________________________
> > mesa-dev mailing list
> > mesa-dev at lists.freedesktop.org
> > http://lists.freedesktop.org/mailman/listinfo/mesa-dev

-- 
Jan Vesely <jan.vesely at rutgers.edu>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: This is a digitally signed message part
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20140814/aa15a212/attachment.sig>


More information about the mesa-dev mailing list