POV-Ray : Newsgroups : povray.off-topic : My first C++ program : Re: My first C++ program Server Time
4 Nov 2024 13:44:29 EST (-0500)
  Re: My first C++ program  
From: Warp
Date: 20 Sep 2008 05:20:05
Message: <48d4c045@news.povray.org>
Orchid XP v8 <voi### [at] devnull> wrote:
> Yup. A simple and obvious mistake. But unfortunately, not one the 
> compiler warned me about.

  Than turn on the warning flags. You should always compile with warning
flags.

g++ -Wall -Wextra -pedantic -ansi -O3 yourprogram.cc

  Learn to use makefiles too. You can use the attached generic makefile
to automatically build your program. (You'll probably need gnu make.)

  (Note that if you add, remove or change any #include line in your
program, except those which include standard libraries, you'll have to
delete the .dep file before running make.)


Post a reply to this message


Attachments:
Download 'Makefile.txt' (1 KB)

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.