tags:

views:

43

answers:

1

Hi all

I've been trying to compile a program that uses PCL. However, I keep getting this error:

test.c:23: error: ‘PCL_CNT_TYPE’ undeclared (first use in this function)
test.c:23: error: (Each undeclared identifier is reported only once
test.c:23: error: for each function it appears in.)
test.c:23: error: expected ‘;’ before ‘i_result_list1’
test.c:24: error: ‘PCL_FP_CNT_TYPE’ undeclared (first use in this function)
test.c:24: error: expected ‘;’ before ‘fp_result_list1’
test.c:27: error: ‘PCL_L1DCACHE_MISS’ undeclared (first use in this function)
test.c:28: error: ‘PCL_L2CACHE_MISS’ undeclared (first use in this function)
test.c:30: error: ‘PCL_MODE_USER’ undeclared (first use in this function)
test.c:33: error: ‘PCL_SUCCESS’ undeclared (first use in this function)
test.c:47: error: ‘i_result_list2’ undeclared (first use in this function)
test.c:47: error: ‘fp_result_list2’ undeclared (first use in this function)

Any ideas why?

I have libpcl1{-dev} installed in me machine, so I'm wondering what else is necessary to make this works.

If you need further inforamtion just let me know.

Thanks.

+2  A: 

Put:

#include <pcl.h>

at the top of the file. You will also need -lpcl when linking. E.g.:

gcc program.c -lpcl -o program
Matthew Flaschen