home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!zaphod.mps.ohio-state.edu!pacific.mps.ohio-state.edu!cis.ohio-state.edu!news.sei.cmu.edu!cert!netnews.upenn.edu!cronkite.ocis.temple.edu!astro.ocis.temple.edu!ray
- From: ray@astro.ocis.temple.edu (Ray Lauff)
- Newsgroups: comp.std.c
- Subject: Libraries specified in source?
- Message-ID: <1993Jan21.182949.29796@cronkite.ocis.temple.edu>
- Date: 21 Jan 93 18:29:49 GMT
- Sender: news@cronkite.ocis.temple.edu (NetWork News (readnews))
- Organization: Temple University
- Lines: 24
- X-Newsreader: TIN [version 1.1 PL8]
-
- I have been programming in c for about a year or so now on various
- platforms and I often find myself wondering why standard C has
- no mechanisms for embedding the libraries required for loading
- into the code. Right now I have to specify them on the command
- line of the compiler call. Of course, using make files can
- simplify the process, but why not just have a line in the
- main program such as
-
- #library "/lib/libc.a"
-
- which would then alert the linker that that library will be
- required. DIGITAL supplies macro assembly programmers with
- this capibility (.library directive), but they recommend
- against using it since it makes moving library files a problem
- since all the source code would need to be updated. Perhaps
- C could avoid this problem by putting them in an include file.
-
- It seems to me this would be a reasonable extension to C, since
- just about every c program requires some type of library that's
- not automagically provided. Does this make sense to anyone
- else? Would it not be a consideration for the language?
-
- Ray
- ray@astro.temple.edu
-