[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Foundation.h help
From: |
address@hidden |
Subject: |
Re: Foundation.h help |
Date: |
Sun, 28 Nov 2010 23:41:37 -0800 (PST) |
User-agent: |
G2/1.0 |
On 29 Nov., 07:07, cbw2...@comcast.net wrote:
> Using a programming book, one of the exercises has me try
>
> #import <Foundation/Foundation.h>
> int main(int argc, const char * argv[])
>
> {
> NSAutoreleasePool * Pool = [NSAutoreleasePool alloc] init];
>
> NSLog (@"programming is fun");
> [pool drain];
> return 0;
>
> }
>
> // i am using Windows vista, GNUstep to compile, and jEdit to enter the data.
> i get these errors from GNUstep
>
> $ gcc -o run prog1.m
> prog1.m:1:34: error: Foundation/Foundation.h: No such file or directory
Looks as if gcc does not know the header file search paths.
> prog1.m: In function 'main' :
> prog1.m:5: error: 'NSAutoreleasePool' undeclared (first use in this function)
> prog1.m:5: error: (Each undeclared identifier is reported only once
> prog1.m:5: error: for each function it appears in.)
> prog1.m:5: error: 'Pool' undeclared (first use in this function)
> prog1.m:5: error: expected ';' before 'init'
> prog1.m:5: error: expected statement before ']' token
> prog1.m:5: error: cannot find interface declaration for 'NXConstantString'
> prog1.m:5: error: 'pool' undeclared (first use in this function)
>
> //thanks for any help anyone can provide!!
And, the linker will not know where to look for the libraries.
Did you initialize your GNUstep environment?
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: Foundation.h help,
address@hidden <=