Mail Archives: djgpp/1996/12/14/22:37:45
I have successfully compiled programs with the input file a .c file, and
the output file a .exe with one call to gcc.
However, I just had an error doing so.
t.c:
#include <stdio.h>
int main(void)
{
int n;
printf("Please enter a number:");
scanf("%d",&n);
printf("Modulated by 40: %d",n%40);
return(0);
}
tc.bat (used for compiling it)
@gcc -c t.c -o t.exe -v
The verbose listing showed that the following were called:
cpp
cc1
as
(I've omitted their arguments)
Gcc would then exit, with the resulting (Object?) file being t.exe
The same thing would happen when I rewrote t.c as a 'hello world' style
program.
Is this due to the @? (In batch files, this tells ms-dog not to echo that
line to the screen. I think it means to get input from a file for djgpp,
doesn't it?)
Really messed up,
...Chambers
- Raw text -