[CMake] error: multiple declaration of main

Maik Beckmann beckmann.maik at googlemail.com
Thu Jan 29 01:51:01 EST 2009


2009/1/29 ankit jain <ankitguddu at gmail.com>:
> 2009/1/29 Maik Beckmann <beckmann.maik at googlemail.com>
>>
>> > but there is another function of a one header file which is called in
>> > the
>> > two C files. also it used to initialize a variable...
>>
>> If this is the case, you shouldn't have any problems, so I assume the
>> situation is different.  You can call as often as you wish, but you cannot
>> implement the same function more than once.
>>
>> This is totally unrelated to cmake.  You should post to:
>>  http://groups.google.de/group/comp.lang.c++
>
>
> thanks maik,
>
> actually i just tried and put the static keyword before the definition of
> that function which is defined as STD_NAMESPACE.
>
> its working
> Thanks for all the help
>

Cool.


More information about the CMake mailing list