Your code compiles and works under these gcc and g++ versions:

gcc (Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0

g++ (Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0

However, the message you are getting should just be a warning, not an error.

Did you remember to run ./configure && make && make install on libagar before using it in your IDE?


On 8/3/19 10:35 AM, Gavin M2301 wrote:
HI all-

I am getting this error message and am not sure why...I am running in mingw with U++ IDE. I am using g++ to compile.

C:\agar-1.5.0-mingw32-x86_64\include\agar/agar/core/object.h (311): warning: invalid conversion from 'void*' to 'AG_Variable*' {aka 'ag_variable*'} [-fpermissive]

I ran this code in my IDE: Any ideas?
thnx.

#include <iostream>
#include <agar/core.h>
#include <agar/gui.h>
int main(int argc, const char *argv[])
{
  AG_Window *win;
  if (AG_InitCore(NULL, 0) == -1 ||
      AG_InitGraphics(0) == -1)
   return (1);
  win = AG_WindowNew(AG_WINDOW_MAIN);
  AG_LabelNew(win, 0, "Hello, world!");
  AG_WindowShow(win);
  AG_EventLoop();
  return 0;

}



_______________________________________________
Agar mailing list
[email protected]
http://libagar.org/lists.html


_______________________________________________
Agar mailing list
[email protected]
http://libagar.org/lists.html

Reply via email to