delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/03/05/09:39:30

From: "J. van Eijnsbergen" <hanvane AT worldonline DOT nl>
Newsgroups: comp.os.msdos.djgpp
Subject: Compile ???
Date: Wed, 05 Mar 1997 14:00:32 -0800
Organization: ZIN http://www.worldonline.nl/~hanvane/zin.htm
Message-ID: <331DED00.16D9@worldonline.nl>
Reply-To: hanvane AT worldonline DOT nl
NNTP-Posting-Host: drdt1-p83.worldonline.nl
Mime-Version: 1.0
Lines: 204
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

When I want to compile the folowing (simple c-code) gcc.exe returns an
error:
The program is test.c and is located in C:\DJGPP\PROG\
So I run : C:\DJGPP\PROG\gcc test.c (from pain DOS 6.22)
gcc returns: C:\DJGPP\PROG\test.c:1: stdio.h: No such file or directory
(ENOENT)

What am I doing wrong?

The test.c I am trying to compile is printed below:
#include <stdio.h>

float data[5];  /* data to average and total */
float total;    /* the total of the data items */
float average;  /* average of the items */

main()
{
    data[0] = 34.0;
    data[1] = 27.0;
    data[2] = 45.0;
    data[3] = 82.0;
    data[4] = 22.0;

    total = data[0] + data[1] + data[2] + data[3] + data[4];
    average =  total / 5.0;
    (void)printf("Total %f Average %f\n", total, average);
    return (0);
}

I ran DJVERIFY, This reports:
************************************************************************
DJVRFY01.LOG

    DJVERIFY -- DJGPP Installation Verification Utility -- version 0.33a

                       *** Interactive Mode ***

Initializing...
Report filename = 'djvrfy01.log'
Examining environment...
DJGPP environment variable not found.
DJDIR environment variable not found.

Generating system report to sysrpt00.log...
Attempting to compile test program 'temp0000.c'.
c:/djgpp/bin/redir -o temp0000.out -eo c:/djgpp/bin/gcc -v -Wall -g -O
-o temp0000.exe temp0000.c
Finished generating system report.

************************************************************************

             -----===== DJGPP System Report file =====-----
    Generated by DJVERIFY version 0.33 Alpha on Wed Mar  5 13:22:26 1997


    This report should be posted to the DJGPP newsgroup/mailing list
    along with a complete description of the problem or problems you are
    experiencing.  See the file readme.1st for posting instructions.

     ***** c:/config.sys *****     

SWITCHES=/f
DEVICE=C:\DOS\HIMEM.SYS
BUFFERS=40,0
FILES=80
DOS=UMB
FCBS=4,0
DOS     = HIGH
STACKS  = 9,256
BREAK   = ON
COUNTRY = 001,,C:\DOS\COUNTRY.SYS
INSTALL = C:\DOS\NLSFUNC.EXE C:\DOS\COUNTRY.SYS
SHELL   = C:\NDOS.COM @C:\PR_U\NU\NDOS.INI /E:1024 /P
include shared
LASTDRIVE=C 
DEVICE=C:\DOS\EMM386.EXE NOEMS HIGHSCAN WIN=ED00-EFFF
WIN=E900-ECFF       
DEVICEHIGH /L:1,48720 =C:\PR_U\F-PROT\VIRSTOP.EXE
DEVICE=C:\PR_U\QUICKCMD\CMD640X2.SYS /A33
DEVICEHIGH /L:1,15792 =C:\DOS\DISPLAY.SYS CON=(EGA,,1)
DEVICEHIGH /L:1,12048 =C:\DOS\SETVER.EXE
DEVICEHIGH /L:1,9072 =C:\DOS\ANSI.SYS
DEVICEHIGH /L:1,4560 =C:\WINDOWS\IFSHLP.SYS
     ***** END *****     


     ***** c:/autoexec.bat *****     
