diff --git a/cb5/buildap b/cb5/buildap index 9a76e7026..19a90ffc1 100755 --- a/cb5/buildap +++ b/cb5/buildap @@ -1,4 +1,4 @@ -cc -M3 $1.c -o $1 -lx -lcb +gcc $1.c -o $1 -lx -lcb diff --git a/cb5/cb51make b/cb5/cb51make index aca9179e0..920f60d35 100755 --- a/cb5/cb51make +++ b/cb5/cb51make @@ -1,11 +1,10 @@ # cb51make (c)Copyright Sequiter Software Inc., All rights reserved. */ # -# Make file for creating libcb.a +# Make file for creating library # *Implicit Rules* -Compiler = cc -Compiler_options = -c +Compiler = cc++ # *List Macros* @@ -22,412 +21,417 @@ Header_files = \ r4reinde.h \ r4relate.h \ r4report.h \ - s4sort.h + s4sort.h \ + x4filter.h Object_files = \ - b4block.o \ - c4.o \ - c4bcd.o \ - c4code.o \ - c4const.o \ - d4append.o \ - d4close.o \ - d4create.o \ - d4data.o \ - d4date.o \ - d4field.o \ - d4flush.o \ - d4fresh.o \ - d4go.o \ - d4index.o \ - d4lock.o \ - d4open.o \ - d4opt.o \ - d4pack.o \ - d4positi.o \ - d4seek.o \ - d4skip.o \ - d4tag.o \ - d4unlock.o \ - d4write.o \ - d4zap.o \ - e4calc.o \ - e4calc_2.o \ - e4error.o \ - e4expr.o \ - e4functi.o \ - e4not_s.o \ - e4parse.o \ - f4ass_f.o \ - f4char.o \ - f4close.o \ - f4create.o \ - f4double.o \ - f4field.o \ - f4file.o \ - f4filese.o \ - f4flag.o \ - f4flush.o \ - f4info.o \ - f4int.o \ - f4lock.o \ - f4long.o \ - f4memo.o \ - f4open.o \ - f4opt.o \ - f4ptr.o \ - f4str.o \ - f4temp.o \ - f4true.o \ - f4write.o \ - i4add.o \ - i4addtag.o \ - i4check.o \ - i4create.o \ - i4dump.o \ - i4index.o \ - i4info.o \ - i4init.o \ - i4key.o \ - i4lock.o \ - i4ntag.o \ - i4positi.o \ - i4remove.o \ - i4tag.o \ - l4link.o \ - l4lock_c.o \ - m4check.o \ - m4create.o \ - m4file.o \ - m4map.o \ - m4memo.o \ - m4memory.o \ - o4opt.o \ - r4area.o \ - r4bit.o \ - r4driver.o \ - r4drive2.o \ - r4group.o \ - r4log.o \ - r4obj.o \ - r4reinde.o \ - r4reindx.o \ - r4relate.o \ - r4report.o \ - r4save.o \ - r4save_2.o \ - r4style.o \ - r4total.o \ - s4init.o \ - s4initfr.o \ - s4next.o \ - s4quick.o \ - s4sort.o \ - u4name.o \ - u4util.o \ + $(Lib)(b4block.o) \ + $(Lib)(c4.o) \ + $(Lib)(c4bcd.o) \ + $(Lib)(c4code.o) \ + $(Lib)(c4const.o) \ + $(Lib)(d4append.o) \ + $(Lib)(d4close.o) \ + $(Lib)(d4create.o) \ + $(Lib)(d4data.o) \ + $(Lib)(d4date.o) \ + $(Lib)(d4field.o) \ + $(Lib)(d4flush.o) \ + $(Lib)(d4fresh.o) \ + $(Lib)(d4go.o) \ + $(Lib)(d4index.o) \ + $(Lib)(d4lock.o) \ + $(Lib)(d4open.o) \ + $(Lib)(d4opt.o) \ + $(Lib)(d4pack.o) \ + $(Lib)(d4positi.o) \ + $(Lib)(d4seek.o) \ + $(Lib)(d4skip.o) \ + $(Lib)(d4tag.o) \ + $(Lib)(d4unlock.o) \ + $(Lib)(d4write.o) \ + $(Lib)(d4zap.o) \ + $(Lib)(e4calc.o) \ + $(Lib)(e4calc_2.o) \ + $(Lib)(e4error.o) \ + $(Lib)(e4expr.o) \ + $(Lib)(e4functi.o) \ + $(Lib)(e4not_s.o) \ + $(Lib)(e4parse.o) \ + $(Lib)(f4ass_f.o) \ + $(Lib)(f4char.o) \ + $(Lib)(f4close.o) \ + $(Lib)(f4create.o) \ + $(Lib)(f4double.o) \ + $(Lib)(f4field.o) \ + $(Lib)(f4file.o) \ + $(Lib)(f4filese.o) \ + $(Lib)(f4flag.o) \ + $(Lib)(f4flush.o) \ + $(Lib)(f4info.o) \ + $(Lib)(f4int.o) \ + $(Lib)(f4lock.o) \ + $(Lib)(f4long.o) \ + $(Lib)(f4memo.o) \ + $(Lib)(f4open.o) \ + $(Lib)(f4opt.o) \ + $(Lib)(f4ptr.o) \ + $(Lib)(f4str.o) \ + $(Lib)(f4temp.o) \ + $(Lib)(f4true.o) \ + $(Lib)(f4write.o) \ + $(Lib)(i4add.o) \ + $(Lib)(i4addtag.o) \ + $(Lib)(i4check.o) \ + $(Lib)(i4create.o) \ + $(Lib)(i4dump.o) \ + $(Lib)(i4index.o) \ + $(Lib)(i4info.o) \ + $(Lib)(i4init.o) \ + $(Lib)(i4key.o) \ + $(Lib)(i4lock.o) \ + $(Lib)(i4ntag.o) \ + $(Lib)(i4positi.o) \ + $(Lib)(i4remove.o) \ + $(Lib)(i4tag.o) \ + $(Lib)(l4link.o) \ + $(Lib)(l4lock_c.o) \ + $(Lib)(m4check.o) \ + $(Lib)(m4create.o) \ + $(Lib)(m4file.o) \ + $(Lib)(m4map.o) \ + $(Lib)(m4memo.o) \ + $(Lib)(m4memory.o) \ + $(Lib)(o4opt.o) \ + $(Lib)(r4area.o) \ + $(Lib)(r4bit.o) \ + $(Lib)(r4driver.o) \ + $(Lib)(r4drive2.o) \ + $(Lib)(r4group.o) \ + $(Lib)(r4log.o) \ + $(Lib)(r4obj.o) \ + $(Lib)(r4reinde.o) \ + $(Lib)(r4reindx.o) \ + $(Lib)(r4relate.o) \ + $(Lib)(r4report.o) \ + $(Lib)(r4save.o) \ + $(Lib)(r4save_2.o) \ + $(Lib)(r4style.o) \ + $(Lib)(r4total.o) \ + $(Lib)(s4init.o) \ + $(Lib)(s4initfr.o) \ + $(Lib)(s4next.o) \ + $(Lib)(s4quick.o) \ + $(Lib)(s4sort.o) \ + $(Lib)(u4name.o) \ + $(Lib)(u4util.o) \ + $(Lib)(x4filter.o) # *Compile* -libcb.a : $(Object_files) cb_build - cb_build +$(Lib) : $(Object_files) cb_build + cb_build $(Lib) -b4block.o: b4block.c $(Header_files) - $(Compiler) $(Compiler_options) b4block.c +$(Lib)(b4block.o): b4block.c $(Header_files) + $(Compiler) $(Compiler_options) b4block -c4.o : c4.c $(Header_files) - $(Compiler) $(Compiler_options) c4.c +$(Lib)(c4.o) : c4.c $(Header_files) + $(Compiler) $(Compiler_options) c4 -c4bcd.o : c4bcd.c $(Header_files) - $(Compiler) $(Compiler_options) c4bcd.c +$(Lib)(c4bcd.o) : c4bcd.c $(Header_files) + $(Compiler) $(Compiler_options) c4bcd -c4code.o : c4code.c $(Header_files) - $(Compiler) $(Compiler_options) c4code.c +$(Lib)(c4code.o) : c4code.c $(Header_files) + $(Compiler) $(Compiler_options) c4code -c4const.o : c4const.c $(Header_files) - $(Compiler) $(Compiler_options) c4const.c +$(Lib)(c4const.o) : c4const.c $(Header_files) + $(Compiler) $(Compiler_options) c4const -d4append.o : d4append.c $(Header_files) - $(Compiler) $(Compiler_options) d4append.c +$(Lib)(d4append.o) : d4append.c $(Header_files) + $(Compiler) $(Compiler_options) d4append -d4close.o : d4close.c $(Header_files) - $(Compiler) $(Compiler_options) d4close.c +$(Lib)(d4close.o) : d4close.c $(Header_files) + $(Compiler) $(Compiler_options) d4close -d4create.o : d4create.c $(Header_files) - $(Compiler) $(Compiler_options) d4create.c +$(Lib)(d4create.o) : d4create.c $(Header_files) + $(Compiler) $(Compiler_options) d4create -d4data.o : d4data.c $(Header_files) - $(Compiler) $(Compiler_options) d4data.c +$(Lib)(d4data.o) : d4data.c $(Header_files) + $(Compiler) $(Compiler_options) d4data -d4date.o : d4date.c $(Header_files) - $(Compiler) $(Compiler_options) d4date.c +$(Lib)(d4date.o) : d4date.c $(Header_files) + $(Compiler) $(Compiler_options) d4date -d4field.o : d4field.c $(Header_files) - $(Compiler) $(Compiler_options) d4field.c +$(Lib)(d4field.o) : d4field.c $(Header_files) + $(Compiler) $(Compiler_options) d4field -d4flush.o : d4flush.c $(Header_files) - $(Compiler) $(Compiler_options) d4flush.c +$(Lib)(d4flush.o) : d4flush.c $(Header_files) + $(Compiler) $(Compiler_options) d4flush -d4fresh.o : d4fresh.c $(Header_files) - $(Compiler) $(Compiler_options) d4fresh.c +$(Lib)(d4fresh.o) : d4fresh.c $(Header_files) + $(Compiler) $(Compiler_options) d4fresh -d4go.o : d4go.c $(Header_files) - $(Compiler) $(Compiler_options) d4go.c +$(Lib)(d4go.o) : d4go.c $(Header_files) + $(Compiler) $(Compiler_options) d4go -d4lock.o : d4lock.c $(Header_files) - $(Compiler) $(Compiler_options) d4lock.c +$(Lib)(d4lock.o) : d4lock.c $(Header_files) + $(Compiler) $(Compiler_options) d4lock -d4index.o : d4index.c $(Header_files) - $(Compiler) $(Compiler_options) d4index.c +$(Lib)(d4index.o) : d4index.c $(Header_files) + $(Compiler) $(Compiler_options) d4index -d4open.o : d4open.c $(Header_files) - $(Compiler) $(Compiler_options) d4open.c +$(Lib)(d4open.o) : d4open.c $(Header_files) + $(Compiler) $(Compiler_options) d4open -d4opt.o : d4opt.c $(Header_files) - $(Compiler) $(Compiler_options) d4opt.c +$(Lib)(d4opt.o) : d4opt.c $(Header_files) + $(Compiler) $(Compiler_options) d4opt -d4pack.o : d4pack.c $(Header_files) - $(Compiler) $(Compiler_options) d4pack.c +$(Lib)(d4pack.o) : d4pack.c $(Header_files) + $(Compiler) $(Compiler_options) d4pack -d4positi.o : d4positi.c $(Header_files) - $(Compiler) $(Compiler_options) d4positi.c +$(Lib)(d4positi.o) : d4positi.c $(Header_files) + $(Compiler) $(Compiler_options) d4positi -d4seek.o : d4seek.c $(Header_files) - $(Compiler) $(Compiler_options) d4seek.c +$(Lib)(d4seek.o) : d4seek.c $(Header_files) + $(Compiler) $(Compiler_options) d4seek -d4skip.o : d4skip.c $(Header_files) - $(Compiler) $(Compiler_options) d4skip.c +$(Lib)(d4skip.o) : d4skip.c $(Header_files) + $(Compiler) $(Compiler_options) d4skip -d4tag.o : d4tag.c $(Header_files) - $(Compiler) $(Compiler_options) d4tag.c +$(Lib)(d4tag.o) : d4tag.c $(Header_files) + $(Compiler) $(Compiler_options) d4tag -d4unlock.o : d4unlock.c $(Header_files) - $(Compiler) $(Compiler_options) d4unlock.c +$(Lib)(d4unlock.o) : d4unlock.c $(Header_files) + $(Compiler) $(Compiler_options) d4unlock -d4write.o : d4write.c $(Header_files) - $(Compiler) $(Compiler_options) d4write.c +$(Lib)(d4write.o) : d4write.c $(Header_files) + $(Compiler) $(Compiler_options) d4write -d4zap.o : d4zap.c $(Header_files) - $(Compiler) $(Compiler_options) d4zap.c +$(Lib)(d4zap.o) : d4zap.c $(Header_files) + $(Compiler) $(Compiler_options) d4zap -e4calc.o : e4calc.c $(Header_files) - $(Compiler) $(Compiler_options) e4calc.c +$(Lib)(e4calc.o) : e4calc.c $(Header_files) + $(Compiler) $(Compiler_options) e4calc -e4calc_2.o : e4calc_2.c $(Header_files) - $(Compiler) $(Compiler_options) e4calc_2.c +$(Lib)(e4calc_2.o) : e4calc_2.c $(Header_files) + $(Compiler) $(Compiler_options) e4calc_2 -e4error.o : e4error.c $(Header_files) - $(Compiler) $(Compiler_options) e4error.c +$(Lib)(e4error.o) : e4error.c $(Header_files) + $(Compiler) $(Compiler_options) e4error -e4expr.o : e4expr.c $(Header_files) - $(Compiler) $(Compiler_options) e4expr.c +$(Lib)(e4expr.o) : e4expr.c $(Header_files) + $(Compiler) $(Compiler_options) e4expr -e4not_s.o : e4not_s.c $(Header_files) - $(Compiler) $(Compiler_options) e4not_s.c +$(Lib)(e4not_s.o) : e4not_s.c $(Header_files) + $(Compiler) $(Compiler_options) e4not_s -e4functi.o : e4functi.c $(Header_files) - $(Compiler) $(Compiler_options) e4functi.c +$(Lib)(e4functi.o) : e4functi.c $(Header_files) + $(Compiler) $(Compiler_options) e4functi -e4parse.o : e4parse.c $(Header_files) - $(Compiler) $(Compiler_options) e4parse.c +$(Lib)(e4parse.o) : e4parse.c $(Header_files) + $(Compiler) $(Compiler_options) e4parse -f4ass_f.o : f4ass_f.c $(Header_files) - $(Compiler) $(Compiler_options) f4ass_f.c +$(Lib)(f4ass_f.o) : f4ass_f.c $(Header_files) + $(Compiler) $(Compiler_options) f4ass_f -f4char.o : f4char.c $(Header_files) - $(Compiler) $(Compiler_options) f4char.c +$(Lib)(f4char.o) : f4char.c $(Header_files) + $(Compiler) $(Compiler_options) f4char -f4close.o : f4close.c $(Header_files) - $(Compiler) $(Compiler_options) f4close.c +$(Lib)(f4close.o) : f4close.c $(Header_files) + $(Compiler) $(Compiler_options) f4close -f4create.o : f4create.c $(Header_files) - $(Compiler) $(Compiler_options) f4create.c +$(Lib)(f4create.o) : f4create.c $(Header_files) + $(Compiler) $(Compiler_options) f4create -f4double.o : f4double.c $(Header_files) - $(Compiler) $(Compiler_options) f4double.c +$(Lib)(f4double.o) : f4double.c $(Header_files) + $(Compiler) $(Compiler_options) f4double -f4field.o : f4field.c $(Header_files) - $(Compiler) $(Compiler_options) f4field.c +$(Lib)(f4field.o) : f4field.c $(Header_files) + $(Compiler) $(Compiler_options) f4field -f4file.o : f4file.c $(Header_files) - $(Compiler) $(Compiler_options) f4file.c +$(Lib)(f4file.o) : f4file.c $(Header_files) + $(Compiler) $(Compiler_options) f4file -f4filese.o : f4filese.c $(Header_files) - $(Compiler) $(Compiler_options) f4filese.c +$(Lib)(f4filese.o) : f4filese.c $(Header_files) + $(Compiler) $(Compiler_options) f4filese -f4flag.o : f4flag.c $(Header_files) - $(Compiler) $(Compiler_options) f4flag.c +$(Lib)(f4flag.o) : f4flag.c $(Header_files) + $(Compiler) $(Compiler_options) f4flag -f4flush.o : f4flush.c $(Header_files) - $(Compiler) $(Compiler_options) f4flush.c +$(Lib)(f4flush.o) : f4flush.c $(Header_files) + $(Compiler) $(Compiler_options) f4flush -f4info.o : f4info.c $(Header_files) - $(Compiler) $(Compiler_options) f4info.c +$(Lib)(f4info.o) : f4info.c $(Header_files) + $(Compiler) $(Compiler_options) f4info -f4int.o : f4int.c $(Header_files) - $(Compiler) $(Compiler_options) f4int.c +$(Lib)(f4int.o) : f4int.c $(Header_files) + $(Compiler) $(Compiler_options) f4int -f4lock.o : f4lock.c $(Header_files) - $(Compiler) $(Compiler_options) f4lock.c +$(Lib)(f4lock.o) : f4lock.c $(Header_files) + $(Compiler) -u _POSIX_SOURCE $(Compiler_options) f4lock -f4long.o : f4long.c $(Header_files) - $(Compiler) $(Compiler_options) f4long.c +$(Lib)(f4long.o) : f4long.c $(Header_files) + $(Compiler) $(Compiler_options) f4long -f4memo.o : f4memo.c $(Header_files) - $(Compiler) $(Compiler_options) f4memo.c +$(Lib)(f4memo.o) : f4memo.c $(Header_files) + $(Compiler) $(Compiler_options) f4memo -f4open.o : f4open.c $(Header_files) - $(Compiler) $(Compiler_options) f4open.c +$(Lib)(f4open.o) : f4open.c $(Header_files) + $(Compiler) $(Compiler_options) f4open -f4opt.o : f4opt.c $(Header_files) - $(Compiler) $(Compiler_options) f4opt.c +$(Lib)(f4opt.o) : f4opt.c $(Header_files) + $(Compiler) $(Compiler_options) f4opt -f4ptr.o : f4ptr.c $(Header_files) - $(Compiler) $(Compiler_options) f4ptr.c +$(Lib)(f4ptr.o) : f4ptr.c $(Header_files) + $(Compiler) $(Compiler_options) f4ptr -f4str.o : f4str.c $(Header_files) - $(Compiler) $(Compiler_options) f4str.c +$(Lib)(f4str.o) : f4str.c $(Header_files) + $(Compiler) $(Compiler_options) f4str -f4temp.o : f4temp.c $(Header_files) - $(Compiler) $(Compiler_options) f4temp.c +$(Lib)(f4temp.o) : f4temp.c $(Header_files) + $(Compiler) $(Compiler_options) f4temp -f4true.o : f4true.c $(Header_files) - $(Compiler) $(Compiler_options) f4true.c +$(Lib)(f4true.o) : f4true.c $(Header_files) + $(Compiler) $(Compiler_options) f4true -f4write.o : f4write.c $(Header_files) - $(Compiler) $(Compiler_options) f4write.c +$(Lib)(f4write.o) : f4write.c $(Header_files) + $(Compiler) $(Compiler_options) f4write -i4add.o : i4add.c $(Header_files) - $(Compiler) $(Compiler_options) i4add.c +$(Lib)(i4add.o) : i4add.c $(Header_files) + $(Compiler) $(Compiler_options) i4add -i4addtag.o : i4addtag.c $(Header_files) - $(Compiler) $(Compiler_options) i4addtag.c +$(Lib)(i4addtag.o) : i4addtag.c $(Header_files) + $(Compiler) $(Compiler_options) i4addtag -i4check.o : i4check.c $(Header_files) - $(Compiler) $(Compiler_options) i4check.c +$(Lib)(i4check.o) : i4check.c $(Header_files) + $(Compiler) $(Compiler_options) i4check -i4create.o : i4create.c $(Header_files) - $(Compiler) $(Compiler_options) i4create.c +$(Lib)(i4create.o) : i4create.c $(Header_files) + $(Compiler) $(Compiler_options) i4create -i4dump.o : i4dump.c $(Header_files) - $(Compiler) $(Compiler_options) i4dump.c +$(Lib)(i4dump.o) : i4dump.c $(Header_files) + $(Compiler) $(Compiler_options) i4dump -i4index.o : i4index.c $(Header_files) - $(Compiler) $(Compiler_options) i4index.c +$(Lib)(i4index.o) : i4index.c $(Header_files) + $(Compiler) $(Compiler_options) i4index -i4info.o : i4info.c $(Header_files) - $(Compiler) $(Compiler_options) i4info.c +$(Lib)(i4info.o) : i4info.c $(Header_files) + $(Compiler) $(Compiler_options) i4info -i4init.o : i4init.c $(Header_files) - $(Compiler) $(Compiler_options) i4init.c +$(Lib)(i4init.o) : i4init.c $(Header_files) + $(Compiler) $(Compiler_options) i4init -i4key.o : i4key.c $(Header_files) - $(Compiler) $(Compiler_options) i4key.c +$(Lib)(i4key.o) : i4key.c $(Header_files) + $(Compiler) $(Compiler_options) i4key -i4lock.o : i4lock.c $(Header_files) - $(Compiler) $(Compiler_options) i4lock.c +$(Lib)(i4lock.o) : i4lock.c $(Header_files) + $(Compiler) $(Compiler_options) i4lock -i4ntag.o : i4ntag.c $(Header_files) - $(Compiler) $(Compiler_options) i4ntag.c +$(Lib)(i4ntag.o) : i4ntag.c $(Header_files) + $(Compiler) $(Compiler_options) i4ntag -i4positi.o : i4positi.c $(Header_files) - $(Compiler) $(Compiler_options) i4positi.c +$(Lib)(i4positi.o) : i4positi.c $(Header_files) + $(Compiler) $(Compiler_options) i4positi -i4remove.o : i4remove.c $(Header_files) - $(Compiler) $(Compiler_options) i4remove.c +$(Lib)(i4remove.o) : i4remove.c $(Header_files) + $(Compiler) $(Compiler_options) i4remove -i4tag.o : i4tag.c $(Header_files) - $(Compiler) $(Compiler_options) i4tag.c +$(Lib)(i4tag.o) : i4tag.c $(Header_files) + $(Compiler) $(Compiler_options) i4tag -l4link.o : l4link.c $(Header_files) - $(Compiler) $(Compiler_options) l4link.c +$(Lib)(l4link.o) : l4link.c $(Header_files) + $(Compiler) $(Compiler_options) l4link -l4lock_c.o : l4lock_c.c $(Header_files) - $(Compiler) $(Compiler_options) l4lock_c.c +$(Lib)(l4lock_c.o) : l4lock_c.c $(Header_files) + $(Compiler) $(Compiler_options) l4lock_c -m4check.o : m4check.c $(Header_files) - $(Compiler) $(Compiler_options) m4check.c +$(Lib)(m4check.o) : m4check.c $(Header_files) + $(Compiler) $(Compiler_options) m4check -m4create.o : m4create.c $(Header_files) - $(Compiler) $(Compiler_options) m4create.c +$(Lib)(m4create.o) : m4create.c $(Header_files) + $(Compiler) $(Compiler_options) m4create -m4file.o : m4file.c $(Header_files) - $(Compiler) $(Compiler_options) m4file.c +$(Lib)(m4file.o) : m4file.c $(Header_files) + $(Compiler) $(Compiler_options) m4file -m4map.o : m4map.c $(Header_files) - $(Compiler) $(Compiler_options) m4map.c +$(Lib)(m4map.o) : m4map.c $(Header_files) + $(Compiler) $(Compiler_options) m4map -m4memo.o : m4memo.c $(Header_files) - $(Compiler) $(Compiler_options) m4memo.c +$(Lib)(m4memo.o) : m4memo.c $(Header_files) + $(Compiler) $(Compiler_options) m4memo -m4memory.o : m4memory.c $(Header_files) - $(Compiler) $(Compiler_options) m4memory.c +$(Lib)(m4memory.o) : m4memory.c $(Header_files) + $(Compiler) $(Compiler_options) m4memory -o4opt.o : o4opt.c $(Header_files) - $(Compiler) $(Compiler_options) o4opt.c +$(Lib)(o4opt.o) : o4opt.c $(Header_files) + $(Compiler) $(Compiler_options) o4opt -r4area.o : r4area.c $(Header_files) - $(Compiler) $(Compiler_options) r4area.c +$(Lib)(r4area.o) : r4area.c $(Header_files) + $(Compiler) $(Compiler_options) r4area -r4bit.o : r4bit.c $(Header_files) - $(Compiler) $(Compiler_options) r4bit.c +$(Lib)(r4bit.o) : r4bit.c $(Header_files) + $(Compiler) $(Compiler_options) r4bit -r4driver.o : r4driver.c $(Header_files) - $(Compiler) $(Compiler_options) r4driver.c +$(Lib)(r4driver.o) : r4driver.c $(Header_files) + $(Compiler) $(Compiler_options) r4driver -r4drive2.o : r4drive2.c $(Header_files) - $(Compiler) $(Compiler_options) r4drive2.c +$(Lib)(r4drive2.o) : r4drive2.c $(Header_files) + $(Compiler) $(Compiler_options) r4drive2 -r4group.o : r4group.c $(Header_files) - $(Compiler) $(Compiler_options) r4group.c +$(Lib)(r4group.o) : r4group.c $(Header_files) + $(Compiler) $(Compiler_options) r4group -r4log.o : r4log.c $(Header_files) - $(Compiler) $(Compiler_options) r4log.c +$(Lib)(r4log.o) : r4log.c $(Header_files) + $(Compiler) $(Compiler_options) r4log -r4obj.o : r4obj.c $(Header_files) - $(Compiler) $(Compiler_options) r4obj.c +$(Lib)(r4obj.o) : r4obj.c $(Header_files) + $(Compiler) $(Compiler_options) r4obj -r4reinde.o : r4reinde.c $(Header_files) - $(Compiler) $(Compiler_options) r4reinde.c +$(Lib)(r4reinde.o) : r4reinde.c $(Header_files) + $(Compiler) $(Compiler_options) r4reinde -r4reindx.o : r4reindx.c $(Header_files) - $(Compiler) $(Compiler_options) r4reindx.c +$(Lib)(r4reindx.o) : r4reindx.c $(Header_files) + $(Compiler) $(Compiler_options) r4reindx -r4relate.o : r4relate.c $(Header_files) - $(Compiler) $(Compiler_options) r4relate.c +$(Lib)(r4relate.o) : r4relate.c $(Header_files) + $(Compiler) $(Compiler_options) r4relate -r4report.o : r4report.c $(Header_files) - $(Compiler) $(Compiler_options) r4report.c +$(Lib)(r4report.o) : r4report.c $(Header_files) + $(Compiler) $(Compiler_options) r4report -r4save.o : r4save.c $(Header_files) - $(Compiler) $(Compiler_options) r4save.c +$(Lib)(r4save.o) : r4save.c $(Header_files) + $(Compiler) $(Compiler_options) r4save -r4save_2.o : r4save_2.c $(Header_files) - $(Compiler) $(Compiler_options) r4save_2.c +$(Lib)(r4save_2.o) : r4save_2.c $(Header_files) + $(Compiler) $(Compiler_options) r4save_2 -r4style.o : r4style.c $(Header_files) - $(Compiler) $(Compiler_options) r4style.c +$(Lib)(r4style.o) : r4style.c $(Header_files) + $(Compiler) $(Compiler_options) r4style -r4total.o : r4total.c $(Header_files) - $(Compiler) $(Compiler_options) r4total.c +$(Lib)(r4total.o) : r4total.c $(Header_files) + $(Compiler) $(Compiler_options) r4total -s4init.o : s4init.c $(Header_files) - $(Compiler) $(Compiler_options) s4init.c +$(Lib)(s4init.o) : s4init.c $(Header_files) + $(Compiler) $(Compiler_options) s4init -s4initfr.o : s4initfr.c $(Header_files) - $(Compiler) $(Compiler_options) s4initfr.c +$(Lib)(s4initfr.o) : s4initfr.c $(Header_files) + $(Compiler) $(Compiler_options) s4initfr -s4next.o : s4next.c $(Header_files) - $(Compiler) $(Compiler_options) s4next.c +$(Lib)(s4next.o) : s4next.c $(Header_files) + $(Compiler) $(Compiler_options) s4next -s4quick.o : s4quick.c $(Header_files) - $(Compiler) $(Compiler_options) s4quick.c +$(Lib)(s4quick.o) : s4quick.c $(Header_files) + $(Compiler) $(Compiler_options) s4quick -s4sort.o : s4sort.c $(Header_files) - $(Compiler) $(Compiler_options) s4sort.c +$(Lib)(s4sort.o) : s4sort.c $(Header_files) + $(Compiler) $(Compiler_options) s4sort -u4name.o : u4name.c $(Header_files) - $(Compiler) $(Compiler_options) u4name.c +$(Lib)(u4name.o) : u4name.c $(Header_files) + $(Compiler) $(Compiler_options) u4name -u4util.o : u4util.c $(Header_files) - $(Compiler) $(Compiler_options) u4util.c +$(Lib)(u4util.o) : u4util.c $(Header_files) + $(Compiler) $(Compiler_options) u4util + +$(Lib)(x4filter.o) : x4filter.c $(Header_files) + $(Compiler) $(Compiler_options) x4filter diff --git a/cb5/compile b/cb5/compile index f346e00ce..b36af40b0 100755 --- a/cb5/compile +++ b/cb5/compile @@ -1,100 +1,100 @@ -cc -c -M3 b4block.c 2>out -cc -c -M3 c4.c 2>>out -cc -c -M3 c4bcd.c 2>>out -cc -c -M3 c4code.c 2>>out -cc -c -M3 c4const.c 2>>out -cc -c -M3 d4append.c 2>>out -cc -c -M3 d4close.c 2>>out -cc -c -M3 d4create.c 2>>out -cc -c -M3 d4data.c 2>>out -cc -c -M3 d4date.c 2>>out -cc -c -M3 d4field.c 2>>out -cc -c -M3 d4flush.c 2>>out -cc -c -M3 d4fresh.c 2>>out -cc -c -M3 d4go.c 2>>out -cc -c -M3 d4index.c 2>>out -cc -c -M3 d4lock.c 2>>out -cc -c -M3 d4open.c 2>>out -cc -c -M3 d4opt.c 2>>out -cc -c -M3 d4pack.c 2>>out -cc -c -M3 d4positi.c 2>>out -cc -c -M3 d4seek.c 2>>out -cc -c -M3 d4skip.c 2>>out -cc -c -M3 d4tag.c 2>>out -cc -c -M3 d4unlock.c 2>>out -cc -c -M3 d4write.c 2>>out -cc -c -M3 d4zap.c 2>>out -cc -c -M3 e4calc.c 2>>out -cc -c -M3 e4calc_2.c 2>>out -cc -c -M3 e4error.c 2>>out -cc -c -M3 e4expr.c 2>>out -cc -c -M3 e4functi.c 2>>out -cc -c -M3 e4not_s.c 2>>out -cc -c -M3 e4parse.c 2>>out -cc -c -M3 f4ass_f.c 2>>out -cc -c -M3 f4char.c 2>>out -cc -c -M3 f4close.c 2>>out -cc -c -M3 f4create.c 2>>out -cc -c -M3 f4double.c 2>>out -cc -c -M3 f4field.c 2>>out -cc -c -M3 f4file.c 2>>out -cc -c -M3 f4filese.c 2>>out -cc -c -M3 f4flag.c 2>>out -cc -c -M3 f4flush.c 2>>out -cc -c -M3 f4info.c 2>>out -cc -c -M3 f4int.c 2>>out -cc -c -M3 f4lock.c 2>>out -cc -c -M3 f4long.c 2>>out -cc -c -M3 f4memo.c 2>>out -cc -c -M3 f4open.c 2>>out -cc -c -M3 f4opt.c 2>>out -cc -c -M3 f4ptr.c 2>>out -cc -c -M3 f4str.c 2>>out -cc -c -M3 f4temp.c 2>>out -cc -c -M3 f4true.c 2>>out -cc -c -M3 f4write.c 2>>out -cc -c -M3 i4add.c 2>>out -cc -c -M3 i4addtag.c 2>>out -cc -c -M3 i4check.c 2>>out -cc -c -M3 i4create.c 2>>out -cc -c -M3 i4dump.c 2>>out -cc -c -M3 i4index.c 2>>out -cc -c -M3 i4info.c 2>>out -cc -c -M3 i4init.c 2>>out -cc -c -M3 i4key.c 2>>out -cc -c -M3 i4lock.c 2>>out -cc -c -M3 i4ntag.c 2>>out -cc -c -M3 i4positi.c 2>>out -cc -c -M3 i4remove.c 2>>out -cc -c -M3 i4tag.c 2>>out -cc -c -M3 l4link.c 2>>out -cc -c -M3 l4lock_c.c 2>>out -cc -c -M3 m4check.c 2>>out -cc -c -M3 m4create.c 2>>out -cc -c -M3 m4file.c 2>>out -cc -c -M3 m4map.c 2>>out -cc -c -M3 m4memo.c 2>>out -cc -c -M3 m4memory.c 2>>out -cc -c -M3 o4opt.c 2>>out -cc -c -M3 r4area.c 2>>out -cc -c -M3 r4bit.c 2>>out -cc -c -M3 r4drive2.c 2>>out -cc -c -M3 r4driver.c 2>>out -cc -c -M3 r4group.c 2>>out -cc -c -M3 r4log.c 2>>out -cc -c -M3 r4obj.c 2>>out -cc -c -M3 r4reinde.c 2>>out -cc -c -M3 r4reindx.c 2>>out -cc -c -M3 r4relate.c 2>>out -cc -c -M3 r4report.c 2>>out -cc -c -M3 r4save.c 2>>out -cc -c -M3 r4save_2.c 2>>out -cc -c -M3 r4style.c 2>>out -cc -c -M3 r4total.c 2>>out -cc -c -M3 s4init.c 2>>out -cc -c -M3 s4initfr.c 2>>out -cc -c -M3 s4next.c 2>>out -cc -c -M3 s4quick.c 2>>out -cc -c -M3 s4sort.c 2>>out -cc -c -M3 u4name.c 2>>out -cc -c -M3 u4util.c 2>>out +gcc -c b4block.c 2>out +gcc -c c4.c 2>>out +gcc -c c4bcd.c 2>>out +gcc -c c4code.c 2>>out +gcc -c c4const.c 2>>out +gcc -c d4append.c 2>>out +gcc -c d4close.c 2>>out +gcc -c d4create.c 2>>out +gcc -c d4data.c 2>>out +gcc -c d4date.c 2>>out +gcc -c d4field.c 2>>out +gcc -c d4flush.c 2>>out +gcc -c d4fresh.c 2>>out +gcc -c d4go.c 2>>out +gcc -c d4index.c 2>>out +gcc -c d4lock.c 2>>out +gcc -c d4open.c 2>>out +gcc -c d4opt.c 2>>out +gcc -c d4pack.c 2>>out +gcc -c d4positi.c 2>>out +gcc -c d4seek.c 2>>out +gcc -c d4skip.c 2>>out +gcc -c d4tag.c 2>>out +gcc -c d4unlock.c 2>>out +gcc -c d4write.c 2>>out +gcc -c d4zap.c 2>>out +gcc -c e4calc.c 2>>out +gcc -c e4calc_2.c 2>>out +gcc -c e4error.c 2>>out +gcc -c e4expr.c 2>>out +gcc -c e4functi.c 2>>out +gcc -c e4not_s.c 2>>out +gcc -c e4parse.c 2>>out +gcc -c f4ass_f.c 2>>out +gcc -c f4char.c 2>>out +gcc -c f4close.c 2>>out +gcc -c f4create.c 2>>out +gcc -c f4double.c 2>>out +gcc -c f4field.c 2>>out +gcc -c f4file.c 2>>out +gcc -c f4filese.c 2>>out +gcc -c f4flag.c 2>>out +gcc -c f4flush.c 2>>out +gcc -c f4info.c 2>>out +gcc -c f4int.c 2>>out +gcc -c f4lock.c 2>>out +gcc -c f4long.c 2>>out +gcc -c f4memo.c 2>>out +gcc -c f4open.c 2>>out +gcc -c f4opt.c 2>>out +gcc -c f4ptr.c 2>>out +gcc -c f4str.c 2>>out +gcc -c f4temp.c 2>>out +gcc -c f4true.c 2>>out +gcc -c f4write.c 2>>out +gcc -c i4add.c 2>>out +gcc -c i4addtag.c 2>>out +gcc -c i4check.c 2>>out +gcc -c i4create.c 2>>out +gcc -c i4dump.c 2>>out +gcc -c i4index.c 2>>out +gcc -c i4info.c 2>>out +gcc -c i4init.c 2>>out +gcc -c i4key.c 2>>out +gcc -c i4lock.c 2>>out +gcc -c i4ntag.c 2>>out +gcc -c i4positi.c 2>>out +gcc -c i4remove.c 2>>out +gcc -c i4tag.c 2>>out +gcc -c l4link.c 2>>out +gcc -c l4lock_c.c 2>>out +gcc -c m4check.c 2>>out +gcc -c m4create.c 2>>out +gcc -c m4file.c 2>>out +gcc -c m4map.c 2>>out +gcc -c m4memo.c 2>>out +gcc -c m4memory.c 2>>out +gcc -c o4opt.c 2>>out +gcc -c r4area.c 2>>out +gcc -c r4bit.c 2>>out +gcc -c r4drive2.c 2>>out +gcc -c r4driver.c 2>>out +gcc -c r4group.c 2>>out +gcc -c r4log.c 2>>out +gcc -c r4obj.c 2>>out +gcc -c r4reinde.c 2>>out +gcc -c r4reindx.c 2>>out +gcc -c r4relate.c 2>>out +gcc -c r4report.c 2>>out +gcc -c r4save.c 2>>out +gcc -c r4save_2.c 2>>out +gcc -c r4style.c 2>>out +gcc -c r4total.c 2>>out +gcc -c s4init.c 2>>out +gcc -c s4initfr.c 2>>out +gcc -c s4next.c 2>>out +gcc -c s4quick.c 2>>out +gcc -c s4sort.c 2>>out +gcc -c u4name.c 2>>out +gcc -c u4util.c 2>>out diff --git a/cb5/d4all.h b/cb5/d4all.h index e44f59e96..4bf1ea368 100755 --- a/cb5/d4all.h +++ b/cb5/d4all.h @@ -4,7 +4,7 @@ /********** USER SWITCH SETTINGS AREA ***********/ /* Index File compatibility options */ -#define S4FOX +/* #define S4FOX */ /* #define S4CLIPPER */ /* #define S4MDX */ /* #define S4NDX */ @@ -17,7 +17,7 @@ /* #define S4OS2 */ /* #define S4OS2DLL */ /* OS/2 PRESENTATION MANAGER DLL LIBRARY */ /* #define S4OS2PM */ /* OS/2 PRESENTATION MANAGER STATIC LIBRARY */ -#define S4UNIX /* requires Multi-Platform Version */ +/* #define S4UNIX */ /* requires Multi-Platform Version */ /* #define S4MACINTOSH */ /* requires Multi-Platform Version */ /* #define S4CODE_SCREENS */ /* #define S4CONTROLS */ /* for use with CodeControls DLL */ @@ -28,11 +28,11 @@ /* General Configuration Options */ /* #define S4DEBUG */ /* #define S4DEBUG_DEV */ -/* #define S4ERROR_HOOK */ +#define S4ERROR_HOOK /* #define S4LOCK_CHECK */ /* #define S4LOCK_HOOK */ /* #define S4MAX */ -/* #define S4MEMO_OFF */ +#define S4MEMO_OFF /* #define S4OFF_ERROR */ /* #define S4OFF_INDEX */ /* #define S4OFF_MEMO */ @@ -42,7 +42,7 @@ /* #define S4OFF_WRITE */ /* #define S4OLD_CODE */ /* #define S4OPTIMIZE_OFF */ -/* #define S4SAFE */ +#define S4SAFE /* #define S4SINGLE */ /**********************************************************************/ diff --git a/cb5/diag b/cb5/diag index 09e3a4e49..9db0c308e 100755 --- a/cb5/diag +++ b/cb5/diag @@ -1,28 +1,29 @@ rm out rm t4*.o -cc -c -M3 t4main.c -cc -c -M3 t4test.c -cc -M3 t4bcd.c c4bcd.c t4test.o t4main.o -o t4bcd -lx -lcb -cc -M3 t4conv.c t4test.o t4main.o -o t4conv -lx -lcb -cc -M3 t4data.c t4test.o t4main.o -o t4data -lx -lcb -cc -M3 t4expr.c t4test.o t4main.o -o t4expr -lx -lcb -cc -M3 t4index.c t4test.o t4main.o -o t4index -lx -lcb -cc -M3 t4index2.c t4test.o t4main.o -o t4index2 -lx -lcb -cc -M3 t4large.c t4test.o t4main.o -o t4large -lx -lcb -cc -M3 t4max.c t4test.o t4main.o -o t4max -lx -lcb -cc -M3 t4memo.c t4test.o t4main.o -o t4memo -lx -lcb -cc -M3 t4mul.c t4test.o t4main.o -o t4mul -lx -lcb -cc -M3 t4mul2.c t4test.o t4main.o -o t4mul2 -lx -lcb -cc -M3 t4pack_z.c t4test.o t4main.o -o t4pack_z -lx -lcb -cc -M3 t4positi.c t4test.o t4main.o -o t4positi -lx -lcb -cc -M3 t4seek.c t4test.o t4main.o -o t4seek -lx -lcb -cc -M3 t4skip.c t4test.o t4main.o -o t4skip -lx -lcb -cc -M3 t4sort.c t4test.o t4main.o -o t4sort -lx -lcb -cc -M3 t4sort2.c t4test.o t4main.o -o t4sort2 -lx -lcb -cc -M3 t4unique.c t4test.o t4main.o -o t4unique -lx -lcb -cc -M3 t4write.c t4test.o t4main.o -o t4write -lx -lcb -cc -M3 t4write2.c t4test.o t4main.o -o t4write2 -lx -lcb -cc -M3 t4write3.c t4test.o t4main.o -o t4write3 -lx -lcb +gcc -DS4UNIX -DS4FOX -c t4main.c +gcc -DS4UNIX -DS4FOX -c t4test.c +gcc -DS4UNIX -DS4FOX t4bcd.c c4bcd.c t4test.o t4main.o -o t4bcd -lx -lcb +gcc -DS4UNIX -DS4FOX t4conv.c t4test.o t4main.o -o t4conv -lx -lcb +gcc -DS4UNIX -DS4FOX t4data.c t4test.o t4main.o -o t4data -lx -lcb +gcc -DS4UNIX -DS4FOX t4expr.c t4test.o t4main.o -o t4expr -lx -lcb +gcc -DS4UNIX -DS4FOX t4index.c t4test.o t4main.o -o t4index -lx -lcb +gcc -DS4UNIX -DS4FOX t4index2.c t4test.o t4main.o -o t4index2 -lx -lcb +gcc -DS4UNIX -DS4FOX t4large.c t4test.o t4main.o -o t4large -lx -lcb +gcc -DS4UNIX -DS4FOX t4max.c t4test.o t4main.o -o t4max -lx -lcb +gcc -DS4UNIX -DS4FOX t4memo.c t4test.o t4main.o -o t4memo -lx -lcb +gcc -DS4UNIX -DS4FOX t4mul.c t4test.o t4main.o -o t4mul -lx -lcb +gcc -DS4UNIX -DS4FOX t4mul2.c t4test.o t4main.o -o t4mul2 -lx -lcb +gcc -DS4UNIX -DS4FOX t4pack_z.c t4test.o t4main.o -o t4pack_z -lx -lcb +gcc -DS4UNIX -DS4FOX t4positi.c t4test.o t4main.o -o t4positi -lx -lcb +gcc -DS4UNIX -DS4FOX t4seek.c t4test.o t4main.o -o t4seek -lx -lcb +gcc -DS4UNIX -DS4FOX t4skip.c t4test.o t4main.o -o t4skip -lx -lcb +gcc -DS4UNIX -DS4FOX t4sort.c t4test.o t4main.o -o t4sort -lx -lcb +gcc -DS4UNIX -DS4FOX t4sort2.c t4test.o t4main.o -o t4sort2 -lx -lcb +gcc -DS4UNIX -DS4FOX t4unique.c t4test.o t4main.o -o t4unique -lx -lcb +gcc -DS4UNIX -DS4FOX t4write.c t4test.o t4main.o -o t4write -lx -lcb +gcc -DS4UNIX -DS4FOX t4write2.c t4test.o t4main.o -o t4write2 -lx -lcb +gcc -DS4UNIX -DS4FOX t4write3.c t4test.o t4main.o -o t4write3 -lx -lcb +rm t4*.o t4bcd t4conv t4data @@ -32,6 +33,8 @@ t4index2 500 t4large t4max 1000 47 16384 2000 t4memo +t4mul +t4mul2 t4pack_z 1000 100 t4positi 1000 t4seek 999 @@ -42,3 +45,25 @@ t4unique t4write t4write2 1000 t4write3 1000 2048 +rm t4bcd +rm t4conv +rm t4data +rm t4expr +rm t4index +rm t4index2 +rm t4large +rm t4max +rm t4memo +rm t4mul +rm t4mul2 +rm t4pack_z +rm t4positi +rm t4seek +rm t4skip +rm t4sort +rm t4sort2 +rm t4unique +rm t4write +rm t4write2 +rm t4write3 +rm *.dbf *.cdx diff --git a/cb5/e4error.c b/cb5/e4error.c index e5987bf23..a997c154d 100755 --- a/cb5/e4error.c +++ b/cb5/e4error.c @@ -27,12 +27,12 @@ static void do_error_box( void ) ; #ifndef S4TEST /* Add alternative error display code here. Function e4hook() may be placed in your own separate source code - file, but ensure that the same function prototype as below is used. - void S4FUNCTION e4hook( CODE4 S4PTR *c4, int err_code, char *desc1, char *desc2, char *desc3 ) - { + file, but ensure that the same function prototype as below is used. */ +void S4FUNCTION e4hook( CODE4 S4PTR *c4, int err_code, char *desc1, char *desc2, char *desc3 ) +{ return ; - } - */ +} + #endif #ifdef S4TESTING diff --git a/cb5/i4init.c b/cb5/i4init.c index 412341516..cbe3297c2 100755 --- a/cb5/i4init.c +++ b/cb5/i4init.c @@ -521,21 +521,21 @@ void S4FUNCTION t4init_seek_conv( TAG4 *t4, int key_type ) #else case r4date: case r4date_doub: - t4->cmp = u4memcmp ; + t4->cmp = (S4CMP_FUNCTION *)u4memcmp ; t4->stok = t4no_change_str ; t4->dtok = t4date_doub_to_str ; break ; case r4num: case r4num_doub: - t4->cmp = u4memcmp ; + t4->cmp = (S4CMP_FUNCTION *)u4memcmp ; t4->stok = t4str_to_clip ; t4->dtok = 0 ; break ; #endif case r4str: - t4->cmp = u4memcmp ; + t4->cmp = (S4CMP_FUNCTION *)u4memcmp ; t4->stok = t4no_change_str ; t4->dtok = 0 ; break ; diff --git a/cb5/i4ntag.c b/cb5/i4ntag.c index 0b6015a26..acab69546 100755 --- a/cb5/i4ntag.c +++ b/cb5/i4ntag.c @@ -1314,7 +1314,7 @@ TAG4 *S4FUNCTION t4open( DATA4 *d4, INDEX4 *i4ndx, char *file_name ) t4->index = i4 ; t4->code_base = c4 ; -t4->cmp = u4memcmp ; +t4->cmp = (S4CMP_FUNCTION *)u4memcmp ; t4->header.root = -1 ; t4->header.old_version = t4->header.version ; diff --git a/cb5/p4port.h b/cb5/p4port.h index 88ac96ad8..1d7435cbb 100755 --- a/cb5/p4port.h +++ b/cb5/p4port.h @@ -4,6 +4,9 @@ CB 5.1 MULTI-PLATFORM RELEASE DATE: JULY 15/94 */ +#ifdef XVT_OS +#include +#endif #ifdef S4UNIX #define S4OPTIMIZE_OFF @@ -15,7 +18,7 @@ #define S4NO_ECVT #else #define S4LOCKF /* use function lockf() for locking */ -#define S4NO_MEMMOVE /* use if memmove() not found */ +/* #define S4NO_MEMMOVE */ /* use if memmove() not found */ #endif /* CodeBase Multi-Platform defines */ @@ -25,8 +28,8 @@ #define S4NO_FILELENGTH /* use if filelength() not found */ #define S4NO_NEGATIVE_LOCK /* use if negative locking not supported */ #define S4NO_POW /* use if pow() not found */ -#define S4NO_REMOVE /* use if remove() not found */ -#define S4NO_RENAME /* use if rename() not found */ +/* #define S4NO_REMOVE */ /* use if remove() not found */ +/* #define S4NO_RENAME */ /* use if rename() not found */ #define S4NO_STRLWR /* use if strlwr() not found */ #define S4NO_STRNICMP /* use if strnicmp() not found */ #define S4NO_STRUPR /* use if strupr() not found */ @@ -35,44 +38,54 @@ /* #define S4BYTEORDER_3210 */ /* use for 3210 systems */ /* #define S464BIT */ /* use for 64 bit systems */ /* #define S4BYTE_SWAP */ /* use for swapping bytes on 3210 or 2301 systems */ -/* #define S4MEMCMP */ /* use if memcmp() uses signed byte comparison */ +#define S4MEMCMP /* use if memcmp() uses signed byte comparison */ /* #define S4LSEEK */ /* use if lseek() cannot seek past EOF */ /* #define S4NO_ATOF */ /* use if atof() not found */ /* #define S4NO_ECVT */ /* use if ecvt() not found */ /* #define S4NO_FCVT */ /* use if fcvt() not found */ /* #define S4NO_SIZE_T */ /* use if variable size_t not found */ +/* #define S4NO_STDLIB */ /* use if no stdlib include file */ +/* #define S4NO_UNISTD */ /* use if no unistd include file */ +#endif + +#ifdef S4NO_SIZE_T +typedef unsigned size_t ; #endif #ifdef S4UNIX #define S4CMP_PARM void * /* These functions are usually declared */ #ifndef S4MACINTOSH /* in other system header files, and */ -extern long filelength() ; /* therefore most of these declarations */ -extern int atoi() ; /* are redundant. Sometimes, however, */ -extern long atol() ; /* the declaration is in a header file */ -extern int chsize() ; /* not included in the compile. In that */ -extern int close() ; /* case, compile and/or run-time errors */ -extern void exit() ; /* will be avoided because of these */ -extern int lock() ; /* declarations. */ -extern int locking() ; -extern void *malloc() ; /* malloc(), calloc() and realloc() may */ -extern void *calloc() ; /* return a 'char *' in some compilers. */ -extern void *realloc() ; /* if so, change 'void *' to 'char *' */ -extern void free() ; -extern int read() ; -extern long time() ; -extern int unlink() ; -extern int write() ; +extern long filelength(int hand) ; /* therefore most of these declarations */ +#ifdef S4NO_STDLIB +extern int atoi(char * nptr) ; /* are redundant. Sometimes, however, */ +extern long atol(char * nptr) ; /* the declaration is in a header file */ +#endif +extern int chsize(int fildes, long size) ; /* not included in the compile. In that */ +extern int close(int fildes) ; /* case, compile and/or run-time errors */ +extern void exit(int status) ; /* will be avoided because of these */ +extern int lock(int flag) ; /* declarations. */ +extern int locking(int fildes, int mode, long size) ; +extern void *malloc(size_t size) ; /* malloc(), calloc() and realloc() may */ +extern void *calloc(size_t nelem, size_t size) ; /* return a 'char *' in some compilers. */ +extern void *realloc(void * ptr, size_t size) ; /* if so, change 'void *' to 'char *' */ +extern void free(void * ptr) ; +extern long time(long * tloc) ; +#ifdef S4NO_UNISTD +extern int read(int fildes, char * buf, unsigned nbyte) ; +extern int unlink(char * path) ; +extern int write(int fildes, char * buf, unsigned nbyte) ; +#endif #ifndef S4NO_ECVT -extern char *ecvt() ; +extern char *ecvt(double value, int ndigit, int * decpt, int * sign) ; #ifndef S4NO_FCVT -extern char *fcvt() ; +extern char *fcvt(double value, int ndigit, int * decpt, int * sign) ; #endif #endif #ifndef S4LSEEK -extern long lseek() ; +extern long lseek(int fildes, long offset, int whence) ; #endif #ifndef S4MEMCMP -extern int memcmp() ; +extern int memcmp(const void * s1, const void * s2, size_t n) ; #endif #else long filelength(int) ; @@ -82,25 +95,22 @@ long MAClseek(int, long, int, int) ; #include #endif -#define USHRT_MAX 0xFFFF /* may comment these out if compiler */ -#define INT_MAX 0x7FFF /* error occurs */ -#define UINT_MAX 0xFFFF +/* #define USHRT_MAX 0xFFFF */ /* may comment these out if compiler */ +/* #define INT_MAX 0x7FFF */ /* error occurs */ +/* #define UINT_MAX 0xFFFF */ #endif #ifdef S4LOCKF #define S4LOCKING -#endif - -#ifdef S4NO_SIZE_T -typedef unsigned size_t ; +int lockf(int fildes, int locking, long size); #endif #ifdef S4NO_STRNICMP -int strnicmp() ; +int strnicmp(char *a, char *b, size_t n ); #endif #ifdef S4NO_MEMMOVE -void *memmove() ; +void *memmove(void *dest, void *src, size_t count ); #endif #ifdef S4LSEEK @@ -109,15 +119,15 @@ long f4seek() ; #endif #ifdef S4NO_FCVT -char *f4fcvt() ; +char *f4fcvt( double value, int numdigits, int *dec_ptr, int *sign_ptr ); #endif #ifdef S4NO_ECVT -char *f4ecvt() ; +char *f4ecvt( double value, int numdigits, int *dec_ptr, int *sign_ptr ); #endif #ifdef S4NO_ATOF -double c4atof() ; +double c4atof( char * buf ); #endif #ifdef S4BYTEORDER_3210