roberto caselli wrote:

> Thank you very much! How can I edit the raster example to have a c++ source 
> code (.cc extension)?
> I should edit something in the makefile, but I don't how to do. Someone could 
> help me?

Add the following line before including the *.make files (e.g. Module.make):

        MOD_OBJS := $(subst .cc,.o,$(wildcard *.cc))

By default, MOD_OBJS is determined based upon the .c files in the
directory.

Rules.make already includes pattern rules for compiling .cc and .cpp
files.

Note that the GRASS headers don't make allowances for use in C++ code,
so you need to use e.g.:

        extern "C" {
        #include <grass/gis.h>
        }

At some point, we should probably change Rules.make to automatically
deal with C++ files (.cc and .cpp extensions; maybe .cxx as well).

-- 
Glynn Clements <[EMAIL PROTECTED]>
_______________________________________________
grass-dev mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/grass-dev

Reply via email to