Re: Linux C++ compiler

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, 2010-01-24 at 15:48 -0500, Matt Smith wrote:
> after typing g++ gedit_file.cc i get a filed name a.out in the same
> folder that is locked.  where do i go from here?  thanks

You're missing the output filename:

$ gcc source_filename.cc -o output_filename

Where output_filename is name of the resulting executable. (Equivalent
to .exe file in Windows/DOS)

If you want to execute the resulting executable, type:
$ ./output_filename

If you want to be able to debug the resulting executable, try:
(Quick and dirty solution)

First, install DDD (simple but effective debugger):
$ su -c 'yum install ddd'

Compile the file with debug information.
$ gcc source_filename.cc -ggdb3 -o output_filename

Start the debugger.
$ ddd ./output_filename

- Gilboa


-- 
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Communicate/MailingListGuidelines

[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux