[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: file annotations
From: |
Nicola Pero |
Subject: |
Re: file annotations |
Date: |
Tue, 1 Mar 2005 13:39:57 +0000 (GMT) |
> > Try to compile and run this:
> >
> > int main(int argc, char** argv)
> > {
> > CREATE_AUTORELEASE_POOL (pool);
> > NSString *path = @"/";
> > NSArray *contents = [[NSFileManager defaultManager] subpathsAtPath:
> > path];
> > NSLog(@"%i", [contents count]);
> > RELEASE (pool);
> > exit(0);
> > }
>
> I am not familiar with gnustep-make at all. I am not sure which
> headers I should include and which libraries to link to to get it
> compiled.
Not having read any of the discussion, my eye just catched the words
"gnustep-make" ...
You don't need to know which headers/libraries are needed ;-) gnustep-make
does it all for you. If you just need to compile that main() function,
copy the following stuff
include $(GNUSTEP_MAKEFILES)/common.make
TOOL_NAME = Test
Test_OBJC_FILES = Test.m
include $(GNUSTEP_MAKEFILES)/tool.make
into a file called GNUmakefile, make sure your source code is in file
Test.m in the same directory, then type 'make' there. The generated tool
(which you can immediately run) should be in ./obj/Test
For more information, please check
http://www.gnustep.it/nicola/Tutorials/WritingMakefiles/index.html
compiling with gnustep-make is really easy stuff, nothing to be scared
about. :-)
Thanks