This is the mail archive of the automake@gnu.org mailing list for the automake project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: compiler change


[...]

 David> One of my subdirectories will be using the mpiCC
 David> compiler, but the rest of the subdirectories will be
 David> using gcc. How do I acheive this using Automake?
 >> 
 >> You can override the CC or COMPILE variables in this
 >> Makefile.am.

(Actually, you'll probably have to fiddle with CCDEPMODE too,
for the dependency tracking to work -- good luck!)

[...]

 David> I have an additional question with respect to using different 
 David> compilers for different codes.

 David> I can override the compiler choice (and compiler flags) in a given 
 David> Makefile.am using 

 David> CXX = mpicc
 David> AM_CXXFLAGS = -O5 -Wall

 David> If I do this then it applies to all codes which the
 David> Makefile.am compiles.

 David> Is there a way of doing this on a code-by-code basis?

No easy.  What you can do is to supply the build rules yourself.

 David> I have tried

 David> code_CXX
 David> code_CXXFLAGS = -O5 -Wall

 David> for a particular code, but it doesn't seem to work.

 David> What am I doing wrong?

Nothing.  code_CXX is not supported.
-- 
Alexandre Duret-Lutz



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]