aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Author Topic: pupnp library OS X  (Read 3387 times)

branka

  • Newbie
  • Karma: 0
  • Offline Offline
  • Posts: 2
pupnp library OS X
« on: July 24, 2007, 05:09:25 PM »

I just started to successfully compile and install amule cvs builds on my macbook pro lately.

Here's my problem: i want to enable amule upnp on mac osx 10.4... Is there an equivalent of pupnp for osx or, as an alternative, how do i compile and install it to have the library available? I know it may have been asked before, but i tried googleing for this topic with no luck.

Thanks a lot and keep up with the good work.
Logged

wuischke

  • Developer
  • Hero Member
  • *****
  • Karma: 183
  • Offline Offline
  • Posts: 4292
Re: pupnp library OS X
« Reply #1 on: July 24, 2007, 07:59:09 PM »

Hi branka,

Frankly, I don't know a lot about Mac packaging, but I hope you'll figure everything out with the little hints I can give you.

To build libupnp:
download  libupnp-1.6.0 from pupnp.sf.net
./configure --disable-static
make

UPnP support will be compiled by default, you only have to put the libraries (libixml.so.2.0.4 and libupnp.so.3.0.0; you have to rename them or create a symlink to libixml.so.2 and libupnp.so.3 ) at the right place.
This should be aMule.app/Contents/Frameworks.

Now I don't know where Mac will look for the files, but you might try to hack aMule code:
UPnP.cpp
Code: [Select]
m_LibIXMLHandle("libixml.so.2"),
m_LibUPnPHandle2("libupnp.so.2"),
m_LibUPnPHandle3("libupnp.so.3"),
m_LibUPnPHandle(NULL)
to
Code: [Select]
m_LibIXMLHandle("../Frameworks/libixml.so.2"),
m_LibUPnPHandle2("../Frameworks/libupnp.so.2"),
m_LibUPnPHandle3("../Frameworks/libupnp.so.3"),
m_LibUPnPHandle(NULL)

Once again, I don't know if this will work with relative paths.
« Last Edit: July 25, 2007, 08:43:17 AM by wuischke »
Logged

kreegee

  • Full Member
  • ***
  • Karma: 2
  • Offline Offline
  • Posts: 160
    • http://kreegee.cycovery.com
Re: pupnp library OS X
« Reply #2 on: July 25, 2007, 12:41:58 AM »

Try to build pupnp on mac first, i always had some problems (never really found out how to hack pupnp for osx-compilation - though i suceeded once)

next thing would be the proper (probably static)) linking with amule.

branka

  • Newbie
  • Karma: 0
  • Offline Offline
  • Posts: 2
Re: pupnp library OS X
« Reply #3 on: July 25, 2007, 01:10:53 AM »

Thanks both of you; i'll try my best to get upnp to work in the next days. I'll keep you updated with my progresses.
Logged

wuischke

  • Developer
  • Hero Member
  • *****
  • Karma: 183
  • Offline Offline
  • Posts: 4292
Re: pupnp library OS X
« Reply #4 on: July 25, 2007, 08:44:50 AM »

I could cross-compile it without problems, so it should work fine. And it has to be dynamically linked or you have to change the aMule UPnP code.
Logged