Compare commits
7 Commits
branch-1.4
...
release-1.
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d0014a1ae5 | ||
|
|
dee7744256 | ||
|
|
adcc34aeac | ||
|
|
3a11a7b113 | ||
|
|
af5db93bb1 | ||
|
|
579a6fdee4 | ||
|
|
5a505c72ec |
80
ChangeLog
80
ChangeLog
@@ -1,28 +1,28 @@
|
||||
2006-07-07 Oxy <virtual_worlds@gmx.de>
|
||||
2006-07-07 Oxy <virtual_worlds(at)gmx.de>
|
||||
|
||||
* full support for Windows added, static library and DLL are fully
|
||||
working, code compiles with Borland Builder C++ and MS Visual
|
||||
C/C++
|
||||
|
||||
2006-07-05 Nektarios K. Papadopoulos <npapadop@inaccessnetworks.com>
|
||||
2006-07-05 Nektarios K. Papadopoulos <npapadop(at)inaccessnetworks.com>
|
||||
|
||||
* Include prebuilt documentation (html,pdf), dropping doc++
|
||||
dependancy.
|
||||
|
||||
2006-07-03 Marcelo Jimenez <mroberto@users.sourceforge.net>
|
||||
2006-07-03 Marcelo Jimenez <mroberto(at)users.sourceforge.net>
|
||||
|
||||
* Patch for FreeBSD, thanks to Markus Strobl.
|
||||
|
||||
2006-06-26 Marcelo Jimenez <mroberto@users.sourceforge.net>
|
||||
2006-06-26 Marcelo Jimenez <mroberto(at)users.sourceforge.net>
|
||||
|
||||
* Fix for missing "else" in httpreadwrite.c. Thanks to npapadop
|
||||
for the patch.
|
||||
|
||||
2006-06-26 Marcelo Jimenez <mroberto@users.sourceforge.net>
|
||||
2006-06-26 Marcelo Jimenez <mroberto(at)users.sourceforge.net>
|
||||
|
||||
* Fix for va_list initialization in x86_64 architectures.
|
||||
|
||||
2006-06-08 Oxy <virtual_worlds@gmx.de>
|
||||
2006-06-08 Oxy <virtual_worlds(at)gmx.de>
|
||||
|
||||
* Patch to fix memory leaks and reasons for crashes added (thanks
|
||||
to loigu)
|
||||
@@ -31,19 +31,19 @@
|
||||
Release of version 1.4.0
|
||||
*************************************************************************
|
||||
|
||||
2006-05-26 Oxy <virtual_worlds@gmx.de>
|
||||
2006-05-26 Oxy <virtual_worlds(at)gmx.de>
|
||||
|
||||
* defines in iasnprintf.h changed to work with GCC-version < 3
|
||||
|
||||
2006-05-22 Oxy <virtual_worlds@gmx.de>
|
||||
2006-05-22 Oxy <virtual_worlds(at)gmx.de>
|
||||
|
||||
* BSD-patch added (not tested yet on an BSD system)
|
||||
|
||||
2006-05-19 Oxy <virtual_worlds@gmx.de>
|
||||
2006-05-19 Oxy <virtual_worlds(at)gmx.de>
|
||||
|
||||
* Patch added for bug: ixml parser colapsed on empty args (arg="")
|
||||
|
||||
2006-05-18 Oxy <virtual_worlds@gmx.de>
|
||||
2006-05-18 Oxy <virtual_worlds(at)gmx.de>
|
||||
|
||||
* DSM-320 patch added (fetched from project MediaTomb)
|
||||
* httpGet additons atch added, Added proxy support by introducing
|
||||
@@ -56,14 +56,14 @@ Release of version 1.4.0
|
||||
FORK FROM DEAD libupnp
|
||||
*************************************************************************
|
||||
|
||||
2006-04-29 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-04-29 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* THANKS: new file with list of contributors
|
||||
|
||||
* upnp/src/gena/gena_device.c (respond_ok): add 'Content-Length: 0'
|
||||
in subscription response. Patch by Chaos (Bug # 1455367).
|
||||
|
||||
2006-04-08 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-04-08 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* upnp/doc/UPnP_Programming_Guide.pdf: replace this document with
|
||||
the one in libupnp-doc-1.2.1 because current CVS version
|
||||
@@ -74,20 +74,20 @@ FORK FROM DEAD libupnp
|
||||
* changes applied to several files to work under Sparc Solaris, temporarily
|
||||
requiring a define SPARC_SOLARIS
|
||||
|
||||
2006-04-03 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-04-03 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* upnp/Makefile.am: install upnp samples in $(docdir)/examples
|
||||
|
||||
2006-03-28 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-03-28 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* configure.ac: add --with-docdir option to choose where documentation
|
||||
is installed (or -without-docdir to not install the documentation)
|
||||
|
||||
2006-03-27 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-03-27 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* ixml/test: add simple test suite for xml parser
|
||||
|
||||
2006-03-26 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-03-26 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* ixml/src/ixmlparser.c (Parser_processCDSect): fix bug which prevents
|
||||
CDATA sections which contain a 0 (zero) to be parsed (instead the
|
||||
@@ -98,18 +98,18 @@ FORK FROM DEAD libupnp
|
||||
option, and move samples compilation from check_PROGRAMS to
|
||||
noinst_PROGRAMS
|
||||
|
||||
2006-03-25 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-03-25 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* upnp/src/genlib/miniserver/miniserver.c (get_miniserver_sockets):
|
||||
fix bug if new socket created has fd 0 (can only occur when stdin
|
||||
has been closed). Patch by Oskar Liljeblad 2004-07-02 :
|
||||
http://sourceforge.net/mailarchive/message.php?msg_id=8870528
|
||||
|
||||
2006-03-21 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-03-21 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* upnp/test/test_init.c: add some version checks and exit if failure
|
||||
|
||||
2006-03-05 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-03-05 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* libupnp version 1.3.1
|
||||
|
||||
@@ -124,11 +124,11 @@ FORK FROM DEAD libupnp
|
||||
dependencies between upnp and ixml / threadutil, so that programs
|
||||
linking against upnp only still work.
|
||||
|
||||
2006-03-04 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-03-04 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* libupnp version 1.3.0
|
||||
|
||||
2006-03-03 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-03-03 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* upnp/src/genlib/net/http/httpreadwrite.c (get_sdk_info): use
|
||||
package version string from configure to set sdk info
|
||||
@@ -136,7 +136,7 @@ FORK FROM DEAD libupnp
|
||||
* upnp/Makefile.am: add sample/tvdevice/web/ files in EXTRA_DIST
|
||||
+ do not distribute generated upnpconfig.h file.
|
||||
|
||||
2006-02-28 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-02-28 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* upnp/src/inc/config.h, configure.ac: use only new defines
|
||||
UPNP_HAVE_xx instead of INCLUDE_yyy_APIS and INTERNAL_WEB_SERVER
|
||||
@@ -145,7 +145,7 @@ FORK FROM DEAD libupnp
|
||||
the librarie LDFLAGS in order to export only the symbols defined
|
||||
in the API
|
||||
|
||||
2006-02-27 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-02-27 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* configure.ac: add libtool versions for the 3 libraries
|
||||
|
||||
@@ -153,7 +153,7 @@ FORK FROM DEAD libupnp
|
||||
|
||||
* threadutil/src/ThreadPool.c (SetSeed): add missing 'static'
|
||||
|
||||
2006-02-26 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-02-26 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* threadutil/inc/iasnprintf.h: add gcc __printf__ format attribute
|
||||
to "iasnprintf"
|
||||
@@ -174,11 +174,11 @@ FORK FROM DEAD libupnp
|
||||
the configuration of the installed libraries (generates installed
|
||||
file <upnp/upnpconfig.h>)
|
||||
|
||||
2006-02-22 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-02-22 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* upnp/ : add missing include of config.h in some .c files
|
||||
|
||||
2006-02-21 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-02-21 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* upnp/inc/upnp.h: move some definitions which should not be
|
||||
exported into "upnp/src/inc/util.h"
|
||||
@@ -186,12 +186,12 @@ FORK FROM DEAD libupnp
|
||||
* import all modifications below from libupnp in djmount 0.51
|
||||
into official libupnp
|
||||
|
||||
2006-01-17 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-01-17 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* threadutil/Makefile.am (libthreadutil_la_SOURCES): remove extraneous
|
||||
file
|
||||
|
||||
2006-01-15 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-01-15 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* configure.ac: add checks for large-file support
|
||||
|
||||
@@ -211,53 +211,53 @@ FORK FROM DEAD libupnp
|
||||
* ixml/src/node.c (ixmlNode_getNodeType): fix compilation warning
|
||||
on const return type
|
||||
|
||||
2006-01-12 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-01-12 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* upnp/src/inc/readwrite.h : suppress unused C++ header file
|
||||
|
||||
2006-01-11 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2006-01-11 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* upnp/inc/config.h, upnp/src/inc/upnpapi.h,
|
||||
upnp/src/inc/httpreadwrite.h: remove internal configuration variable
|
||||
MINIMUM_DELAY (no clear purpose)
|
||||
|
||||
2005-12-05 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2005-12-05 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* upnp/inc/upnp.h: re-declare obsolete method UpnpSetContentLength,
|
||||
for binary compatibility with previous libupnp version.
|
||||
|
||||
* upnp/src/api/upnpapi.c: correct type of g_maxContentLength to size_t
|
||||
|
||||
2005-11-01 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2005-11-01 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* autoconfiscate library : replace all makefiles by Makefile.am
|
||||
for automake support, + preliminary autoconf support
|
||||
(generated config.h not yet used in source files)
|
||||
|
||||
2005-10-18 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2005-10-18 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* upnp/src/makefile: fix location of DEBUG STATIC libupnp library
|
||||
|
||||
* upnp/sample/tvctrlpt/linux/Makefile,
|
||||
upnp/sample/tvdevice/linux/Makefile: fix STATIC library support
|
||||
|
||||
2005-10-16 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2005-10-16 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* threadutil/src/Makefile (clean): remove built library
|
||||
|
||||
2005-08-28 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2005-08-28 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* ixml/src/ixml.h, ixml/src/ixml.c (ixmlRelaxParser) : new function
|
||||
|
||||
* ixml/src/ixmlparser.h, ixml/src/ixmlparser.c (Parser_setErrorChar) :
|
||||
new function
|
||||
|
||||
2005-08-02 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2005-08-02 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* ixml/src/Makefile: correct bug for static library being incorrectly
|
||||
stripped when building non-debug
|
||||
|
||||
2005-06-09 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2005-06-09 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* ixml/src/element.c (ixmlElement_removeAttributeNode):
|
||||
remove some compilation warning
|
||||
@@ -268,7 +268,7 @@ FORK FROM DEAD libupnp
|
||||
* upnp/inc/upnptools.h, upnp/src/api/upnptools.c :
|
||||
add missing const's in public API
|
||||
|
||||
2005-05-28 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2005-05-28 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* upnp/inc/config.h: suppress HTTP_READ_BYTES (unused)
|
||||
and replace by DEFAULT_SOAP_CONTENT_LENGTH (previously in upnpapi.h)
|
||||
@@ -289,7 +289,7 @@ FORK FROM DEAD libupnp
|
||||
* upnp/src/genlib/net/http/httpreadwrite.c : corrected an incorrect
|
||||
sprintf format
|
||||
|
||||
2005-05-27 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2005-05-27 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* upnp/makefile, upnp/src/makefile,
|
||||
ixml/Makefile, ixml/src/Makefile,
|
||||
@@ -297,7 +297,7 @@ FORK FROM DEAD libupnp
|
||||
implement STATIC library support (from patch at
|
||||
http://sourceforge.net/tracker/?group_id=7189&atid=307189 )
|
||||
|
||||
2005-05-26 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
2005-05-26 R<>mi Turboult <r3mi(at)users.sourceforge.net>
|
||||
|
||||
* upnp/src/api/upnpapi.c, upnp/src/soap/soap_device.c,
|
||||
upnp/src/soap/makefile :
|
||||
|
||||
@@ -12,7 +12,14 @@ DISTCHECK_CONFIGURE_FLAGS = --enable-debug --enable-samples
|
||||
SUBDIRS = ixml threadutil upnp docs/dist
|
||||
|
||||
|
||||
EXTRA_DIST = libupnp.pc.in LICENSE THANKS libupnp.spec
|
||||
EXTRA_DIST = libupnp.pc.in LICENSE THANKS libupnp.spec \
|
||||
build/libupnp.bpf \
|
||||
build/libupnp.bpr \
|
||||
build/libupnp.dsp \
|
||||
build/libupnp.dsw \
|
||||
build/inc/autoconfig.h \
|
||||
build/inc/config.h \
|
||||
build/inc/upnpconfig.h
|
||||
|
||||
|
||||
# This variable must have 'exec' in its name, in order to be installed
|
||||
|
||||
71
README
71
README
@@ -1,4 +1,4 @@
|
||||
Linux* SDK for UPnP* Devices (libupnp)
|
||||
Portable SDK for UPnP* Devices (libupnp)
|
||||
|
||||
Copyright (c) 2000-2003 Intel Corporation - All Rights Reserved.
|
||||
Copyright (c) 2005-2006 R<>mi Turboult <r3mi@users.sourceforge.net>
|
||||
@@ -22,8 +22,8 @@ sections:
|
||||
1) Release Contents
|
||||
-------------------------------------------
|
||||
|
||||
The Linux SDK for UPnP Devices is an SDK for development of UPnP device
|
||||
and control point applications for Linux. It consists of the core UPnP
|
||||
The Portable SDK for UPnP Devices is an SDK for development of UPnP device
|
||||
and control point applications. It consists of the core UPnP
|
||||
protocols along with a UPnP-specific eXtensible Markup Language (XML) parser
|
||||
supporting the Document Object Model (DOM) Level 2 API and an optional,
|
||||
integrated mini web server for serving UPnP related documents.
|
||||
@@ -32,7 +32,7 @@ integrated mini web server for serving UPnP related documents.
|
||||
2) Package Contents
|
||||
-------------------------------------------
|
||||
|
||||
The Linux SDK for UPnP Devices contains the following:
|
||||
The SDK for UPnP Devices contains the following:
|
||||
|
||||
README This file. Contains the installation and build instructions.
|
||||
LICENSE The licensing terms the SDK is distributed under.
|
||||
@@ -55,11 +55,10 @@ upnp\sample A sample device and control point application, illustrating the
|
||||
3) System Requirements
|
||||
-------------------------------------------
|
||||
|
||||
The SDK for UPnP Devices is designed to compile and run under the
|
||||
Linux operating system. It does, however, have dependencies on some
|
||||
The SDK for UPnP Devices is designed to compile and run under several
|
||||
operating systems. It does, however, have dependencies on some
|
||||
packages that may not be installed by default. All packages that it
|
||||
requires are listed below. The name of the package and where it can be
|
||||
found is dependent on the distribution of Linux being used.
|
||||
requires are listed below.
|
||||
|
||||
libpthread The header and library are installed as part of the glibc-devel
|
||||
package (or equivalent).
|
||||
@@ -83,7 +82,7 @@ ps2pdf The final step to making the PDF is converting the PostStript
|
||||
into Portable Document Format. The ghostscript package provides
|
||||
this tool.
|
||||
|
||||
For the UPnP library to function correctly, Linux networking must be configured
|
||||
For the UPnP library to function correctly, networking must be configured
|
||||
properly for multicasting. To do this:
|
||||
|
||||
route add -net 239.0.0.0 netmask 255.0.0.0 eth0
|
||||
@@ -93,14 +92,6 @@ this addition, device advertisements and control point searches will not
|
||||
function.
|
||||
|
||||
|
||||
libupnp has been built and tested on the following configurations:
|
||||
|
||||
* MandrakeLinux 10.1 (kernel 2.6.8.1-12mdk, gcc 3.4.1, glibc-2.3.3)
|
||||
|
||||
* Ubuntu 5.10 "Breezy Badger" (Linux kernel 2.6.12-9-386, gcc 4.0.2 20050808
|
||||
prerelease, libc6 2.3.5-1ubuntu12)
|
||||
|
||||
|
||||
|
||||
4) Build Instructions
|
||||
-------------------------------------------
|
||||
@@ -169,7 +160,7 @@ To build without:
|
||||
% make
|
||||
|
||||
|
||||
The SDK for Linux also contains some additional helper APIs, declared in
|
||||
The SDK also contains some additional helper APIs, declared in
|
||||
inc/tools/upnptools.h. If these additional tools are not required, they can
|
||||
be compiled out:
|
||||
|
||||
@@ -249,6 +240,45 @@ sub-directory. Example :
|
||||
% ../../upnp_tv_device
|
||||
|
||||
|
||||
|
||||
SOLARIS BUILD
|
||||
|
||||
The building process for the Solaris operating system is similar to the one
|
||||
described above. Only the call to ./configure has to be done using an
|
||||
additional parameter:
|
||||
|
||||
./configure CFLAGS="-mcpu=<cputype> -mtune=<cputype> -DSPARC_SOLARIS"
|
||||
|
||||
where <cputype> has to be replaced by the appropriate CPU tuning flag (e.g.
|
||||
"supersparc"). Afterwards
|
||||
|
||||
make
|
||||
make install
|
||||
|
||||
can be called as described above.
|
||||
|
||||
|
||||
|
||||
WINDOWS BUILD
|
||||
|
||||
In order to build libupnp under Windows the pthreads-w32 package is required.
|
||||
You can download a self-extracting ZIP file from the following location:
|
||||
|
||||
ftp://sources.redhat.com/pub/pthreads-win32/pthreads-w32-2-7-0-release.exe
|
||||
|
||||
Execute the self-extracting archive and copy the Pre-build.2 folder to the
|
||||
top level source folder.
|
||||
Rename Pre-build.2 to pthreads.
|
||||
Open the provided workspace build\libupnp.dsw with Visual C++ 6.0 and select
|
||||
Build->Build libupnp.dll (F7)
|
||||
|
||||
For building a static library instead of a DLL and for using the static
|
||||
pthreads-w32 library following switches need to be defined additionally:
|
||||
|
||||
UPNP_STATIC_LIB - for creating a statically linkable UPnP-library
|
||||
PTW32_STATIC_LIB - for using the static pthreads32 library
|
||||
|
||||
|
||||
5) Install/Uninstall Instructions
|
||||
-------------------------------------------
|
||||
|
||||
@@ -290,9 +320,8 @@ See NEWS file.
|
||||
8) Support and Contact Information
|
||||
-------------------------------------------
|
||||
|
||||
Intel is not providing support for the Linux SDK for UPnP Devices. Two
|
||||
mailing lists for the SDK are available on http://upnp.sourceforge.net/.
|
||||
Questions and problems should be addressed on the appropriate mailing list.
|
||||
Intel is not providing support for the SDK for UPnP Devices. Mailing lists
|
||||
and discussion boards can be found at http://www.libupnp.org/.
|
||||
|
||||
If you find this SDK useful, please send an email to upnp@intel.com and let
|
||||
us know.
|
||||
|
||||
2
THANKS
2
THANKS
@@ -6,6 +6,8 @@ suggesting various improvements or submitting actual code.
|
||||
Here is a list of these people. Help us keep it complete and
|
||||
exempt of errors.
|
||||
|
||||
- Erwan Velu
|
||||
- Paul Vixie
|
||||
- Arno Willig
|
||||
- Eric Tanguy
|
||||
- Oskar Liljeblad
|
||||
|
||||
@@ -43,7 +43,7 @@ RSC=rc.exe
|
||||
# PROP Ignore_Export_Lib 0
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LIBUPNP_EXPORTS" /YX /FD /c
|
||||
# ADD CPP /nologo /MT /W3 /GX /O2 /I "E:\svnupnp\trunk\ixml\src\inc" /I "E:\svnupnp\trunk\ixml\inc" /I "E:\svnupnp\trunk\threadutil\inc" /I "E:\svnupnp\trunk\upnp\inc" /I "E:\svnupnp\trunk\upnp\src\inc" /I "E:\svnupnp\trunk\build\inc" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LIBUPNP_EXPORTS" /FR /YX /FD /c
|
||||
# ADD CPP /nologo /MT /W3 /GX /O2 /I "..\pthreads\include" /I "..\ixml\src\inc" /I "..\ixml\inc" /I "..\threadutil\inc" /I "..\upnp\inc" /I "..\upnp\src\inc" /I ".\inc" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LIBUPNP_EXPORTS" /FR /YX /FD /c
|
||||
# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
|
||||
# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
|
||||
# ADD BASE RSC /l 0x407 /d "NDEBUG"
|
||||
@@ -53,7 +53,7 @@ BSC32=bscmake.exe
|
||||
# ADD BSC32 /nologo
|
||||
LINK32=link.exe
|
||||
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
|
||||
# ADD LINK32 kernel32.lib user32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib E:\svnupnp\trunk\libupnp\build\bin\pthreadvc2.lib ws2_32.lib /nologo /dll /machine:I386
|
||||
# ADD LINK32 kernel32.lib user32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ..\pthreads\lib\pthreadvc2.lib ws2_32.lib /nologo /dll /machine:I386
|
||||
|
||||
!ELSEIF "$(CFG)" == "libupnp - Win32 Debug"
|
||||
|
||||
@@ -69,7 +69,7 @@ LINK32=link.exe
|
||||
# PROP Ignore_Export_Lib 0
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LIBUPNP_EXPORTS" /YX /FD /GZ /c
|
||||
# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "E:\svnupnp\trunk\ixml\src\inc" /I "E:\svnupnp\trunk\ixml\inc" /I "E:\svnupnp\trunk\threadutil\inc" /I "E:\svnupnp\trunk\upnp\inc" /I "E:\svnupnp\trunk\upnp\src\inc" /I "E:\svnupnp\trunk\build\inc" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LIBUPNP_EXPORTS" /FR /YX /FD /GZ /c
|
||||
# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "..\pthreads\include" /I "..\ixml\src\inc" /I "..\ixml\inc" /I "..\threadutil\inc" /I "..\upnp\inc" /I "..\upnp\src\inc" /I "..\build\inc" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LIBUPNP_EXPORTS" /FR /YX /FD /GZ /c
|
||||
# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
|
||||
# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
|
||||
# ADD BASE RSC /l 0x407 /d "_DEBUG"
|
||||
@@ -79,7 +79,7 @@ BSC32=bscmake.exe
|
||||
# ADD BSC32 /nologo
|
||||
LINK32=link.exe
|
||||
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
|
||||
# ADD LINK32 kernel32.lib user32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib E:\svnupnp\trunk\libupnp\build\bin\pthreadvc2.lib ws2_32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
|
||||
# ADD LINK32 kernel32.lib user32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ..\pthreads\lib\pthreadvc2.lib ws2_32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
|
||||
|
||||
!ENDIF
|
||||
|
||||
|
||||
@@ -38,11 +38,15 @@
|
||||
#include <assert.h>
|
||||
|
||||
#ifdef WIN32
|
||||
#ifdef LIBUPNP_EXPORTS
|
||||
// set up declspec for dll export to make functions visible to library users
|
||||
#define EXPORT_SPEC __declspec(dllexport)
|
||||
#ifndef UPNP_STATIC_LIB
|
||||
#ifdef LIBUPNP_EXPORTS
|
||||
// set up declspec for dll export to make functions visible to library users
|
||||
#define EXPORT_SPEC __declspec(dllexport)
|
||||
#else
|
||||
#define EXPORT_SPEC __declspec(dllimport)
|
||||
#endif
|
||||
#else
|
||||
#define EXPORT_SPEC __declspec(dllimport)
|
||||
#define EXPORT_SPEC
|
||||
#endif
|
||||
#else
|
||||
#define EXPORT_SPEC
|
||||
|
||||
@@ -527,11 +527,15 @@ extern "C" {
|
||||
#define imillisleep(x) usleep(1000*x)
|
||||
|
||||
#ifdef WIN32
|
||||
#ifdef LIBUPNP_EXPORTS
|
||||
// set up declspec for dll export to make functions visible to library users
|
||||
#define EXPORT_SPEC __declspec(dllexport)
|
||||
#ifndef UPNP_STATIC_LIB
|
||||
#ifdef LIBUPNP_EXPORTS
|
||||
// set up declspec for dll export to make functions visible to library users
|
||||
#define EXPORT_SPEC __declspec(dllexport)
|
||||
#else
|
||||
#define EXPORT_SPEC __declspec(dllimport)
|
||||
#endif
|
||||
#else
|
||||
#define EXPORT_SPEC __declspec(dllimport)
|
||||
#define EXPORT_SPEC
|
||||
#endif
|
||||
#else
|
||||
#define EXPORT_SPEC
|
||||
|
||||
@@ -289,7 +289,8 @@ SetRelTimeout( struct timespec *time,
|
||||
* Parameters:
|
||||
* ThreadPoolStats *stats must be valid non null stats structure
|
||||
*****************************************************************************/
|
||||
STATSONLY( static void StatsInit( ThreadPoolStats * stats ) {
|
||||
#ifdef STATS
|
||||
static void StatsInit( ThreadPoolStats * stats ) {
|
||||
assert( stats != NULL ); stats->totalIdleTime = 0; stats->totalJobsHQ = 0; stats->totalJobsLQ = 0; stats->totalJobsMQ = 0; stats->totalTimeHQ = 0; stats->totalTimeMQ = 0; stats->totalTimeLQ = 0; stats->totalWorkTime = 0; stats->totalIdleTime = 0; stats->avgWaitHQ = 0; //average wait in HQ
|
||||
stats->avgWaitMQ = 0; //average wait in MQ
|
||||
stats->avgWaitLQ = 0;
|
||||
@@ -297,7 +298,7 @@ STATSONLY( static void StatsInit( ThreadPoolStats * stats ) {
|
||||
stats->idleThreads = 0;
|
||||
stats->persistentThreads = 0;
|
||||
stats->maxThreads = 0; stats->totalThreads = 0;}
|
||||
)
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
* Function: CalcWaitTime
|
||||
@@ -313,7 +314,8 @@ STATSONLY( static void StatsInit( ThreadPoolStats * stats ) {
|
||||
* ThreadPriority p
|
||||
* ThreadPoolJob *job
|
||||
*****************************************************************************/
|
||||
STATSONLY( static void CalcWaitTime( ThreadPool * tp,
|
||||
#ifdef STATS
|
||||
static void CalcWaitTime( ThreadPool * tp,
|
||||
ThreadPriority p,
|
||||
ThreadPoolJob * job ) {
|
||||
struct timeb now;
|
||||
@@ -329,7 +331,7 @@ tp->stats.totalJobsLQ++; tp->stats.totalTimeLQ += diff; break; default:
|
||||
assert( 0 );}
|
||||
}
|
||||
|
||||
)
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
* Function: SetSeed
|
||||
@@ -380,6 +382,12 @@ tp->stats.totalJobsLQ++; tp->stats.totalTimeLQ += diff; break; default:
|
||||
int retCode = 0;
|
||||
int persistent = -1;
|
||||
ThreadPool *tp = ( ThreadPool * ) arg;
|
||||
//leuk_he allow static linking
|
||||
#ifdef WIN32
|
||||
#ifdef PTW32_STATIC_LIB
|
||||
pthread_win32_thread_attach_np();
|
||||
#endif
|
||||
#endif
|
||||
|
||||
assert( tp != NULL );
|
||||
|
||||
@@ -447,7 +455,12 @@ tp->stats.totalJobsLQ++; tp->stats.totalTimeLQ += diff; break; default:
|
||||
tp->totalThreads--;
|
||||
ithread_cond_broadcast( &tp->start_and_shutdown );
|
||||
ithread_mutex_unlock( &tp->mutex );
|
||||
|
||||
//leuk_he
|
||||
#ifdef WIN32
|
||||
#ifdef PTW32_STATIC_LIB
|
||||
pthread_win32_thread_detach_np ();
|
||||
#endif
|
||||
#endif
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@@ -476,6 +489,12 @@ tp->stats.totalJobsLQ++; tp->stats.totalTimeLQ += diff; break; default:
|
||||
ithread_cond_broadcast( &tp->start_and_shutdown );
|
||||
|
||||
ithread_mutex_unlock( &tp->mutex );
|
||||
//leuk_he
|
||||
#ifdef WIN32
|
||||
#ifdef PTW32_STATIC_LIB
|
||||
pthread_win32_thread_detach_np ();
|
||||
#endif
|
||||
#endif
|
||||
|
||||
return NULL;
|
||||
} else {
|
||||
@@ -703,6 +722,12 @@ tp->stats.totalJobsLQ++; tp->stats.totalTimeLQ += diff; break; default:
|
||||
if( tp == NULL ) {
|
||||
return EINVAL;
|
||||
}
|
||||
//leuk_he
|
||||
#ifdef WIN32
|
||||
#ifdef PTW32_STATIC_LIB
|
||||
pthread_win32_process_attach_np();
|
||||
#endif
|
||||
#endif
|
||||
|
||||
retCode += ithread_mutex_init( &tp->mutex, NULL );
|
||||
assert( retCode == 0 );
|
||||
@@ -1461,7 +1486,8 @@ tp->stats.totalJobsLQ++; tp->stats.totalTimeLQ += diff; break; default:
|
||||
return 0;
|
||||
}
|
||||
|
||||
STATSONLY( void ThreadPoolPrintStats( ThreadPoolStats * stats ) {
|
||||
#ifdef STATS
|
||||
void ThreadPoolPrintStats( ThreadPoolStats * stats ) {
|
||||
assert( stats != NULL ); if( stats == NULL ) {
|
||||
return;}
|
||||
|
||||
@@ -1471,13 +1497,13 @@ tp->stats.totalJobsLQ++; tp->stats.totalTimeLQ += diff; break; default:
|
||||
printf( "ThreadPoolStats at Time: %ld\n", time( NULL ) );
|
||||
#endif
|
||||
printf
|
||||
( "Average Wait in High Priority Q in milliseconds: %lf\n",
|
||||
( "Average Wait in High Priority Q in milliseconds: %f\n",
|
||||
stats->avgWaitHQ );
|
||||
printf
|
||||
( "Average Wait in Med Priority Q in milliseconds: %lf\n",
|
||||
( "Average Wait in Med Priority Q in milliseconds: %f\n",
|
||||
stats->avgWaitMQ );
|
||||
printf
|
||||
( "Averate Wait in Low Priority Q in milliseconds: %lf\n",
|
||||
( "Averate Wait in Low Priority Q in milliseconds: %f\n",
|
||||
stats->avgWaitLQ );
|
||||
printf( "Max Threads Active: %d\n", stats->maxThreads );
|
||||
printf( "Current Worker Threads: %d\n",
|
||||
@@ -1486,11 +1512,11 @@ tp->stats.totalJobsLQ++; tp->stats.totalTimeLQ += diff; break; default:
|
||||
stats->persistentThreads );
|
||||
printf( "Current Idle Threads: %d\n", stats->idleThreads );
|
||||
printf( "Total Threads : %d\n", stats->totalThreads );
|
||||
printf( "Total Time spent Working in seconds: %lf\n",
|
||||
printf( "Total Time spent Working in seconds: %f\n",
|
||||
stats->totalWorkTime );
|
||||
printf( "Total Time spent Idle in seconds : %lf\n",
|
||||
printf( "Total Time spent Idle in seconds : %f\n",
|
||||
stats->totalIdleTime );}
|
||||
)
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
* Function: ThreadPoolGetStats
|
||||
@@ -1505,7 +1531,8 @@ tp->stats.totalJobsLQ++; tp->stats.totalTimeLQ += diff; break; default:
|
||||
* Returns:
|
||||
* Always returns 0.
|
||||
*****************************************************************************/
|
||||
STATSONLY( int
|
||||
#ifdef STATS
|
||||
int
|
||||
ThreadPoolGetStats( ThreadPool * tp,
|
||||
ThreadPoolStats * stats ) {
|
||||
|
||||
@@ -1542,4 +1569,4 @@ tp->stats.totalJobsLQ++; tp->stats.totalTimeLQ += diff; break; default:
|
||||
|
||||
return 0;}
|
||||
|
||||
)
|
||||
#endif
|
||||
|
||||
@@ -150,7 +150,10 @@ EXTRA_DIST = LICENSE \
|
||||
sample/tvdevice/web/tvcontrolSCPD.xml \
|
||||
sample/tvdevice/web/tvdevicedesc.xml \
|
||||
sample/tvdevice/web/tvdevicepres.html \
|
||||
sample/tvdevice/web/tvpictureSCPD.xml
|
||||
sample/tvdevice/web/tvpictureSCPD.xml \
|
||||
src/inc/inet_pton.h \
|
||||
src/inet_pton.c \
|
||||
src/win_dll.c
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -47,11 +47,15 @@
|
||||
#endif
|
||||
|
||||
#ifdef WIN32
|
||||
#ifdef LIBUPNP_EXPORTS
|
||||
// set up declspec for dll export to make functions visible to library users
|
||||
#define EXPORT_SPEC __declspec(dllexport)
|
||||
#ifndef UPNP_STATIC_LIB
|
||||
#ifdef LIBUPNP_EXPORTS
|
||||
// set up declspec for dll export to make functions visible to library users
|
||||
#define EXPORT_SPEC __declspec(dllexport)
|
||||
#else
|
||||
#define EXPORT_SPEC __declspec(dllimport)
|
||||
#endif
|
||||
#else
|
||||
#define EXPORT_SPEC __declspec(dllimport)
|
||||
#define EXPORT_SPEC
|
||||
#endif
|
||||
#else
|
||||
#define EXPORT_SPEC
|
||||
|
||||
@@ -415,6 +415,13 @@ UpnpFinish( )
|
||||
|
||||
// remove all virtual dirs
|
||||
UpnpRemoveAllVirtualDirs( );
|
||||
//leuk_he allow static linking:
|
||||
#ifdef WIN32
|
||||
#ifdef PTW32_STATIC_LIB
|
||||
pthread_win32_thread_detach_np ();
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
UpnpSdkInit = 0;
|
||||
|
||||
|
||||
@@ -348,14 +348,9 @@ UpnpMakeAction( const char *ActionName,
|
||||
va_list ArgList;
|
||||
IXML_Document *out = NULL;
|
||||
|
||||
if( NumArg > 0 ) {
|
||||
va_start( ArgList, Arg );
|
||||
}
|
||||
|
||||
va_start( ArgList, Arg );
|
||||
out = makeAction( 0, ActionName, ServType, NumArg, Arg, ArgList );
|
||||
if( NumArg > 0 ) {
|
||||
va_end( ArgList );
|
||||
}
|
||||
va_end( ArgList );
|
||||
|
||||
return out;
|
||||
}
|
||||
@@ -390,14 +385,9 @@ UpnpMakeActionResponse( const char *ActionName,
|
||||
va_list ArgList;
|
||||
IXML_Document *out = NULL;
|
||||
|
||||
if( NumArg > 0 ) {
|
||||
va_start( ArgList, Arg );
|
||||
}
|
||||
|
||||
va_start( ArgList, Arg );
|
||||
out = makeAction( 1, ActionName, ServType, NumArg, Arg, ArgList );
|
||||
if( NumArg > 0 ) {
|
||||
va_end( ArgList );
|
||||
}
|
||||
va_end( ArgList );
|
||||
|
||||
return out;
|
||||
}
|
||||
|
||||
@@ -41,6 +41,7 @@
|
||||
#include "statcodes.h"
|
||||
#include "httpparser.h"
|
||||
#include "httpreadwrite.h"
|
||||
#include "ssdplib.h"
|
||||
|
||||
#include "unixutil.h"
|
||||
|
||||
@@ -755,8 +756,8 @@ genaInitNotifyExt( IN UpnpDevice_Handle device_handle,
|
||||
}
|
||||
|
||||
sprintf( headers, "CONTENT-TYPE: text/xml\r\nCONTENT-LENGTH: "
|
||||
"%d\r\nNT: upnp:event\r\nNTS: upnp:propchange\r\n",
|
||||
strlen( propertySet ) + 1 );
|
||||
"%ld\r\nNT: upnp:event\r\nNTS: upnp:propchange\r\n",
|
||||
(long) strlen( propertySet ) + 1 );
|
||||
|
||||
//schedule thread for initial notification
|
||||
|
||||
@@ -892,8 +893,8 @@ genaNotifyAllExt( IN UpnpDevice_Handle device_handle,
|
||||
//changed to add null terminator at end of content
|
||||
//content length = (length in bytes of property set) + null char
|
||||
sprintf( headers, "CONTENT-TYPE: text/xml\r\nCONTENT-LENGTH: "
|
||||
"%d\r\nNT: upnp:event\r\nNTS: upnp:propchange\r\n",
|
||||
strlen( propertySet ) + 1 );
|
||||
"%ld\r\nNT: upnp:event\r\nNTS: upnp:propchange\r\n",
|
||||
(long) strlen( propertySet ) + 1 );
|
||||
|
||||
HandleLock( );
|
||||
|
||||
@@ -1053,9 +1054,9 @@ genaNotifyAll( IN UpnpDevice_Handle device_handle,
|
||||
}
|
||||
//changed to add null terminator at end of content
|
||||
//content length = (length in bytes of property set) + null char
|
||||
sprintf( headers, "CONTENT-TYPE: text/xml\r\nCONTENT-LENGTH: %d\r\nNT:"
|
||||
sprintf( headers, "CONTENT-TYPE: text/xml\r\nCONTENT-LENGTH: %ld\r\nNT:"
|
||||
" upnp:event\r\nNTS: upnp:propchange\r\n",
|
||||
strlen( propertySet ) + 1 );
|
||||
(long) strlen( propertySet ) + 1 );
|
||||
|
||||
HandleLock( );
|
||||
|
||||
@@ -1166,7 +1167,7 @@ respond_ok( IN SOCKINFO * info,
|
||||
response.size_inc = 30;
|
||||
if( http_MakeMessage( &response, major, minor,
|
||||
"R" "D" "S" "N" "Xc" "ssc" "sc" "c",
|
||||
HTTP_OK, 0,
|
||||
HTTP_OK, 0, X_USER_AGENT,
|
||||
"SID: ", sub->sid, timeout_str ) != 0 ) {
|
||||
membuffer_destroy( &response );
|
||||
error_respond( info, HTTP_INTERNAL_SERVER_ERROR, request );
|
||||
|
||||
@@ -868,11 +868,11 @@ match_int( INOUT scanner_t * scanner,
|
||||
OUT int *value )
|
||||
{
|
||||
memptr token;
|
||||
token_type_t tok_type;
|
||||
token_type_t tok_type;
|
||||
parse_status_t status;
|
||||
int num;
|
||||
char *end_ptr;
|
||||
size_t save_pos;
|
||||
long num;
|
||||
char *end_ptr;
|
||||
size_t save_pos;
|
||||
|
||||
save_pos = scanner->cursor;
|
||||
|
||||
@@ -2391,7 +2391,7 @@ int
|
||||
raw_to_int( IN memptr * raw_value,
|
||||
IN int base )
|
||||
{
|
||||
int num;
|
||||
long num;
|
||||
char *end_ptr;
|
||||
|
||||
if( raw_value->length == 0 ) {
|
||||
|
||||
@@ -53,6 +53,10 @@
|
||||
#endif
|
||||
#include "unixutil.h"
|
||||
|
||||
#ifndef MSG_NOSIGNAL
|
||||
#define MSG_NOSIGNAL 0
|
||||
#endif
|
||||
|
||||
/************************************************************************
|
||||
* Function : sock_init
|
||||
*
|
||||
@@ -229,7 +233,7 @@ sock_read_write( IN SOCKINFO * info,
|
||||
|
||||
if( bRead ) {
|
||||
// read data
|
||||
numBytes = recv( sockfd, buffer, bufsize,0); // MSG_NOSIGNAL is not a good idea in portable code, here SIGPIPE/SIGEPIPE has to be used instead
|
||||
numBytes = recv( sockfd, buffer, bufsize,MSG_NOSIGNAL);
|
||||
} else {
|
||||
byte_left = bufsize;
|
||||
bytes_sent = 0;
|
||||
@@ -237,7 +241,7 @@ sock_read_write( IN SOCKINFO * info,
|
||||
// write data
|
||||
num_written =
|
||||
send( sockfd, buffer + bytes_sent, byte_left,
|
||||
MSG_DONTROUTE); // | MSG_NOSIGNAL is not a good idea in portable code, here SIGPIPE/SIGEPIPE has to be used instead
|
||||
MSG_DONTROUTE|MSG_NOSIGNAL);
|
||||
if( num_written == -1 ) {
|
||||
return num_written;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user