hi, iam porting a cpp application from windowsNT to rtlinux what i did is .... 1) i have modified testcom.c(renamed it as main2.cpp)from rt_com directory .and used in my application.
my application needs communication with com port .....so i did that . actually i have tested with small cpp code .(i inserted in testcom.c according to my need)it was working very fine ..... when i inserted the actuall application in same way as my small code it is giving weird errors...like this /usr/include/bits/pthreadtypes.h:52: conflicting types for `typedef struct __pthread_attr_s pthread_attr_t' /usr/src/rtlinux-3.1/include/rtl_sched.h:241: previous declaration as `typedef struct STRUCT_PTHREAD_ATTR pthread_attr_t' /usr/include/bits/pthreadtypes.h:60: conflicting types for `typedef struct pthread_cond_t pthread_cond_t' /usr/src/rtlinux-3.1/include/rtl_mutex.h:211: previous declaration as `typedef struct pthread_cond_t pthread_cond_t' /usr/include/bits/pthreadtypes.h:67: conflicting types for `typedef struct pthread_condattr_t pthread_condattr_t' /usr/src/rtlinux-3.1/include/rtl_mutex.h:177: previous declaration as `typedef struct pthread_condattr_t pthread_condattr_t' /usr/include/bits/pthreadtypes.h:70: conflicting types for `typedef unsigned int pthread_key_t' /usr/src/rtlinux-3.1/include/rtl_sched.h:206: previous declaration as `typedef int pthread_key_t' /usr/include/bits/pthreadtypes.h:83: conflicting types for `typedef struct pthread_mutex_t pthread_mutex_t' /usr/src/rtlinux-3.1/include/rtl_mutex.h:64: previous declaration as `typedef struct pthread_mutex_t pthread_mutex_t' /usr/include/bits/pthreadtypes.h:90: conflicting types for `typedef struct pthread_mutexattr_t pthread_mutexattr_t' /usr/src/rtlinux-3.1/include/rtl_mutex.h:27: previous declaration as `typedef struct pthread_mutexattr_t pthread_mutexattr_t' /usr/include/bits/pthreadtypes.h:140: conflicting types for `typedef long unsigned int pthread_t' /usr/src/rtlinux-3.1/include/rtl_sched.h:63: previous declaration as `typedef struct rtl_thread_struct *pthread_t' main2.cpp: In function `void *thread_code (void *)': main2.cpp:1667: cannot convert `long unsigned int' to `rtl_thread_struct *' for argument `1' to `pthread_make_periodic_np (rtl_thread_struct *, long long int, long long int)' main2.cpp: In function `int init_module ()': main2.cpp:1699: cannot convert `__pthread_attr_s *' to `pthread_attr_t *' for argument `1' to `pthread_attr_init (pthread_attr_t *)' main2.cpp:1700: cannot convert `__pthread_attr_s *' to `pthread_attr_t *' for argument `1' to `pthread_attr_setcpu_np (pthread_attr_t *, int)' main2.cpp:1702: cannot convert `__pthread_attr_s *' to `pthread_attr_t *' for argument `1' to `pthread_attr_setschedparam (pthread_attr_t *, const sched_param *)' main2.cpp:1703: cannot convert `long unsigned int *' to `rtl_thread_struct **' for argument `1' to `__pthread_create (rtl_thread_struct **, const pthread_attr_t *, void *(*) (void *), void *, module *)' main2.cpp: In function `void cleanup_module ()': main2.cpp:1718: cannot convert `long unsigned int' to `rtl_thread_struct *' for argument `1' to `pthread_delete_np (rtl_thread_struct *)' hope iam not bugging with this long error messages..... can some body help me , i need it dearly my deadline is nearing ....................................... bye Niranjan ______________________________________ Scanned and protected by email scanner _______________________________________________ Rtl mailing list [EMAIL PROTECTED] http://www2.fsmlabs.com/mailman/listinfo.cgi/rtl
