--- 0.1 1987/05/16 04:00:00 +++ Makefile 1996/09/21 23:02:43 @@ -1,11 +1,26 @@ -DESTDIR = -CFLAGS = -O +#DESTDIR = /usr/bin +#CFLAGS = -O -lc: lc.c - ${CC} ${CFLAGS} -o lc lc.c +CFLAGS = -O2 -fno-strength-reduce +LDLIBS = +DESTDIR = /usr/bin# FSSTND +DISTDIR = /home/ftp/pub/MFCF/lc +#DESTDIR = /.software/local/.admin/bins/bin# on my machine +lc: lc.o + +lc.o: lc.c + ${CC} -c ${CFLAGS} -o lc.o lc.c + install: lc - install -s lc $(DESTDIR)/usr/bin/lc + install -s lc $(DESTDIR)/lc clean: - rm -f lc a.out core *.o *.bak + rm -f lc a.out core diffs *.o *.bak *.tar.gz + +distclean: clean + +dist: distclean + rcsdiff -u -rMFCF Makefile lc.c 2>&1 >diffs || true + ./mkdist + cp -p lc.tar.gz README* *.lsm index.html diffs $(DISTDIR) --- 1.18 1994/02/22 16:44:22 +++ lc.c 1996/09/21 23:17:00 @@ -1,11 +1,27 @@ #ifndef lint static char *copyright = "LC - Copyright University of Waterloo, 1978,1985,1987"; +static char *rcsid = + "$Id: lc.c,v 1.18.1.3 1996/09/14 01:05:38 acli Stab $\n"; #endif /* lint */ /* * lc [directory ...] */ +#ifdef __linux__ +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +typedef struct dirent DirType; +#else /* Hope you have the mfcf-basics package... good luck! */ #include #include #include @@ -15,6 +31,7 @@ #include #include #include +#endif #ifndef MAXPATHLEN # define MAXPATHLEN 1024 /* For older systems */ @@ -310,8 +327,10 @@ struct termio termbuf; ioctl(1, TCGETA, termbuf); #else +#if !defined(__linux__) struct sgttyb sgbuf; (void) gtty(1, &sgbuf); +#endif #endif if (ioctl(1, TIOCGWINSZ, &win) != -1) { ncols = (win.ws_col == 0 ? 5 : (win.ws_col / COLUMNWIDTH));