[2853] in SIPB bug reports

home help back first fref pref prev next nref lref last post

com_err changes for SYSV

daemon@ATHENA.MIT.EDU (John Carr)
Thu May 21 20:28:48 1992

To: bug-sipb@Athena.MIT.EDU
Date: Thu, 21 May 1992 20:28:03 EDT
From: John Carr <jfc@Athena.MIT.EDU>


These are changes somebody sent for the com_err that was shipped with
Kerberos 5.  The changes appear to be:

	1. Make file names at most 14 characters long.

	2. Avoid Berkeley string functions on system 5 UNIX.

	3. Support UNICOS

	4. Support AUX 2

I have not edited these diffs; some may not be relevant to your source.

diff -cr changed_src/com_err/Imakefile com_err/Imakefile
*** changed_src/com_err/Imakefile	Thu Mar 28 09:38:21 1991
--- com_err/Imakefile	Thu Dec 19 11:12:01 1991
***************
*** 17,28 ****
  #endif
  
  LINTFLAGS=-uhvb 
! LINTFILES= error_message.c et_name.c init_et.c com_err.c # perror.c
! LIBOBJS= error_message.o et_name.o init_et.o com_err.o # perror.o
  
! DOCDIR=/usr/doc/athena
! 
! FILES=	Makefile et_name.c error_message.c compile_et.c \
  		et_lex.lex.l error_table.y init_et.c \
  		com_err.c com_err.h \
  		error_table.h mit-sipb-copyright.h \
--- 17,26 ----
  #endif
  
  LINTFLAGS=-uhvb 
! LINTFILES= error_msg.c et_name.c init_et.c com_err.c # perror.c
! LIBOBJS= error_msg.o et_name.o init_et.o com_err.o # perror.o
  
! FILES=	Makefile et_name.c error_msg.c compile_et.c \
  		et_lex.lex.l error_table.y init_et.c \
  		com_err.c com_err.h \
  		error_table.h mit-sipb-copyright.h \
***************
*** 29,40 ****
  		test.c test1.et test2.et \
  		compiler.h internal.h \
  		com_err.texinfo texinfo.tex
- CFILES=	compile_et.c error_table.c error_message.c et_name.c \
- 	init_et.c com_err.c
  
! #
! # what to build...
! #
  
  #
  # rules
--- 27,35 ----
  		test.c test1.et test2.et \
  		compiler.h internal.h \
  		com_err.texinfo texinfo.tex
  
! CFILES=	compile_et.c error_table.c error_msg.c et_name.c \
! 	init_et.c com_err.c
  
  #
  # rules
***************
*** 41,48 ****
  #
  .SUFFIXES: .h .c .et .ps .x9700 .mss .dvi .texinfo
  
- ProfiledObjectRule()
- 
  error_table.o: et_lex.lex.c
  
  .et.c:
--- 36,41 ----
***************
*** 51,88 ****
  .et.h:
  	./compile_et $*.et
  
- .texinfo.dvi:
- 	tex $<
- 
- .dvi.ps:
- 	rm -f $@.new
- 	dvi2ps -r $< > $@.new
- 	mv $@.new $@
- 
  #
  # real entries...
  #
! SimpleProgram(compile_et, compile_et.o error_table.o, -ll,$(ATHBINDIR))
! 
! create_dir($(DOCDIR))
! 
! install_file(com_err.h,$(ATHINCDIR))
! install_file(mit-sipb-copyright.h,$(ATHINCDIR))
! install_man(com_err.3,com_err.3)
! install_man(compile_et.1,compile_et.1)
! install_file(com_err.texinfo,${DOCDIR}/com_err.texinfo)
  
  
! SimpleLibrary(com_err,$(LIBOBJS),$(ATHLIBDIR))
  
- 
- SimpleLint(com_err,$(LINTFILES))
- 
  clean::
  	rm -f *~ \#* *.bak \
  		*.otl *.aux *.toc *.PS *.dvi *.x9700 *.ps \
  		*.cp *.fn *.ky *.log *.pg *.tp *.vr \
! 		*.o profiled/?*.o libcom_err.a libcom_err_p.a \
  		com_err.o compile_et \
  		et.ar TAGS y.tab.c lex.yy.c error_table.c \
  		et_lex.lex.c \
--- 44,63 ----
  .et.h:
  	./compile_et $*.et
  
  #
  # real entries...
  #
! NormalProgramTarget(compile_et, compile_et.o error_table.o, , -ll,$(ATHBINDIR))
  
+ NormalLibraryTarget(com_err,$(LIBOBJS))
  
! all:: compile_et
  
  clean::
  	rm -f *~ \#* *.bak \
  		*.otl *.aux *.toc *.PS *.dvi *.x9700 *.ps \
  		*.cp *.fn *.ky *.log *.pg *.tp *.vr \
! 		*.o libcom_err.a libcom_err_p.a \
  		com_err.o compile_et \
  		et.ar TAGS y.tab.c lex.yy.c error_table.c \
  		et_lex.lex.c \
***************
*** 98,128 ****
  test2.o : test2.c
  test2.c : test2.et
  
