Re: [Ekiga-devel-list] Deviating address-call

Hello Damien:

Thanks a lot for your answer.

We're students from Spain and we're working on a simple project and basically we want to redirect a certain number of SIPs without change ekiga code and by using LD_PRELOAD. We know we could use a SIP proxy, but that's not the objective of the project

I finally was able to make the changes I asked before by modifying Opal SetUpCall. 

BOOL OpalManager::SetUpCall(const PString & partyA,
                            const PString & partyB,
                            PString & token,
                            void * userData

  OpalCall * call = CreateCall();
  token = call->GetToken();

  char **host; int  *port;

  if (EndsWith((string)partyB,"")==0) {
	if (getAddress((char *)p,(char **)&host,(int *)&port)) {
		newPartyB = userName&"@"&(char *)host&":"&(*port);	
  }//else we call SetPartyB with default arguments.
  else call->SetPartyB(partyB);


Now, the problem happens when we make a call ending on "". We get this: undefined symbol: _Z10getAddressPcPS_Pi

As we say before, we use LD_PRELOAD to override SetUpCall and we compile that function:

Where we write the SetUpCall library, is compiled with this. Here are the most important parts of Makefile:

# Dynamic library OPAL building	
managerMOD: managerMOD.o parserxx.o eg_common.o eg_sip.o 
	gcc -shared -o managerMOD.o eg_common.o eg_sip.o parserxx.o -ldl -L/usr/local/lib/

	$(CC) $(CFLAGS) $(INCLUDES) -c -o managerMOD.o ./src/lib/overrided_opal/managerMOD.cxx

//The rest of .o named on managerMOD are compiled like the previous example.

The getAddress(...) function is implemented on eg_common.cxx and managerMOD.h includes eg_common.h.

We would be very thankful if you could give us some hint about that undefined symbol problem. Any ideas?

Thanks a lot!

MSN Video.

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]