[Coin-discuss] Symphony and C++

Michael Hennebry hennebry at web.cs.ndsu.nodak.edu
Tue Jan 11 11:31:57 EST 2005


On Mon, 10 Jan 2005, Ted Ralphs wrote:

> Michael Hennebry wrote:

> > In a copy of Symphony's Template directory
> > how do I add file user_problem.cc to its
> > Master subdirectory and have the Makefiles
> > still work?
> >
>
> Currently, the Makefile does not automatically pick up files that do not
> have either .c or .h extensions. In the near future, we will rewrite the
> makefile to conform to the COIN standard and also allow it to pick up
> files with other extensions. For the time being, the simplest solutions
> are to either (1) confine everything to one of the existing files, or
> (2) place new files in the provided directories and give them .c or .h

Does that require editing a Makefile?
If so, I think I found the place to do it,
but if not, that would be better.

> extensions. Putting C++ code into a file with a .c extension should not
> cause any problems with the compiler in Linux or Unix.

Thank you for the suggestion.
Others reading this should remember that a .c file compiled as C++
produces the same kind of object file as a .cc or .cpp file
compiled as C++.
It will have the same sort of name mangling and linkage requirements.
Not hard to remember, but I know from experience that it can be
frustrating if you don't.

-- 
Mike   hennebry at web.cs.ndsu.NoDak.edu
"Pilot, does Moya know where we are?"  --   Zhaan
"Yes, of course.  We're someplace else.
I'll get back to you on the specifics."  --  Pilot




More information about the Coin-discuss mailing list