delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/04/01/15:37:32

From: elf AT netcom DOT com (Marc Singer)
Message-Id: <199704012020.MAA17868@netcom4.netcom.com>
Subject: Re: DJGPP AND PROJECTS ahhhhhhhhhhhhh HELP
To: zero AT nothing DOT net
Date: Tue, 1 Apr 1997 12:20:13 -0800 (PST)
Cc: djgpp AT delorie DOT com (DJGPP List Alias)
In-Reply-To: <334051e4.7904628@news.interlynx.net> from "zero@nothing.net" at Mar 31, 97 06:07:37 am
MIME-Version: 1.0

> see even in other c++ environments i had trouble with projects.   rite
> now i am doing this
> 
> 
> main file:
> 
> 
> #include <stdio.h>
> #include <stdlib.h>
> #include <conio.h>
> etc...
> 
> 
> //then here are my other source files
> 
> #include "vector.c"
> #include "camera.c"
> #include "preload.c"
> 

This is not really an appropriate question for this list which is
supposed to be dedicated to the DJGPP port of the GNU compiler and the
associated environment.  You may want to look to one of the gaming
newsgroups or, perhaps, a list about C and C++.

WRT to the include issue:  it is common practice to use a guarding
preprocessor directive in each header file.  That way you can include
each as many times as you wish and the compiler will only process the
header file once.

/* foo.h */

#if !defined (__FOO_H__)
#    define   __FOO_H__

/* header goes here

#endif


-- Marc Singer

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019