Using LLVM with Autotools

2016-03-24 Thread Russell Wallace
I'm writing a C++ program that needs to compile and link with LLVM, and trying to figure out how to build it with autotools. The good news is, llvm-config will supply the relevant compiler and linker flags. The bad news is, the llvm-config in the current path is not likely to be the right one (e.

Re: Using LLVM with Autotools

2016-03-24 Thread Jeffrey Walton
> The bad news is, the llvm-config in the current path is not likely to be > the right one (e.g. Ubuntu 14.04 thinks LLVM 3.4 is the latest version > whereas it's actually up to 3.8, and the differences between versions do > matter) so the user or packager needs to supply a path to the correct > ll

Re: Using LLVM with Autotools

2016-03-24 Thread Russell Wallace
I don't think I'm understanding you - in this case, I'm the one writing the program, and thinking about the configure.ac and Makefile.am I'll be supplying to users and prospective package maintainers? I think the default autoconf on typical Linux distributions is normally sufficient these days? W

Re: Using LLVM with Autotools

2016-03-24 Thread Jeffrey Walton
On Thu, Mar 24, 2016 at 12:13 PM, Russell Wallace wrote: > I don't think I'm understanding you - in this case, I'm the one writing the > program, and thinking about the configure.ac and Makefile.am I'll be > supplying to users and prospective package maintainers? > > I think the default autoconf o

Re: Using LLVM with Autotools

2016-03-24 Thread Gavin Smith
On 24 March 2016 at 15:05, Russell Wallace wrote: > I'm writing a C++ program that needs to compile and link with LLVM, and > trying to figure out how to build it with autotools. > > The good news is, llvm-config will supply the relevant compiler and linker > flags. Is llvm-config hardcoded into

Re: Using LLVM with Autotools

2016-03-24 Thread Russell Wallace
In this case I'm the one who has to write configure.ac and Makefile.am so I need to find out what the answers need to be. But I see what you're saying, that it's at least theoretically possible to do the whole job on the ./configure command line. That would make said command line a bit long and unw

Transferring variables from configure.ac to Makefile.am

2016-03-24 Thread Russell Wallace
I think I sort of see how to set variables within configure.ac, and do some minimal calculations on them. But how do you transfer the value of a variable set in configure.ac, to Makefile.am where it will be actually used? ___ Autoconf mailing list Autocon

Re: Transferring variables from configure.ac to Makefile.am

2016-03-24 Thread Nick Bowler
Hi Russell, On 3/24/16, Russell Wallace wrote: > I think I sort of see how to set variables within configure.ac, and do some > minimal calculations on them. But how do you transfer the value of a > variable set in configure.ac, to Makefile.am where it will be actually > used? Any shell variable

Clean rebuild

2016-03-24 Thread Russell Wallace
How do you do a clean rebuild, i.e. rebuilding all machine-generated files? I tried autoconf -i, tried prefixing it with make clean, tried prefixing it with make distclean, but configure still had an old timestamp, so I tried manually rm configure, but the newly generated configure is still printin