Re: Another dummy C question
Re: Another dummy C question
- Subject: Re: Another dummy C question
- From: Thomas Hudson <email@hidden>
- Date: Sun, 24 Jun 2001 20:14:58 -0700
On Sunday, June 24, 2001, at 05:35 PM, Michael Grant wrote:
What's up with "malloc" in Project Builder? Trying to compile the
program introducing malloc in C for Dummies vol. 2 (lesson 11-4, if
anyone cares), I get an error saying "header file 'malloc.h' not found".
The book is maybe a little out of date. 'malloc' is declared in stdlib.h
which is in
the directory /usr/include.
The book suggests using "alloc.h" rather than "malloc.h" with some
compilers, but when I try that I get over **400** errors before I
manage to cancel the build. Is there a different header I should be
using instead with Project Builder? (I don't think I just left out a
semicolon this time....)
Maybe a better question is, where can I find this sort of information
in the OS X developer documentation so I don't have to bother this list
with it? And where are header files stored, anyway? Sherlock doesn't
find them, so I assume they're not stored as actual "files" on the
disk....
For issues regarding any of the standard C lib, or posix functions, the
man pages
are pretty good. Try "man malloc" on the command line. If you're not
sure which
man page to ask for, try "apropos subject"
Thomas