- et.tar:	${FILES}
- 	rm -f et.tar
- 	tar cfrlv et.tar ${FILES}
- 
- tags:	TAGS
- 
- doc:	com_err.dvi
- 
- 
- com_err.ps : com_err.dvi
- com_err.dvi: com_err.texinfo
- 
  libcom_err.o:	$(LIBOBJS)
  	ld -r -s -o libcom_err.o $(LIBOBJS)
  	chmod -x libcom_err.o
  
! 
! archive:	et.tar
! 
! TAGS:	et_name.c error_message.c compile_et.c error_table.c \
  		lex.yy.c perror.c init_et.c
! 	etags et_name.c error_message.c compile_et.c \
  		error_table.c perror.c init_et.c
  
  # 'make depend' code
  depend:: ${CFILES} et_lex.lex.c
! 	makedepend ${CFLAGS} ${CFILES}
  
--- 73,88 ----
  test2.o : test2.c
  test2.c : test2.et
  
  libcom_err.o:	$(LIBOBJS)
  	ld -r -s -o libcom_err.o $(LIBOBJS)
  	chmod -x libcom_err.o
  
! TAGS:	et_name.c error_msg.c compile_et.c error_table.c \
  		lex.yy.c perror.c init_et.c
! 	etags et_name.c error_msg.c compile_et.c \
  		error_table.c perror.c init_et.c
  
  # 'make depend' code
  depend:: ${CFILES} et_lex.lex.c
! 	$(DEPEND) ${CFLAGS} ${CFILES}
  
Only in changed_src/com_err: Imakefile_orig
Only in changed_src/com_err: Makefile
Only in changed_src/com_err: Makefile_orig
Only in com_err: com_err.3
diff -cr changed_src/com_err/com_err.c com_err/com_err.c
*** changed_src/com_err/com_err.c	Fri Mar 23 13:22:34 1990
--- com_err/com_err.c	Wed Oct 30 12:52:51 1991
***************
*** 23,29 ****
--- 23,31 ----
  #else /* varargs: not STDC or no <stdarg> */
  	/* Non-ANSI, always take <varargs.h> path. */
  #	undef VARARGS
+ #ifndef unicos61
  #	define VARARGS 1
+ #endif
  #	include <varargs.h>
  #	undef vfprintf
  #	define vfprintf(stream,fmt,args) _doprnt(fmt,args,stream)
Only in changed_src/com_err: com_err.c_orig
Only in com_err: com_err.h
Only in com_err: com_err.texinfo
Only in com_err: compile_et.1
diff -cr changed_src/com_err/compile_et.c com_err/compile_et.c
*** changed_src/com_err/compile_et.c	Wed Oct 16 11:47:34 1991
--- com_err/compile_et.c	Thu Feb 20 13:41:23 1992
***************
*** 8,13 ****
--- 8,20 ----
   */
  
  #include <stdio.h>
+ #ifdef unicos61
+ #include <sys/types.h>
+ #define MAXPATHLEN PATHSIZE
+ #endif	/* unicos61 */
+ #if defined (sysvimp) || defined(aux20)
+ #include <sys/types.h>
+ #endif	/* sysvimp */
  #include <sys/file.h>
  #include <string.h>
  #include <sys/param.h>
***************
*** 288,294 ****
  	    yylineno, current_token);
  }
  
! #if defined(i386) || defined(hpux)
  /* Need strcasecmp for this machine */
  /*
   * Copyright (c) 1987 Regents of the University of California.
--- 295,302 ----
  	    yylineno, current_token);
  }
  
! #ifdef NEEDS_STRCASECMP
! /* #if defined(i386) || defined(hpux) || defined(sysvimp) */
  /* Need strcasecmp for this machine */
  /*
   * Copyright (c) 1987 Regents of the University of California.
Only in changed_src/com_err: compile_et.c_orig
Only in com_err: compiler.h
Only in com_err: error_message.c
Only in com_err: error_msg.c
Only in com_err: error_table.h
Only in com_err: error_table.y
diff -cr changed_src/com_err/et_lex.lex.l com_err/et_lex.lex.l
*** changed_src/com_err/et_lex.lex.l	Wed Oct 16 11:47:53 1991
--- com_err/et_lex.lex.l	Wed Oct 16 11:48:47 1991
***************
*** 15,21 ****
--- 15,25 ----
  #define rindex(a,b) strrchr(a,b)
  #endif
  	{ register char *p; yylval.dynstr = ds(yytext+1);
+ #ifdef unicos61
+ 	  if (p=(char *)rindex(yylval.dynstr, '"')) *p='\0';
+ #else
  	  if (p=rindex(yylval.dynstr, '"')) *p='\0';
+ #endif	/* unicos61 */
  	  return QUOTED_STRING;
  	}
  
Only in changed_src/com_err: et_lex.lex.l_orig
Only in com_err: et_name.c
Only in com_err: init_et.c
Only in com_err: internal.h
Only in com_err: mit-sipb-copyright.h
Only in com_err: profiled
Only in com_err: test.c
Only in com_err: test1.et
Only in com_err: test2.et
Only in com_err: texinfo.tex

home help back first fref pref prev next nref lref last post