Menu

#24 C++ compilation problem : 'strncpy not declared in this scope'

v1.0_(example)
open
nobody
None
1
2017-09-07
2013-11-14
Anonymous
No

Hi,

I have a compilation problem executing gnu.linux makefile with following configuration :

  • Ubuntu 12.04 64-bits
  • GNU make 3.81
  • gcc 4.6.3

The error:

make
FastEntityPdu.cpp ...
'strncpy' was not declared in this scope.

What am I doing wrong ?

Thanks.

Related

Bugs: #24

Discussion

  • Anonymous

    Anonymous - 2013-11-14

    Huh. That must have been introduced by a patch to get plausible string handling for the marking field. I don't have a C++ build environment handy, but it's looking for the "classic" C string handling routines for copying strings. Doing an

    include <cstring>

    In the cpp file indicated should work. I'll try to get that fix included in the patch once I can get a C++ build environment working. (I usually don't work with the C++ language implementation.)

     
  • Anonymous

    Anonymous - 2017-09-07

    Hi
    Same problem here. How did you fixed it?
    Including cstring had no effect. (I included it in FastEntityPdu.cpp)

     
    • Don McGregor

      Don McGregor - 2017-09-07

      Not a C++ guy, but I think the string code is part of the standard library.

      / strncpy example /

      include <stdio.h>

      include <string.h>

      On Sep 7, 2017, at 8:32 AM, noreply@in.sf.netnoreply@in.sf.net wrote:

      Hi
      Same problem here. How did you fixed it?
      Including cstring had no effect. (I included it in FastEntityPdu.cpp)


      [bugs:#24]https://sourceforge.net/p/open-dis/bugs/24/ C++ compilation problem : 'strncpy not declared in this scope'

      Status: open
      Group: v1.0_(example)
      Created: Thu Nov 14, 2013 06:38 AM UTC by Anonymous
      Last Updated: Thu Sep 07, 2017 06:06 AM UTC
      Owner: nobody

      Hi,

      I have a compilation problem executing gnu.linux makefile with following configuration :

      • Ubuntu 12.04 64-bits
      • GNU make 3.81
      • gcc 4.6.3

      The error:

      make
      FastEntityPdu.cpp ...
      'strncpy' was not declared in this scope.

      What am I doing wrong ?

      Thanks.


      Sent from sourceforge.nethttp://sourceforge.net because you indicated interest in https://sourceforge.net/p/open-dis/bugs/24/

      To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/

       

      Related

      Bugs: #24