<div dir="ltr"><div><div><div><div><div><div><div><div><div><div>I can't change the header files of library. Therefore when I included it in my code I did<br></div>extern "C" {<br></div>#include<c header file><br>...<br>}<br><br></div>instead of just #include and it worked.<br></div><br></div>But the compiler is showing some errors in the header files I included, but of course there isn't anything wrong in them. I could include it this way as well right?<br><br></div>Also I wrote a c file and a corresponding header file in /src folder and appended the 'squid_sources' as this:<br><br></div>squid_sources = .<br>                         ...<br>                         ....<br>                        usdpaa_if.h \<br>                        usdpaa_if.c <br><br></div>Is this okay? As again it is showing errors in the usdpaa_if.c file and there are no syntax errors like the compiler says.<br></div>I saw other folder in /src like compat had also included c files like this so I thought this would be right.<br><br></div>Regards<br><div><div><div><div><div><br></div></div></div></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Mar 25, 2015 at 4:32 PM, Amos Jeffries <span dir="ltr"><<a href="mailto:squid3@treenet.co.nz" target="_blank">squid3@treenet.co.nz</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On 25/03/2015 11:26 p.m., Priya Agarwal wrote:<br>
> I could link the libraries. The problem was that libraries were C and thus<br>
> g++ wasn't creating right symbols.<br>
<br>
</span>.h files fro C libraries need to contain the syntax:<br>
<br>
#if defined(__cplusplus)<br>
extern "C" {<br>
#endif<br>
<br>
  ... library API ...<br>
<br>
#if defined(__cplusplus)<br>
}<br>
#endif<br>
<span class=""><br>
><br>
> I have another question.<br>
> what part of the source code handles shutdown or exiting (ctrl+c).<br>
<br>
</span>src/main.cc<br>
<div class="HOEnZb"><div class="h5"><br>
Amos<br>
_______________________________________________<br>
squid-users mailing list<br>
<a href="mailto:squid-users@lists.squid-cache.org">squid-users@lists.squid-cache.org</a><br>
<a href="http://lists.squid-cache.org/listinfo/squid-users" target="_blank">http://lists.squid-cache.org/listinfo/squid-users</a><br>
</div></div></blockquote></div><br></div>