- Added new napi files

- Port to Linux
This commit is contained in:
cvs
2001-11-14 07:14:04 +00:00
parent 6c5db4ffd0
commit 3712dca74e
13 changed files with 93 additions and 61 deletions

View File

@@ -10,10 +10,17 @@ TCLI_OBJ= sys_aunix.o sys_aunix_c.o $(CLI_OBJ)
TECLI_OBJ= tecs_client.o tecs_plot.o tecs_for.o sys_util.o str.o instr_hosts.o $(TCLI_OBJ)
#------------ for DigitalUnix (add -DFORTIFY to CFLAGS for fortified version)
CC=cc
#CC=cc
#CFLAGS= -std1 -g -warnprotos -I../ -I. -I../hardsup -DFORTIFY
CFLAGS= -std1 -g -warnprotos -I../ -I. -I../hardsup
#CFLAGS= -std1 -g -warnprotos -I../ -I. -I../hardsup
#---------- for Redhat linux
CC= gcc
CFLAGS= -I/usr/local/include -I. -I../ -I../hardsup -DLINUX -g
#------------ for Linux
##CC=gcc
##CFLAGS = -fwritable-strings -DCYGNUS -DNONINTF -g -I../ -I. -I../hardsup
#------------
.f.o:
f77 -c -u -g $*.f
@@ -31,10 +38,18 @@ all: libtecsl.a bin/TecsServer bin/TecsClient rstart bin/keep_running
tecs_plot.o: tecs_plot.f90
f90 -c -u -g tecs_plot.f90
#------------ DigitalUnix4.0D
#bin/TecsServer: $(LIBR_OBJ) $(SERV_OBJ)
# - rm bin/TecsServer
# $(CC) $(CFLAGS) -g -o bin/TecsServer -g $(LIBR_OBJ) $(SERV_OBJ) fortify1.c \
# -lm -L../hardsup -lhlib -lfor
#---------- Linux
bin/TecsServer: $(SERV_OBJ)
- rm bin/TecsServer
$(CC) $(CFLAGS) -o bin/TecsServer -g $(SERV_OBJ) fortify1.c \
-lm -L../hardsup -lhlib -lfor
$(CC) $(CFLAGS) -o bin/TecsServer $(SERV_OBJ) fortify1.c \
-lm -L../hardsup -lhlib
bin/TecsClient: $(TECLI_OBJ)
f77 -o bin/TecsClient -g $(TECLI_OBJ) \

View File

@@ -31,7 +31,7 @@ typedef size_t sys_adr_len; /* argument of accept and gethostbyadr */
void sys_ctrl_init(void);
#elif defined __alpha
#elif defined __unix
#define F_CHAR(VAR) char *VAR
#define STR_TO_C(DST,SRC) str_ntrim(DST, SRC, sizeof(DST), SRC##_len)
@@ -39,7 +39,7 @@ void sys_ctrl_init(void);
typedef int sys_adr_len; /* argument of accept and gethostbyadr */
#define sys_ctrl_init(DUMMY)
#define sys_ctrl_init() {}
#else

View File

@@ -13,7 +13,6 @@
logical done
integer i,iostat
data lunw/0/
if (lunw .ne. 0) then
call err_msg('file already open for write')
@@ -24,7 +23,7 @@
vers=0
open(lunw, name=file, status='old', access='direct', shared
open(lunw, name=file, status='old', access='direct'
1 , recl=recl, iostat=iostat)
if (iostat .eq. 0) then
read(lunw, rec=1, iostat=iostat) vers, stim, etim, wrec, rrec, wdir
@@ -45,7 +44,7 @@
etim=0
wrec=-1
rrec=0
open(lunw, name=file, status='new', access='direct', shared
open(lunw, name=file, status='new', access='direct'
1 , recl=recl, err=93)
else
dlog_open_w=1 ! reopened
@@ -78,7 +77,6 @@
include 'tecs_dlog.inc'
integer p,r,i,j,btim
data update/.true./
logical done
integer dlog_put_
@@ -220,7 +218,6 @@
logical done
integer iostat
data lunr/0/
integer sys_gmt_off
@@ -232,8 +229,8 @@
lunr=39
open(lunr, name=file, status='old', access='direct', shared
1 , recl=recl, err=99, readonly)
open(lunr, name=file, status='old', access='direct'
1 , recl=recl, err=99)
call dlog_read_block(1, done)
if (.not. done) then
close(lunr)