Ok, here is the warning message (with rapidjson) as you wanted to see:
---
scons src/vnsw/agent:vnswad --target=i686
.....
g++ -o build/debug/base/misc_utils.o -c -march=i686 -g -O0 -DDEBUG -Wall -Werror -Wsign-compare -DLINUX -Icontroller/src -Ibuild/include -Icontroller/lib -Ibuild/debug controller/src/base/misc_utils.cc
cc1plus: warnings being treated as errors
build/include/rapidjson/writer.h: In member function ‘void rapidjson::Writer<Stream, Encoding, Allocator>::WriteString(const typename Encoding::Ch*, rapidjson::SizeType) [with Stream = rapidjson::GenericStringBuffer<rapidjson::UTF8<char>, rapidjson::CrtAllocator>, Encoding = rapidjson::UTF8<char>, Allocator = rapidjson::MemoryPoolAllocator<rapidjson::CrtAllocator>]’:
build/include/rapidjson/writer.h:52:   instantiated from ‘rapidjson::Writer<Stream, Encoding, Allocator>& rapidjson::Writer<Stream, Encoding, Allocator>::String(const typename Encoding::Ch*, rapidjson::SizeType, bool) [with Stream = rapidjson::GenericStringBuffer<rapidjson::UTF8<char>, rapidjson::CrtAllocator>, Encoding = rapidjson::UTF8<char>, Allocator = rapidjson::MemoryPoolAllocator<rapidjson::CrtAllocator>]’
build/include/rapidjson/document.h:503:   instantiated from ‘const rapidjson::GenericValue<Encoding, Allocator>& rapidjson::GenericValue<Encoding, Allocator>::Accept(Handler&) const [with Handler = rapidjson::Writer<rapidjson::GenericStringBuffer<rapidjson::UTF8<char>, rapidjson::CrtAllocator>, rapidjson::UTF8<char>, rapidjson::MemoryPoolAllocator<rapidjson::CrtAllocator> >, Encoding = rapidjson::UTF8<char>, Allocator = rapidjson::MemoryPoolAllocator<rapidjson::CrtAllocator>]’
controller/src/base/misc_utils.cc:141:   instantiated from here
build/include/rapidjson/writer.h:188: warning: comparison is always true due to limited range of data type
build/include/rapidjson/reader.h: In member function ‘void rapidjson::GenericReader<Encoding, Allocator>::ParseString(Stream&, Handler&) [with unsigned int parseFlags = 0u, Stream = rapidjson::GenericStringStream<rapidjson::UTF8<char> >, Handler = rapidjson::GenericDocument<rapidjson::UTF8<char>, rapidjson::MemoryPoolAllocator<rapidjson::CrtAllocator> >, Encoding = rapidjson::UTF8<char>, Allocator = rapidjson::MemoryPoolAllocator<rapidjson::CrtAllocator>]’:
build/include/rapidjson/reader.h:281:   instantiated from ‘void rapidjson::GenericReader<Encoding, Allocator>::ParseObject(Stream&, Handler&) [with unsigned int parseFlags = 0u, Stream = rapidjson::GenericStringStream<rapidjson::UTF8<char> >, Handler = rapidjson::GenericDocument<rapidjson::UTF8<char>, rapidjson::MemoryPoolAllocator<rapidjson::CrtAllocator> >, Encoding = rapidjson::UTF8<char>, Allocator = rapidjson::MemoryPoolAllocator<rapidjson::CrtAllocator>]’
build/include/rapidjson/reader.h:243:   instantiated from ‘bool rapidjson::GenericReader<Encoding, Allocator>::Parse(Stream&, Handler&) [with unsigned int parseFlags = 0u, Stream = rapidjson::GenericStringStream<rapidjson::UTF8<char> >, Handler = rapidjson::GenericDocument<rapidjson::UTF8<char>, rapidjson::MemoryPoolAllocator<rapidjson::CrtAllocator> >, Encoding = rapidjson::UTF8<char>, Allocator = rapidjson::MemoryPoolAllocator<rapidjson::CrtAllocator>]’
build/include/rapidjson/document.h:712:   instantiated from ‘rapidjson::GenericDocument<Encoding, Allocator>& rapidjson::GenericDocument<Encoding, Allocator>::ParseStream(Stream&) [with unsigned int parseFlags = 0u, Stream = rapidjson::GenericStringStream<rapidjson::UTF8<char> >, Encoding = rapidjson::UTF8<char>, Allocator = rapidjson::MemoryPoolAllocator<rapidjson::CrtAllocator>]’
build/include/rapidjson/document.h:745:   instantiated from ‘rapidjson::GenericDocument<Encoding, Allocator>& rapidjson::GenericDocument<Encoding, Allocator>::Parse(const typename Encoding::Ch*) [with unsigned int parseFlags = 0u, Encoding = rapidjson::UTF8<char>, Allocator = rapidjson::MemoryPoolAllocator<rapidjson::CrtAllocator>]’
controller/src/base/misc_utils.cc:125:   instantiated from here
build/include/rapidjson/reader.h:422: warning: comparison is always true due to limited range of data type
---
[root@localhost code]# gcc --version
gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-54)
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

The easiest way to test would be to use a centos machine with gcc 4.1.2 (centos 5.3 would do). However, I have a setup that you may use. I'll email you the setup information.