home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Dream 51
/
Amiga_Dream_51.iso
/
Atari
/
Desktops
/
text113b.zoo
/
textutils-1.13
/
src
/
Makefile
< prev
next >
Wrap
Makefile
|
1996-01-22
|
6KB
|
264 lines
# Makefile for GNU text utilities.
# Copyright (C) 1991, 1992, 1993, 1994 Free Software Foundation, Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
SHELL = /bin/sh
srcdir = /d/textutils-1.13/src
VPATH = $(srcdir)
prefix =
exec_prefix =
bindir = $(exec_prefix)/bin
libdir = $(exec_prefix)/lib
INSTALL =
INSTALL_PROGRAM =
CC = gcc
DEFS = -DHAVE_CONFIG_H
LIBS = -liio
CFLAGS = -O2 -fomit-frame-pointer
LDFLAGS =
RM = rm
LN = ln
MV = mv
SOURCES = cat.c cksum.c comm.c csplit.c cut.c expand.c fmt.c fold.c \
head.c join.c md5sum.c nl.c od.c paste.c pr.c sort.c split.c sum.c tac.c \
tail.c tr.c unexpand.c uniq.c wc.c version.c
OBJECTS = cat.o cksum.o comm.o csplit.o cut.o expand.o fmt.o fold.o \
head.o join.o md5sum.o nl.o od.o paste.o pr.o sort.o split.o sum.o tac.o \
tail.o tr.o unexpand.o uniq.o wc.o version.o
DISTFILES = ansi2knr.c ansi2knr.1 Makefile.in system.h version.h \
md5-test.rfc $(SOURCES)
PROGS = cat.ttp cksum.ttp comm.ttp csplit.ttp cut.ttp expand.ttp fmt.ttp fold.ttp head.ttp join.ttp md5sum.ttp nl.ttp od.ttp \
paste.ttp pr.ttp sort.ttp split.ttp sum.ttp tac.ttp tail.ttp tr.ttp unexpand.ttp uniq.ttp wc.ttp
LIBPROGS =
all: $(PROGS) $(LIBPROGS)
.SUFFIXES:
.SUFFIXES: .c .o
COMPILE = $(CC) -c $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS)
INCLUDES = -I.. -I$(srcdir) -I$(srcdir)/../lib
.c.o:
$(COMPILE) $<
subdir = src
#Makefile: ../config.status Makefile.in
# cd .. && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= ./config.status
installdirs:
$(srcdir)/../mkinstalldirs $(bindir)
transform = @program_transform_name@
install: install-exec install-data
install-data:
install-exec: all installdirs
for f in $(PROGS); do \
$(INSTALL_PROGRAM) $$f \
$(bindir)/`echo $$f|sed '$(transform)'`; \
done
uninstall:
for f in $(PROGS); do \
$(RM) -f \
$(bindir)/`echo $$f|sed '$(transform)'`; \
done
TAGS: $(SOURCES)
etags $(SOURCES)
check: md5sum.ttp
./md5sum \
--string="" \
--string="a" \
--string="abc" \
--string="message digest" \
--string="abcdefghijklmnopqrstuvwxyz" \
--string="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789" \
--string="12345678901234567890123456789012345678901234567890123456789012345678901234567890" \
| diff -c $(srcdir)/md5-test.rfc -
clean:
$(RM) -f $(PROGS) $(LIBPROGS) ansi2knr core krtmp*.c *._c *._o *.o
mostlyclean: clean
distclean: clean
$(RM) -f Makefile
maintainer-clean: distclean
$(RM) -f TAGS
distdir = ../`cat ../distname`/$(subdir)
dist: $(DISTFILES)
for file in $(DISTFILES); do \
$(LN) $$file $(distdir) \
|| { echo copying $$file instead; cp -p $$file $(distdir);}; \
done
# Linking rules.
ansi2knr: ansi2knr.o
$(link_command) ansi2knr.o $(LIBS)
link_command = $(CC) $(LDFLAGS) -o $@
cat.ttp: cat.o
$(link_command) cat.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
cksum.ttp: cksum.o
$(link_command) cksum.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
comm.ttp: comm.o
$(link_command) comm.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
csplit.ttp: csplit.o
$(link_command) csplit.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
cut.ttp: cut.o
$(link_command) cut.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
expand.ttp: expand.o
$(link_command) expand.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
fmt.ttp: fmt.o
$(link_command) fmt.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
fold.ttp: fold.o
$(link_command) fold.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
head.ttp: head.o
$(link_command) head.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
join.ttp: join.o
$(link_command) join.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
md5sum.ttp: md5sum.o
$(link_command) md5sum.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
nl.ttp: nl.o
$(link_command) nl.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
od.ttp: od.o
$(link_command) od.o ../lib/libtu.a version.o
strip -k $@
chmod +x $@
paste.ttp: paste.o
$(link_command) paste.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
pr.ttp: pr.o
$(link_command) pr.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
sort.ttp: sort.o
$(link_command) sort.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
split.ttp: split.o
$(link_command) split.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
sum.ttp: sum.o
$(link_command) sum.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
tac.ttp: tac.o
$(link_command) tac.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
tail.ttp: tail.o
$(link_command) tail.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
tr.ttp: tr.o
$(link_command) tr.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
unexpand.ttp: unexpand.o
$(link_command) unexpand.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
uniq.ttp: uniq.o
$(link_command) uniq.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
wc.ttp: wc.o
$(link_command) wc.o ../lib/libtu.a version.o $(LIBS)
strip -k $@
chmod +x $@
$(PROGS) $(LIBPROGS): ../lib/libtu.a version.o
csplit.o nl.o tac.o: ../lib/regex.h
comm$O nl.o uniq.o: ../lib/linebuffer.h
od.o tail.o: ../lib/xstrtol.h
join.o md5sum$O sort.o: ../lib/long-options.h
# Make all .o files depend on these files even though there are a few
# unnecessary dependencies.
$(OBJECTS): ../config.h ../lib/error.h system.h version.h
.PHONY: all check clean dist distclean install install-data install-exec \
installdirs maintainer-clean mostlyclean uninstall
# Tell versions [3.59,3.63) of GNU make not to export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT: