-
Notifications
You must be signed in to change notification settings - Fork 84
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
118 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
# Makefile for less under DJGPP v2.0 or later. | ||
|
||
#### Start of system configuration section. #### | ||
|
||
srcdir = . | ||
VPATH = . | ||
|
||
CC = gcc | ||
|
||
CFLAGS = -O2 | ||
CFLAGS_COMPILE_ONLY = -c | ||
LDFLAGS = -s | ||
O=o | ||
|
||
LIBS = | ||
|
||
#### End of system configuration section. #### | ||
|
||
SUBSHELL = command >nul /c | ||
|
||
# This rule allows us to supply the necessary -D options | ||
# in addition to whatever the user asks for. | ||
.c.o: | ||
${CC} -I. ${CFLAGS_COMPILE_ONLY} ${CPPFLAGS} ${CFLAGS} $< | ||
|
||
OBJ = main.${O} screen.${O} brac.${O} ch.${O} charset.${O} cmdbuf.${O} \ | ||
command.${O} decode.${O} edit.${O} filename.${O} forwback.${O} \ | ||
help.${O} ifile.${O} input.${O} jump.${O} line.${O} linenum.${O} \ | ||
lsystem.${O} mark.${O} optfunc.${O} option.${O} opttbl.${O} os.${O} \ | ||
output.${O} position.${O} prompt.${O} search.${O} signal.${O} \ | ||
tags.${O} ttyin.${O} version.${O} | ||
|
||
all: less lesskey | ||
|
||
less: ${OBJ} | ||
${CC} ${LDFLAGS} -o $@ ${OBJ} ${LIBS} | ||
|
||
lesskey: lesskey.${O} version.${O} | ||
${CC} ${LDFLAGS} -o $@ lesskey.${O} version.${O} | ||
|
||
defines.h: defines.ds | ||
update $< $@ | ||
|
||
${OBJ}: less.h defines.h funcs.h | ||
|
||
info: | ||
install-info: | ||
dvi: | ||
check: | ||
installcheck: | ||
|
||
TAGS: | ||
etags *.c *.h | ||
|
||
# command > funcs.h /c mkfuncs | ||
newfuncs: | ||
redir -o funcs.h gawk -f mkfuncs.awk ${OBJ:.${O}=.c} | ||
|
||
clean: | ||
${SUBSHELL} for %%f in (*.${O} less lesskey *.exe) do if exist %%f del %%f | ||
|
||
mostlyclean: clean | ||
|
||
distclean: clean | ||
if not exist makefile.dj ren makefile makefile.dj | ||
if not exist defines.ds ren defines.h defines.ds | ||
${SUBSHELL} for %%f in (Makefile defines.h) do if exist %%f del %%f | ||
|
||
realclean: distclean | ||
if exist TAGS del TAGS | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
/* | ||
* Copyright (c) 1984,1985,1989,1994,1995,1996 Mark Nudelman | ||
* All rights reserved. | ||
* | ||
* Redistribution and use in source and binary forms, with or without | ||
* modification, are permitted provided that the following conditions | ||
* are met: | ||
* 1. Redistributions of source code must retain the above copyright | ||
* notice, this list of conditions and the following disclaimer. | ||
* 2. Redistributions in binary form must reproduce the above copyright | ||
* notice in the documentation and/or other materials provided with | ||
* the distribution. | ||
* | ||
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY | ||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR | ||
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE | ||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR | ||
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT | ||
* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR | ||
* BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, | ||
* WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE | ||
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN | ||
* IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | ||
*/ | ||
|
||
/* | ||
* Definitions of keys on the PC. | ||
* Special (non-ASCII) keys on the PC send a two-byte sequence, | ||
* where the first byte is 0 and the second is as defined below. | ||
*/ | ||
#define PCK_SHIFT_TAB '\017' | ||
#define PCK_ALT_E '\022' | ||
#define PCK_F1 '\073' | ||
#define PCK_HOME '\107' | ||
#define PCK_UP '\110' | ||
#define PCK_PAGEUP '\111' | ||
#define PCK_LEFT '\113' | ||
#define PCK_RIGHT '\115' | ||
#define PCK_END '\117' | ||
#define PCK_DOWN '\120' | ||
#define PCK_PAGEDOWN '\121' | ||
#define PCK_INSERT '\122' | ||
#define PCK_DELETE '\123' | ||
#define PCK_CTL_LEFT '\163' | ||
#define PCK_CTL_RIGHT '\164' | ||
#define PCK_CTL_DELETE '\223' |