Eclipse CDT Consistently Producing Three Inclusion Related Errors - c++

Every time I make a new project in Eclipse Oxygen CDT, I'm always plagued by three main errors: "Type 'std::string' could not be resolved" (or similar inclusion problems), "Launch failed. Binaries not found," and "Launch failed. Program file does not exist".
I feel like I have tried just about everything. I have researched and followed these questions: Eclipse C++: Symbol 'std' could not be resolved
, The program file specified in the launch configuration does not exist, Launch Failed Binary not found Eclipse for C in Windows
, Eclipse CDT project built but “Launch Failed. Binary Not Found”
, “string could not resolved” error in Eclipse for C++ (Eclipse can't resolve standard library)
, C++ - Unresolved inclusion: iostream
, Eclipse c++ Type could not be resolved error even though build is successful
, and How to include a file from another folder?
.
Hi World Example:
/*
* Hi_world.cpp
*
* Created on: Feb 22, 2018
* Author: Me
*/
//I tried using the actual file paths but that didn't help either
#include <C:\MinGW\lib\gcc\mingw32\5.3.0\include\c++\iostream>
#include <C:\MinGW\include\string.h>
using namespace std;//"Symbol 'std' could not be resolved"
int main()
{
std::string me = "hi world";//"Type 'std::string' could not be resolved"
std::cout << me << std::endl;//"Symbol 'cout' could not be resolved"
// and "Symbol 'endl' could not be resolved"
}
Note: I tried to get this to run for several hours one day, was unsuccessful, so I saved and exited eclipse and my computer. The next day I turned on my computer, cleaned, built, and ran my this program as is, and it ran corectly on first try (although the red squiggly lines didn't disappear).
Hear is this Programs build log:
12:37:15 **** Rebuild of configuration Debug for project Hi world ****
Info: Internal Builder is used for build
g++ -O0 -g3 -Wall -c -fmessage-length=0 -o Hi_world.o "..\\Hi_world.cpp"
g++ "-LC:\\MinGW" -o "Hi world.exe" Hi_world.o
12:37:17 Build Finished (took 1s.47ms)
Hear is another example that still doesn't Run:
#include <iostream>
#include "stdio.h"
#include "time.h"
#include "string.h"
int main ()
{
time_t timer;
struct tm y2k = {0};
double seconds;
y2k.tm_hour = 0; y2k.tm_min = 0; y2k.tm_sec = 0;
y2k.tm_year = 100; y2k.tm_mon = 0; y2k.tm_mday = 1;
time(&timer); /* get current time; same as: timer = time(NULL) */
seconds = difftime(timer,mktime(&y2k));
printf ("%.f seconds since January 1, 2000 in the current timezone", seconds);
return 0;
}
Note: This had all the inclusion errors mentioned before, but randomly between a clean and rebuild those red squiggly errors went away. However it still doesn't build and run correctly with the error message "Launch failed. Binary not found."
Hear is this programs build log:
12:40:10 **** Rebuild of configuration Debug for project Time ****
Info: Internal Builder is used for build
g++ "-IC:\\MinGW\\lib\\gcc\\mingw32\\5.3.0\\include\\c++\\debug" -O0 -g3 -Wall -c -fmessage-length=0 -o Time.o "..\\Time.cpp"
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h: In member function 'std::__cxx11::string std::__cxx11::numpunct<_CharT>::grouping() const':
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:1777:7: error: return type 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}' is incomplete
{ return this->do_grouping(); }
^
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h: In member function 'virtual std::__cxx11::string std::__cxx11::numpunct<_CharT>::do_grouping() const':
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:1845:7: error: return type 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}' is incomplete
{ return _M_data->_M_grouping; }
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:2651:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc: In member function 'void std::__numpunct_cache<_CharT>::_M_cache(const std::locale&)':
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc:88:26: error: invalid use of incomplete type 'const string {aka const class std::__cxx11::basic_string<char>}'
_M_grouping_size = __g.size();
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iosfwd:39:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\stringfwd.h:71:11: note: declaration of 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
class basic_string;
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:2651:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc:90:7: error: invalid use of incomplete type 'const string {aka const class std::__cxx11::basic_string<char>}'
__g.copy(__grouping, _M_grouping_size);
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iosfwd:39:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\stringfwd.h:71:11: note: declaration of 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
class basic_string;
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:2651:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc: In member function '_InIter std::num_get<_CharT, _InIter>::_M_extract_float(_InIter, _InIter, std::ios_base&, std::ios_base::iostate&, std::__cxx11::string&) const':
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc:211:18: error: invalid use of incomplete type 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
__found_grouping.reserve(32);
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iosfwd:39:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\stringfwd.h:71:11: note: declaration of 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
class basic_string;
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:2651:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc:282:10: error: invalid use of incomplete type 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
__xtrc.clear();
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iosfwd:39:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\stringfwd.h:71:11: note: declaration of 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
class basic_string;
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:2651:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc:296:27: error: invalid use of incomplete type 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
if (__found_grouping.size())
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iosfwd:39:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\stringfwd.h:71:11: note: declaration of 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
class basic_string;
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:2651:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc:319:27: error: invalid use of incomplete type 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
if (__found_grouping.size() && !__found_dec)
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iosfwd:39:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\stringfwd.h:71:11: note: declaration of 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
class basic_string;
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:2651:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc:355:27: error: invalid use of incomplete type 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
if (__found_grouping.size())
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iosfwd:39:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\stringfwd.h:71:11: note: declaration of 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
class basic_string;
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:2651:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc: In member function '_InIter std::num_get<_CharT, _InIter>::_M_extract_int(_InIter, _InIter, std::ios_base&, std::ios_base::iostate&, _ValueT&) const':
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc:468:20: error: invalid use of incomplete type 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
__found_grouping.reserve(32);
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iosfwd:39:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\stringfwd.h:71:11: note: declaration of 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
class basic_string;
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:2651:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc:554:22: error: invalid use of incomplete type 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
if (__found_grouping.size())
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iosfwd:39:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\stringfwd.h:71:11: note: declaration of 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
class basic_string;
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:2651:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc:567:55: error: invalid use of incomplete type 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
if ((!__sep_pos && !__found_zero && !__found_grouping.size())
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iosfwd:39:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\stringfwd.h:71:11: note: declaration of 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
class basic_string;
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:2651:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc: In member function 'virtual _InIter std::num_get<_CharT, _InIter>::do_get(std::num_get<_CharT, _InIter>::iter_type, std::num_get<_CharT, _InIter>::iter_type, std::ios_base&, std::ios_base::iostate&, float&) const':
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc:695:13: error: invalid use of incomplete type 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
__xtrc.reserve(32);
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iosfwd:39:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\stringfwd.h:71:11: note: declaration of 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
class basic_string;
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:2651:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc:697:33: error: invalid use of incomplete type 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
std::__convert_to_v(__xtrc.c_str(), __v, __err, _S_get_c_locale());
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iosfwd:39:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\stringfwd.h:71:11: note: declaration of 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
class basic_string;
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:2651:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc: In member function 'virtual _InIter std::num_get<_CharT, _InIter>::do_get(std::num_get<_CharT, _InIter>::iter_type, std::num_get<_CharT, _InIter>::iter_type, std::ios_base&, std::ios_base::iostate&, double&) const':
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc:710:13: error: invalid use of incomplete type 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
__xtrc.reserve(32);
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iosfwd:39:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\stringfwd.h:71:11: note: declaration of 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
class basic_string;
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:2651:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc:712:33: error: invalid use of incomplete type 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
std::__convert_to_v(__xtrc.c_str(), __v, __err, _S_get_c_locale());
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iosfwd:39:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\stringfwd.h:71:11: note: declaration of 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
class basic_string;
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:2651:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc: In member function 'virtual _InIter std::num_get<_CharT, _InIter>::do_get(std::num_get<_CharT, _InIter>::iter_type, std::num_get<_CharT, _InIter>::iter_type, std::ios_base&, std::ios_base::iostate&, long double&) const':
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc:742:13: error: invalid use of incomplete type 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
__xtrc.reserve(32);
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iosfwd:39:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\stringfwd.h:71:11: note: declaration of 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
class basic_string;
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.h:2651:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\basic_ios.h:37,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:44,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\locale_facets.tcc:744:33: error: invalid use of incomplete type 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
std::__convert_to_v(__xtrc.c_str(), __v, __err, _S_get_c_locale());
^
In file included from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iosfwd:39:0,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ios:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\iostream:39,
from ..\Time.cpp:8:
c:\mingw\lib\gcc\mingw32\5.3.0\include\c++\bits\stringfwd.h:71:11: note: declaration of 'std::__cxx11::string {aka class std::__cxx11::basic_string<char>}'
class basic_string;
^
12:40:10 Build Finished (took 656ms)
I am using a native install of Windows 10, and am using MinGW installed on my computer. What is strange about this problem is that I will start a new project, the inclusion errors will pop up, making it not be able to build or run, and thus causing the other two errors, I will then battle it for days, following the answers above and get no where. Then out of the blue, I will click "build and run" and the program will build correctly and run properly (so long as I don't changing the code or click "Clean" thereafter). It gets even worse if I try to make a class and include the classes header file, with all the method declarations, in the classes .cpp file with similar errors in the .cpp file as in the example above.
Could this be caused by a faulty insulation of Eclipse CDT, or of MinGW? Are there settings that I could change in Eclipse to designate where to look for its libraries (would that even help?)? Any help is GREATLY appreciated =).
Thanks!

Related

How to fix malfunctioning G++ Complier?

The G++ complier is not working. Yesterday I was updating MinGW and Windows PATHS to get Natbeans working but now Visual Studio Code is not Saying "Hello World", It is giving 20+ errors each run.
Any ideas on how to fix so I can run my program? I Uninstalled and Reinstalled MinGw twice but it did not work
Some of the Errors:
required from 'class std::__cxx11::basic_string<char16_t>'
c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\basic_string.h:5677:41:
required from here
c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\ext\alloc_traits.h:61:53:
error: no type named 'size_type' in 'struct
std::allocator_traitsstd::allocator<char16_t >'
typedef typename _Base_type::size_type size_type;
^~~~~~~~~ c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\ext\alloc_traits.h:62:53:
error: no type named 'difference_type' in 'struct
std::allocator_traitsstd::allocator<char16_t >'
typedef typename _Base_type::difference_type difference_type;
^~~~~~~~~~~~~~~ c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\ext\alloc_traits.h:70:23:
error: no members matching
'__gnu_cxx::__alloc_traitsstd::allocator<char16_t >::_Base_type {aka
std::allocator_traitsstd::allocator<char16_t >}::max_size' in
'__gnu_cxx::__alloc_traitsstd::allocator<char16_t >::_Base_type {aka
struct std::allocator_traitsstd::allocator<char16_t >}'
using _Base_type::max_size;
^~~~~~~~ In file included from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\string:52:0,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\locale_classes.h:40,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\ios_base.h:41,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\ios:42,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\iostream:39,
from test17.cpp:23: c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\basic_string.h: In
member function 'size_t std::hashstd::__cxx11::basic_string<char16_t
::operator()(const u16string&) const': c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\basic_string.h:5678:42:
error: 'const u16string {aka const class
std::__cxx11::basic_string<char16_t>}' has no member named 'length'
__s.length() * sizeof(char16_t)); }
^~~~~~ In file included from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\basic_string.h:40:0,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\string:52,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\locale_classes.h:40,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\ios_base.h:41,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\ios:42,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\iostream:39,
from test17.cpp:23: c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\ext\alloc_traits.h: In
instantiation of 'struct
__gnu_cxx::__alloc_traitsstd::allocator<char32_t >': c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\basic_string.h:75:24:
required from 'class std::__cxx11::basic_string<char32_t>'
c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\basic_string.h:5692:41:
required from here
c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\ext\alloc_traits.h:61:53:
error: no type named 'size_type' in 'struct
std::allocator_traitsstd::allocator<char32_t >'
typedef typename _Base_type::size_type size_type;
^~~~~~~~~ c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\ext\alloc_traits.h:62:53:
error: no type named 'difference_type' in 'struct
std::allocator_traitsstd::allocator<char32_t >'
typedef typename _Base_type::difference_type difference_type;
^~~~~~~~~~~~~~~ c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\ext\alloc_traits.h:70:23:
error: no members matching
'__gnu_cxx::__alloc_traitsstd::allocator<char32_t >::_Base_type {aka
std::allocator_traitsstd::allocator<char32_t >}::max_size' in
'__gnu_cxx::__alloc_traitsstd::allocator<char32_t >::_Base_type {aka
struct std::allocator_traitsstd::allocator<char32_t >}'
using _Base_type::max_size;
^~~~~~~~ In file included from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\string:52:0,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\locale_classes.h:40,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\ios_base.h:41,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\ios:42,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\ostream:38,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\iostream:39,
from test17.cpp:23: c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\basic_string.h: In
member function 'size_t std::hashstd::__cxx11::basic_string<char32_t
::operator()(const u32string&) const': c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\basic_string.h:5693:42:
error: 'const u32string {aka const class
std::__cxx11::basic_string<char32_t>}' has no member named 'length'
The Code so far (Want it to print Hello World to the Console using C++):
#include <iostream>
int main()
{
//Prints Hello World to the Console
std::cout << "Hello World" << std::endl;
}
Desired output:
"Hello World"

