[hxplay] CR: player/hxclientkit

[hxplay] CR: player/hxclientkit

Scott Hancher sehancher at real.com
Wed Oct 29 13:59:38 PST 2003


Trying to get rid of all STL dependencies by today.

On Wednesday, October 29, 2003, at 12:36 PM, nhart at real.com wrote:

> What are your plans for STL, then?
>
>> I don't mind you moving the #include, but does it have to be Solaris
>> specific? Why can't it just be moved on all platforms, so the  
>> unsightly
>> #ifdef's are removed?
>>
>> By the way. I hope to cut this dependency on STL entirely by later
>> today anyway.
>> ++Scott.
>>
>> On Wednesday, October 29, 2003, at 11:24 AM, nhart at real.com wrote:
>>
>>> The problem is that there are some cpp files that include a header
>>> that includes <vector> after InterlockedIncrement/Decrement have
>>> already  been
>>> redefined in such a way as to break Solaris.  If you're curious, the
>>> actual problem is that a solaris header contains a declaration like
>>> this:
>>>
>>> long InterlockedIncrement(long*);
>>>
>>> Which then turns into:
>>>
>>> long _HXAtomicAddRetUINT32(((UINT32*)(long*)), (UINT32)1);
>>>
>>> Which is of course an illegal declaration.
>>>
>>> If I move the <vector> include to the top of the header files that
>>> include
>>> them, there are still some cpp files that include other helix headers
>>> before getting to the hxclientkit headers that include <vector>.   
>>> This
>>>  is
>>> an ugly problem and I wish it had a pretty solution.  I fear that
>>> we're going to see future solaris build busters when someone
>>> inadvertently changes the order of some includes.  Putting the extra
>>> <vector>  include at
>>> the top of the cpp files will hopefully forestall some of these
>>> problems.
>>>
>>>
>>>> hlxclib/... includes - Fine.
>>>>
>>>> Are you essentially including <vector> twice on _SOLARIS? I realize
>>>> this won't actually happen due to built in #ifdef tests. Couldn't  
>>>> you
>>>> just move the include on all platforms and avoid the messy #ifdef
>>>> platform test? Also, the only classes that use <vector> currently  
>>>> are
>>>> the CHXClientSiteSupplier and CHXStatisticTracker. Why are you
>>>> including it in CHXClientPlayer and CHXClientSite?
>>>>
>>>> ++Scott.
>>>>
>>>> On Tuesday, October 28, 2003, at 03:47 PM, Nicholas Hart wrote:
>>>>
>>>>>
>>>>> This fixes a bunch of solaris build busters.  Note, there were
>>>>> several
>>>>> places where I had to include "hlxclib/string.h" to get some string
>>>>> functions.  There was one place where I commented out a
>>>>> windows-specific
>>>>> macro that redefined strcasecmp as strcmp, as this sort of thing is
>>>>> handled by hlxclib/string.h.  Also, one place I altered an include
>>>>> of <stdlib.h> to "hlxclib/stdlib.h" because this is just good
>>>>> practice for building cross-platform helix code (since these  
>>>>> headers
>>>>> hide all the ugly macros we typically need to implement on a
>>>>> per-platform basis.)
>>>>>
>>>>> Index: src/CHXClientContext.cpp
>>>>> ===================================================================
>>>>> RCS file: /cvs/player/hxclientkit/src/CHXClientContext.cpp,v
>>>>> retrieving revision 1.7
>>>>> diff -u -b -r1.7 CHXClientContext.cpp
>>>>> --- src/CHXClientContext.cpp	23 Oct 2003 01:52:51 -0000	1.7
>>>>> +++ src/CHXClientContext.cpp	28 Oct 2003 23:45:39 -0000
>>>>> @@ -50,9 +50,7 @@
>>>>>  #define SERVER_HEADER "_server"
>>>>>  #define REALM_HEADER  "realm"
>>>>>
>>>>> -#ifdef _WINDOWS
>>>>> -#define strcasecmp _stricmp
>>>>> -#endif
>>>>> +#include "hlxclib/string.h"
>>>>>
>>>>>  CHXClientContext::~CHXClientContext( void )
>>>>>  {
>>>>> Index: src/CHXClientEngineContext.cpp
>>>>> ===================================================================
>>>>> RCS file: /cvs/player/hxclientkit/src/CHXClientEngineContext.cpp,v
>>>>> retrieving revision 1.5
>>>>> diff -u -b -r1.5 CHXClientEngineContext.cpp
>>>>> --- src/CHXClientEngineContext.cpp	3 Oct 2003 00:09:42 -0000	1.5  
>>>>> +++
>>>>> src/CHXClientEngineContext.cpp	28 Oct 2003 23:45:39 -0000
>>>>> @@ -38,6 +38,7 @@
>>>>>
>>>>>  #include "enter_hx_headers.h"
>>>>>  #include "ihxpckts.h"
>>>>> +#include "hlxclib/string.h"
>>>>>
>>>>>  #include "hxsmartptr.h"
>>>>>  HX_SMART_POINTER_INLINE( SPIHXBuffer, IHXBuffer );
>>>>> Index: src/CHXClientPlayer.cpp
>>>>> ===================================================================
>>>>> RCS file: /cvs/player/hxclientkit/src/CHXClientPlayer.cpp,v
>>>>> retrieving revision 1.9
>>>>> diff -u -b -r1.9 CHXClientPlayer.cpp
>>>>> --- src/CHXClientPlayer.cpp	22 Oct 2003 20:19:58 -0000	1.9
>>>>> +++ src/CHXClientPlayer.cpp	28 Oct 2003 23:45:39 -0000
>>>>> @@ -33,6 +33,12 @@
>>>>>   *
>>>>>   * ***** END LICENSE BLOCK ***** */
>>>>>
>>>>> +#if defined(_SOLARIS)
>>>>> +// XXXNH: include this before helix includes, as it results in
>>>>> conflicting
>>>>> +// definitions for InterlockedIncrement/Decrement
>>>>> +#include <vector>
>>>>> +#endif
>>>>> +
>>>>>  #include "CHXClientPlayer.h"
>>>>>  #include "CHXClientSink.h"
>>>>>  #include "CHXClientContext.h"
>>>>> Index: src/CHXClientRequest.cpp
>>>>> ===================================================================
>>>>> RCS file: /cvs/player/hxclientkit/src/CHXClientRequest.cpp,v
>>>>> retrieving revision 1.1
>>>>> diff -u -b -r1.1 CHXClientRequest.cpp
>>>>> --- src/CHXClientRequest.cpp	18 Sep 2003 01:33:00 -0000	1.1
>>>>> +++ src/CHXClientRequest.cpp	28 Oct 2003 23:45:39 -0000
>>>>> @@ -39,7 +39,8 @@
>>>>>  #include "ihxpckts.h" // IHXValues
>>>>>  #include "exit_hx_headers.h"
>>>>>
>>>>> -#include <stdlib.h>
>>>>> +#include "hlxclib/string.h"
>>>>> +#include "hlxclib/stdlib.h"
>>>>>
>>>>>  CHXClientRequest::CHXClientRequest( void )
>>>>>  	: m_lCount( 0 )
>>>>> Index: src/CHXClientSite.cpp
>>>>> ===================================================================
>>>>> RCS file: /cvs/player/hxclientkit/src/CHXClientSite.cpp,v
>>>>> retrieving revision 1.4
>>>>> diff -u -b -r1.4 CHXClientSite.cpp
>>>>> --- src/CHXClientSite.cpp	10 Oct 2003 20:21:15 -0000	1.4
>>>>> +++ src/CHXClientSite.cpp	28 Oct 2003 23:45:39 -0000
>>>>> @@ -33,6 +33,12 @@
>>>>>   *
>>>>>   * ***** END LICENSE BLOCK ***** */
>>>>>
>>>>> +#if defined(_SOLARIS)
>>>>> +// XXXNH: include this before helix includes, as it results in
>>>>> conflicting
>>>>> +// definitions for InterlockedIncrement/Decrement
>>>>> +#include <vector>
>>>>> +#endif
>>>>> +
>>>>>  #include "CHXClientSite.h"
>>>>>
>>>>>  #include "enter_hx_headers.h"
>>>>> Index: src/CHXClientSiteSupplier.cpp
>>>>> ===================================================================
>>>>> RCS file: /cvs/player/hxclientkit/src/CHXClientSiteSupplier.cpp,v
>>>>> retrieving revision 1.3
>>>>> diff -u -b -r1.3 CHXClientSiteSupplier.cpp
>>>>> --- src/CHXClientSiteSupplier.cpp	10 Oct 2003 20:21:15 -0000	1.3  
>>>>> +++
>>>>> src/CHXClientSiteSupplier.cpp	28 Oct 2003 23:45:39 -0000
>>>>> @@ -33,6 +33,12 @@
>>>>>   *
>>>>>   * ***** END LICENSE BLOCK ***** */
>>>>>
>>>>> +#if defined(_SOLARIS)
>>>>> +// XXXNH: include this before helix includes, as it results in
>>>>> conflicting
>>>>> +// definitions for InterlockedIncrement/Decrement
>>>>> +#include <vector>
>>>>> +#endif
>>>>> +
>>>>>  #include "CHXClientSiteSupplier.h"
>>>>>  #include "CHXClientSite.h"
>>>>>  #include <assert.h>
>>>>> Index: src/CHXMimeTypeHeader.cpp
>>>>> ===================================================================
>>>>> RCS file: /cvs/player/hxclientkit/src/CHXMimeTypeHeader.cpp,v
>>>>> retrieving revision 1.1
>>>>> diff -u -b -r1.1 CHXMimeTypeHeader.cpp
>>>>> --- src/CHXMimeTypeHeader.cpp	18 Sep 2003 01:33:00 -0000	1.1
>>>>> +++ src/CHXMimeTypeHeader.cpp	28 Oct 2003 23:45:39 -0000
>>>>> @@ -35,6 +35,7 @@
>>>>>
>>>>>  #include "CHXMimeTypeHeader.h"
>>>>>  #include "CHXClientBuffer.h"
>>>>> +#include "hlxclib/string.h"
>>>>>
>>>>>  const char* const CHXMimeTypeHeader::kMimeTypePropertyName =
>>>>> "Content-Type";
>>>>>
>>>>> Index: src/CHXStatisticTracker.cpp
>>>>> ===================================================================
>>>>> RCS file: /cvs/player/hxclientkit/src/CHXStatisticTracker.cpp,v
>>>>> retrieving revision 1.3
>>>>> diff -u -b -r1.3 CHXStatisticTracker.cpp
>>>>> --- src/CHXStatisticTracker.cpp	25 Sep 2003 01:03:12 -0000	1.3 +++
>>>>> src/CHXStatisticTracker.cpp	28 Oct 2003 23:45:39 -0000
>>>>> @@ -33,6 +33,12 @@
>>>>>   *
>>>>>   * ***** END LICENSE BLOCK ***** */
>>>>>
>>>>> +#if defined(_SOLARIS)
>>>>> +// XXXNH: include this before helix includes, as it results in
>>>>> conflicting
>>>>> +// definitions for InterlockedIncrement/Decrement
>>>>> +#include <vector>
>>>>> +#endif
>>>>> +
>>>>>  #include "CHXStatisticTracker.h"
>>>>>  #include "HXClientConstants.h"
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Nicholas Hart
>>>>> nhart at real.com
>>>>> Technical Lead, Helix Player
>>>>> https://player.helixcommunity.org
>>>>>
>>>>>
>>>>> ------------------------------------------------------------------- 
>>>>> --
>>>>> To unsubscribe, e-mail: dev-unsubscribe at player.helixcommunity.org
>>>>> For additional commands, e-mail: dev-help at player.helixcommunity.org
>>>
>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: dev-unsubscribe at player.helixcommunity.org For
>>> additional commands, e-mail: dev-help at player.helixcommunity.org
>>>
>>>
>>
>>
>> ---------------------------------------------------------------------  
>> To
>> unsubscribe, e-mail: dev-unsubscribe at player.helixcommunity.org
>> For additional commands, e-mail: dev-help at player.helixcommunity.org
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe at player.helixcommunity.org
> For additional commands, e-mail: dev-help at player.helixcommunity.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe at player.helixcommunity.org
For additional commands, e-mail: dev-help at player.helixcommunity.org




More information about the Player-dev mailing list
 

Site Map   |   Terms of Use   |   Privacy Policy   |   Contact Us

Copyright © 1995-2007 RealNetworks, Inc. All rights reserved. RealNetworks and Helix are trademarks of RealNetworks.
All other trademarks or registered trademarks are the property of their respective holders.