Code::Blocks

User forums => Help => Topic started by: Rbt618 on December 14, 2019, 07:12:06 am

Title: Linker Problem
Post by: Rbt618 on December 14, 2019, 07:12:06 am
I am assuming I have a linker problem.
I run my program and get an "Undefined" function error.
But if I include the Implementation file on my main.cpp file then it will run. So I am assuming codeblocks is not linking the Header and the implementation files >> that's why I have to include the implementation file on main.cpp.
I use Ubuntu 18.04 and codeblocks 17.04.

Once I do include the implementation file on main.cpp, then my program runs perfectly. That's why I think its a Linker Error

Any Thoughts on resolving this??
Title: Re: Linker Problem
Post by: stahta01 on December 14, 2019, 07:22:16 am
Add the files to the CB Project.

Note: If you are not using a CB Project, then I suggest using one.

Edit: If you still have problems post a build log!
http://wiki.codeblocks.org/index.php?title=FAQ-Compiling_%28general%29#Q:_How_do_I_report_a_compilation_problem_on_the_forums.3F (http://wiki.codeblocks.org/index.php?title=FAQ-Compiling_%28general%29#Q:_How_do_I_report_a_compilation_problem_on_the_forums.3F)

Tim S.