From owner-freebsd-chat Fri Nov 8 9:32:45 2002 Delivered-To: freebsd-chat@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0381037B401; Fri, 8 Nov 2002 09:32:44 -0800 (PST) Received: from serenity.mcc.ac.uk (serenity.mcc.ac.uk [130.88.200.93]) by mx1.FreeBSD.org (Postfix) with ESMTP id 896AB43E6E; Fri, 8 Nov 2002 09:32:42 -0800 (PST) (envelope-from jcm@freebsd-uk.eu.org) Received: from dogma.freebsd-uk.eu.org ([130.88.200.97]) by serenity.mcc.ac.uk with esmtp (Exim 2.05 #6) id 18ACzk-000Eq2-00; Fri, 8 Nov 2002 17:32:36 +0000 Received: from dogma.freebsd-uk.eu.org (localhost [127.0.0.1]) by dogma.freebsd-uk.eu.org (8.12.3/8.11.1) with ESMTP id gA8HWZ9l082508; Fri, 8 Nov 2002 17:32:35 GMT (envelope-from jcm@dogma.freebsd-uk.eu.org) Received: (from jcm@localhost) by dogma.freebsd-uk.eu.org (8.12.3/8.12.3/Submit) id gA8HWZ75082507; Fri, 8 Nov 2002 17:32:35 GMT Date: Fri, 8 Nov 2002 17:32:35 +0000 From: Jonathon McKitrick To: freebsd-chat@freebsd.org, freebsd-questions@freebsd.org Subject: Unresolved reference compiling Objective-C ?? Message-ID: <20021108173235.GA82490@dogma.freebsd-uk.eu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4i Sender: owner-freebsd-chat@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org Hi all, I just compiled a 'hello world' in objective c on a box with gcc but no GNUstep. I'm using the compile command as I found it in the tutorial. Any idea what I did wrong? thanks, jonathon dogma:...files/programs/objc> gcc -lobjc main.m printer.m -o testme main.m: In function `main': main.m:4: warning: return type of `main' is not `int' /tmp/ccgeR5Vc.o: In function `main': /tmp/ccgeR5Vc.o(.text+0x28): undefined reference to `objc_get_class' /tmp/ccgeR5Vc.o(.text+0x33): undefined reference to `objc_msg_lookup' /tmp/ccgeR5Vc.o(.text+0x4b): undefined reference to `objc_msg_lookup' /tmp/ccgeR5Vc.o(.text+0x74): undefined reference to `objc_msg_lookup' /tmp/ccgeR5Vc.o(.text+0xa3): undefined reference to `objc_msg_lookup' /tmp/ccgeR5Vc.o(.text+0xd0): undefined reference to `objc_msg_lookup' /tmp/ccgeR5Vc.o: In function `global constructors keyed to main': /tmp/ccgeR5Vc.o(.text+0xff): undefined reference to `__objc_exec_class' /tmp/ccBL0eLu.o: In function `_i_Printer__init': /tmp/ccBL0eLu.o(.text+0x26): undefined reference to `objc_msg_lookup_super' /tmp/ccBL0eLu.o(.text+0x4d): undefined reference to `objc_msg_lookup' /tmp/ccBL0eLu.o: In function `_i_Printer__print': /tmp/ccBL0eLu.o(.text+0xc6): undefined reference to `objc_msg_lookup' /tmp/ccBL0eLu.o: In function `global constructors keyed to printer.m5B2iAd': /tmp/ccBL0eLu.o(.text+0x11f): undefined reference to `__objc_exec_class' /tmp/ccBL0eLu.o(.rodata+0x8): undefined reference to `__objc_class_name_Object' dogma: NOTE: Please CC me, as I am not currently subscribed. Thanks. jm -- My other computer is your windows box. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-chat" in the body of the message