Changes between Initial Version and Version 9 of Ticket #6988
- Timestamp:
- Jul 10, 2020, 11:30:59 AM (4 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #6988
- Property Summary COMPILER: Using --enable-c++11 breaks in commandline.cpp → COMPILER: --enable-c++11 breaks compilation in commandline.cpp (AmigaOS4)
- Property Component → Port: AmigaOS4
- Property Owner set to
- Property Resolution → fixed
- Property Status new → closed
-
Ticket #6988 – Description
initial v9 1 {{{#!Markdown 2 Using the flag --enable-c++11 with configure makes the compiler break with an error early on in commandline.cpp. 3 1 Using the flag 2 {{{ 3 --enable-c++11 4 }}} 5 with configure, makes the compiler error early in commandline.cpp. 6 {{{ 4 7 C++ base/commandLine.o 5 8 base/commandLine.cpp: In function 'void Base::usage(const char*, ...)': 6 9 base/commandLine.cpp:162:36: error: 'vsnprintf' was not declared in this scope 7 10 vsnprintf(buf, STRINGBUFLEN, s, va); 8 11 ^ 9 12 gmake: *** [base/commandLine.o] Error 1 10 11 The same (or at least something similar) happens when using the flag -std=c++11 12 on a test program. 13 13 }}} 14 The same (or at least something similar) happens when using the flag 15 {{{ 16 -std=c++11 17 }}} 18 on a test program. 19 {{{ 14 20 #include <stdio.h> 15 21 #include <stdarg.h> 16 22 void test() { va_list ap; vsnprintf(0, 0, 0, ap); } 17 23 }}} 18 24 Building it with 19 g++ -c -o test.o test.cpp works fine, but adding the c++11 flag and using 20 g++ -c -o test.o test.cpp -std=c++11 throws this error 21 25 {{{ 26 g++ -c -o test.o test.cpp 27 }}} 28 works fine, but adding the c++11 flag and using 29 {{{ 30 g++ -c -o test.o test.cpp -std=c++11 31 }}} 32 throws this error 33 {{{ 22 34 test.cpp: In function 'void test()': 23 35 test.cpp:5:48: error: 'vsnprintf' was not declared in this scope 24 36 void test() { va_list ap; vsnprintf(0, 0, 0, ap); } 25 37 ^ 26 38 }}} 27 39 AmigaOS4 - PPC - SDL - BE 28 40 GCC (adtools build 5.3.0) 5.3.0 29 }}} 41 30 42 {{{#!div style="font-size: 75%" 31 43 Ticket imported from: bugs/6988.