On Mon, Jan 16, 2006 at 09:48:58PM -0800, sumit singhal wrote: > I am starting a project in which I want to use APR for portability. I > download APR version 1.2.2 from > "http://apr.apache.org/download.cgi#apr1" and I am using Redhat/Linux > 9. As I am a newbie to APR and I have no prior experience of using > APR, so I started learning it from: > "http://dev.ariel-networks.com/apr/apr-tutorial/html/apr-tutorial.html#toc19" > But when I try to run my First Program: > "http://dev.ariel-networks.com/apr/apr-tutorial/sample/mp-sample.c", > with the command: "cc -I/usr/local/apr/include/apr-1/ > -L/usr/local/apr/lib/ mp-sample.c -o mp-sample", I face the error: > "/usr/local/apr/include/apr-1/apr.h:270: parse error before > "apr_off_t""
You need to pass the output of the command: apr-1-config --cppflags --includes --cflags to cc, e.g. CFLAGS = `/path/to/apr-1-config --cppflags --includes --cflags` if you're using a Makefile. Regards, joe
