v0.27.3
Robin Mills 9 years ago
parent 92659f24c8
commit 6ea3b00b02

@ -76,7 +76,18 @@ IF( MINGW OR UNIX )
)
ENDIF()
IF ( CYGWIN )
if (CMAKE_COMPILER_IS_GNUCC)
execute_process(COMMAND ${CMAKE_C_COMPILER} -dumpversion
OUTPUT_VARIABLE GCC_VERSION)
string(REGEX MATCHALL "[0-9]+" GCC_VERSION_COMPONENTS ${GCC_VERSION})
list(GET GCC_VERSION_COMPONENTS 0 GCC_MAJOR)
list(GET GCC_VERSION_COMPONENTS 1 GCC_MINOR)
message(STATUS Compiler major ${GCC_MAJOR})
message(STATUS ${GCC_MINOR})
endif()
IF ( CYGWIN OR ( ${GCC_MAJOR} GREATER 5 ))
ADD_DEFINITIONS( -std=gnu++98 ) # to support snprintf
ELSE()
ADD_DEFINITIONS( -std=c++98 )

@ -335,6 +335,26 @@ for u in gettext msginit msgmerge msgfmt msgconv msgfilter ; do
fi
done
AC_DEFUN([AX_GCC_VERSION], [
GCC_VERSION=""
AX_CHECK_COMPILE_FLAG([-dumpversion],
[ax_gcc_version_option=yes],
[ax_gcc_version_option=no])
AS_IF([test "x$GCC" = "xyes"],[
AS_IF([test "x$ax_gcc_version_option" != "xno"],[
AC_CACHE_CHECK([gcc version],[ax_cv_gcc_version],[
ax_cv_gcc_version="`$CC -dumpversion`"
AS_IF([test "x$ax_cv_gcc_version" = "x"],[
ax_cv_gcc_version=""
])
])
GCC_VERSION=$ax_cv_gcc_version
])
])
AC_SUBST([GCC_VERSION])
])
# 1188 v0.26 uses c++98
# 1188 v0.27 should have an option to specify versions such as c++11
case "$host_os" in
@ -345,7 +365,9 @@ case "$host_os" in
CPPFLAGS="$CPPFLAGS" # mingw doesn't link pthreads if you specify -std !!
;;
*)
CPPFLAGS="$CPPFLAGS -std=c++98" # // all others use c++98
if [ $GCC_VERSION -le 5 ]; then CPPFLAGS="$CPPFLAGS -std=c++98" # // most others use c++98
else CPPFLAGS="$CPPFLAGS -std=gnu++98" # // but not GCC 6
fi
;;
esac

@ -123,7 +123,7 @@ LINK.cc += -rpath $(PREFIX) -L$(PREFIX)
# to build the samples. Some errors only show up in this scenario, e.g., errors
# due to missing headers which are not installed (depending on compile-time
# settings) but may be wrongly included from other headers.
COMPILE.cc += -I$(top_srcdir)/include -I$(top_srcdir)/include/exiv2
COMPILE.cc += -I$(top_srcdir)/include -I$(top_srcdir)/include/exiv2 -std=gnu++98
# ******************************************************************************
# Rules

@ -674,7 +674,8 @@ namespace Exiv2 {
// and dumping the XMP in a post read operation similar to kpsIptcErase
// for the moment, dumping 'on the fly' is working fine
if ( ! bExtXMP ) {
while (xmp[start]) start++; start++;
while (xmp[start]) start++;
start++;
if ( ::strstr((char*)xmp+start,"HasExtendedXMP") ) {
start = size ; // ignore this packet, we'll get on the next time around
bExtXMP = true;

@ -1,5 +1,4 @@
// =================================================================================================
// Copyright 2002-2008 Adobe Systems Incorporated
// ================================================================================================= // Copyright 2002-2008 Adobe Systems Incorporated
// All Rights Reserved.
//
// NOTICE: Adobe permits you to use, modify, and distribute this file in accordance with the terms
@ -284,7 +283,7 @@ AppendNodeValue ( XMP_VarString & outputStr, const XMP_VarString & value, bool f
unsigned char * runStart = (unsigned char *) value.c_str();
unsigned char * runLimit = runStart + value.size();
unsigned char * runEnd;
unsigned char ch;
unsigned char ch=0;
while ( runStart < runLimit ) {

Loading…
Cancel
Save