Getting weird struct and typedef errors in Win consoleapi using MinGW-w64

Below is the compile log. All of these errors are either from Wincon.h or Wincontypes.h . Everything else, including my code, works. I'm using MinGW-w64 (v8.1.0), it doesn't give any errors for Winapi or ConsoleApi3. I am helpless at this point. Visual Studio (MSBuild) compiles it without a problem.
g++ MainConsole.cpp -o run -mconsole
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:36:16: error: redefinition of 'struct _COORD'
typedef struct _COORD {
^~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:17:18: note: previous definition of 'struct _COORD'
typedef struct _COORD {
^~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:22:18: note: previous definition of 'struct _SMALL_RECT'
typedef struct _SMALL_RECT {
^~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:46:3: error: conflicting declaration 'typedef int SMALL_RECT'
} SMALL_RECT, *PSMALL_RECT;
^~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:27:17: note: previous declaration as 'typedef struct _SMALL_RECT* PSMALL_RECT'
} SMALL_RECT,*PSMALL_RECT;
^~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:78:18: note: previous definition of 'struct _WINDOW_BUFFER_SIZE_RECORD'
typedef struct _WINDOW_BUFFER_SIZE_RECORD {
^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:112:3: error: conflicting declaration 'typedef int WINDOW_BUFFER_SIZE_RECORD'
} WINDOW_BUFFER_SIZE_RECORD, *PWINDOW_BUFFER_SIZE_RECORD;
^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:80:5: note: previous declaration as 'typedef struct _WINDOW_BUFFER_SIZE_RECORD WINDOW_BUFFER_SIZE_RECORD'
} WINDOW_BUFFER_SIZE_RECORD,*PWINDOW_BUFFER_SIZE_RECORD;
^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:112:31: error: conflicting declaration 'typedef int* PWINDOW_BUFFER_SIZE_RECORD'
} WINDOW_BUFFER_SIZE_RECORD, *PWINDOW_BUFFER_SIZE_RECORD;
^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:80:32: note: previous declaration as 'typedef struct _WINDOW_BUFFER_SIZE_RECORD* PWINDOW_BUFFER_SIZE_RECORD'
} WINDOW_BUFFER_SIZE_RECORD,*PWINDOW_BUFFER_SIZE_RECORD;
^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:114:16: error: redefinition of 'struct _MENU_EVENT_RECORD'
typedef struct _MENU_EVENT_RECORD {
^~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:82:18: note: previous definition of 'struct _MENU_EVENT_RECORD'
typedef struct _MENU_EVENT_RECORD {
^~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:116:3: error: conflicting declaration 'typedef int MENU_EVENT_RECORD'
} MENU_EVENT_RECORD, *PMENU_EVENT_RECORD;
^~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:84:5: note: previous declaration as 'typedef struct _MENU_EVENT_RECORD MENU_EVENT_RECORD'
} MENU_EVENT_RECORD,*PMENU_EVENT_RECORD;
^~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:116:23: error: conflicting declaration 'typedef int* PMENU_EVENT_RECORD'
} MENU_EVENT_RECORD, *PMENU_EVENT_RECORD;
^~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:84:24: note: previous declaration as 'typedef struct _MENU_EVENT_RECORD* PMENU_EVENT_RECORD'
} MENU_EVENT_RECORD,*PMENU_EVENT_RECORD;
^~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:118:16: error: redefinition of 'struct _FOCUS_EVENT_RECORD'
typedef struct _FOCUS_EVENT_RECORD {
^~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:86:18: note: previous definition of 'struct _FOCUS_EVENT_RECORD'
typedef struct _FOCUS_EVENT_RECORD {
^~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:120:3: error: conflicting declaration 'typedef int FOCUS_EVENT_RECORD'
} FOCUS_EVENT_RECORD, *PFOCUS_EVENT_RECORD;
^~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:88:5: note: previous declaration as 'typedef struct _FOCUS_EVENT_RECORD FOCUS_EVENT_RECORD'
} FOCUS_EVENT_RECORD,*PFOCUS_EVENT_RECORD;
^~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:120:24: error: conflicting declaration 'typedef int* PFOCUS_EVENT_RECORD'
} FOCUS_EVENT_RECORD, *PFOCUS_EVENT_RECORD;
^~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:88:25: note: previous declaration as 'typedef struct _FOCUS_EVENT_RECORD* PFOCUS_EVENT_RECORD'
} FOCUS_EVENT_RECORD,*PFOCUS_EVENT_RECORD;
^~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:122:16: error: redefinition of 'struct _INPUT_RECORD'
typedef struct _INPUT_RECORD {
^~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:90:18: note: previous definition of 'struct _INPUT_RECORD'
typedef struct _INPUT_RECORD {
^~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:131:3: error: conflicting declaration 'typedef int INPUT_RECORD'
} INPUT_RECORD, *PINPUT_RECORD;
^~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:99:5: note: previous declaration as 'typedef struct _INPUT_RECORD INPUT_RECORD'
} INPUT_RECORD,*PINPUT_RECORD;
^~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:131:18: error: conflicting declaration 'typedef int* PINPUT_RECORD'
} INPUT_RECORD, *PINPUT_RECORD;
^~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:99:19: note: previous declaration as 'typedef struct _INPUT_RECORD* PINPUT_RECORD'
} INPUT_RECORD,*PINPUT_RECORD;
^~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:143:16: error: redefinition of 'struct _CHAR_INFO'
typedef struct _CHAR_INFO {
^~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:107:18: note: previous definition of 'struct _CHAR_INFO'
typedef struct _CHAR_INFO {
^~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:149:3: error: conflicting declaration 'typedef int CHAR_INFO'
} CHAR_INFO, *PCHAR_INFO;
^~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:113:5: note: previous declaration as 'typedef struct _CHAR_INFO CHAR_INFO'
} CHAR_INFO,*PCHAR_INFO;
^~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:149:15: error: conflicting declaration 'typedef int* PCHAR_INFO'
} CHAR_INFO, *PCHAR_INFO;
^~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:113:16: note: previous declaration as 'typedef struct _CHAR_INFO* PCHAR_INFO'
} CHAR_INFO,*PCHAR_INFO;
^~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:151:16: error: redefinition of 'struct _CONSOLE_FONT_INFO'
typedef struct _CONSOLE_FONT_INFO {
^~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:146:18: note: previous definition of 'struct _CONSOLE_FONT_INFO'
typedef struct _CONSOLE_FONT_INFO {
^~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:154:3: error: conflicting declaration 'typedef int CONSOLE_FONT_INFO'
} CONSOLE_FONT_INFO, *PCONSOLE_FONT_INFO;
^~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:149:5: note: previous declaration as 'typedef struct _CONSOLE_FONT_INFO CONSOLE_FONT_INFO'
} CONSOLE_FONT_INFO,*PCONSOLE_FONT_INFO;
^~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:21,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/wincontypes.h:154:23: error: conflicting declaration 'typedef int* PCONSOLE_FONT_INFO'
} CONSOLE_FONT_INFO, *PCONSOLE_FONT_INFO;
^~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:149:24: note: previous declaration as 'typedef struct _CONSOLE_FONT_INFO* PCONSOLE_FONT_INFO'
} CONSOLE_FONT_INFO,*PCONSOLE_FONT_INFO;
^~~~~~~~~~~~~~~~~~
In file included from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:66:16: error: redefinition of 'struct _CONSOLE_FONT_INFOEX'
typedef struct _CONSOLE_FONT_INFOEX {
^~~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:297:16: note: previous definition of 'struct _CONSOLE_FONT_INFOEX'
typedef struct _CONSOLE_FONT_INFOEX {
^~~~~~~~~~~~~~~~~~~~
In file included from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:73:3: error: conflicting declaration 'typedef int CONSOLE_FONT_INFOEX'
} CONSOLE_FONT_INFOEX, *PCONSOLE_FONT_INFOEX;
^~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:304:3: note: previous declaration as 'typedef struct _CONSOLE_FONT_INFOEX CONSOLE_FONT_INFOEX'
} CONSOLE_FONT_INFOEX, *PCONSOLE_FONT_INFOEX;
^~~~~~~~~~~~~~~~~~~
In file included from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:73:25: error: conflicting declaration 'typedef int* PCONSOLE_FONT_INFOEX'
} CONSOLE_FONT_INFOEX, *PCONSOLE_FONT_INFOEX;
^~~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:304:25: note: previous declaration as 'typedef struct _CONSOLE_FONT_INFOEX* PCONSOLE_FONT_INFOEX'
} CONSOLE_FONT_INFOEX, *PCONSOLE_FONT_INFOEX;
^~~~~~~~~~~~~~~~~~~~
In file included from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:107:16: error: redefinition of 'struct _CONSOLE_SELECTION_INFO'
typedef struct _CONSOLE_SELECTION_INFO {
^~~~~~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:151:18: note: previous definition of 'struct _CONSOLE_SELECTION_INFO'
typedef struct _CONSOLE_SELECTION_INFO {
^~~~~~~~~~~~~~~~~~~~~~~
In file included from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:111:3: error: conflicting declaration 'typedef int CONSOLE_SELECTION_INFO'
} CONSOLE_SELECTION_INFO, *PCONSOLE_SELECTION_INFO;
^~~~~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:155:5: note: previous declaration as 'typedef struct _CONSOLE_SELECTION_INFO CONSOLE_SELECTION_INFO'
} CONSOLE_SELECTION_INFO,*PCONSOLE_SELECTION_INFO;
^~~~~~~~~~~~~~~~~~~~~~
In file included from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:111:28: error: conflicting declaration 'typedef int* PCONSOLE_SELECTION_INFO'
} CONSOLE_SELECTION_INFO, *PCONSOLE_SELECTION_INFO;
^~~~~~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:155:29: note: previous declaration as 'typedef struct _CONSOLE_SELECTION_INFO* PCONSOLE_SELECTION_INFO'
} CONSOLE_SELECTION_INFO,*PCONSOLE_SELECTION_INFO;
^~~~~~~~~~~~~~~~~~~~~~~
In file included from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:127:16: error: redefinition of 'struct _CONSOLE_HISTORY_INFO'
typedef struct _CONSOLE_HISTORY_INFO {
^~~~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:306:16: note: previous definition of 'struct _CONSOLE_HISTORY_INFO'
typedef struct _CONSOLE_HISTORY_INFO {
^~~~~~~~~~~~~~~~~~~~~
In file included from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:132:3: error: conflicting declaration 'typedef int CONSOLE_HISTORY_INFO'
} CONSOLE_HISTORY_INFO, *PCONSOLE_HISTORY_INFO;
^~~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:311:3: note: previous declaration as 'typedef struct _CONSOLE_HISTORY_INFO CONSOLE_HISTORY_INFO'
} CONSOLE_HISTORY_INFO, *PCONSOLE_HISTORY_INFO;
^~~~~~~~~~~~~~~~~~~~
In file included from F:\PROJECTS\gpge\GPGE\Dependencies.h:7,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/ConsoleApi3.h:132:26: error: conflicting declaration 'typedef int* PCONSOLE_HISTORY_INFO'
} CONSOLE_HISTORY_INFO, *PCONSOLE_HISTORY_INFO;
^~~~~~~~~~~~~~~~~~~~~
In file included from C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/Windows.h:74,
from F:\PROJECTS\gpge\GPGE\Dependencies.h:5,
from MainConsole.cpp:6:
C:/mingw-w64/x86_64-8.1.0-win32-seh-rt_v6-rev0/mingw64/x86_64-w64-mingw32/include/wincon.h:311:26: note: previous declaration as 'typedef struct _CONSOLE_HISTORY_INFO* PCONSOLE_HISTORY_INFO'
} CONSOLE_HISTORY_INFO, *PCONSOLE_HISTORY_INFO;
"AFAIK, you shouldn't need to include "ConsoleApi3.h" explicitly if you include "Windows.h". It's possible that there's something a bit off with the mingw headers, but it's more likely to be caused by something that your code does before including those headers."
-- #molbdnilo has the solution. This is new to me, looks like MSBuild checked overlaps before compiling, MinGW doesn't.

