LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Other *NIX Forums > Solaris / OpenSolaris
User Name
Password
Solaris / OpenSolaris This forum is for the discussion of Solaris and OpenSolaris.
General Sun, SunOS and Sparc related questions also go here.

Notices

Reply
 
Thread Tools
Old 10-29-2009, 08:25 AM   #1
Ssk8harddiefast
LQ Newbie
 
Registered: Jul 2009
Location: athens
Distribution: Gentoo
Posts: 13
Thanked: 0
Question CC compilation


[Log in to get rid of this advertisement]
I have the source of a program.when i was using linux i had gcc compiler.
./configure
make
make install
Here i have CC compiler.How to compile a program?The program is not only 1 file.c .Is a folder with makefile,header files,C files etc
solaris Ssk8harddiefast is offline     Reply With Quote
Old 10-29-2009, 08:55 AM   #2
jlightner
Senior Member
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 3,548
Thanked: 144
cc -o file file.c

This tells it to compile file.c into output (object) named file.

gcc and cc are roughly equivalent commands. You should also have make. You may have a rudimentary compiler and need to install an ANSI C compiler for some things (or load gcc and use it).
jlightner is offline     Reply With Quote

Reply

Bookmarks


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
c++ compilation karan101 Programming 6 03-12-2006 06:23 AM
compilation? itz2000 Programming 19 11-11-2005 03:25 PM
C Compilation eshwar_ind Programming 6 05-10-2004 02:38 AM
Compilation HoRrIdPrObLeMs Programming 2 03-12-2002 03:52 PM
Compilation mikeshn Programming 2 03-03-2002 11:08 PM


All times are GMT -5. The time now is 07:16 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
RSS2  LQ Podcast
RSS2  LQ Radio
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration