Mail Archives: cygwin/2007/02/17/04:40:52
Matthew Pemrich wrote:
> Heck, it's easier to apologize than ask permission, so sorry in advance if this
> is in the wrong newsgroup.
This is a mailing list, not a newsgroup.
> You can see what I'm looking for. I've installed gcc and mingw for C packages
> on my computer, but I am having trouble doing manual lookups for header files
> like string.h, or functions like srandom. Man is installed. I use it
> occasionally to look up command line arguments for gcc.
This list has nothing to do with MinGW. That's another project. If you
are really talking about MinGW then you want to ignore the rest of this
email, since MinGW targets the Microsoft runtime and Win32 APIs, not
POSIX, and everything you want in terms of those is online at MSDN.
> I'm a beginning developer, and a newbie linux user. GUI is easy, and moving
> away from DOS was something I dreaded when I was first introduced to NT-based
> Operating Systems, so I'm really stuck here.
>
> Do those manual pages appear in any packages, or is there a way I can install
> them... ahem... manually?
Have you not installed the cygwin-doc package? It contains man pages
and 'info' pages for the parts of Cygwin that are implemented through
newlib. Type "info libc" or "info libm". But again this only covers
the newlib parts, which are things like I/O and math. Other parts of
the api are implemented by Cygwin itself, and there are not man pages
for these. These Cygwin-specific things are documented in html and PDF,
and are also included in the cygwin-doc package. They are not
extensive, and often amount to just listing which functions are
supported, and some of this may be quite out of date.
Thus, the best thing you can do to learn the POSIX apis is to actually
just read... the POSIX spec:
http://www.opengroup.org/onlinepubs/009695399/mindex.html
The one you want for C programming is the System Interfaces volume,
which defines what all POSIX systems, Cygwin included, strive to
implement. You can also read the man pages for other POSIX
implementations: for example, glibc has their docs online, FreeBSD has a
great manpage viewer online, and Solaris has very good documentation.
http://www.gnu.org/software/libc/manual/html_node/index.html
http://www.freebsd.org/cgi/man.cgi
http://docs.sun.com/app/docs/doc/816-5167/6mbb2jaeu?a=expand
All of these resources will tell you about a particular vender's
implementation of the POSIX API. Now don't misunderstand, that doesn't
mean that you can take whatever you read about e.g. glibc and apply it
to Cygwin. These are two very different implementations of the POSIX
api -- glibc for example includes a large number of extensions and
features outside the standard. And Cygwin is not complete even in its
implementation of the basic POSIX api, although it is pretty close. So
don't get the idea that you can use these above links as references to
Cygwin. But what they are good for is to see how things are done on
these other platforms, because that is the whole idea of Cygwin, to
emulate as close as possible a POSIX api on Windows. The answer to any
such question about Cygwin "how do I do <x>" should be "however it's
done on linux/POSIX".
If you want to see if a function is implemented or not, the easiest way
is to just try it. Or you can look at the cygwin.din file, which is the
source file used to create cygwin.def, which in turn defines all the
symbols exported by the DLL. You can view this in CVS:
http://cygwin.com/cgi-bin/cvsweb.cgi/~checkout~/src/winsup/cygwin/cygwin.din?cvsroot=src
But do note that the CVS version might have changes that were made since
the last release, so have a look at the logs in case of confusion.
Brian
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
- Raw text -