LNode:链接列表节点
LList:链接列表
Eleman:链接列表值类型
Kontrol:所有主要代码
程序:main,包含kontrol()
g++ -I "./include" -c ./src/Program.cpp -o ./lib/Program.o
g++ ./lib/LNode.o ./lib/LListe.o ./lib/Kontrol.o ./lib/Program.o ./lib/Eleman.o -o ./bin/program
./lib/Kontrol.o:Kontrol.cpp:(.text+0x3e): undefined reference to `LListe<Eleman>::LListe()'
./lib/Kontrol.o:Kontrol.cpp:(.text+0x1ad): undefined reference to `LListe<Eleman>::pushBack(Eleman
const&)'
./lib/Kontrol.o:Kontrol.cpp:(.text+0x1de): undefined reference to `LListe<Eleman>::end()'
./lib/Kontrol.o:Kontrol.cpp:(.text+0x2fc): undefined reference to `LListe<Eleman>::pushBack(Eleman
const&)'
./lib/Kontrol.o:Kontrol.cpp:(.text+0x3fa): undefined reference to `LListe<Eleman>::pushBack(Eleman
const&)'
./lib/Kontrol.o:Kontrol.cpp:(.text+0x44e): undefined reference to `LListe<Eleman>::end()'
./lib/Kontrol.o:Kontrol.cpp:(.text+0x587): undefined reference to `LListe<Eleman>::pushBack(Eleman
const&)'
./lib/Kontrol.o:Kontrol.cpp:(.text+0x68e): undefined reference to `LListe<Eleman>::pushBack(Eleman
const&)'
./lib/Kontrol.o:Kontrol.cpp:(.text+0x711): undefined reference to `LListe<Eleman>::begin()'
collect2.exe: error: ld returned 1 exit status
Makefile:3: recipe for target 'program' failed
mingw32-make: *** [program] Error 1
对LListe :: LListe()的未定义引用
我假设LListe是在src / LListe.cpp中实现的模板? LListe.o在第二行中提供给g ++,但在那里有些不起作用