0

i found msoftcon.h on the book and added. when i run below program
on dev c compiler

linker error undefined reference to set_color(color,color)
linker error undefined reference to set_fill_style

linker error undefined reference to draw_circle

linker error undefined reference to init graphics

#include <cstdlib>
#include <iostream>
#include <msoftcon.h>

using namespace std;

struct daire
{
       int x,y;
       int r;
       color fillcolor;
       fstyle fillstyle;
        };
       
void bbbb_draw(daire c)
{
     set_color(c.fillcolor);
     set_fill_style(c.fillstyle);
     draw_circle(c.x,c.y,c.r);
}

int main(int argc, char *argv[])
{
    init_graphics();
    daire c1={1,5,25,cBLUE,X_FILL};
    bbbb_draw(c1);
    system("PAUSE");
    return EXIT_SUCCESS;
}
2
Contributors
2
Replies
5
Views
7 Years
Discussion Span
Last Post by burcin erek
0

There should be a file probably called msoftcon.cpp that you need to include in your project. These functions are not defined in the file you have posted, so you can't use them unless you link to the file that defines them.

0

thank you I did as you said. linker error eliminated
I faced with this error
"C:\Dev-Cpp\Makefile.win [Build Error] [new.o] Error 1 " what is it for _?

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.