Compiler error with std::map and dense_hash_map in GTEST

I am getting this error when I try to use my project/module in my GOOGLE TESTS.
gcc.compile.c++ bin/gcc-4.8.3/debug/link-static/gmock_test.o
In file included from /usr/include/c++/4.8.2/tr1/functional:39:0,
from /usr/local/include/google/dense_hash_map:106,
from sagarmatha/utils/include/multicast_receiver.h:11,
from include/transmitter/mcx_receiver.h:25,
from src/unit_tests_theo.cpp:7:
/usr/include/c++/4.8.2/tr1/tuple:130:11: error: redefinition of ‘class std::tuple< <template-parameter-1-1> >’
class tuple : public _Tuple_impl<0, _Elements...>
^
In file included from /usr/include/c++/4.8.2/bits/stl_map.h:63:0,
from /usr/include/c++/4.8.2/map:61,
from 8k/include/Source.h:12,
from src/unit_tests_theo.cpp:2:
/usr/include/c++/4.8.2/tuple:388:11: error: previous definition of ‘class std::tuple< <template-parameter-1-1> >’
class tuple : public _Tuple_impl<0, _Elements...>
^
In file included from /usr/include/c++/4.8.2/tr1/functional:39:0,
from /usr/local/include/google/dense_hash_map:106,
from sagarmatha/utils/include/multicast_receiver.h:11,
from include/transmitter/mcx_receiver.h:25,
from src/unit_tests_theo.cpp:7:
/usr/include/c++/4.8.2/tr1/tuple:164:20: error: redefinition of ‘class std::tuple<>’
template<> class tuple<> { };
^
In file included from /usr/include/c++/4.8.2/bits/stl_map.h:63:0,
from /usr/include/c++/4.8.2/map:61,
from 8k/include/Source.h:12,
from src/unit_tests_theo.cpp:2:
/usr/include/c++/4.8.2/tuple:512:11: error: previous definition of ‘class std::tuple<>’
class tuple<>
^
In file included from /usr/include/c++/4.8.2/tr1/functional:39:0,
from /usr/local/include/google/dense_hash_map:106,
from sagarmatha/utils/include/multicast_receiver.h:11,
from include/transmitter/mcx_receiver.h:25,
from src/unit_tests_theo.cpp:7:
/usr/include/c++/4.8.2/tr1/tuple:168:11: error: redefinition of ‘class std::tuple<_T1, _T2>’
class tuple<_T1, _T2> : public _Tuple_impl<0, _T1, _T2>
^
In file included from /usr/include/c++/4.8.2/bits/stl_map.h:63:0,
from /usr/include/c++/4.8.2/map:61,
from 8k/include/Source.h:12,
from src/unit_tests_theo.cpp:2:
/usr/include/c++/4.8.2/tuple:521:11: error: previous definition of ‘class std::tuple<_T1, _T2>’
class tuple<_T1, _T2> : public _Tuple_impl<0, _T1, _T2>
^
In file included from /usr/include/c++/4.8.2/tuple:38:0,
from /usr/include/c++/4.8.2/bits/stl_map.h:63,
from /usr/include/c++/4.8.2/map:61,
from 8k/include/Source.h:12,
from src/unit_tests_theo.cpp:2:
/usr/include/c++/4.8.2/utility:83:24: error: template parameter ‘long unsigned int _Int’
template<std::size_t _Int, class _Tp>
^
In file included from /usr/include/c++/4.8.2/tr1/functional:39:0,
from /usr/local/include/google/dense_hash_map:106,
from sagarmatha/utils/include/multicast_receiver.h:11,
from include/transmitter/mcx_receiver.h:25,
from src/unit_tests_theo.cpp:7:
/usr/include/c++/4.8.2/tr1/tuple:223:12: error: redeclared here as ‘int __i’
struct tuple_element;
^
/usr/include/c++/4.8.2/tr1/tuple:230:12: error: specialization of ‘template<long unsigned int _Int, class _Tp> struct std::tuple_element’ in different namespace [-fpermissive]
struct tuple_element<__i, tuple<_Head, _Tail...> >
^
In file included from /usr/include/c++/4.8.2/tuple:38:0,
from /usr/include/c++/4.8.2/bits/stl_map.h:63,
from /usr/include/c++/4.8.2/map:61,
from 8k/include/Source.h:12,
from src/unit_tests_theo.cpp:2:
/usr/include/c++/4.8.2/utility:84:11: error: from definition of ‘template<long unsigned int _Int, class _Tp> struct std::tuple_element’ [-fpermissive]
class tuple_element;
^
In file included from /usr/include/c++/4.8.2/tr1/functional:39:0,
from /usr/local/include/google/dense_hash_map:106,
from sagarmatha/utils/include/multicast_receiver.h:11,
from include/transmitter/mcx_receiver.h:25,
from src/unit_tests_theo.cpp:7:
/usr/include/c++/4.8.2/tr1/tuple:237:12: error: redefinition of ‘struct std::tuple_element<0ul, std::tuple<_El0, _El ...> >’
struct tuple_element<0, tuple<_Head, _Tail...> >
^
In file included from /usr/include/c++/4.8.2/bits/stl_map.h:63:0,
from /usr/include/c++/4.8.2/map:61,
from 8k/include/Source.h:12,
from src/unit_tests_theo.cpp:2:
/usr/include/c++/4.8.2/tuple:687:12: error: previous definition of ‘struct std::tuple_element<0ul, std::tuple<_El0, _El ...> >’
struct tuple_element<0, tuple<_Head, _Tail...> >
^
In file included from /usr/include/c++/4.8.2/tr1/functional:39:0,
from /usr/local/include/google/dense_hash_map:106,
from sagarmatha/utils/include/multicast_receiver.h:11,
from include/transmitter/mcx_receiver.h:25,
from src/unit_tests_theo.cpp:7:
/usr/include/c++/4.8.2/tr1/tuple:248:12: error: redefinition of ‘struct std::tuple_size<std::tuple<_Args1 ...> >’
struct tuple_size<tuple<_Elements...> >
^
In file included from /usr/include/c++/4.8.2/bits/stl_map.h:63:0,
from /usr/include/c++/4.8.2/map:61,
from 8k/include/Source.h:12,
from src/unit_tests_theo.cpp:2:
/usr/include/c++/4.8.2/tuple:737:12: error: previous definition of ‘struct std::tuple_size<std::tuple<_Args1 ...> >’
struct tuple_size<tuple<_Elements...>>
^
In file included from /usr/include/c++/4.8.2/tr1/functional:39:0,
from /usr/local/include/google/dense_hash_map:106,
from sagarmatha/utils/include/multicast_receiver.h:11,
from include/transmitter/mcx_receiver.h:25,
from src/unit_tests_theo.cpp:7:
/usr/include/c++/4.8.2/tr1/tuple:254:49: error: definition of ‘std::tuple_size<std::tuple<_Args1 ...> >::value’ is not in namespace enclosing ‘std::tuple_size<std::tuple<_Args1 ...> >’ [-fpermissive]
const int tuple_size<tuple<_Elements...> >::value;
Is it related to map and dense_hash_map usage together ? Please help?
Since it solved your problem I'm making this an answer: set -DGTEST_HAS_TR1_TUPLE=0 -DGTEST_USE_OWN_TR1_TUPLE=0 to instruct the compilation not to use tr1 tuple nor its own tuple implementation.

