From owner-freebsd-questions Thu Oct 12 11:15:55 2000 Delivered-To: freebsd-questions@freebsd.org Received: from gateway.telecom.ksu.edu (gateway-1.telecom.ksu.edu [129.130.63.239]) by hub.freebsd.org (Postfix) with ESMTP id 0B0A537B502 for ; Thu, 12 Oct 2000 11:15:46 -0700 (PDT) Received: from sioux.telecom.ksu.edu(129.130.60.32) by pawnee.telecom.ksu.edu via smap (V2.0) id xma009228; Thu, 12 Oct 00 13:15:21 -0500 Message-ID: <39E5FFA3.9DE8D056@telecom.ksu.edu> Date: Thu, 12 Oct 2000 13:14:59 -0500 From: nathan X-Mailer: Mozilla 4.7 [en] (X11; U; FreeBSD 4.1-STABLE i386) X-Accept-Language: en MIME-Version: 1.0 To: "freebsd-questions@freebsd.org" Subject: c++/qt lib compile error Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG I know this isn't fbsd specific but... i'm tryin to follow a qt tutorial to get started with the qt libraries. when tryin to compile 'hello world' : --snip-- #include #include int main( int argc, char **argv ) { QApplication a( argc, argv ); QPushButton hello( "Hello world!", 0 ); hello.resize( 100, 30 ); a.setMainWidget( &hello ); hello.show(); return a.exec(); } --snip-- i get this: --snip-- [nathan@sabre src]$ g++ -I/usr/local/qt/include hello_qt.cc /tmp/ccJ85228.o: In function `main': /tmp/ccJ85228.o(.text+0x28): undefined reference to `QApplication::QApplication(int &, char **)' /tmp/ccJ85228.o(.text+0x3f): undefined reference to `QApplication::~QApplication(void)' /tmp/ccJ85228.o(.text+0x5e): undefined reference to `QString::QString(char const *)' /tmp/ccJ85228.o(.text+0xa8): undefined reference to `QPushButton::QPushButton(QString const &, QWidget *, char const *)' /tmp/ccJ85228.o(.text+0xe7): undefined reference to `QPushButton::~QPushButton(void)' /tmp/ccJ85228.o(.text+0x10e): undefined reference to `QPushButton::resize(int, int)' /tmp/ccJ85228.o(.text+0x124): undefined reference to `QApplication::setMainWidget(QWidget *)' /tmp/ccJ85228.o(.text+0x136): undefined reference to `QWidget::show(void)' /tmp/ccJ85228.o(.text+0x145): undefined reference to `QApplication::exec(void)' /tmp/ccJ85228.o(.text+0x169): undefined reference to `QPushButton::~QPushButton(void)' /tmp/ccJ85228.o(.text+0x188): undefined reference to `QApplication::~QApplication(void)' /tmp/ccJ85228.o: In function `QString::~QString(void)': /tmp/ccJ85228.o(.gnu.linkonce.t._$_7QString+0x29): undefined reference to `QStringData::deleteSelf(void)' [nathan@sabre src]$ --snip-- i've looked in my -I arg dir and it DOES contain the .h files in the source. what gives? To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message