Bug fix: properly handle overridden compressed objects

When caching objects in an object stream, only cache objects that
still resolve to that stream.  See Changelog mod from this commit for
details.
Work around gcc 4.8.0 issue on ppc64

Change iteration to use size_t instead of int.  The code should be
equivalent in all reasonable cases, but the original way this was
coded was causing a test failure with gcc 4.8.0 on ppc64.  See
https://bugzilla.redhat.com/show_bug.cgi?id=915321 for additional
information.
Replace many calls to sprintf with QUtil::hex_encode

Add QUtil::hex_encode to encode binary data has a hexadecimal string,
and use it in place of sprintf where possible.
Handle warning flags better

Make --enable-werror work properly on msvc, handle extra warnings
flags for msvc in configure.ac instead of hardcoding into
make/msvc.mk, separate warnings flags into WFLAGS in autoconf.mk to
avoid duplication and to make it easier to override.
Use -Wold-style-cast for C++ if supported

Also separate C and C++ warning flags.
Changing default warnings for MSVC

Enable C4996, deprecation/security warnings, which helps for Windows 8
certification.  Stop enabling C4267, which was warning about
conversions between size_t and other integer types.
Remove all old-style casts from C++ code
Fix unused local variable warnings
Rewrite QUtil::int_to_string and QUtil::double_to_string

Make them safer by avoiding any internal limits and replacing sprintf
with std::ostringstream.
Mark secure CRT warnings with comment

Put a specific comment marker next to every piece of code that MSVC
gives warning 4996 for.  This warning is generated for calls to
functions that Microsoft considers insecure or deprecated.  This
change is in preparation for fixing all these cases even though none
of them are actually incorrect or insecure as used in qpdf.  The
comment marker makes them easier to find so they can be fixed in
subsequent commits.
Use portable versions of some UNIX-specific calls

Remove needless calls to open, close, and fileno; call remove instead
of unlink.
Remove all calls to sprintf
Remove all calls to strcpy
Call QUtil::safe_fopen in place of fopen

fopen was previuosly called wrapped by QUtil::fopen_wrapper, but
QUtil::safe_fopen does this itself, which is less cumbersome.
Favor strerror_s and fopen_s on MSVC

Make remaining calls to fopen and strerror use strerror_s and fopen_s
on MSVC.
Fix inadvertent pointer to integer cast
Fix long long format string for WIN32
Add method to terminate content stream parsing
Fix getTypeCode and getTypeName work for indirect objects

Remove const qualifier from getTypeCode and get getTypeName methods of
QPDFObjectHandle, make them work properly for indirect objects, and
exercise them much better in the test suite.
Use ./install-sh instead of install -c