Attempt to detect best UPnP library available

Because we don't support libupnp-1.8.x yet avoid using that library
If libupnp-1.6.x is available use that, if not try to use miniupnc if
  if unavailble print a warning and disable RetroShare UPnP support
This commit is contained in:
Gioacchino Mazzurco 2019-04-24 18:08:35 +02:00
parent 2498f945f4
commit fb4f206427
No known key found for this signature in database
GPG key ID: A1FBCA3872E87051
3 changed files with 56 additions and 9 deletions

View file

@ -1586,9 +1586,11 @@ int RsServer::StartupRetroShare()
mNetMgr->addNetListener(mProxyStack);
#endif
#if defined(RS_USE_LIBMINIUPNPC) || defined(RS_USE_LIBUPNP)
// Original UPnP Interface.
pqiNetAssistFirewall *mUpnpMgr = new upnphandler();
mNetMgr->addNetAssistFirewall(1, mUpnpMgr);
#endif // defined(RS_USE_LIBMINIUPNPC) || defined(RS_USE_LIBUPNP)
}
/**************************************************************************/