From: Danny S. <dan...@cl...> - 2005-10-30 02:17:00
|
This recent commit: by Chris S =================================================================== RCS file: /cvs/src/src/winsup/w32api/include/objbase.h,v retrieving revision 1.14 retrieving revision 1.15 diff -u -r1.14 -r1.15 --- src/winsup/w32api/include/objbase.h 2005/09/08 13:52:48 1.14 +++ src/winsup/w32api/include/objbase.h 2005/10/30 00:07:58 1.15 @@ -4,7 +4,7 @@ #include <rpcndr.h> #ifndef _OBJBASE_H -#define _OBJBASE_H_ +#define _OBJBASE_H #if __GNUC__ >=3 #pragma GCC system_header #endif gets us back to the objbase.h header guard before this 2004-04-24 Luke Dunstan <in...@us...> * include/objbase.h (_OBJBASE_H_): Define. which was followed by this incorrect reversion of the above 2005-09-08 Dimitri Papadopoulos <pap...@us...> * include/objbase.h: Avoid double header guard. Luke, What was reason for your patch to add _OBJBASE_H_? Is that reason still valid? Danny |
From: Luke D. <cod...@ho...> - 2005-10-30 06:52:49
|
----- Original Message ----- From: "Danny Smith" <dan...@cl...> To: "mingw-dvlpr" <min...@li...> Sent: Sunday, October 30, 2005 10:11 AM Subject: [MinGW-dvlpr] OBJBASE_H_? > This recent commit: by Chris S > =================================================================== > RCS file: /cvs/src/src/winsup/w32api/include/objbase.h,v > retrieving revision 1.14 > retrieving revision 1.15 > diff -u -r1.14 -r1.15 > --- src/winsup/w32api/include/objbase.h 2005/09/08 13:52:48 1.14 > +++ src/winsup/w32api/include/objbase.h 2005/10/30 00:07:58 1.15 > @@ -4,7 +4,7 @@ > #include <rpcndr.h> > > #ifndef _OBJBASE_H > -#define _OBJBASE_H_ > +#define _OBJBASE_H > #if __GNUC__ >=3 > #pragma GCC system_header > #endif > > gets us back to the objbase.h header guard before this > 2004-04-24 Luke Dunstan <in...@us...> > * include/objbase.h (_OBJBASE_H_): Define. > > which was followed by this incorrect reversion of the above > 2005-09-08 Dimitri Papadopoulos <pap...@us...> > * include/objbase.h: Avoid double header guard. > > > Luke, > What was reason for your patch to add _OBJBASE_H_? Is that reason still > valid? > > Danny I believe it was necessary to compile a C++ library that was part of the DirectX 9 SDK. I would prefer to revert back to before both of the above patches, unless there is a specific reason not to #define _OBJBASE_H_ Luke |
From: Chris S. <iro...@wa...> - 2005-10-30 02:34:53
|
Hey, > gets us back to the objbase.h header guard before this > 2004-04-24 Luke Dunstan <in...@us...> > * include/objbase.h (_OBJBASE_H_): Define. > > which was followed by this incorrect reversion of the above > 2005-09-08 Dimitri Papadopoulos <pap...@us...> > * include/objbase.h: Avoid double header guard. Since the removal of the proper #define caused compilation failures, I figured it was just a matter of correcting what appeared to be the incorrect #define. If, for some reason, it's better to use _OBJBASE_H_, I have no problem with it, as long as the #ifndef is also changed to suit. > What was reason for your patch to add _OBJBASE_H_? Is that reason still > valid? Let me know... I uploaded the new release so as to mitigate what I felt was a serious flaw (since it caused compilation failures). Thanx! Chris -- Chris Sutcliffe iro...@wa... http://emergedesktop.org http://ironhead.modblog.com |
From: Luke D. <cod...@ho...> - 2005-11-01 15:00:17
|
----- Original Message ----- From: "Chris Sutcliffe" <iro...@wa...> To: <min...@li...> Sent: Sunday, October 30, 2005 10:34 AM Subject: Re: [MinGW-dvlpr] OBJBASE_H_? > Hey, > >> gets us back to the objbase.h header guard before this >> 2004-04-24 Luke Dunstan <in...@us...> >> * include/objbase.h (_OBJBASE_H_): Define. >> >> which was followed by this incorrect reversion of the above >> 2005-09-08 Dimitri Papadopoulos <pap...@us...> >> * include/objbase.h: Avoid double header guard. > > Since the removal of the proper #define caused compilation failures, I > figured it was just a matter of correcting what appeared to be the > incorrect #define. If, for some reason, it's better to use _OBJBASE_H_, I > have no problem with it, as long as the #ifndef is also changed to suit. Your patch was a correct fix to the problem caused by Dimitri's patch. The issue is that it effectively also reverted my patch: if you look at the version from before Dimitri's patch then you will understand. It defines BOTH OBJBASE_H_ and _OBJBASE_H_ but uses #ifndef OBJBASE_H_. Luke > >> What was reason for your patch to add _OBJBASE_H_? Is that reason still >> valid? > > Let me know... I uploaded the new release so as to mitigate what I felt > was a serious flaw (since it caused compilation failures). > > Thanx! > > Chris |
From: Chris S. <iro...@wa...> - 2005-11-01 15:21:09
|
>> Since the removal of the proper #define caused compilation failures, I >> figured it was just a matter of correcting what appeared to be the >> incorrect #define. If, for some reason, it's better to use _OBJBASE_H_, >> I >> have no problem with it, as long as the #ifndef is also changed to suit. > > Your patch was a correct fix to the problem caused by Dimitri's patch. The > issue is that it effectively also reverted my patch: if you look at the > version from before Dimitri's patch then you will understand. It defines > BOTH OBJBASE_H_ and _OBJBASE_H_ but uses #ifndef OBJBASE_H_. Is your preference that I change _OBJBASE_H to _OBJBASE_H_? I have no issue with doing that, however, I don't understand why. Doing a grep for _OBJBASE_H in the include directory did not provide more than the one definition, so there should not be a conflict. Chris -- Chris Sutcliffe iro...@wa... http://emergedesktop.org http://ironhead.modblog.com |
From: Dimitri Papadopoulos-O. <pap...@sh...> - 2005-11-02 09:21:55
|
Hi, > Your patch was a correct fix to the problem caused by Dimitri's patch. The reason for my patch was that MinGW is currently using standard _*_H header guards everywhere, except for <objbase.h> I felt defining Microsoft's _OBJBASE_H_ in addition to MinGW's _OBJBASE_H for <objbase.h> only was just a hack. The reason for Luke's patch was that some pieces of software expect Microsoft's header guards. Indeed this is a general problem with MinGW headers. Here is another example I'm aware of: #include <windows.h> [...] #if !defined(_WINDOWS_) #error Please include <windows.h> first! #endif This will fail with MinGW but it works with Visual C++. Now I don't know how compatible MinGW should be with Microsoft's headers. At first I thought it would be worth keeping strict conformance to MinGW's standard header guards. Thinking about it again, I tend to agree with Luke, it's probably worth trying to use the same header guards as Microsoft. Now a good option is maybe to maintain two sets of header guards: 1) MinGW's standard header guards (_*_H) and 2) Microsoft's header guards. The problem is that Microsoft obviously do not follow any standard. Here are some examples I'm aware of: windows.h -> _WINDOWS_ objbase.h -> _OBJBASE_H_ objsel.h -> __OBJSEL_H_ objsafe.h -> __objsafe_h__ So what about changing from: #ifndef _OBJSAFE_H #define _OBJSAFE_H to: #ifndef _OBJSAFE_H #define _OBJSAFE_H #define __objsafe_h__ Anyway, I'm sorry for breaking the software that relied on _OBJBASE_H_... Dimitri Papadopoulos |
From: Danny S. <dan...@cl...> - 2005-11-02 18:25:22
|
----- Original Message ----- From: "Dimitri Papadopoulos-Orfanos" <pap...@sh...> To: <min...@li...> Sent: Wednesday, 2 November 2005 22:21 Subject: Re: [MinGW-dvlpr] OBJBASE_H_? > Hi, > > > Your patch was a correct fix to the problem caused by Dimitri's patch. > > The reason for my patch was that MinGW is currently using standard _*_H > header guards everywhere, except for <objbase.h> I felt defining > Microsoft's _OBJBASE_H_ in addition to MinGW's _OBJBASE_H for > <objbase.h> only was just a hack. > And your patch to remove _OBJBASE_H was just careless Danny |
From: Dimitri Papadopoulos-O. <pap...@sh...> - 2005-11-03 07:09:24
|
Hi, >>>Your patch was a correct fix to the problem caused by Dimitri's patch. >> >>The reason for my patch was that MinGW is currently using standard _*_H >>header guards everywhere, except for <objbase.h> I felt defining >>Microsoft's _OBJBASE_H_ in addition to MinGW's _OBJBASE_H for >><objbase.h> only was just a hack. >> > > > And your patch to remove _OBJBASE_H was just careless Thank you, Danny. That was what one might call an error, the intent was to remove _OBJBASE_H_. I wasn't actually aware I had removed _OBJBASE_H until I looked at the CVS log a few minutes ago. What about the proposal for maintaining both MinGW's _*_H and Microsoft's headers guards? I think Luke was right and I was wrong about that. Dimitri |