delorie.com/archives/browse.cgi | search |
From: | "gunno" <gunno AT no-spam DOT telia DOT com> |
Newsgroups: | comp.os.msdos.djgpp |
References: | <00c401bfdde0$74f9bd40$bada36cb AT mpdywdzn> |
Subject: | SV: Request for assistance from real IT newbie |
Lines: | 74 |
MIME-Version: | 1.0 |
X-Priority: | 3 |
X-MSMail-Priority: | Normal |
X-Newsreader: | Microsoft Outlook Express 5.00.2919.6600 |
X-MimeOLE: | Produced By Microsoft MimeOLE V5.00.2919.6600 |
Message-ID: | <fIj55.14943$Za1.235453@newsc.telia.net> |
Date: | Sun, 25 Jun 2000 08:49:15 GMT |
NNTP-Posting-Host: | 213.64.22.40 |
X-Complaints-To: | abuse AT telia DOT com |
X-Trace: | newsc.telia.net 961922955 213.64.22.40 (Sun, 25 Jun 2000 10:49:15 MET DST) |
NNTP-Posting-Date: | Sun, 25 Jun 2000 10:49:15 MET DST |
Organization: | Telia Internet |
To: | djgpp AT delorie DOT com |
DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
X-MIME-Autoconverted: | from quoted-printable to 8bit by delorie.com id NAB12483 |
Reply-To: | djgpp AT delorie DOT com |
Hello, Basically with djgpp you're working in a DOS box (call it DOS-Prompt [MS name for it?], DOS window or whatever) In that DOS box try these commands C:\>gcc -v /* testing if you've got a working compiler */ Reading specs from c:/djgpp/lib/specs /* yes it's there and this is it's answer */ gcc version 2.8.1 C:\>info /* The information program. To quit 'info' press 'q' */ 'info' has tons of valuable information and answers to most of your questions. Think it's well worth the time you spend on learning how to navigate in it. Here are two commands: C:\>info djgppfaq /* Don't miss the two last lines of this info page. Nothing beats an index !!! */ C:\>info libc alpha /* Yet another marvellous index */ Some specific answers: "jeffflew" <jflew AT bigpond DOT com> skrev i meddelandet news:00c401bfdde0$74f9bd40$bada36cb AT mpdywdzn... >I installed from the CD and have looked at FAQ and readme but am getting quite lost. I've used a compiler for > Java before and it could be set up like a window where you'd type the code and enter the commands for > compile and execute but I can't seem to work out how to get up such a window on DJGPP. Do you just use > the DOS-Prompt with DJGPP? I tried creating a file hello.c and running it from the DOS-Prompt with the > commands suggested but no luck. 1. Create a source file in an editor that can produce files in pure text format. If you've got nothing else, 'Notepad' can do - at least as a start. (There are better editors for programming, 'Emacs' for one) 2. Save that source file with the extension '.c' . 'hello.c' is a good name. 3. Compile it. > "CMDLINE=gcc -o hello hello.c" Looks fine with the exception that you have to give the executable file the extension '.exe' if you want it to be executable. It's DOS that's requires that extension to understand. So the command should look something like: C:\MyCprogs\newprogs> gcc -o hello.exe hello.c And you can get warnings if you have created code that might be faulty. I's a very valuable option, which is called with '-Wall'. So it would then look like: C:\MyCprogs\newprogs> gcc -Wall -o hello.exe hello.c Good Luck with "Hello World" (and all your following programs)! gunno (and please turn that HTML-stuff off. It's just irritating and waste of space)
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |