delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/03/25/15:04:41

Message-ID: <351930C2.4E585DA5@cs.joensuu.fi>
Date: Wed, 25 Mar 1998 18:28:50 +0200
From: Eugene Ageenko <ageson AT cs DOT joensuu DOT fi>
MIME-Version: 1.0
To: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>, djgpp AT delorie DOT com
Subject: Re: Problems with GCC 2.8.0
References: <Pine DOT SUN DOT 3 DOT 91 DOT 980325192132 DOT 1132C-100000 AT is>

Eli Zaretskii wrote:
> 
> On Wed, 25 Mar 1998, Andris Pavenis wrote:
> 
> > I tried to reproduce this with both gcc-2.8.0 (precompiled, I take
> > precompiled gcc.exe also) and gcc-2.8.1 and had no success.
> 
> Did you try to compile two or more source files on the same GCC command
> line?  That's how this problem was found, I believe.

yes. I tried

gcc test.c modules.c -o test

and the files were following (but could be anything)

================== test.c ===================

/* test program that does not compiled with gcc 2.8.0 following way
*/
/* gcc test.c module.c -o test.exe                                 
*/

#include "module.h"
#include <stdio.h>

int main(void) 
{
  hello();

  exit(0);
}

================ module.h =====================

#ifndef __MODULE_H
#define __MODULE_H

int hello(void);

#endif  /* __MODULE_H */

================= module.c ====================

#include "module.h"
#include <stdio.h>

int hello(void)
{
   printf("Hello World");
}

- Raw text -


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