Fehler "undefined reference ... " trotz eingebundener Headerdatei

Udo Gerhards <[email protected]>
Newsgroups gmane.linux.suse.programming
Organization ...
Message-ID <[email protected]>
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hallo zusammen,

ich schreib mir gerade ein Programm in C++ ein eigenes Programm zur 
Überwachung von Netzwerkadressen. Allerdings kriege ich beim Compilieren 
immer folgende Fehlermeldungen:

- ---------------------------Fehler--------------------------

*g++ -lpcap -lmysqlclient -o nwarp nwarp.o nw_standarts.o nw_database.o 
nw_device.o nw_dev_storage.o -L/usr/lib/ -L/usr/lib/qt3/lib/ 
- -L/usr/X11R6/lib/ -lqt-mt -lXext -lX11 -lm -lpthread 
*nw_device.o(.text+0x7a): In function `nw_device::nw_device[not-in-charge]
(char*, char*, char*, nw_sniff_count, int)': 
*: undefined reference to `nw_queue<nw_sniff_host>::nw_queue[in-charge](int)' 
*nw_device.o(.text+0x1ca): In function `nw_device::nw_device[in-charge](char*, 
char*, char*, nw_sniff_count, int)': 
*: undefined reference to `nw_queue<nw_sniff_host>::nw_queue[in-charge](int)' 
*nw_device.o(.text+0x320): In function `nw_device::nw_device[not-in-charge
](nw_device const&)': 
*: undefined reference to `nw_queue<nw_sniff_host>::nw_queue[in-charge]
(nw_queue<nw_sniff_host> const&)' 
*nw_device.o(.text+0x490): In function `nw_device::nw_device[in-charge]
(nw_device const&)': 
*: undefined reference to `nw_queue<nw_sniff_host>::nw_queue[in-charge]
(nw_queue<nw_sniff_host> const&)' 
*nw_device.o(.text+0x5b7): In function `nw_device::~nw_device [not-in-charge]
()':
...

- --------------------------------------------------------------

Soweit ich das jetzt verstehe, ist in dem File die Deklaration der 
Templateklasse "nw_queue<nw_sniff_host>" nicht bekannt, obwohl ich die 
Headerdatei, in der die Klasse deklariert wird, über #include "....." 
eingebunden habe und "nw_queue<nw_sniff_host>" eigentlich bekannt sein 
sollte.

Wenn Ihr wollt, kann ich Euch auch mal die betreffenden Deklarationen beider 
Klassen posten.

Gruß

Udo

- -- 
- -------------------------------------------------------------------------------------------------
                                          Wir sind Bill Gates! 
Widerstand ist zwecklos! Sie werden assimiliert! Ihre Datenbestände werden den 
unseren hinzugefügt!
- -------------------------------------------------------------------------------------------------

- -- 
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)

iD8DBQFBXVAvw91zS84Ugh8RAhaGAJoDh8fvfyDHmvYNsT9BjLYpRr9R1QCdExLa
reVEivf8z11+DzKCxMAKIAU=
=d/oH
-----END PGP SIGNATURE-----

-- 
Um die Liste abzubestellen, schicken Sie eine Mail an:
    [email protected]
Um eine Liste aller verfügbaren Kommandos zu bekommen, schicken
Sie eine Mail an: [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.