[mythtv] [mythtv-commits] mythtv commit: r14781 - in trunk/mythtv by nigel
Nigel Pearson
nigel at ind.tansu.com.au
Fri Nov 2 06:14:56 UTC 2007
On 01/11/2007, at 12:57 PM, David wrote:
> I'm trying to keep the upnp library a pure protocol implementation.
Speaking of which, the Makefile seems
to pull in a lot of un-needed libraries.
Any objection to:
% svn diff *.pro
Index: libmythupnp.pro
===================================================================
--- libmythupnp.pro (revision 14784)
+++ libmythupnp.pro (working copy)
@@ -32,15 +32,11 @@
INCLUDEPATH += ../libmyth
INCLUDEPATH += ../..
-DEPENDPATH += ../libmythtv ../libmyth ../libavcodec
-DEPENDPATH += ../libavformat
+DEPENDPATH += ../libmyth
-LIBS += -L../libmyth -L../libmythtv -L../libavcodec
-LIBS += -L../libavformat
+LIBS += -L../libmyth
+LIBS += -lmyth-$$LIBVERSION
-LIBS += -lmythtv-$$LIBVERSION -lmythavformat-$$LIBVERSION
-LIBS += -lmythavcodec-$$LIBVERSION -lmyth-$$LIBVERSION $$EXTRA_LIBS
-
isEmpty(QMAKE_EXTENSION_SHLIB) {
QMAKE_EXTENSION_SHLIB=so
}
@@ -77,8 +73,4 @@
macx {
HEADERS += darwin-sendfile.h
SOURCES += darwin-sendfile.c
-
- # This lib depends on libmythtv which depends on some stuff in
libmythui.
- LIBS += -L../libmythui -lmythui-$$LIBVERSION
- #QMAKE_LFLAGS_SHLIB += -flat_namespace -undefined warning
}
> Let me know if you would like to discuss this more.
I think we need one more class in there, just to
simplify autodiscovery. Something I could use like:
#include <libmythupnp/simpleclient.h>
QString sMBE = "urn:schemas-mythtv-
org:device:MasterMediaServer:1";
UPnpClient *pClient = new UPnpClient();
SSDPCacheEntries *pMBEs = pClient->Search(sMBEs, 2); // Fill cache
for 2secs
if (pMBEs->Count() == 1)
selected = pMBEs[0];
else
{
pClient.AddListener(this) // Get events for newly discovered
devices
// Put up UI to choose a BE
}
delete pClient;
if (selected)
{
// Pop up PIN, try to get details
// try to store details in config.xml
}
At the moment, I need to create an XmlConfiguration,
a UPnp, and then an HttpServer (in that order :-).
Having a simple wrapper class would be nicer.
Thoughts?
--
Nigel Pearson, nigel at ind.tansu.com.au| All science is;
Telstra Net. Eng., Sydney, Australia | either Physics,
Office: 9202 3900 Fax: 9261 3912 | or stamp collecting!
Mobile: 0408 664435 Home: 9792 6998 | - Rutherford
More information about the mythtv-dev
mailing list