@ECHO OFF
PATH C:\DOS;C:\BATCH;C:\WINDOWS;C:\PRGR\WP51;C:\PRGR\DBASE;C:\NWCLIENT
PATH %PATH%;C:\PRGR\123R3;C:\PR_U\NU;C:\PR_U\NC;C:\COMPR
PATH %PATH%;C:\PR_U\VPROTECT.PC;C:\DOSFAX;C:\TR;C:\DESKJET;C:\DJGPP\BIN
SET DJGPP   =C:\DJGPP\DJGPP.ENV
SET LMOUSE  =C:\DRIVERS\MOUSE
SET NU      =C:\PR_U\NU
SET SYMANTEC=C:\SYMANTEC
SET PROMPT  =$e[0;30;47m$P$G
SET TELIX   =C:\MODEM\TELIX
MODE CON CODEPAGE PREPARE=((437) C:\DOS\EGA.CPI)
MODE CON CODEPAGE SELECT=437
LH /L:0;1,25232 /S C:\DRIVERS\MOUSE\MOUSE.EXE
C:\PR_U\NU\IMAGE C:
C:\DOS\SMARTDRV /X /U 2048 128      
LH /L:1,16288 KEYB US,,C:\DOS\KEYBOARD.SYS   
LH /L:1,6384 C:\DOS\DOSKEY
LH /L:1,4752 C:\WINDOWS\VGAUTIL\TSRFONT.COM
SET TEMP    =C:\TEMP
SET TEMPNDOS=C:\TEMP
CLS
     ***** END *****     


     ***** c:/djgpp/djgpp.env *****     
#= Don't edit this line unless you move djgpp.env outside
#= of the djgpp installation directory.  If you do move
#= it, set DJDIR to the directory you installed DJGPP in.
#=
DJDIR=%:/>DJGPP%

+USER=dosuser
+TMPDIR=%DJDIR%/tmp
+EMU387=%DJDIR%/bin/emu387.dxe
+LFN=n

[bison]
BISON_HAIRY=%DJDIR%/lib/bison.hai
BISON_SIMPLE=%DJDIR%/lib/bison.sim

[cpp]
CPLUS_INCLUDE_PATH=%/>;CPLUS_INCLUDE_PATH%%DJDIR%/lang/cxx;%DJDIR%/include;%DJDIR%/contrib/grx20/include
C_INCLUDE_PATH=%/>;C_INCLUDE_PATH%%DJDIR%/include;%DJDIR%/contrib/grx20/include
OBJCPLUS_INCLUDE_PATH=%/>;OBJCPLUS_INCLUDE_PATH%%DJDIR%/include;%DJDIR%/lang/objc
OBJC_INCLUDE_PATH=%/>;OBJC_INCLUDE_PATH%%DJDIR%/include;%DJDIR%/lang/objc

[gcc]
COMPILER_PATH=%/>;COMPILER_PATH%%DJDIR%/bin
LIBRARY_PATH=%/>;LIBRARY_PATH%%DJDIR%/lib;%DJDIR%/contrib/grx20/lib

[info]
INFOPATH=%/>;INFOPATH%%DJDIR%/info
     ***** END *****     


     ***** Output of 'command /c set' *****     
CONFIG=dos
COMSPEC=C:\NDOS.COM
CMDLINE=djvrfy2
PATH=C:\DOS;C:\BATCH;C:\WINDOWS;C:\PRGR\WP51;C:\PRGR\DBASE;C:\NWCLIENT;C:\PRGR\123R3;C:\PR_U\NU;C:\PR_U\NC;C:\COMPR;C:\DJGPP\INC
DJGPP   =C:\DJGPP\DJGPP.ENV
LMOUSE  =C:\DRIVERS\MOUSE
NU      =C:\PR_U\NU
SYMANTEC=C:\SYMANTEC
PROMPT  =$e[0;30;47m$P$G
TELIX   =C:\MODEM\TELIX
DIRCMD=/n/2/p
TEMP    =C:\TEMP
TEMPNDOS=C:\TEMP
     ***** END *****     


     ***** Output of 'c:/djgpp/bin/go32-v2' *****     
go32/v2 version 2.0 built Jan 23 1996 22:03:02
Usage: go32 coff-image [args]
Rename this to go32.exe only if you need a go32 that can run v2 binaries
as
 well as v1 binaries (old makefiles).  Put ahead of the old go32 in your
PATH.
DPMI memory available: 4204 Kb
DPMI swap space available: 115664 Kb
     ***** END *****     


     ***** Sample program compilation with gcc -v *****
c:/djgpp/bin/redir -o temp0000.out -eo c:/djgpp/bin/gcc -v -Wall -g -O
-o temp0000.exe temp0000.c
gcc version 2.7.2
 cpp -lang-c -v -undef -D__GNUC__=2 -D__GNUC_MINOR__=7 -Dunix -Di386
-DGO32 -DMSDOS -D__unix__ -D__i386__ -D__GO32__ -D__MSDOS__ -D__unix
-D__i386 -D__GO32 -D__MSDOS -Asystem(unix) -Asystem(msdos) -Acpu(i386)
-Amachine(i386) -D__OPTIMIZE__ -g -Wall temp0000.c .\ccbaaaaa
GNU CPP version 2.7.2 (80386, BSD syntax)
#include "..." search starts here:
#include <...> search starts here:
 /usr/local/include
 /usr/local/go32/include
 /usr/local/lib/gcc-lib/go32/2.7.2/include
 /usr/include
End of search list.
temp0000.c:2: stdio.h: No such file or directory (ENOENT)
temp0000.c:3: stdlib.h: No such file or directory (ENOENT)
temp0000.c:4: math.h: No such file or directory (ENOENT)
temp0000.c:5: string.h: No such file or directory (ENOENT)
     ***** END *****     

             -----===== END OF SYSTEM REPORT =====-----


Can anybody help?
Thanks (and sorry for the large message),
-- 
Han van Eijnsbergen
hanvane AT worldonline DOT nl
http://www.worldonline.nl/~hanvane/index.html
http://www.worldonline.nl/~hanvane/zin.htm

- Raw text -


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