Tensorflow Serving bazel build Error: mnist_inference_2.cc - Signatures' has not been declared

I am trying to replicate tensorflow serving examples from https://tensorflow.github.io/serving/serving_advanced.html
But I get following error. It is possibly Tensorflow library error. Any help will be greatly appreciated.
:
~/serving$ bazel build //tensorflow_serving/example:mnist_inference_2
INFO: Found 1 target...
ERROR: /home/ubuntu/serving/tensorflow_serving/session_bundle/BUILD:125:1: C++ compilation of rule '//tensorflow_serving/session_bundle:session_bundle' failed: gcc failed: error executing command /usr/bin/gcc -U_FORTIFY_SOURCE '-D_FORTIFY_SOURCE=1' -fstack-protector -Wall -Wl,-z,-relro,-z,now -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer '-std=c++0x' -iquote . ... (remaining 103 argument(s) skipped): com.google.devtools.build.lib.shell.BadExitStatusException: Process exited with status 1.
In file included from ./tensorflow_serving/session_bundle/session_bundle.h:30:0,
from tensorflow_serving/session_bundle/session_bundle.cc:16:
./tensorflow_serving/session_bundle/signature.h:40:22: error: 'Signatures' has not been declared
Signatures* signatures);
^
./tensorflow_serving/session_bundle/signature.h:43:28: error: 'Signatures' does not name a type
Status SetSignatures(const Signatures& signatures,
^
./tensorflow_serving/session_bundle/signature.h:43:40: error: ISO C++ forbids declaration of 'signatures' with no type [-fpermissive]
Status SetSignatures(const Signatures& signatures,
^
./tensorflow_serving/session_bundle/signature.h:51:5: error: 'ClassificationSignature' has not been declared
ClassificationSignature* signature);
^
./tensorflow_serving/session_bundle/signature.h:58:5: error: 'ClassificationSignature' has not been declared
ClassificationSignature* signature);
^
./tensorflow_serving/session_bundle/signature.h:64:31: error: 'RegressionSignature' has not been declared
RegressionSignature* signature);
^
./tensorflow_serving/session_bundle/signature.h:73:32: error: 'ClassificationSignature' does not name a type
Status RunClassification(const ClassificationSignature& signature,
^
./tensorflow_serving/session_bundle/signature.h:73:57: error: ISO C++ forbids declaration of 'signature' with no type [-fpermissive]
Status RunClassification(const ClassificationSignature& signature,
^
./tensorflow_serving/session_bundle/signature.h:83:28: error: 'RegressionSignature' does not name a type
Status RunRegression(const RegressionSignature& signature, const Tensor& input,
^
./tensorflow_serving/session_bundle/signature.h:83:49: error: ISO C++ forbids declaration of 'signature' with no type [-fpermissive]
Status RunRegression(const RegressionSignature& signature, const Tensor& input,
^
./tensorflow_serving/session_bundle/signature.h:90:28: error: 'GenericSignature' has not been declared
GenericSignature* signature);
^
./tensorflow_serving/session_bundle/signature.h:94:28: error: 'Signature' has not been declared
Signature* default_signature);
^
./tensorflow_serving/session_bundle/signature.h:100:26: error: 'Signature' has not been declared
Signature* default_signature);
^
./tensorflow_serving/session_bundle/signature.h:106:32: error: 'GenericSignature' does not name a type
Status BindGenericInputs(const GenericSignature& signature,
^
./tensorflow_serving/session_bundle/signature.h:106:50: error: ISO C++ forbids declaration of 'signature' with no type [-fpermissive]
Status BindGenericInputs(const GenericSignature& signature,
^
./tensorflow_serving/session_bundle/signature.h:117:31: error: 'GenericSignature' does not name a type
Status BindGenericNames(const GenericSignature& signature,
^
./tensorflow_serving/session_bundle/signature.h:117:49: error: ISO C++ forbids declaration of 'signature' with no type [-fpermissive]
Status BindGenericNames(const GenericSignature& signature,
^
tensorflow_serving/session_bundle/session_bundle.cc:68:49: error: 'AssetFile' was not declared in this scope
const std::vector<AssetFile>& asset_files,
^
tensorflow_serving/session_bundle/session_bundle.cc:68:49: note: suggested alternative:
In file included from ./tensorflow_serving/session_bundle/manifest.pb.h:19:0,
from ./tensorflow_serving/session_bundle/session_bundle.h:29,
from tensorflow_serving/session_bundle/session_bundle.cc:16:
bazel-out/local-fastbuild/genfiles/external/org_tensorflow/tensorflow/contrib/session_bundle/manifest.pb.h:237:7: note: 'tensorflow::contrib::AssetFile'
class AssetFile : public ::google::protobuf::Message {
^
tensorflow_serving/session_bundle/session_bundle.cc:68:58: error: template argument 1 is invalid
const std::vector<AssetFile>& asset_files,
^
tensorflow_serving/session_bundle/session_bundle.cc:68:58: error: template argument 2 is invalid
tensorflow_serving/session_bundle/session_bundle.cc: In function 'void tensorflow::serving::{anonymous}::AddAssetsTensorsToInputs(tensorflow::StringPiece, const int&, std::vector<std::pair<std::basic_string<char>, tensorflow::Tensor> >*)':
tensorflow_serving/session_bundle/session_bundle.cc:70:20: error: request for member 'empty' in 'asset_files', which is of non-class type 'const int'
if (!asset_files.empty()) {
^
tensorflow_serving/session_bundle/session_bundle.cc:71:24: error: no matching function for call to 'begin(const int&)'
for (auto& asset : asset_files) {
^
tensorflow_serving/session_bundle/session_bundle.cc:71:24: note: candidates are:
In file included from /usr/include/c++/4.8/string:51:0,
from /usr/include/c++/4.8/stdexcept:39,
from /usr/include/c++/4.8/array:38,
from /usr/include/c++/4.8/tuple:39,
from /usr/include/c++/4.8/functional:55,
from /usr/include/c++/4.8/memory:79,
from ./tensorflow_serving/session_bundle/session_bundle.h:21,
from tensorflow_serving/session_bundle/session_bundle.cc:16:
/usr/include/c++/4.8/bits/range_access.h:87:5: note: template<class _Tp, long unsigned int _Nm> _Tp* std::begin(_Tp (&)[_Nm])
begin(_Tp (&__arr)[_Nm])
^
/usr/include/c++/4.8/bits/range_access.h:87:5: note: template argument deduction/substitution failed:
tensorflow_serving/session_bundle/session_bundle.cc:71:24: note: mismatched types '_Tp [_Nm]' and 'const int'
for (auto& asset : asset_files) {
^
In file included from /usr/include/c++/4.8/string:51:0,
from /usr/include/c++/4.8/stdexcept:39,
from /usr/include/c++/4.8/array:38,
from /usr/include/c++/4.8/tuple:39,
from /usr/include/c++/4.8/functional:55,
from /usr/include/c++/4.8/memory:79,
from ./tensorflow_serving/session_bundle/session_bundle.h:21,
from tensorflow_serving/session_bundle/session_bundle.cc:16:
/usr/include/c++/4.8/bits/range_access.h:58:5: note: template<class _Container> decltype (__cont.begin()) std::begin(const _Container&)
begin(const _Container& __cont) -> decltype(__cont.begin())
^
/usr/include/c++/4.8/bits/range_access.h:58:5: note: template argument deduction/substitution failed:
/usr/include/c++/4.8/bits/range_access.h: In substitution of 'template<class _Container> decltype (__cont.begin()) std::begin(const _Container&) [with _Container = int]':
tensorflow_serving/session_bundle/session_bundle.cc:71:24: required from here
/usr/include/c++/4.8/bits/range_access.h:58:5: error: request for member 'begin' in '__cont', which is of non-class type 'const int'
/usr/include/c++/4.8/bits/range_access.h:48:5: note: template<class _Container> decltype (__cont.begin()) std::begin(_Container&)
begin(_Container& __cont) -> decltype(__cont.begin())
^
/usr/include/c++/4.8/bits/range_access.h:48:5: note: template argument deduction/substitution failed:
/usr/include/c++/4.8/bits/range_access.h: In substitution of 'template<class _Container> decltype (__cont.begin()) std::begin(_Container&) [with _Container = const int]':
tensorflow_serving/session_bundle/session_bundle.cc:71:24: required from here
/usr/include/c++/4.8/bits/range_access.h:48:5: error: request for member 'begin' in '__cont', which is of non-class type 'const int'
In file included from /usr/include/c++/4.8/utility:74:0,
from /usr/include/c++/4.8/tuple:38,
from /usr/include/c++/4.8/functional:55,
from /usr/include/c++/4.8/memory:79,
from ./tensorflow_serving/session_bundle/session_bundle.h:21,
from tensorflow_serving/session_bundle/session_bundle.cc:16:
/usr/include/c++/4.8/initializer_list:89:5: note: template<class _Tp> constexpr const _Tp* std::begin(std::initializer_list<_Tp>)
begin(initializer_list<_Tp> __ils) noexcept
^
/usr/include/c++/4.8/initializer_list:89:5: note: template argument deduction/substitution failed:
tensorflow_serving/session_bundle/session_bundle.cc:71:24: note: mismatched types 'std::initializer_list<_Tp>' and 'int'
for (auto& asset : asset_files) {
^
tensorflow_serving/session_bundle/session_bundle.cc:71:24: error: no matching function for call to 'end(const int&)'
tensorflow_serving/session_bundle/session_bundle.cc:71:24: note: candidates are:
In file included from /usr/include/c++/4.8/string:51:0,
from /usr/include/c++/4.8/stdexcept:39,
from /usr/include/c++/4.8/array:38,
from /usr/include/c++/4.8/tuple:39,
from /usr/include/c++/4.8/functional:55,
from /usr/include/c++/4.8/memory:79,
from ./tensorflow_serving/session_bundle/session_bundle.h:21,
from tensorflow_serving/session_bundle/session_bundle.cc:16:
/usr/include/c++/4.8/bits/range_access.h:97:5: note: template<class _Tp, long unsigned int _Nm> _Tp* std::end(_Tp (&)[_Nm])
end(_Tp (&__arr)[_Nm])
^
/usr/include/c++/4.8/bits/range_access.h:97:5: note: template argument deduction/substitution failed:
tensorflow_serving/session_bundle/session_bundle.cc:71:24: note: mismatched types '_Tp [_Nm]' and 'const int'
for (auto& asset : asset_files) {
^
In file included from /usr/include/c++/4.8/string:51:0,
from /usr/include/c++/4.8/stdexcept:39,
from /usr/include/c++/4.8/array:38,
from /usr/include/c++/4.8/tuple:39,
from /usr/include/c++/4.8/functional:55,
from /usr/include/c++/4.8/memory:79,
from ./tensorflow_serving/session_bundle/session_bundle.h:21,
from tensorflow_serving/session_bundle/session_bundle.cc:16:
/usr/include/c++/4.8/bits/range_access.h:78:5: note: template<class _Container> decltype (__cont.end()) std::end(const _Container&)
end(const _Container& __cont) -> decltype(__cont.end())
^
/usr/include/c++/4.8/bits/range_access.h:78:5: note: template argument deduction/substitution failed:
/usr/include/c++/4.8/bits/range_access.h: In substitution of 'template<class _Container> decltype (__cont.end()) std::end(const _Container&) [with _Container = int]':
tensorflow_serving/session_bundle/session_bundle.cc:71:24: required from here
/usr/include/c++/4.8/bits/range_access.h:78:5: error: request for member 'end' in '__cont', which is of non-class type 'const int'
/usr/include/c++/4.8/bits/range_access.h:68:5: note: template<class _Container> decltype (__cont.end()) std::end(_Container&)
end(_Container& __cont) -> decltype(__cont.end())
^
/usr/include/c++/4.8/bits/range_access.h:68:5: note: template argument deduction/substitution failed:
/usr/include/c++/4.8/bits/range_access.h: In substitution of 'template<class _Container> decltype (__cont.end()) std::end(_Container&) [with _Container = const int]':
tensorflow_serving/session_bundle/session_bundle.cc:71:24: required from here
/usr/include/c++/4.8/bits/range_access.h:68:5: error: request for member 'end' in '__cont', which is of non-class type 'const int'
In file included from /usr/include/c++/4.8/utility:74:0,
from /usr/include/c++/4.8/tuple:38,
from /usr/include/c++/4.8/functional:55,
from /usr/include/c++/4.8/memory:79,
from ./tensorflow_serving/session_bundle/session_bundle.h:21,
from tensorflow_serving/session_bundle/session_bundle.cc:16:
/usr/include/c++/4.8/initializer_list:99:5: note: template<class _Tp> constexpr const _Tp* std::end(std::initializer_list<_Tp>)
end(initializer_list<_Tp> __ils) noexcept
^
/usr/include/c++/4.8/initializer_list:99:5: note: template argument deduction/substitution failed:
tensorflow_serving/session_bundle/session_bundle.cc:71:24: note: mismatched types 'std::initializer_list<_Tp>' and 'int'
for (auto& asset : asset_files) {
^
tensorflow_serving/session_bundle/session_bundle.cc:76:69: error: no matching function for call to 'std::vector<std::pair<std::basic_string<char>, tensorflow::Tensor> >::push_back(<brace-enclosed initializer list>)'
{asset.tensor_binding().tensor_name(), assets_file_tensor});
^
tensorflow_serving/session_bundle/session_bundle.cc:76:69: note: candidates are:
In file included from /usr/include/c++/4.8/vector:64:0,
from external/protobuf/src/google/protobuf/unknown_field_set.h:43,
from external/protobuf/src/google/protobuf/metadata.h:43,
from bazel-out/local-fastbuild/genfiles/external/org_tensorflow/tensorflow/core/lib/core/error_codes.pb.h:25,
from external/org_tensorflow/tensorflow/core/lib/core/status.h:22,
from ./tensorflow_serving/session_bundle/session_bundle.h:23,
from tensorflow_serving/session_bundle/session_bundle.cc:16:
/usr/include/c++/4.8/bits/stl_vector.h:901:7: note: void std::vector<_Tp, _Alloc>::push_back(const value_type&) [with _Tp = std::pair<std::basic_string<char>, tensorflow::Tensor>; _Alloc = std::allocator<std::pair<std::basic_string<char>, tensorflow::Tensor> >; std::vector<_Tp, _Alloc>::value_type = std::pair<std::basic_string<char>, tensorflow::Tensor>]
push_back(const value_type& __x)
^
/usr/include/c++/4.8/bits/stl_vector.h:901:7: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'const value_type& {aka const std::pair<std::basic_string<char>, tensorflow::Tensor>&}'
/usr/include/c++/4.8/bits/stl_vector.h:919:7: note: void std::vector<_Tp, _Alloc>::push_back(std::vector<_Tp, _Alloc>::value_type&&) [with _Tp = std::pair<std::basic_string<char>, tensorflow::Tensor>; _Alloc = std::allocator<std::pair<std::basic_string<char>, tensorflow::Tensor> >; std::vector<_Tp, _Alloc>::value_type = std::pair<std::basic_string<char>, tensorflow::Tensor>]
push_back(value_type&& __x)
^
/usr/include/c++/4.8/bits/stl_vector.h:919:7: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'std::vector<std::pair<std::basic_string<char>, tensorflow::Tensor> >::value_type&& {aka std::pair<std::basic_string<char>, tensorflow::Tensor>&&}'
tensorflow_serving/session_bundle/session_bundle.cc: At global scope:
tensorflow_serving/session_bundle/session_bundle.cc:103:39: error: 'AssetFile' was not declared in this scope
const std::vector<AssetFile>& asset_files,
^
tensorflow_serving/session_bundle/session_bundle.cc:103:39: note: suggested alternative:
In file included from ./tensorflow_serving/session_bundle/manifest.pb.h:19:0,
from ./tensorflow_serving/session_bundle/session_bundle.h:29,
from tensorflow_serving/session_bundle/session_bundle.cc:16:
bazel-out/local-fastbuild/genfiles/external/org_tensorflow/tensorflow/contrib/session_bundle/manifest.pb.h:237:7: note: 'tensorflow::contrib::AssetFile'
class AssetFile : public ::google::protobuf::Message {
^
tensorflow_serving/session_bundle/session_bundle.cc:103:48: error: template argument 1 is invalid
const std::vector<AssetFile>& asset_files,
^
tensorflow_serving/session_bundle/session_bundle.cc:103:48: error: template argument 2 is invalid
tensorflow_serving/session_bundle/session_bundle.cc:117:36: error: 'AssetFile' was not declared in this scope
const std::vector<AssetFile>& asset_files,
^
tensorflow_serving/session_bundle/session_bundle.cc:117:36: note: suggested alternative:
In file included from ./tensorflow_serving/session_bundle/manifest.pb.h:19:0,
from ./tensorflow_serving/session_bundle/session_bundle.h:29,
from tensorflow_serving/session_bundle/session_bundle.cc:16:
bazel-out/local-fastbuild/genfiles/external/org_tensorflow/tensorflow/contrib/session_bundle/manifest.pb.h:237:7: note: 'tensorflow::contrib::AssetFile'
class AssetFile : public ::google::protobuf::Message {
^
tensorflow_serving/session_bundle/session_bundle.cc:117:45: error: template argument 1 is invalid
const std::vector<AssetFile>& asset_files,
^
tensorflow_serving/session_bundle/session_bundle.cc:117:45: error: template argument 2 is invalid
tensorflow_serving/session_bundle/session_bundle.cc: In function 'tensorflow::Status tensorflow::serving::LoadSessionBundleFromPath(const tensorflow::SessionOptions&, tensorflow::StringPiece, tensorflow::serving::SessionBundle*)':
tensorflow_serving/session_bundle/session_bundle.cc:165:15: error: 'AssetFile' was not declared in this scope
std::vector<AssetFile> asset_files;
^
tensorflow_serving/session_bundle/session_bundle.cc:165:15: note: suggested alternative:
In file included from ./tensorflow_serving/session_bundle/manifest.pb.h:19:0,
from ./tensorflow_serving/session_bundle/session_bundle.h:29,
from tensorflow_serving/session_bundle/session_bundle.cc:16:
bazel-out/local-fastbuild/genfiles/external/org_tensorflow/tensorflow/contrib/session_bundle/manifest.pb.h:237:7: note: 'tensorflow::contrib::AssetFile'
class AssetFile : public ::google::protobuf::Message {
^
tensorflow_serving/session_bundle/session_bundle.cc:165:24: error: template argument 1 is invalid
std::vector<AssetFile> asset_files;
^
tensorflow_serving/session_bundle/session_bundle.cc:165:24: error: template argument 2 is invalid
tensorflow_serving/session_bundle/session_bundle.cc:165:37: error: invalid type in declaration before ';' token
std::vector<AssetFile> asset_files;
^
tensorflow_serving/session_bundle/session_bundle.cc:170:17: error: expected ';' before 'asset_file'
AssetFile asset_file;
^
tensorflow_serving/session_bundle/session_bundle.cc:171:25: error: the value of 'AssetFile' is not usable in a constant expression
if (!any_asset.Is<AssetFile>()) {
^
tensorflow_serving/session_bundle/session_bundle.cc:165:15: note: 'AssetFile' was not declared 'constexpr'
std::vector<AssetFile> asset_files;
^
tensorflow_serving/session_bundle/session_bundle.cc:171:36: error: no matching function for call to 'google::protobuf::Any::Is() const'
if (!any_asset.Is<AssetFile>()) {
^
tensorflow_serving/session_bundle/session_bundle.cc:171:36: note: candidate is:
In file included from bazel-out/local-fastbuild/genfiles/external/org_tensorflow/tensorflow/core/protobuf/meta_graph.pb.h:32:0,
from ./tensorflow_serving/session_bundle/session_bundle.h:25,
from tensorflow_serving/session_bundle/session_bundle.cc:16:
external/protobuf/src/google/protobuf/any.pb.h:66:29: note: template<class T> bool google::protobuf::Any::Is() const
template<typename T> bool Is() const {
^
external/protobuf/src/google/protobuf/any.pb.h:66:29: note: template argument deduction/substitution failed:
tensorflow_serving/session_bundle/session_bundle.cc:174:13: error: 'asset_file' was not declared in this scope
asset_file.descriptor()->full_name(), ". Got: ",
^
tensorflow_serving/session_bundle/session_bundle.cc:178:32: error: 'asset_file' was not declared in this scope
if (!any_asset.UnpackTo(&asset_file)) {
^
tensorflow_serving/session_bundle/session_bundle.cc:182:19: error: request for member 'push_back' in 'asset_files', which is of non-class type 'int'
asset_files.push_back(asset_file);
^
tensorflow_serving/session_bundle/session_bundle.cc:182:29: error: 'asset_file' was not declared in this scope
asset_files.push_back(asset_file);
^
Target //tensorflow_serving/example:mnist_inference_2 failed to build
Use --verbose_failures to see the command lines of failed build steps.
INFO: Elapsed time: 4.822s, Critical Path: 4.54s
From the page you linked: "Before getting started, please complete the prerequisites."
The type Signatures is defined in a header generated by following said prereqs process, so you've either not followed those steps or not followed them correctly – there's no way to tell which just from the compiler errors.

boost log error when used in a project

I compiled Boost 1.54 on my Debian 7 64 bit Linux box and installed it successfully.
However, when trying to use it in my project I'm getting a huge bunch of errors (Full dump is here: http://pastebin.com/zUTcb7vp).
I tried creating a simple test app, which is below (saved in main.cpp):
#include <boost/log/trivial.hpp>
#include <boost/log/utility/init/to_file.hpp>
int main(int, char*[])
{
BOOST_LOG_TRIVIAL(trace) << " a trace message ";
}
This also fails to compile. I get the following errors (too many characters for stack overflow to handle - full stacktrace here: http://pastebin.com/xiXZZVYb):
g++ -o build/main.o -c -std=c++11 -Wall -g -O0 src/main.cpp
In file included from /usr/local/include/boost/log/utility/init/to_file.hpp:31:0,
from src/main.cpp:2:
/usr/local/include/boost/log/detail/prologue.hpp:253:36: error: declaration of namespace ‘boost::log’ conflicts with
In file included from /usr/local/include/boost/log/trivial.hpp:20:0,
from src/main.cpp:1:
/usr/local/include/boost/log/detail/config.hpp:371:15: error: previous declaration of namespace ‘boost::log’ here
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:59:20: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:59:20: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:59:43: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp: In function ‘int boost::log2_mt_posix::aux::setup_file_collector(const ArgsT&, const true_&)’:
/usr/local/include/boost/log/utility/init/to_file.hpp:61:24: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:61:24: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:61:47: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp: At global scope:
/usr/local/include/boost/log/utility/init/to_file.hpp:64:20: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:64:20: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:64:43: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp: In function ‘int boost::log2_mt_posix::aux::setup_file_collector(const ArgsT&, const false_&)’:
/usr/local/include/boost/log/utility/init/to_file.hpp:66:12: error: ‘sinks’ has not been declared
/usr/local/include/boost/log/utility/init/to_file.hpp: At global scope:
/usr/local/include/boost/log/utility/init/to_file.hpp:72:5: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:72:5: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:75:1: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp: In function ‘int boost::log2_mt_posix::aux::init_log_to_file(const ArgsT&)’:
/usr/local/include/boost/log/utility/init/to_file.hpp:77:13: error: ‘sinks’ does not name a type
/usr/local/include/boost/log/utility/init/to_file.hpp:78:17: error: ‘backend_t’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:78:27: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp:78:38: error: invalid type in declaration before ‘=’ token
/usr/local/include/boost/log/utility/init/to_file.hpp:78:60: error: the value of ‘backend_t’ is not usable in a constant expression
/usr/local/include/boost/log/utility/init/to_file.hpp:78:17: note: ‘backend_t’ was not declared ‘constexpr’
/usr/local/include/boost/log/utility/init/to_file.hpp:80:17: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:80:17: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:80:40: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp:80:53: error: invalid type in declaration before ‘=’ token
/usr/local/include/boost/log/utility/init/to_file.hpp:81:63: error: ‘keywords’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:81:63: note: suggested alternatives:
In file included from /usr/local/include/boost/log/trivial.hpp:21:0,
from src/main.cpp:1:
/usr/local/include/boost/log/keywords/severity.hpp:29:20: note: ‘boost::log::v2s_mt_posix::keywords’
/usr/local/include/boost/log/keywords/severity.hpp:29:20: note: ‘boost::log::v2s_mt_posix::keywords’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:81:91: error: template argument 2 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp:81:99: error: expected ‘(’ before ‘>’ token
/usr/local/include/boost/log/utility/init/to_file.hpp:81:99: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp:84:17: error: base operand of ‘->’ is not a pointer
/usr/local/include/boost/log/utility/init/to_file.hpp:85:17: error: base operand of ‘->’ is not a pointer
/usr/local/include/boost/log/utility/init/to_file.hpp:85:39: error: ‘keywords’ is not a class, namespace, or enumeration
/usr/local/include/boost/log/utility/init/to_file.hpp:85:63: error: ‘sinks’ is not a class, namespace, or enumeration
/usr/local/include/boost/log/utility/init/to_file.hpp:88:17: error: the value of ‘sinks’ is not usable in a constant expression
/usr/local/include/boost/log/utility/init/to_file.hpp:80:17: note: ‘sinks’ was not declared ‘constexpr’
/usr/local/include/boost/log/utility/init/to_file.hpp:88:68: error: type/value mismatch at argument 1 in template parameter list for ‘template<class T> class boost::shared_ptr’
/usr/local/include/boost/log/utility/init/to_file.hpp:88:68: error: expected a type, got ‘sinks’
/usr/local/include/boost/log/utility/init/to_file.hpp:88:76: error: invalid type in declaration before ‘=’ token
/usr/local/include/boost/log/utility/init/to_file.hpp:89:29: error: the value of ‘sinks’ is not usable in a constant expression
/usr/local/include/boost/log/utility/init/to_file.hpp:80:17: note: ‘sinks’ was not declared ‘constexpr’
/usr/local/include/boost/log/utility/init/to_file.hpp:89:16: error: parse error in template argument list
/usr/local/include/boost/log/utility/init/to_file.hpp:89:90: error: no matching function for call to ‘make_shared(int&)’
/usr/local/include/boost/log/utility/init/to_file.hpp:89:90: note: candidates are:
In file included from /usr/local/include/boost/smart_ptr/make_shared.hpp:15:0,
from /usr/local/include/boost/make_shared.hpp:15,
from /usr/local/include/boost/log/utility/init/to_file.hpp:23,
from src/main.cpp:2:
/usr/local/include/boost/smart_ptr/make_shared_object.hpp:138:72: note: template<class T> typename boost::detail::sp_if_not_array::type boost::make_shared()
/usr/local/include/boost/smart_ptr/make_shared_object.hpp:138:72: note: template argument deduction/substitution failed:
In file included from /usr/local/include/boost/smart_ptr/make_shared.hpp:15:0,
from /usr/local/include/boost/make_shared.hpp:15,
from /usr/local/include/boost/log/utility/init/to_file.hpp:23,
from src/main.cpp:2:
/usr/local/include/boost/smart_ptr/make_shared_object.hpp:210:99: note: template<class T, class Arg1, class ... Args> typename boost::detail::sp_if_not_array<T>::type boost::make_shared(Arg1&&, Args&& ...)
/usr/local/include/boost/smart_ptr/make_shared_object.hpp:210:99: note: template argument deduction/substitution failed:
In file included from /usr/local/include/boost/smart_ptr/make_shared.hpp:18:0,
from /usr/local/include/boost/make_shared.hpp:15,
from /usr/local/include/boost/log/utility/init/to_file.hpp:23,
from src/main.cpp:2:
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:24:5: note: template<class T> typename boost::detail::sp_if_array::type boost::make_shared(std::size_t)
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:24:5: note: template argument deduction/substitution failed:
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:42:5: note: template<class T, class ... Args> typename boost::detail::sp_if_array<T>::type boost::make_shared(std::size_t, Args&& ...)
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:42:5: note: template argument deduction/substitution failed:
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:59:5: note: template<class T, class ... Args> typename boost::detail::sp_if_size_array<T>::type boost::make_shared(Args&& ...)
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:59:5: note: template argument deduction/substitution failed:
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:80:5: note: template<class T> typename boost::detail::sp_if_size_array::type boost::make_shared(const T&)
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:80:5: note: template argument deduction/substitution failed:
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:102:5: note: template<class T> typename boost::detail::sp_if_array::type boost::make_shared(std::size_t, const typename boost::detail::array_inner<T>::type&)
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:102:5: note: template argument deduction/substitution failed:
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:126:5: note: template<class T> typename boost::detail::sp_if_size_array::type boost::make_shared(const typename boost::detail::array_inner<T>::type&)
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:126:5: note: template argument deduction/substitution failed:
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:150:5: note: template<class T> typename boost::detail::sp_if_array::type boost::make_shared(std::initializer_list<typename boost::detail::array_inner<T>::type>)
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:150:5: note: template argument deduction/substitution failed:
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:172:5: note: template<class T> typename boost::detail::sp_if_array::type boost::make_shared(std::size_t, typename boost::detail::array_base<T>::type&&)
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:172:5: note: template argument deduction/substitution failed:
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:190:5: note: template<class T> typename boost::detail::sp_if_size_array::type boost::make_shared(typename boost::detail::array_base<T>::type&&)
/usr/local/include/boost/smart_ptr/make_shared_array.hpp:190:5: note: template argument deduction/substitution failed:
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:91:5: error: ‘setup_filter’ is not a member of ‘boost::log2_mt_posix::aux’
/usr/local/include/boost/log/utility/init/to_file.hpp:91:5: note: suggested alternative:
...
...
TO MANY CHARACTERS - HAD TO TRUNCATE IT DOWN
...
...
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: template argument 1 is invalid
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: ‘sinks’ was not declared in this scope
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: note: suggested alternatives:
In file included from /usr/local/include/boost/log/sources/basic_logger.hpp:38:0,
from /usr/local/include/boost/log/sources/severity_logger.hpp:23,
from /usr/local/include/boost/log/trivial.hpp:22,
from src/main.cpp:1:
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
/usr/local/include/boost/log/core/core.hpp:41:17: note: ‘boost::log::v2s_mt_posix::sinks’
In file included from src/main.cpp:2:0:
/usr/local/include/boost/log/utility/init/to_file.hpp:170:1: error: template argument 1 is invalid
I removed the #include <boost/log/utility/init/to_file.hpp> line, but it still fails to compile.
Anyone have any idea what the heck is going on?
Turns out, I needed to delete the previous Boost files in /usr/local/include/boost and /usr/local/lib/libboost*, then install the new version.
Also, I had to define BOOST_LOG_DYN_LINK in my cpp file (so that my application would dynamically link with Boost Log - I guess I built it as a shared library? I'm not sure why it wouldn't just work with static linking or dynamic linking on its own, but it didn't).
Thanks to Andysem on the boost bug tracker (https://svn.boost.org/trac/boost/ticket/8866).