placeholders and g++ 4.1.1

I am attempting to port our source, which makes heavy use of boost, to RHEL5 with gcc version 4.1.1-18. I am getting 'defined but not used' warnings from placeholders.hpp. Since we've got a clean build policy, we need to clean this up somehow. I've done a bit of googling on both the boost site and the internet trying to determine where this error appeared from since our other compiles don't show it. Anyway, has anyone else seen this? I'd like to figure out a work around, or, barring that, a way to suppress it, but I have to admit that I'm not an expert with g++ flags, and I'd like to leave as much warning information intact as possible, of course. Anyone have any ideas?

Geoff Wedig wrote:
I am attempting to port our source, which makes heavy use of boost, to RHEL5 with gcc version 4.1.1-18. I am getting 'defined but not used' warnings from placeholders.hpp. Since we've got a clean build policy, we need to clean this up somehow. I've done a bit of googling on both the boost site and the internet trying to determine where this error appeared from since our other compiles don't show it.
Can you post one such warning, and the version of Boost that you're using?

Peter Dimov wrote:
Geoff Wedig wrote:
I am attempting to port our source, which makes heavy use of boost, to RHEL5 with gcc version 4.1.1-18. I am getting 'defined but not used' warnings from placeholders.hpp. Since we've got a clean build policy, we need to clean this up somehow. I've done a bit of googling on both the boost site and the internet trying to determine where this error appeared from since our other compiles don't show it.
Can you post one such warning, and the version of Boost that you're using?
Sorry this took me so long. Got distracted by a different issue that I've been tracking down. The warnings look like this: .../boost_1_33_1/boost/bind/placeholders.hpp:56: warning: â<unnamed>::_3â defined but not used This is with boost 1.33.1, obviously. We tried boost 1.32, but it doesn't like 4.1.1 because the compiler isn't in it's preprocessor guards. The warnings show up for every one of the placeholders that aren't used in the including code, so generally for 3-9, since 1 and 2 parameter functions are what we use most. Hope this helps. I'm sure it's spurious, but I have to get rid of it somehow. Thanks for your help! Geoff Wedig

Geoff Wedig wrote:
Peter Dimov wrote:
Geoff Wedig wrote:
I am attempting to port our source, which makes heavy use of boost, to RHEL5 with gcc version 4.1.1-18. I am getting 'defined but not used' warnings from placeholders.hpp. Since we've got a clean build policy, we need to clean this up somehow. I've done a bit of googling on both the boost site and the internet trying to determine where this error appeared from since our other compiles don't show it.
Can you post one such warning, and the version of Boost that you're using?
Sorry this took me so long. Got distracted by a different issue that I've been tracking down.
The warnings look like this:
.../boost_1_33_1/boost/bind/placeholders.hpp:56: warning: â<unnamed>::_3â defined but not used
You could try the following trivial patch: http://boost.cvs.sourceforge.net/boost/boost/boost/bind/placeholders.hpp?r1=1.13&r2=1.14 and see if it helps. This is a fix for a problem with g++ precompiled headers, but it should take care of the warning as well.

Peter Dimov wrote:
Geoff Wedig wrote:
Peter Dimov wrote:
Geoff Wedig wrote:
I am attempting to port our source, which makes heavy use of boost, to RHEL5 with gcc version 4.1.1-18. I am getting 'defined but not used' warnings from placeholders.hpp. Since we've got a clean build policy, we need to clean this up somehow. I've done a bit of googling on both the boost site and the internet trying to determine where this error appeared from since our other compiles don't show it. Can you post one such warning, and the version of Boost that you're using? Sorry this took me so long. Got distracted by a different issue that I've been tracking down.
The warnings look like this:
.../boost_1_33_1/boost/bind/placeholders.hpp:56: warning: â<unnamed>::_3â defined but not used
You could try the following trivial patch:
http://boost.cvs.sourceforge.net/boost/boost/boost/bind/placeholders.hpp?r1=1.13&r2=1.14
and see if it helps. This is a fix for a problem with g++ precompiled headers, but it should take care of the warning as well.
Yep, that worked like a charm. Thanks so much, I never would have figured that one out on my own. Geoff
participants (2)
-
Geoff Wedig
-
Peter Dimov