Добрый день! такая проблема, не могу подключить класс и создать бинарник.
test.h
#ifndef _test_h_
#define _test_h_
class test
{
public:
test ();
void show();
private:
};
#endif
test.cpp
#include "test.h"
#include
test::test(){}
void test::show(){
std::cout
main.cpp
#include "test.h"
int main (int argc, char const* argv[])
{
test t();
t.show();
return 0;
}
g++ -o bin main.cpp выводит /tmp/ccmd32Df.o: In function main': main.cpp:(.text+0x2c): undefined reference totest::test()' main.cpp:(.text+0x3b): undefined reference to `test::show()' collect2: error: ld returned 1 exit status