Re: Automatic dependency checking problems
Thore Karlsen <sid-m3MN3Z/L/[email protected]> Thu, 06 May 2004 14:35:06 -0500
| Newsgroups | gmane.comp.tools.aap.user |
|---|---|
| Organization | I've resigned. |
| Message-ID | <[email protected]> |
On Thu, 06 May 2004 20:37:00 +0200, Bram Moolenaar <[email protected]> wrote: >> I'm having some issues with this. >> >> First: I'm running AAP under cygwin, but I'm compiling with MSVC. This >> means that gcc can be found, so AAP will default to using that to >> generate the dependencies. This doesn't work, for a couple of reasons: >> >> 1. gcc doesn't understand the MSVC compiler flags. >> 2. The dependency files use .o for object files, not .obj which is the >> standard suffix for the windows platform. >> >> It would be good if I could tell AAP not to try to use gcc for >> dependency checking, regardless of whether it's found or not. There >> doesn't seem to be a good way to do this. >This is actually mentioned in the default.aap recipe as a todo item. > >I would think that when $CC is set to use MSVC, the test that gcc exists >should fail and Aap will use aap_depend_c() instead. Why doesn't it >work that way? Is $CC still set to gcc perhaps? When I run AAP in cygwin, AAP defaults to using gcc. I have ":usetool MSVC" in my recipe. However, the gcccheck action has cc for $CC and gcc for $CXX. I assume this is because the value of these variables is substituted when the action is parsed, and not when it is actually invoked? [...] >The order in which directories are searched for include files is often a >cause of trouble. I think when using a file in double quotes the search >always looks in the directory of the source file first. When using <> >that is skipped. My old K&R C book mentions this. > >The code apparently uses the current directory instead of the directory >of the source file. I suppose that's wrong. Please try this patch: [...] This does appear to have done the trick. I had to trick AAP into believing that gcc wasn't present to get it to use aap_depend_c(), though. -- Be seeing you. ------------------------------------------------------- This SF.Net email is sponsored by Sleepycat Software Learn developer strategies Cisco, Motorola, Ericsson & Lucent use to deliver higher performing products faster, at low TCO. http://www.sleepycat.com/telcomwpreg.php?From=osdnemail3