[LLVMdev] creating a project from sample project

Reid Spencer reid at x10sys.com
Mon Apr 17 23:29:59 PDT 2006


Rather than fix the documentation to match reality, I decided to fix
reality to match the documentation. I have just committed (CVS head)
changes to the sample project's AutoRegen.sh script that will prompt the
user for the path to the LLVM source root and the LLVM object root, if
it can't automatically determine the location (because your project is
not located in the llvm/projects directory).  Once entered, the value is
retained and used throughout so you never need to specify it again.
Hopefully, this will help with your circumstances.

Please try it out and let me know if that solution works or if you have
any further issues.


On Tue, 2006-04-18 at 00:03 -0500, Ryan M. Lefever wrote:
> Thank you for the response.  I guess the only thing that is confusing is 
> that the LLVM documentation, at http://llvm.org/docs/Projects.html under 
> the "Create a Project from the Sample Project" heading, indicates that 
> (1) you can place your project *anywhere* you want, and (2) that you are 
> supposed to use the AutoRegen.sh script as is.  However, that seems not 
> to be the case.
> The reason my project is not in the LLVM projects directory is because 
> it is in a CVS directory as part of a different project I am working on.
> Again thanks for the help.
> Ryan
> Reid Spencer wrote:
> > It's complaining about the LLVM autoconf/m4 directory which contains the
> > m4 macros that are used in your project's configure.ac. By convention,
> > your project should be in the llvm/projects directory so that you have:
> > 
> > 1. llvm/autoconf
> > 2. llvm/projects/yourProj/autoconf
> > 
> > The AutoRegen.sh in #2 is looking for #1. By convention that should be
> > located at ../../../autoconf/m4.  AC_CONFIG_AUX_DIR has nothing to do
> > with it, as that comes into play only when autoconf is run, not when
> > AutoRegen.sh is running. 
> > 
> > Probably the only thing you're doing "wrong" is not placing your project
> > in the llvm/projects directory.  If you need to have your project
> > elsewhere, then what you did (change llvm_m4) is correct.  But, please
> > be aware, the directory you want is *not* your project's autoconf
> > directory, but LLVM's autoconf directory.
> > 
> > Reid.
> > 
> > On Fri, 2006-04-14 at 18:40 -0500, Ryan M. Lefever wrote:
> > 
> >>I am trying to create a project in my home directory based off the 
> >>instructions in http://llvm.org/docs/Projects.html.  I have completed 
> >>step 4 requiring me to set the values in autoconf/configure.ac  In step 
> >>5, when I run AutoRegen.sh, I get the following error:
> >>
> >>Can't find the LLVM autoconf/m4 directory. The project should be checked 
> >>out to projects directory
> >>
> >>So, I assumed that I set AC_CONFIG_AUX_DIR incorrectly in configure.ac. 
> >>  I tried setting it to an absolute path and a relative path but had no 
> >>luck.  Then I looked at AutoRegen.sh, and it seems to have a variable 
> >>called llvm_m4 that is hardcoded to either ../../../autoconf/m4 or 
> >>../../llvm/autoconf/m4.  If I hardcode in another option that allows 
> >>llvm_m4 to be hardcoded to the same value that I set AC_CONFIG_AUX_DIR 
> >>to, then I am able to run AutoRegen.sh.  Am I doing something wrong?
> >>
> >>Regards,
> >>Ryan
> >>
> >>_______________________________________________
> >>LLVM Developers mailing list
> >>LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> >>http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
> >>
> >>
> >>------------------------------------------------------------------------
> >>
> >>_______________________________________________
> >>LLVM Developers mailing list
> >>LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> >>http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20060417/4f4ffd2f/attachment.sig>

More information about the llvm-dev mailing list