[Bug 218178] devel/jsoncpp: sparc64: snprintf is not a member of std

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Tue Mar 28 08:08:57 UTC 2017


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=218178

            Bug ID: 218178
           Summary: devel/jsoncpp: sparc64: snprintf is not a member of
                    std
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: Individual Port(s)
          Assignee: freebsd-ports-bugs at FreeBSD.org
          Reporter: phoe at openmailbox.org
                CC: yuri at rawbw.com
                CC: yuri at rawbw.com
             Flags: maintainer-feedback?(yuri at rawbw.com)

Requires patches to build on 11.0-RELEASE on sparc64.

For making it compile, I needed to comment out the preprocessor lines which
"#define snprintf std::snprintf" in the following files:

src/lib_json/json_writer.cpp
src/lib_json/json_reader.cpp

The errors generated are like:
src/lib_json/json_writer.cpp: In function 'std::__cxx11::string
Json::valueToString(double, bool, unsigned int)':
src/lib_json/json_writer.cpp:61:18: error: 'snprintf' is not a member of 'std'
 #define snprintf std::snprintf 
                  ^          
src/lib_json/json_writer.cpp:151:11: note: in expansion of macro 'snprintf'
     len = snprintf(buffer, sizeof(buffer), formatString, value);  
           ^ 
src/lib_json/json_writer.cpp:61:18: note: suggested alternative: 
 #define snprintf

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-ports-bugs mailing list