Mailing List Archive
tlug.jp Mailing List tlug archive tlug Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]Re: [tlug] how to compile a C program without main() ?
- Date: Thu, 12 May 2011 17:10:38 +0900
- From: Kenneth Burling <burlingk@example.com>
- Subject: Re: [tlug] how to compile a C program without main() ?
- References: <BANLkTik1jqshor=yANvp1FThNzf=S-Uj9w@example.com>
On Thu, May 12, 2011 at 3:57 PM, Gernot Hassenpflug <aikishugyo@example.com> wrote: > Dear all, > > I'm not sure how best to word the subject, as I am not sure what I should be > looking to solve here. > > I found this preload library (nocache) source code > > http://enricozini.org/2010/tips/nocache/ > The information provided by others will be of more use for this particular issue, but in general, if you are compiling a module, and not a complete program, the -c flag will generally allow it to compile in gcc. This tells it to compile, but not link. >From there you would use ar or similar to link them together as a library, or you would use gcc to link them together as a program (which would have to have exactly one main() in one of the modules). I am sure there are more complicated ways of doing things, but I am not an expert. :) -- Ken
- References:
- [tlug] how to compile a C program without main() ?
- From: Gernot Hassenpflug
Home | Main Index | Thread Index
- Prev by Date: Re: [tlug] how to compile a C program without main() ?
- Next by Date: Re: [tlug] how to compile a C program without main() ?
- Previous by thread: Re: [tlug] how to compile a C program without main() ?
- Next by thread: [tlug] Computer to give away or sell
- Index(es):
Home Page Mailing List Linux and Japan TLUG Members Links