I am trying to compile hosts3d from sourceforge and it compiles, but generates some narrowing errors. I do not know how to fix this, but any help would be greatly appreciated. I suspect that I can download the previous version of the compiler, and I can finish this, but for now ... C ++ 11
g ++ -Wall -O2 -c -o src / glwin.o src / glwin.cpp src / glwin.cpp: in the member function 'int MyGLWin :: AddInput (int, int, unsigned int, int, const char *, bool ) ': src / glwin.cpp: 983: 147: warning: narrowing conversion "max" from "int" to "unsigned int" inside {} poorly formed in C ++ 11 [-Wnarrowing] glin_obj glin = {GLWIN_INPUT , lastWin , lower, names ++, left, top, cwidth, strlen (text), (strlen (text)> cwidth? strlen (text) - cwidth: 0), max};
int MyGLWin::AddInput(int left, int top, unsigned int cwidth, int max, const char *text, bool lower)
{
if (!lastWin) return -1;
glin_obj glin = {GLWIN_INPUT, lastWin, lower, names++, left, top, cwidth, strlen(text), (strlen(text) > cwidth ? strlen(text) - cwidth : 0), max};
strcpy(glin.text, text);
currInput = glin.name;
lastInput = (glin_obj *)GLWinLL.Write(new glin_obj(glin));
return glin.name;
}