From 64e484ca714cd4d928cf47a6556745a62de09c65 Mon Sep 17 00:00:00 2001 From: styluseater Date: Sat, 26 Feb 2011 05:38:16 +0000 Subject: Add old changelogs forgotten in last commit. Remove object files. --- lib/ChangeLog.old | 1414 +++++++++++++++++++++++++++++++++++++++++++++++++ lib/basename.o | Bin 4956 -> 0 bytes lib/fmod-deprecated.c | 145 +++++ lib/strstr.o | Bin 5172 -> 0 bytes 4 files changed, 1559 insertions(+) create mode 100644 lib/ChangeLog.old delete mode 100644 lib/basename.o create mode 100644 lib/fmod-deprecated.c delete mode 100644 lib/strstr.o (limited to 'lib') diff --git a/lib/ChangeLog.old b/lib/ChangeLog.old new file mode 100644 index 0000000..0f3ff5d --- /dev/null +++ b/lib/ChangeLog.old @@ -0,0 +1,1414 @@ +Tue Dec 26 10:16:08 1995 Kathy Hargreaves + + * identity.c (get_identity): Added. + +Sun Nov 26 12:47:00 1995 Kathy Hargreaves + + * bb-outline.c: (find_outline_bbs): Doc fix. + + * edge.c: (next_unmarked_outline_edge): Doc fix. + +Fri Nov 24 05:48:20 1995 Kathy Hargreaves + + * concat*.c: made arguments const_string's to conform to .h files. + Call assert on the arguments, that they aren't NULL, because it + makes strlen blow up if they are. Set answer to NULL, and only + work on it if all the arguments are non-NULL. + +Thu Nov 23 09:08:00 1995 Kathy Hargreaves + + * font.c: (get_font): replaced find_tfm_filename with kpse_find_tfm. + +Thu Aug 24 16:00:46 1995 Karl Berry + + * GNUmakefile (c_only): strstr is now in kpathsea. + +Sat May 27 13:52:19 1995 Karl Berry + + * GNUmakefile (c_only): atou is in kpathsea. + +Fri Apr 14 15:56:43 1995 Karl Berry + + * GNUmakefile (c_only): Remove xfseek and xftell. + +Mon Oct 24 19:04:34 1994 Karl Berry + + * GNUmakefile (c_only): basename is in kpathsea now. + +Sun May 1 15:31:10 1994 Karl Berry (karl@cs.umb.edu) + + * vector.c (Vangle): Declare const. + +Thu Sep 30 10:13:45 1993 Karl Berry (karl@cs.umb.edu) + + * str-to-bit.c (string_to_bitmap): Call close_font. + +Sun Aug 1 09:56:42 1993 Karl Berry (karl@cs.umb.edu) + + * Most *.c: Include files now in kpathsea. + + * GNUmakefile (c_only): Add statistics, remove many things now in + kpathsea. + +Tue Jul 27 09:24:08 1993 Karl Berry (karl@cs.umb.edu) + + * GNUmakefile (c_only): Remove dir-p and find-suffix (now in kpathsea). + +Fri May 21 13:45:30 1993 Karl Berry (karl@cs.umb.edu) + + * gmalloc.c (my_memmove): New routine, since ISC doesn't have a + real memmove. + +Thu May 20 19:11:05 1993 Karl Berry (karl@cs.umb.edu) + + * gmalloc.c: New file from the malloc distribution (plus a few + edits). + * GNUmakefile (malloc): Define to be gmalloc, and toss the old + malloc.c. + +Thu Apr 22 17:03:53 1993 Karl Berry (karl@cs.umb.edu) + + * remove-suffx.c (remove_suffix): If no suffix, return the string, + not NULL. + +Tue Apr 6 19:58:45 1993 Karl Berry (karl@cs.umb.edu) + + * malloc.c (getpagesize.h): Do not include. + (memalign, valloc): Remove, since we don't need them. + + * filename.c (find_tfm_filename): Call extend_filename to get the + `.tfm', instead of just concatenating. Not sure if this is a good + idea, but periods in font names are problematic all over, I think. + +Tue Mar 16 07:47:38 1993 Karl Berry (karl@cs.umb.edu) + + * fontmap.c (map_lookup): Don't extend the filename if there was + no suffix. + +Wed Mar 3 06:20:09 1993 Karl Berry (karl@cs.umb.edu) + + * xftell.c (xftell): Declare as unsigned long. + +Mon Jan 18 15:43:02 1993 Karl Berry (karl@cs.umb.edu) + + * xrealloc.c: Doc fix. + +Sun Jan 3 19:36:39 1993 Karl Berry (karl@cs.umb.edu) + + * pathsrch.c (R_OK): Defined in the config files now. + +Fri Dec 11 15:00:31 1992 Karl Berry (karl@cs.umb.edu) + + * font.c (print_char): Change ctype references to use uppercase macros. + * libfile.c (libfile_line), + * pathsrch.c (absolute_p), + * str-to-bit.c (string_to_bitmap), + * float-ok.c (float_ok), + * integer-ok.c (integer_ok), + * charspec.c (xparse_charspec): Likewise. + +Sun Nov 29 17:05:40 1992 Karl Berry (karl@cs.umb.edu) + + * xmessage.c [X_DISPLAY_MISSING]: Conditionalize whole file. + + * numtoa.c (xdtoa): Rename from `dtoa', to avoid Linux conflict. + (awasthi@cps.msu.edu) + +Tue Nov 17 09:25:58 1992 Karl Berry (karl@cs.umb.edu) + + * hexify.c: Doc fix. + +Mon Nov 16 16:08:39 1992 Karl Berry (karl@cs.umb.edu) + + * malloc.c (calloc): Complain if the malloc fails. + +Tue Oct 27 12:56:15 1992 Karl Berry (karl@cs.umb.edu) + + * Version 0.6. + +Sun Oct 25 06:26:42 1992 Karl Berry (karl@cs.umb.edu) + + * getopt.c: New version. + +Thu Oct 22 17:58:12 1992 Karl Berry (karl@cs.umb.edu) + + * make-suffix.c: Doc fix. + +Tue Oct 20 11:57:57 1992 Karl Berry (karl@cs.umb.edu) + + * filename.c (find_{gf,pk,tfm}_filename): Just concatenate the + suffix onto the main font name, don't replace a suffix. + +Mon Oct 5 10:07:59 1992 Karl Berry (karl@cs.umb.edu) + + * report.c (report_file): New variable. + +Sun Oct 4 09:13:24 1992 Karl Berry (karl@cs.umb.edu) + + * bb-list.c: New file, from bb-outline.c. + * GNUmakefile (c_only): Add it. + * bb-outline.c: Change calls and decls for new improved names. + +Sat Oct 3 16:58:38 1992 Karl Berry (karl@cs.umb.edu) + + * bb-outline.c: Doc fix. + +Tue Sep 22 12:46:49 1992 Karl Berry (karl@cs.umb.edu) + + * malloc.c (realloc): abort if we can't malloc enough memory to do + the realloc. + + * bitmap.c (bb_ensure_bounds): new routine. + (extract_subbitmap): call it. + +Mon Sep 21 12:00:35 1992 Karl Berry (karl@cs.umb.edu) + + * malloc.c: define NO_NEW_HANDLER. + +Thu Sep 3 09:31:06 1992 Karl Berry (karl@hayley) + + * Version 0.5. + +Thu Aug 27 09:06:25 1992 Karl Berry (karl@hayley) + + * getopt.c: update from MIT. + +Mon Aug 24 15:50:03 1992 Karl Berry (karl@hayley) + + * rand.c (k_rand): use Ghostscript's algorithm exactly, to avoid + overflow problems. + + * rand.c (seed_rand): Our simplification was a loser if the + state ever became zero, so set the state to the seed + 1, and + subtract again before output. + +Wed Aug 19 07:10:12 1992 Karl Berry (karl@hayley) + + * charspec.c: doc fix. + +Mon Aug 17 15:43:42 1992 Karl Berry (karl@hayley) + + * encoding.c: doc fix. + +Mon Aug 10 11:11:52 1992 Karl Berry (karl@hayley) + + * rand.c (x): change the default seed to 1. + +Mon Jul 27 15:29:33 1992 Karl Berry (karl@hayley) + + * charspec.c (xparse_charspec): use an `int' while figuring out + the charcode. + +Sat Jul 25 14:38:23 1992 Karl Berry (karl@hayley) + + * getopt.c: new version. + + * pathsrch.c (expand_tilde): cast the result of getpwnam. + +Sat Jul 18 16:35:41 1992 Karl Berry (karl@hayley) + + * edge.c: add ^L's. + +Fri Jul 3 15:26:12 1992 Karl Berry (karl@hayley) + + * charspec.c (xparse_charspec): if arg is one character long, and + undefined in the encoding, use its value in C. + +Fri Jun 26 16:53:39 1992 Karl Berry (karl@hayley) + + * charspec.c: new file. + * GNUmakefile: add it. + +Thu Jun 25 07:04:49 1992 Karl Berry (karl@hayley) + + * pathsrch.c (readable) [ENAMETOOLONG]: conditionalize the test + for doing our own truncating, since it appears not all systems + have ENAMETOOLONG. + +Sun Jun 14 08:11:32 1992 Karl Berry (karl@hayley) + + * font.c (get_font): remove computation of NCHARS (and reading of + all the TFM chars). + + * str-lcase.c (str_to_lower): assert the arg is non-null. + +Sat Jun 13 16:28:08 1992 Karl Berry (karl@hayley) + + * libfile.c (libfile_start): return the FILE * we open. + +Sat Jun 13 13:52:30 1992 Kathy Hargreaves (kathy@hayley) + + * encoding.c (DEFAULT_ENCODING): moved to .h file. + +Sat Jun 13 09:24:12 1992 Karl Berry (karl@hayley) + + * encoding.c: include `str-lcase.h', not `str-casefold.h'. + + * xmessage.c (x_message): cast initializer in `popup_args' to + avoid warning. + + * str-to-bit.c (string_to_bitmap): `TFM_FONT_PARAMETER' is now + `TFM_FONTDIMEN'. + + * pathsrch.c (absolute_p): add parens to stop GCC 2's stupid warning. + + * encoding.c: change for new list fn names. + * font.c: likewise. + + * list.c (new_list): rename to `list_init', and rewrite to use + accessor macros. + (append_element): rename to `list_append', and likewise rewrite. + (list_free): new routine. + +Sun Jun 7 17:25:43 1992 Karl Berry (karl@hayley) + + * encoding.c (coding_scheme_to_filename): rewrite to avoid + sentinel boolean, lowercasing the passed codingscheme more than + once, etc. + + * str-casefold.c (str_to_lower): rewrite to use ? :. + (str_to_upper): remove this. + Rename to str-lcase.c. + * GNUmakefile (c_only): change str-casefold to str-lcase. + +Sun Jun 7 14:39:09 1992 Kathy Hargreaves (kathy@hayley) + + * bb-outline.c (find_outline_bbs): don't calculate edge if it's an + interior pixel. + + * bb-outline.c (find_outline_bbs): deleted avoiding finding a + bounding box which corresponds to a counterform by not looking + inside existing bounding boxes. + Added finding the bounding box for a counterform (i.e., marking + its edges) but not adding it to the list unless find_all is true. + Changed find_all to find_inner. + +Sun Jun 7 08:55:31 1992 Karl Berry (karl@hayley) + + * GNUmakefile (c_only): add `str-to-bit'. + * font.c (string_to_bitmap): extract the interword space out of + the TFM information, instead of expecting it in the main font + structure. Also, move this fn to its own file, `str-to-bit.c'. + + * float-ok.c (float_ok): don't accept the empty string, or just a + sign, or just a sign and a `.', etc. + * integer-ok.c (integer_ok): likewise. + +Thu Jun 4 08:11:36 1992 Karl Berry (karl@hayley) + + * pathsrch.c (absolute_p): `k./' should not be considered + explicitly relative. + +Tue Jun 2 11:40:32 1992 Karl Berry (karl@hayley) + + * encoding.c (encoding_number): don't crash if NAME is NULL. + +Mon Jun 1 15:16:15 1992 Karl Berry (karl@hayley) + + * GNUmakefile (c_only): add `integer-ok' and `float-ok'. + * {integer,float}-ok.c: new files. + + * libfile.c (libfile_start): use extend_filename. + + * encoding.c (read_encoding_file): initialize the return structure + after we know the file exists. + +Fri May 29 08:29:26 1992 Karl Berry (karl@hayley) + + * getopt*.c: new versions. + +Sat May 23 15:51:53 1992 Karl Berry (karl@hayley) + + * charcode.c (parse_charcode): ensure there are no extra + characters at the end of the charcode; change return type to + charcode_type. + (xparse_charcode): change return type. + +Sat May 23 12:33:32 1992 Kathy Hargreaves (kathy@hayley) + + * str-casefold.c (str_to_lower): added variable `length'; put 0 at + end of return string. + +Sat May 23 06:27:28 1992 Karl Berry (karl@hayley) + + * dir-p.c (leaf_dir_p): remove; `expand_subdir' now calls stat + itself, for efficiency. + + * pathsrch.c (expand_subdir): rewrite to always look for subdirs. + (initialize_path_list): check for the dir-ness of `foo' in + `foo//'. This change makes symlinks under `foo' be considered. + + * pathsrch.c (add_directory): don't check for the arg being a + directory. + (initialize_path_list): check here for the directory-ness of a + path element. + (expand_subdir): check here, too. + + * pathsrch.c (expand_subdir): call closedir after we read the + directory contents. + +Thu May 21 11:40:53 1992 Karl Berry (karl@hayley) + + * hexify.c (hexify): take a block of memory and a length, instead + of a varstring. + +Tue May 19 16:43:43 1992 Kathy Hargreaves (kathy@hayley) + + * line.c (read_line): return a string if not at EOF. + +Sat May 16 21:22:57 1992 Kathy Hargreaves (kathy@hayley) + + * varstring.c (vs_concat): added. + +Fri May 15 10:22:27 1992 Karl Berry (karl@hayley) + + * getopt.c: new version. + +Thu May 14 22:05:10 1992 Karl Berry (karl@claude.cs.umb.edu) + + * rand.c (srand): -> seed_rand, to avoid header conflicts. + (rand): -> k_rand, same reason. + +Sun May 10 10:05:36 1992 Karl Berry (karl@hayley) + + * encoding.c (coding_scheme_to_filename): don't xstrdup the return + value. + (DEFAULT_ENCODING): new macro. + +Fri May 8 15:38:38 1992 Karl Berry (karl@hayley) + + * pathshare from dvips. + +Thu May 7 16:44:14 1992 Karl Berry (karl@hayley) + + * GNUmakefile (c_only): add dlsym. + * dlsym.c: new file. + +Wed May 6 10:08:09 1992 Karl Berry (karl@hayley) + + * bitmap.c (bitmap_find_transitions): don't look outside the + current row when it's only one pixel long. + +Tue May 5 08:46:48 1992 Karl Berry (karl@hayley) + + * dir-p.c: doc fix. + +Sat May 2 07:51:53 1992 Karl Berry (karl@hayley) + + * pathsrch.c (add_directory): use ?:. + +Thu Apr 30 08:52:34 1992 Karl Berry (karl@hayley) + + * pathsrch.c (parse_envpath): expand the ~ here; + (add_directory): not here. + + * pathsrch.c (expand_tilde): free space for the login name. + + * dir-p.c (leaf_dir_p): use stat, not xlstat, so we don't bomb + out on missing directories in paths, and so we get info about + the (potential) dir, not the link. + +Tue Apr 21 07:44:52 1992 Karl Berry (karl@hayley) + + * bitmap.c (bitmap_find_transitions): use XTALLOC1. + * font.c (get_char): likewise. + +Mon Apr 20 08:35:23 1992 Karl Berry (karl@hayley) + + * pathsrch.c: doc fix. + + * malloc.c: don't include config.h. + (my_bzero, my_bcopy): new routines to simplify things. + +Sat Apr 18 12:22:29 1992 Kathy Hargreaves (kathy@hayley) + + * str-casefold.c: added. + + * encoding.c (coding_scheme_to_filename): compare case-folded + versions of the coding scheme and the mapped scheme. + +Wed Apr 15 15:23:20 1992 Karl Berry (karl@hayley) + + * make-output.c: rename to `extend-fname.c'; rename the fn to + `extend_filename'. + * GNUmakefile (c_only): analogously. + +Wed Apr 15 13:20:11 1992 Kathy Hargreaves (kathy@hayley) + + * encoding.c (coding_scheme_to_filename): changed some variable + names; added `mapped_coding' and set it to a second call to + strtok with `mapping'. + +Tue Apr 14 13:46:45 1992 Karl Berry (karl@hayley) + + * scaled-num.c (scaled_to_real): as below. + +Sun Apr 12 15:06:58 1992 Karl Berry (karl@hayley) + + * scaled-num.c (real_to_scaled): simplify to just multiply the + real by SCALED_UNITY. + +Fri Apr 10 16:36:33 1992 Karl Berry (karl@hayley) + + * concat.c: put concat[345] in separate files. + * GNUmakefile (c_only): update. + + * filename.c: remove prefix/suffix routines. + ({make-{output,prefix,suffix},remove-suffx,find-suffix}.c): new files. + * GNUmakefile (c_only): update. + + * pathsrch.c (initialize_path_list): remove cwd_first_p. + * filename.c (find_*_filename): change calls. + * libfile.c (libfile_start): change call. + +Mon Apr 6 13:46:36 1992 Kathy Hargreaves (kathy@fosse) + + * encoding.c (encoding_scheme_to_filename): added. + +Fri Apr 3 13:17:22 1992 Karl Berry (karl@hayley) + + * rand.c: new file. + * GNUmakefile (c_only): include it. + +Wed Apr 1 14:14:01 1992 Karl Berry (karl at hayley) + + * (pathshare from web2c) + + * filename.c (make_output_filename): don't duplicate the input + string, just return it. + + * filename.c (remove_suffix): remove. + + * edge.c: new file. + * GNUmakefile (c_only): add it. + * bb-outline.c: remove edge stuff in favor of this new file. + +Tue Mar 31 13:35:51 1992 Karl Berry (karl at hayley) + + * bitmap.c (bitmap_find_transitions): handle a row with a single + black pixel at the end correctly. + +Sun Mar 29 10:58:27 1992 Karl Berry (karl at hayley) + + * xrealloc.c (xrealloc): cast the ptr. + + * file-input.c (get_n_bytes): had args switched to fatal. + + * bb-outline.c (is_outline_edge): remove the assertion that we're + at a valid pixel, since it's half-implied by the types, anyway. + + * GNUmakefile (malloc.o): remove the special rule and vars. + * malloc.c [STDC_HEADERS | USG]: add the former for memset etc. + +Sat Mar 28 07:49:09 1992 Karl Berry (karl at hayley) + + * malloc.c: new version, from libg++ 2.0. + + * GNUmakefile (malloc_stats): don't define this. + + * Version 0.4. + + * Change copyright years to 1992 only. + +Wed Mar 25 08:37:28 1992 Karl Berry (karl at hayley) + + * GNUmakefile (c_only): add fmod. + * fmod.c: new file. + +Thu Mar 19 07:47:30 1992 Karl Berry (karl at hayley) + + * pathsearch.c, libfile.c, filename.c: include paths.h. + + * pathsearch.c: rename to pathsrch.c; new version. + +Wed Mar 11 10:03:12 1992 Karl Berry (karl at hayley) + + * bitmap.c (bitmap_find_transitions): handle the pixel at the end + of the row specially, unfortunately. + +Tue Mar 10 12:17:09 1992 Kathy Hargreaves (kathy at hayley) + + * libfile.c (libfile_start): use find_suffix instead of finding a + dot position. + +Mon Mar 9 16:42:49 1992 Kathy Hargreaves (kathy at hayley) + + * filename.c (make_stem_suffix): remove suffix from name before + adding stem_suffix and putting suffix back on. + + * filename.c (make_stem_suffix): don't add a dot if no suffix. + + * filename.c (make_stem_suffix): added. + +Sun Mar 8 17:08:06 1992 Kathy Hargreaves (kathy at hayley) + + * filename.c (make_output_filename): put dot between NAME and + DEFAULT_SUFFIX. + +Sun Mar 8 08:37:46 1992 Karl Berry (karl at fosse) + + * numtoa.c (dtoa): rename from ftoa. + + * strstr.c: new file. + GNUmakefile (c_only): add strstr. + +Sat Mar 7 17:00:44 1992 Kathy Hargreaves (kathy at hayley) + + * filename.c (sizeless_font_name): removed. + +Sat Mar 7 13:21:33 1992 Karl Berry (karl at fosse) + + * xmessage.c: include xmessage.h. + + * GNUmakefile (c_only): remove statistics; we never use it. + + * pathsearch.c: add prototypes for the subroutines. + + * line.c: include line.h. + + * bb-outline.c (find_outlines_bbs): rename parameters to avoid + shadow warnings. + +Sat Mar 7 09:14:00 1992 Karl Berry (karl at hayley) + + * GNUmakefile (files, headers, sources): replace with `c_and_h', etc. + + * scaled-num.c (print_scaled): use putchar instead of printf where + possible. + +Wed Mar 4 10:40:02 1992 Karl Berry (karl at hayley) + + * filename.c (remove_suffix): don't include the `.' in what we + return. + +Tue Mar 3 16:28:38 1992 Karl Berry (karl at hayley) + + * filename.c (find_suffix): new routine. + (remove_suffix, make_output_filename, make_suffix): write in terms + of it. + +Sun Mar 1 16:33:49 1992 Kathy Hargreaves (kathy at hayley) + + * filename.c (make_output_file): use concat instead of make_suffix. + +Sun Mar 1 15:17:28 1992 Karl Berry (karl at hayley) + + * GNUmakefile (files): add bb-outline. + +Sun Mar 1 14:48:41 1992 Kathy Hargreaves (kathy at hayley) + + * filename.c (make_output_file): added. + +Mon Feb 24 08:38:56 1992 Karl Berry (karl at hayley) + + * pathsearch.c (truncate_pathname): separate this out from `readable'. + + * concat.c dir-p.c file-p.c pathsearch.c xmalloc.c xopendir.c + xrealloc.c xstat.c xstrdup.c: redo with (un)prototype macros. + +Wed Feb 19 10:00:35 1992 Karl Berry (karl at hayley) + + * varstring.c (vs_set_char): set the allocated field after we + allocate more space. + + * hexify.c (hexify): add 'a' to each hex char to make it visible + ASCII; shift the upper nybble down before adding. + +Mon Feb 17 07:38:27 1992 Karl Berry (karl at hayley) + + * filename.c (sizeless_font_name): new routine. + + * line.c (read_line): use vs_append_char, and generally simplify. + + * varstring.c (vs_append_char): don't append a null afterwards. + + * GNUmakefile (files): add it. + * hexify.c: new file. + +Sun Feb 16 10:31:41 1992 Karl Berry (karl at hayley) + + * pathsearch.c (readable): keep track of the component lengths + properly; do the second test on the new name, not the old. + +Sat Feb 15 16:10:30 1992 Karl Berry (karl at hayley) + + * pathsearch.c (READABLE): redo the macro as a function, and + truncate the pathname if necessary. + +Fri Feb 14 07:26:35 1992 Karl Berry (karl at hayley) + + * varstring.c (vs_append_char): use VS_USED instead of strlen. + (vs_init): initialize VS_USED to zero. + (vs_set_char): set VS_USED. + All routines: rename `VS_LENGTH to `VS_ALLOCATED'. + + * varstring.c (vs_free): new routine. + + * math.c (acosd): clear errno before testing it. + +Thu Feb 13 13:32:54 1992 Karl Berry (karl at hayley) + + * pathsearch.c (READABLE): call it readable if the error is + ENAMETOOLONG; include and declare errno if that is + undefined. + +Sun Feb 2 16:08:44 1992 Karl Berry (karl at hayley) + + * filename.c (find_{gf,pk}_filename): allocate enough space for + the null sprintf writes. + +Sat Feb 1 14:53:39 1992 Karl Berry (karl at hayley) + + * filename.c (depath): remove. + + * pathsearch.c (initialize_path_list): subdirectories are now + indicated by // terminating a path element, instead of as + a separate envvar/path. + * filename.c (find*filename): remove subdirectory stuff. + * libfile.c (libfile_start): likewise. + +Mon Jan 20 11:09:10 1992 Kathy Hargreaves (kathy at hayley) + + * filename.c (depath): added this routine to take the path off the + front of a filename. + + * filename.c (make_prefix): added this routine to add a prefix to + a filename which may or may not be the full pathname. + +Wed Jan 15 16:57:36 1992 Kathy Hargreaves (kathy at hayley) + + * libfile.c (libfile_start): when FATAL, report `name', not it + concatenated with the default suffix. + +Wed Jan 15 13:01:30 1992 Karl Berry (karl at hayley) + + * GNUmakefile (c_only): remove xchdir and xgetcwd, as we don't + need them anymore. + * pathsearch.c: changes from TeX. + +Wed Jan 15 11:59:56 1992 Kathy Hargreaves (kathy at hayley) + + * filename.c (find_*_filename): only free `name' if it's not the + same string as `*_name'. + +Tue Jan 14 12:36:15 1992 Kathy Hargreaves (kathy at hayley) + + * bitmap.c (bitmap_find_transitions): make the last transition + always imply a black-to-white transition, even if ROW's last + pixel is black. + + * libfile.c (libfile_start): make FATAL2 report `name', not + `filename' as the library file not found. Also, only add suffix + to the library file name if it doesn't have one already. + +Sun Jan 12 16:29:11 1992 Kathy Hargreaves (kathy at hayley) + + * filename.c (make_suffix): copy suffix into new_s, not s. + +Sun Jan 12 14:57:24 1992 Karl Berry (karl at hayley) + + * pathsearch.c (check_subdir): add every existing subdirectory, + even if it's not a leaf. + +Sun Jan 12 12:47:57 1992 Kathy Hargreaves (kathy at hayley) + + * libfile.c (libfile_start): don't prepend a dot to the suffix. + + * dir-p.c (dir_p): call stat instead of xstat. + +Sat Jan 11 15:01:02 1992 Karl Berry (karl at hayley) + + * filename.c (find_*_filename): set cwd_first_p. + + * pathsearch.c (initialize_path_list): take an additional + argument, saying whether to search `.' first. + +Fri Jan 10 07:40:50 1992 Karl Berry (karl at hayley) + + * xgetcwd.c (xgetcwd) [GETWD_MISSING]: if it's not missing, use + it. + + * filename.c (find_*_filename): only initialize the path lists + once. + + * pathsearch.c (expand_colon): if env_path is null, return the + default path. + + * file-input.c (MOVE_BACK): use xfseek. + + * filename.c (*_suffix): use strrchr instead of rpos. + + * varstring.c: change names to start with `vs'. + + * memory.c: split into various files. + + * math.c (adjacent_points): rename to `points_adjacent_p'. + + * math.c (find_bounds): use MAXDOUBLE and MINDOUBLE instead of + MAXFLOAT and MINFLOAT. + + * filename.c (find_dpi): move to cmdline.c. + (basename): move to basename.c. + +Thu Jan 9 08:57:39 1992 Karl Berry (karl at hayley) + + * convert.c: split into various files. + * GNUmakefile: update. + + * cmdline.c (scan_integer_list): rename to `scan_unsigned_list'. + + * *.c: do not include global.h. + + * arith.c: split into `scaled-num.c' and `fix-num.c'. + * GNUmakefile: update. + +Wed Jan 8 09:14:45 1992 Karl Berry (karl at hayley) + + * update copyright messages. + + * change `allocate to `xmalloc', `reallocate' to `xrealloc', and + `string_copy' to `strdup'. + + * list.c: doc fix. + +Tue Jan 7 17:28:07 1992 Karl Berry (karl at hayley) + + * filename.c (expand_colon): don't put the default value at the + end if we've already put it at the beginning. + +Thu Sep 12 11:06:58 1991 Karl Berry (karl at hayley) + + * malloc.c (malloc_sanity_check): new function. + + * bitmap.c (bitmap_find_transitions): rearrange logic for clarity. + + * malloc.c, getpagesize.h: new files. + * GNUmakefile (c_only): add Doug Lea's malloc. + (malloc_stats, malloc_inline): new variables. + (malloc.o): rule to explicitly use them. + +Tue Jul 30 13:18:12 1991 Karl Berry (karl at ra.cs.umb.edu) + + * Version 0.3. + +Wed Jul 24 06:34:11 1991 Karl Berry (karl at hayley) + + * bitmap.c (concat_bitmaps): remove; it's only used in one program. + + * bitmap.c (new_bitmap): call it. + + * memory.c (xcalloc): new routine. + +Tue Jul 16 08:24:08 1991 Karl Berry (karl at hayley) + + * memory.c (allocate): don't do assignment inside if. + + * bitmap.c (bitmap_find_transitions): we don't need to look at the + first black pixel twice. + +Fri Jun 28 09:09:59 1991 Karl Berry (karl at hayley) + + * font.c (close_font): only close the TFM file if the font is not + bitmap-only. + +Sat Jun 15 09:51:45 1991 Karl Berry (karl at hayley) + + * font.c (get_font): set the new `tfm_font' and `tfm_filename' + members. + + * {dirio,file-misc,file-open,filename,libfile}.c: change + `checked_' to `x'. + +Tue Jun 11 16:46:25 1991 Karl Berry (karl at hayley) + + * font.c (get_char): use XTALLOC. + + * font.c (close_font): close the TFM file here, instead of in + `get_font'. + +Sun Jun 9 13:23:59 1991 Karl Berry (karl at hayley) + + * font.c (string_to_bitmap): use `BITMAP_PIXEL (CHAR_BITMAP'... + instead of `CHAR_BITMAP_PIXEL'. + +Thu Jun 6 07:30:07 1991 Karl Berry (karl at hayley) + + * All files: change to version 2 of the GPL. + +Sat Jun 1 16:00:03 1991 Kathy Hargreaves (kathy at hayley) + + * libfile.c (libfile_start): Don't concat a `.' to suffix if it's + the empty string. + +Thu May 16 07:35:47 1991 Karl Berry (karl at hayley) + + * GNUmakefile (files): include `xmessage' (from xbce). + * xmessage.c: new file. + +Sun Apr 21 17:38:48 1991 Karl Berry (karl at hayley) + + * bitmap.c (bitmap_to_bb): declare the arg as const. + +Sun Apr 14 13:45:29 1991 Karl Berry (karl at hayley) + + * bitmap.c (print_bitmap): use `bitmap_to_bb' instead of + `dimensions_to_bb'. + +Fri Apr 12 15:12:32 1991 Karl Berry (karl at hayley) + + * math.c: doc fix. + + * GNUmakefile (files): add `report' and `logreport'. + * {log,}report.c: new files. + +Wed Apr 10 11:27:49 1991 Karl Berry (karl at hayley) + + * font.c (save_internal_font): omit needless casts. + +Mon Apr 8 07:57:20 1991 Karl Berry (karl at hayley) + + * font.c (ascender_part): move to ospace. + + * encoding.c (parse_encoding_line): make a copy of the character + name, since the line gets freed. + + * encoding.c (read_encoding_file): reinitialize the character + code, so we fill up the right array. + + * libfile.c (libfile_start): prepend the `.' to the suffix. + +Sun Apr 7 14:34:06 1991 Karl Berry (karl at hayley) + + * file-output.c (put_signed_four): declare this as a macro in the + .h file. + +Thu Apr 4 07:03:36 1991 Karl Berry (karl at hayley) + + * font.c (get_char): don't allocate any space unless the character + actually exists in the font. + +Mon Apr 1 07:57:58 1991 Karl Berry (karl at hayley) + + * {encoding,libfile}.c: new files. + GNUmakefile (files): add them to the list. + +Sat Mar 23 16:42:39 1991 Karl Berry (karl at hayley) + + * font.c (delete_internal_font): free the memory for the internal + font, and for the font name. + +Sat Mar 9 17:06:57 1991 Karl Berry (karl at hayley) + + * string.c: declare args to routines as const. + + * string.c (lowercasify): new routine. + +Thu Mar 7 07:33:05 1991 Karl Berry (karl at hayley) + + * Version 0.2. + +Mon Mar 4 15:06:59 1991 Karl Berry (karl at hayley) + + * font.c (delete_internal_font): new routine. + (close_font): call it, thus preventing us from finding a font that + has been closed. + +Mon Feb 25 15:58:21 1991 Karl Berry (karl at hayley) + + * font.c (get_font): use `tfm_...' instead of `..._tfm_...'; use + `pk_...' instead of `..._pk_...'; use `gf_...' instead of + `..._gf_...'. + +Sun Feb 24 15:34:36 1991 Karl Berry (karl at ra.cs.umb.edu) + + * math.c (int_distance): cast the arguments to `double'. + +Sun Feb 17 09:43:06 1991 Karl Berry (karl at hayley) + + * *.c: include config.h. + +Sat Feb 16 16:54:18 1991 Karl Berry (karl at hayley) + + * dirio.c (checked_lstat) [HAVE_SYMBOLIC_LINKS]: change + conditional from being on S_ISLNK and S_IFLNK. + +Tue Jan 22 15:44:43 1991 Karl Berry (karl at hayley) + + * bitmap.c (extract_subbitmap): new routine from imgtogf. + +Fri Jan 18 08:14:23 1991 Karl Berry (karl at hayley) + + * vector.c (all routines): declare args to be const. + + * vector.c (Vabs): new routine. + +Tue Jan 15 15:29:38 1991 Karl Berry (karl at hayley) + + * spline.c (append_spline): use LAST_SPLINE_LIST_ELT. + + * spline.c (new_spline_list_array, free_spline_list_array, + append_spline_list): new routines. + + * spline.c (append_spline_list): rename to concat_spline_lists. + +Sun Jan 13 09:48:56 1991 Karl Berry (karl at hayley) + + * font.c (bitmap_format_type): move to font.h. + + * file-output.c (put_n_bytes): give the arguments to fwrite in the + correct order. + +Sat Jan 12 16:46:44 1991 Karl Berry (karl at hayley) + + * file-output.c (put_n_bytes): use fwrite to do all the bytes at + one shot. + +Mon Jan 7 10:42:22 1991 Karl Berry (karl at hayley) + + * spline.c (evaluate_spline): no compiler bug anymore without + temporaries (as of gcc 1.38). + +Sat Dec 29 17:43:40 1990 Karl Berry (karl at hayley) + + * spline.c (print_spline): make the output lines shorter. + +Wed Dec 26 15:13:26 1990 Karl Berry (karl at hayley) + + * math.c (find_bounds): use MAXFLOAT and MINFLOAT, instead of + MAXDOUBLE and MINDOUBLE, since Sun's atof can't deal with + the latter. + +Sun Dec 9 11:02:20 1990 Karl Berry (karl at hayley) + + * spline.c: doc fix. + + * dirio.c (getwd): close each directory after we read it. + + * filename.c (find_subdir_path_filename): use getwd instead of + getcwd, and use checked_chdir. + + * dirio.c (checked_opendir, is_dir): make arguments be const strings. + + * dirio.c (checked_chdir, checked_stat, checked_lstat, getwd): new + routines. + +Sat Nov 17 11:09:56 1990 Karl Berry (karl at hayley) + + * file-*.c: include the appropriate file-....h file. + + * math.c (distance): put this back; it's too annoying to call + hypot with the x and y arguments. + +Thu Oct 18 15:00:32 1990 Karl Berry (karl at hayley) + + * filename.c (find_subdir_path_filename): initialize the list of + subdirectories to the empty string. + +Wed Oct 17 17:54:40 1990 Karl Berry (karl at aten) + + * filename.c (find_subdir_path_filename): do not do strlen when + the path is empty. + +Tue Oct 9 08:59:43 1990 Karl Berry (karl at hayley) + + * filename.c (find_dpi): don't crash if the argument doesn't have + a `.' at all. + + * cmdline.c: new file. + * GNUmakefile (files): add it. + +Mon Oct 8 09:08:30 1990 Karl Berry (karl at hayley) + + * filename.c (find_dpi): new routine. + +Wed Oct 3 07:33:07 1990 Karl Berry (karl at hayley) + + * filename.c (find_tfm_filename, find_pk_filename, + find_gf_filename): new routines. + +Sat Sep 29 08:34:52 1990 Karl Berry (karl at hayley) + + * bitmap.c (new_bitmap): don't use memset if the bitmap is null. + + * font.c (find_internal_font): use STREQ. + +Fri Sep 28 08:30:04 1990 Karl Berry (karl at hayley) + + * filename.c (next_component): return NULL after we've read all + the directories in the list. + + * filename.c (next_component): omit the path separator from the + returned directory. + +Thu Sep 27 11:45:36 1990 Karl Berry (karl at hayley) + + * font.c (DEFAULT_SUBDIR_PATH): new macro. + (get_bitmap_font): try to open the PK and GF files using + subdirectories if opening without them fails. + (get_font): likewise, for the TFM file. + * filename.c (get_subdir_path_filename): new routine. + (next_component): new routine, replaces `find_components'. + +Fri Sep 21 09:15:28 1990 Karl Berry (karl at hayley) + + * dirio.o (is_dir): use S_ISDIR. + +Thu Sep 13 10:38:32 1990 Karl Berry (karl at hayley) + + * convert.c (parse_char_code): new routine to replace the + PARSE_CHAR_CODE macro; return a status indicator. + (xparse_char_code): like the above, but gives a fatal error. + +Wed Sep 12 18:19:13 1990 Karl Berry (karl at aten) + + * font.c (get_font): set `bitmap_only' to false. + (save_internal_font): overwrite the old value if we're called with + the same key twice. + +Sun Sep 9 07:10:29 1990 Karl Berry (karl at hayley) + + * convert.c: new file for some numeric conversions. + * math.c: move atou to convert.c. + +Mon Sep 3 11:05:19 1990 Karl Berry (karl at hayley) + + * line.c (read_line): doc fix. + +Fri Aug 31 11:04:02 1990 Karl Berry (karl at hayley) + + * font.c (get_bitmap_font): new routine, taken from get_font. + +Thu Aug 30 16:32:25 1990 Karl Berry (karl at hayley) + + * file-misc.c (same_file_p): new function. + +Wed Aug 29 11:37:24 1990 Karl Berry (karl at hayley) + + * fileio.c: split up into several new files: file-open.c, + file-input.c, file-output.c, file-misc.c. + +Thu Aug 23 07:26:58 1990 Karl Berry (karl at hayley) + + * filename.c (remove_suffix): new routine. + (make_suffix): if the `.' is before a `/', it doesn't start the + extension. + +Thu Aug 16 07:10:48 1990 Karl Berry (karl at hayley) + + * memory.c (safe_free): use fprintf instead of FATAL, so the core dump + will happen. + +Thu Jul 26 06:53:33 1990 Karl Berry (karl at hayley) + + * bitmap.c (bitmap_find_transitions): new routine (from imgtogf). + +Wed Jul 25 08:20:12 1990 Karl Berry (karl at hayley) + + * string.c (concat5): new routine. + +Tue Jul 24 10:24:59 1990 Karl Berry (karl at hayley) + + * font.c (get_font): save the design size in points instead of + pixels. + + * filename.c: new file. + * fileio.c (find_path_filename): move there. + * string.c (make_suffix): ditto. + + * font.c (get_char): retrieve the TFM width also. + +Mon Jul 16 07:30:33 1990 Karl Berry (karl at hayley) + + * bitmap.c (bitmap_to_bb): new routine. + +Thu Jul 12 06:01:16 1990 Karl Berry (karl at hayley) + + * bitmap.c (copy_bitmap): don't use `new_bitmap', to avoid setting + all the bits twice. + +Tue Jul 10 06:23:54 1990 Karl Berry (karl at hayley) + + * bitmap.c (concat_bitmaps): new routine. + +Mon Jul 9 08:27:09 1990 Karl Berry (karl at hayley) + + * bitmap.c (get_bitmap_bounding_box): delete this. + (print_bitmap): use dimensions_to_bb. + + * bitmap.c (free_bitmap): don't free the bitmap if it's null. + + * bitmap.c (new_bitmap): use memset. + (copy_bitmap): use memcpy if the bitmap's size is greater than + zero. + +Sat Jul 7 18:22:55 1990 Karl Berry (karl at hayley) + + * memory.c (safe_free): dump core if we are freeing a null item. + +Fri Jul 6 14:21:07 1990 Karl Berry (karl at hayley) + + * bounding-box.c (bb_to_dimensions): ensure that the dimensions + are nonnegative. + +Wed Jul 4 12:06:49 1990 Karl Berry (karl at hayley) + + * memory.c (allocate): dump core if we run out of memory. + (reallocate): ditto. + + * bounding-box.c (dimensions_to_bb): don't subtract one from the + width, so it will work with the GF routines. + (bb_to_dimensions): use BB_WIDTH and BB_HEIGHT, instead of doing + the subtraction out here. + + * bounding-box.c (update_bounding_box): new routine. + +Sun Jul 1 15:11:56 1990 Karl Berry (karl at hayley) + + * font.c (ascender_part): new routine. + +Tue Jun 26 11:27:15 1990 Karl Berry (karl at hayley) + + * spline.c (evaluate_spline): use temporaries in the computation + to avoid a compiler bug. + + * vector.c (Padd, Pmult_scalar): remove definitions, since they + are defined as macros now. + +Sun Jun 24 15:31:34 1990 Karl Berry (karl at claude) + + * font.c (get_font): don't check the checksums if either one is + zero. + +Sat Jun 23 12:11:47 1990 Karl Berry (karl at hayley) + + * font.c (print_char): change precision for printing the row numbers. + +Tue Jun 19 11:50:52 1990 Karl Berry (karl at hayley) + + * fileio.c (move_to_byte): delete this. + + * fileio.c (cur_pos): rename to checked_ftell, and take a filename + argument for perror. + +Mon Jun 18 12:47:17 1990 Karl Berry (karl at hayley) + + * font.c (find_internal_font): return a pointer to an + internal_font_type, instead of a structure, and change callers. + (get_font): if we have already saved the font, return it, instead + of opening the files again. + +Mon Jun 4 16:20:32 1990 Karl Berry (karl at hayley) + + * math.c (find_bounds): use MAXDOUBLE and MINDOUBLE, instead of + MAXFLOAT and MINFLOAT. + + * spline.c (spline_bounding_box): remove this routine. + +Sun Jun 3 10:51:28 1990 Karl Berry (karl at hayley) + + * arith.c, math.c, vector.c: add const declarations. + + * fileio.c (get_two, get_four): don't bother to initialize the + variable before we read it. + + * fileio.c (get_n_bytes): improve the error message if the read + fails. + +Sat Jun 2 07:51:08 1990 Karl Berry (karl at hayley) + + * bounding-box.c (increase_int_bound): remove this. + + * spline.c (print_spline): print different things for lines and + splines. + +Wed May 30 16:02:26 1990 Karl Berry (karl at hayley) + + * bitmap.c (new_bitmap): if the bitmap is going to be zero bits, + don't try to allocate it. + + * font.c (get_font): figure out how many characters are in the + font by testing the `exists' member of the TFM structure. + + * font.c (get_font): don't try to open the GF file if we couldn't + find it. + +Tue May 22 09:51:20 1990 Karl Berry (karl at hayley) + + * fileio.c (find_path_filename): close the directories in the path. + +Sat May 19 10:30:39 1990 Karl Berry (karl at hayley) + + * fileio.c (find_path_filename): return NULL if we can't find the + file, instead of the original name. + * font.c (get_font): rewrite the file-opening code. + +Wed May 16 18:02:54 1990 Karl Berry (karl at aten) + + * font.c (string_to_bitmap): if the character doesn't exist in the + font, don't crash. + + * fileio.c (find_path_filename): don't get a fatal error when a + directory in the path doesn't exist. + +Sun May 13 13:45:12 1990 Karl Berry (karl at hayley) + + * dirio.c (is_dir): new routine. + + * fileio.c (find_path_filename): just return the name we're given + if the path is relative; move the suffix concatenation out of the + loop; search in subdirectories. + +Tue May 8 12:08:57 1990 Karl Berry (karl at hayley) + + * math.c: doc fix. + +Thu May 3 10:45:05 1990 Karl Berry (karl at hayley) + + * line.c (read_line): use VS_CHARS. + +Wed May 2 12:25:08 1990 Karl Berry (karl at claude) + + * font.c (string_to_bitmap): don't close the font when we're done. + +Wed Apr 25 13:16:28 1990 Karl Berry (karl at aten) + + * font.c (string_to_bitmap): don't asked for chars[x] when x is a + character that isn't there. + +Tue Apr 24 18:35:08 1990 Karl Berry (karl at hayley) + + * math.c (real_to_int_coord): new routine. + +Sun Apr 22 06:42:37 1990 Karl Berry (karl at hayley) + + * font.c (string_to_bitmap): initialize char_y properly. + [whoops, I mean test it properly, and initialize y.] + Pass the row and column to BITMAP_PIXEL in the right order. + Give the row and column to the constructor in the right order, + too. Use MAX to find the depth, not MIN. + + * font.c (print_char): print the bitmap here, so we can print out + the Cartesian row number, instead of calling `print_bitmap'. + +Sat Apr 21 09:49:42 1990 Karl Berry (karl at hayley) + + * fileio.c (get_n_bytes): use fread to read the whole block, + instead of getting them one byte at a time. + +Thu Apr 19 16:19:33 1990 Karl Berry (karl at hayley) + + * font.c (get_font): do checksum test before getting the + postamble. + +Tue Apr 17 16:53:31 1990 Karl Berry (karl at hayley) + + * font.c (print_char): new routine to print a text representation + of a character. + +Mon Apr 16 11:12:28 1990 Karl Berry (karl at hayley) + + * font.c (get_font): get the design size from the TFM file, + instead of the bitmap file. + +Sun Apr 15 07:34:19 1990 Karl Berry (karl at hayley) + + * font.c (get_font): do not set the font bounding box. + +Sat Apr 14 15:11:19 1990 Karl Berry (karl at hayley) + + * fileio.c (checked_fseek): make argument type be + seek_direction_type. + + * fileio.c (checked_fclose): new (trivial) routine. + +Thu Apr 12 12:06:17 1990 Karl Berry (karl at hayley) + + * GNUmakefile: do not define USG and USGr3. + + * time.c: include and declare time(2) and ctime(3) + using time_t. + + * fileio.c (find_path_filename): use access(2) instead of + fopen(3); pass the default path to find_components. + (find_components): use a default path if the environment variable + doesn't exist. + +Mon Apr 9 08:19:53 1990 Karl Berry (karl at hayley) + + * math.c (distance): remove this, I came across hypot(3). + + * all files: upcase macro names. + +Sun Mar 18 14:58:23 1990 Kathy Hargreaves (kathy at hayley) + + * bounding_box.[hc] (increase_int_bound): added this to increase a + bounding boxes bounds nicely, i.e., if the bound is negative, it + gets decreased, and increased otherwise. + +Tue Feb 27 21:01:24 1990 Kathy Hargreaves (kathy at hayley) + + * fileio.c (get_n_bytes): don't try to read zero bytes. + +Wed Feb 7 17:00:47 1990 Karl Berry (karl at hayley) + + * time.c (now): chop off the trailing space. + +Mon Jan 29 12:46:56 1990 Karl Berry (karl at hayley) + + * bounding-box.c (bb_to_dimensions): new routine. + + * math.c (atou): like atoi but < 0 is a fatal error. + +Sun Jan 21 09:55:14 1990 Karl Berry (karl at hayley) + + * Makefile: rename to GNUmakefile. + + * bounding_box.c (dimensions_to_bounding_box): rename to + dimensions_bb. Remove other conversion routines. And rename to + bounding-box.c. + +Tue Oct 31 07:24:05 1989 Karl Berry (karl at hayley) + + * math.c (int_to_real_coordinate): remove this. + +Mon Oct 30 14:03:57 1989 Karl Berry (karl at hayley) + + * all files: add the copyleft. + + * string.c (concat4): define this. + +Sun Oct 29 18:37:33 1989 Karl Berry (karl at claude) + + * math.c (undefined_real_coordinate): remove this. + +Sat Oct 28 15:55:59 1989 Karl Berry (karl at hayley) + + * arith.c (real_to_scaled, real_to_fix): multiply the integer part + by scaled_one and fix_one, respectively. + + * fileio.c (put_three): define this. + (put_three, put_four): had the mask wrong for the + low-order byte. + (put_two, put_three, put_four): a & b >> c is + a & (b >> c), not (a & b) >> c. + +Fri Oct 27 22:14:05 1989 Karl Berry (karl at hayley) + + * bitmap.c (new_bitmap): use the bitmap_dimensions macro. + +Sun Oct 8 15:41:01 1989 Karl Berry (karl at hayley) + + * math.c (epsilon_equal): new function to test if two values are + within epsilon of each other. + (acosd): changed to call that one. + + * bitmap.c (free_bitmap): new function to deallocate storage + used in a bitmap_type. + + * math.c (acosd): normalize to 1.0 or -1.0 if the argument is + within an epsilon of that anyway. + +Fri Oct 6 22:12:05 1989 Karl Berry (karl at hayley) + + * line.c (read_line): overwrite the newline at the end of the + string with a null. diff --git a/lib/basename.o b/lib/basename.o deleted file mode 100644 index 8242dd6..0000000 Binary files a/lib/basename.o and /dev/null differ diff --git a/lib/fmod-deprecated.c b/lib/fmod-deprecated.c new file mode 100644 index 0000000..0c78f52 --- /dev/null +++ b/lib/fmod-deprecated.c @@ -0,0 +1,145 @@ +/* + * Copyright (c) 1989 The Regents of the University of California. + * All rights reserved. + * + * Redistribution and use in source and binary forms are permitted + * provided that: (1) source distributions retain this entire copyright + * notice and comment, and (2) distributions including binaries display + * the following acknowledgement: ``This product includes software + * developed by the University of California, Berkeley and its contributors'' + * in the documentation or other materials provided with the distribution + * and in all advertising materials mentioning features or use of this + * software. Neither the name of the University nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. + */ + +#ifndef lint +static char sccsid[] = "@(#)fmod.c 5.2 (Berkeley) 6/1/90"; +#endif /* not lint */ + +/* fmod.c + * + * SYNOPSIS + * + * #include + * double fmod(double x, double y) + * + * DESCRIPTION + * + * The fmod function computes the floating-point remainder of x/y. + * + * RETURNS + * + * The fmod function returns the value x-i*y, for some integer i + * such that, if y is nonzero, the result has the same sign as x and + * magnitude less than the magnitude of y. + * + * On a VAX or CCI, + * + * fmod(x,0) traps/faults on floating-point divided-by-zero. + * + * On IEEE-754 conforming machines with "isnan()" primitive, + * + * fmod(x,0), fmod(INF,y) are invalid operations and NaN is returned. + * + */ +#include /* changed from "mathimpl.h" --karl */ + +#if !defined(vax) && !defined(tahoe) +extern int isnan(),finite(); +#endif /* !defined(vax) && !defined(tahoe) */ +extern double frexp(),ldexp(),fabs(); + +#ifdef TEST_FMOD +static double +_fmod(x,y) +#else /* TEST_FMOD */ +double +fmod(x,y) +#endif /* TEST_FMOD */ +double x,y; +{ + int ir,iy; + double r,w; + + if (y == (double)0 +#if 0 /* removed this --karl */ +#if !defined(vax) && !defined(tahoe) /* per "fmod" manual entry, SunOS 4.0 */ + || isnan(y) || !finite(x) +#endif /* !defined(vax) && !defined(tahoe) */ +#endif + ) + return (x*y)/(x*y); + + r = fabs(x); + y = fabs(y); + (void)frexp(y,&iy); + while (r >= y) { + (void)frexp(r,&ir); + w = ldexp(y,ir-iy); + r -= w <= r ? w : w*(double)0.5; + } + return x >= (double)0 ? r : -r; +} + +#ifdef TEST_FMOD +extern long random(); +extern double fmod(); + +#define NTEST 10000 +#define NCASES 3 + +static int nfail = 0; + +static void +doit(x,y) +double x,y; +{ + double ro = fmod(x,y),rn = _fmod(x,y); + if (ro != rn) { + (void)printf(" x = 0x%08.8x %08.8x (%24.16e)\n",x,x); + (void)printf(" y = 0x%08.8x %08.8x (%24.16e)\n",y,y); + (void)printf(" fmod = 0x%08.8x %08.8x (%24.16e)\n",ro,ro); + (void)printf("_fmod = 0x%08.8x %08.8x (%24.16e)\n",rn,rn); + (void)printf("\n"); + } +} + +main() +{ + register int i,cases; + double x,y; + + srandom(12345); + for (i = 0; i < NTEST; i++) { + x = (double)random(); + y = (double)random(); + for (cases = 0; cases < NCASES; cases++) { + switch (cases) { + case 0: + break; + case 1: + y = (double)1/y; break; + case 2: + x = (double)1/x; break; + default: + abort(); break; + } + doit(x,y); + doit(x,-y); + doit(-x,y); + doit(-x,-y); + } + } + if (nfail) + (void)printf("Number of failures: %d (out of a total of %d)\n", + nfail,NTEST*NCASES*4); + else + (void)printf("No discrepancies were found\n"); + exit(0); +} +#endif /* TEST_FMOD */ diff --git a/lib/strstr.o b/lib/strstr.o deleted file mode 100644 index a882b08..0000000 Binary files a/lib/strstr.o and /dev/null differ -- cgit v1.2.1