1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157
|
# ----------------------------------------------------------------------------
#
# A license is hereby granted to reproduce this software source code and
# to create executable versions from this source code for personal,
# non-commercial use. The copyright notice included with the software
# must be maintained in all copies produced.
#
# THIS PROGRAM IS PROVIDED "AS IS". THE AUTHOR PROVIDES NO WARRANTIES
# WHATSOEVER, EXPRESSED OR IMPLIED, INCLUDING WARRANTIES OF
# MERCHANTABILITY, TITLE, OR FITNESS FOR ANY PARTICULAR PURPOSE. THE
# AUTHOR DOES NOT WARRANT THAT USE OF THIS PROGRAM DOES NOT INFRINGE THE
# INTELLECTUAL PROPERTY RIGHTS OF ANY THIRD PARTY IN ANY COUNTRY.
#
# Copyright (c) 1995, John Conover, All Rights Reserved.
#
# Comments and/or bug reports should be addressed to:
#
# john@johncon.com (John Conover)
#
# ----------------------------------------------------------------------------
#
# Makefile, makefile for rel
#
# $Revision: 1.1 $
# $Date: 1995/12/23 23:08:20 $
# $Id: Makefile,v 1.1 1995/12/23 23:08:20 john Exp $
# $Log: Makefile,v $
# Revision 1.1 1995/12/23 23:08:20 john
# Added special GNU gcc option; added compile time option to control program behavior during file system exceptions.
# Changes to files: Makefile, searchpath.c, searchfile.c, message.c, version.c-specifically to control program behavior under certain file system exceptions; specifics for the GNU gcc compiler, and ANSI C cosmetic formalities.
#
# Revision 1.0 1995/04/22 05:16:24 john
# Initial revision
#
# The define, FSE_CONTINUE, controls the program behavior during the
# file system exceptions, error opening file, and error opening
# directory-if defined, the program will continue under these
# exceptions, and if not defined, the program will shutdown under these
# exceptions. For particulars, see the file CHANGES, section "Version
# 1.1," and searchpath.c.
#
CFLAGS = -DFSE_CONTINUE -O -c
# CFLAGS = -DFSE_CONTINUE -g -c
LFLAGS = -O
# LFLAGS = -g
#
# System V, BSD:
#
# CC = cc $(CFLAGS) $*.c
# LINK = cc $(LFLAGS) -o $(PROGRAM) $(OBJECTS)
# LINT = /usr/bin/lint -ux -DLINT $(SOURCES)
#
# GNU gcc:
#
CC = gcc $(CFLAGS) $*.c
LINK = gcc $(LFLAGS) -o $(PROGRAM) $(OBJECTS)
LINT = gcc -DLINT -fsyntax-only -pedantic -W -Wall -Waggregate-return -Wcast-align -Wcast-qual -Wconversion -Wenum-clash -Winline -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Wno-import -Wpointer-arith -Wshadow -Wstrict-prototypes -Wtraditional -Wwrite-strings $(SOURCES)
PROGRAM = rel
HEADERS = rel.h \
postfix.h \
lexicon.h \
searchfile.h \
relclose.h \
stack.h \
eval.h \
bmhsearch.h \
searchpath.h \
translit.h \
qsortlist.h \
uppercase.h \
memalloc.h \
message.h \
version.h
SOURCES = rel.c \
postfix.c \
lexicon.c \
searchfile.c \
relclose.c \
eval.c \
bmhsearch.c \
searchpath.c \
translit.c \
qsortlist.c \
uppercase.c \
memalloc.c \
message.c \
version.c
OBJECTS = rel.o \
postfix.o \
lexicon.o \
searchfile.o \
relclose.o \
eval.o \
bmhsearch.o \
searchpath.o \
translit.o \
qsortlist.o \
uppercase.o \
memalloc.o \
message.o \
version.o
.c.o:
$(CC)
$(PROGRAM): $(OBJECTS)
$(LINK)
$(OBJECTS): $(HEADERS)
lint:
$(LINT)
# Various test cases for the modules in rel-forces top down compile for
# assurance that -g is used
testlexicon: lexicon.c lexicon.h uppercase.c uppercase.h memalloc.c memalloc.h message.c message.h
cc -DTEST_LEXICON -g -o testlexicon lexicon.c uppercase.c memalloc.c message.c
testpostfix: postfix.c postfix.h lexicon.c lexicon.h message.c message.h
cc -DTEST_POSTFIX -g -o testpostfix postfix.c lexicon.c message.c memalloc.c eval.c uppercase.c
teststack: stack.h
cp stack.h teststack.c
cc -DTEST_STACK -g -o teststack teststack.c
rm -f teststack.c
testmessage: message.c message.h
cc -DTEST_MESSAGE -g -o testmessage message.c
testsearchfile: searchfile.c searchfile.h uppercase.c uppercase.h translit.c translit.h memalloc.c memalloc.h bmhsearch.c bmhsearch.h postfix.c postfix.h eval.c eval.h lexicon.c lexicon.h message.c message.h
cc -DTEST_SEARCHFILE -g -o testsearchfile searchfile.c uppercase.c translit.c memalloc.c bmhsearch.c postfix.c eval.c lexicon.c message.c
testversion: version.c version.h
cc -DTEST_VERSION -g -o testversion version.c
testuppercase: uppercase.c uppercase.h memalloc.c memalloc.h message.c message.h
cc -DTEST_UPPERCASE -g -o testuppercase uppercase.c memalloc.c message.c
testsearchpath: searchpath.c searchpath.h searchfile.c searchfile.h uppercase.c uppercase.h translit.c translit.h memalloc.c memalloc.h bmhsearch.c bmhsearch.h postfix.c postfix.h eval.c eval.h lexicon.c lexicon.h message.c message.h
cc -DTEST_SEARCHPATH -g -o testsearchpath searchpath.c searchfile.c uppercase.c translit.c memalloc.c bmhsearch.c postfix.c eval.c lexicon.c message.c
testtranslit: translit.c translit.h uppercase.c uppercase.h memalloc.c memalloc.h message.c message.h
cc -DTEST_TRANSLIT -g -o testtranslit translit.c uppercase.c memalloc.c message.c
testmemalloc: memalloc.c memalloc.h message.c message.h
cc -DTEST_MEMALLOC -g -o testmemalloc memalloc.c message.c
testqsortlist: qsortlist.c qsortlist.h
cc -DTEST_QSORTLIST -g -o testqsortlist qsortlist.c
testbmhsearch: bmhsearch.c bmhsearch.h memalloc.c memalloc.h message.c message.h
cc -DTEST_BMHSEARCH -g -o testbmhsearch bmhsearch.c memalloc.c message.c
|