Re: A makefile with a mix of gcc and g++

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 04/12/2011 12:57 PM, Mahmood Naderan wrote:
Hi,
I have a makefile that compiles source files with gcc. However I want to exclude
one file and compile it with g++ (since I want to use STL in a pure ANSI C
application).  The question is how can I do that in such a way that make file
automatically compile this file with g++ and others with gcc.

Thanks,

// Naderan *Mahmood;

you can add a specific rule, like:
special_file.o: special_file.c
	g++ <foo bar>


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux