Re: Linking agent against a C++ application

2006-01-30 Thread Raffles
Dave Shield wrote: > > ... Could we not make it standard in the Makefiles to use > $(CC) for compiling and $(LINKCC) for linking, so that you could do > > ./configure --with-linkcc=g++ With LINKCC defaulting to $(CC), presumably? I hadn't thought of that, but yes, sounds like a great idea

Re: Linking agent against a C++ application

2006-01-27 Thread Dave Shield
On Fri, 2006-01-27 at 15:34 +, Raffles wrote: > ./configure --with-cc=g++ compiles the entire agent with the C++ > compiler, which I definitely want to avoid Fair enough. I wasn't sure whether this would be an acceptable approach or not. It was just the simplest way forward. > I can unde

Re: Linking agent against a C++ application

2006-01-27 Thread Raffles
Hi Dave, ./configure --with-cc=g++ compiles the entire agent with the C++ compiler, which I definitely want to avoid - the semantics are subtly different and it would be very easy to introduce bugs without realising it. As it happens I kicked it off just before I started this reply and the bu

Re: Linking agent against a C++ application

2006-01-27 Thread Dave Shield
On Fri, 2006-01-27 at 14:39 +, Raffles wrote: > OK I've fixed it. All you need to be able to link the agent in to a C++ > application, is a small change to the Makefiles in the agent and apps > directories. When linking the Makefile needs to give g++ as the first > "argument" to libtool, rat

Re: Linking agent against a C++ application

2006-01-27 Thread Raffles
OK I've fixed it. All you need to be able to link the agent in to a C++ application, is a small change to the Makefiles in the agent and apps directories. When linking the Makefile needs to give g++ as the first "argument" to libtool, rather than gcc. Below is a patch file for fixing the two ma

Linking agent against a C++ application

2006-01-24 Thread Raffles
Hi There, I'm trying to use NetSNMP to monitor a software system which is written in C++. I've created a C wrapper for the API to the C++ application, and written a mib2c config file to generate code which calls the API to get/set the information it needs. I've stuck the mib2c output into th