mirror of
https://github.com/lcn2/calc.git
synced 2025-08-16 01:03:29 +03:00
Release calc version 2.11.5.7
This commit is contained in:
36
CHANGES
36
CHANGES
@@ -18,6 +18,38 @@ The following are the changes from calc version 2.11.5.5 to date:
|
||||
NOTE: See the BUGS file for a Linux issue when compiling calc
|
||||
with -O (or -O2 or -O3) AND with -g (or -g3) AND with readline.
|
||||
|
||||
Removed an obsolete reference to TOPDIR. This was fixed thanks to
|
||||
a bug report by Clifford Kite <kite_public1 at ev1 dot net>.
|
||||
|
||||
Fixed calc man page so that is refers to -f instead of the old -S flag.
|
||||
Fixed thanks to Clifford Kite <kite_public1 at ev1 dot net> for
|
||||
point this out.
|
||||
|
||||
All for loops end with /dev/null to avoid any problems related
|
||||
to systems that cannot grok empty for loops.
|
||||
|
||||
Changed the libcalc functions creal and cimag to c_real and c_imag
|
||||
to about conflicts with new libc such as those used by gcc v3.
|
||||
Thanks Eli Zaretskii <eliz at is dot elta dot co dot il> and
|
||||
Martin Buck <m at rtin-buck dot de> for alerting us to this conflict.
|
||||
|
||||
The Makefile no longer hard code's /usr/include. Instead it uses
|
||||
the ${INCDIR} Makefile variable. Thanks goes to Eli Zaretskii
|
||||
<eliz at is dot elta dot co dot il> for pointing out this inconsistency.
|
||||
|
||||
Added mods to support compilation under DJGPP. DJGPP runs on 386
|
||||
and newer PCs running DOS or dos-compatible operating systems.
|
||||
See http://www.delorie.com/djgpp/. Thanks goes to Eli Zaretskii
|
||||
<eliz at is dot elta dot co dot il> for sending in these mods.
|
||||
|
||||
Updated README.WINDOWS to include information on building with DJGPP.
|
||||
|
||||
The pld folks are building RPMs based on our calc distrbutions.
|
||||
See: ftp://ftp.pld.org.pl/dists/ra/PLD/i686/PLD/RPMS or
|
||||
http://ftp.pld.org.pl/dists/ra/PLD/i686/PLD/RPMS more information.
|
||||
We appreciate their work in this regard. In the next release, we
|
||||
plan to also build and release our own RPMs based on their efforts.
|
||||
|
||||
|
||||
The following are the changes from calc version 2.11.5t4.1 to 2.11.5t4.4:
|
||||
|
||||
@@ -5379,8 +5411,8 @@ Following is a list of visible changes to calc from version 1.24.7 to 1.26.1:
|
||||
## received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
## 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
##
|
||||
## @(#) $Revision: 29.45 $
|
||||
## @(#) $Id: CHANGES,v 29.45 2001/12/31 22:12:35 chongo Exp $
|
||||
## @(#) $Revision: 29.46 $
|
||||
## @(#) $Id: CHANGES,v 29.46 2002/03/12 10:58:31 chongo Exp $
|
||||
## @(#) $Source: /usr/local/src/cmd/calc/RCS/CHANGES,v $
|
||||
##
|
||||
## Under source code control: 1993/06/02 18:12:57
|
||||
|
@@ -19,12 +19,21 @@ Installing calc in 4 easy steps:
|
||||
As shipped the Makefile assumes 'more'. On your system
|
||||
you may find 'less' to be a better pager.
|
||||
|
||||
Set TOPDIR to be the place under which help files, calc,
|
||||
include files and calc libs are to be installed. As shipped
|
||||
the Makefile assumes a TOPDIR of /usr/local/lib.
|
||||
Set BINDIR to the directory where calc is installed.
|
||||
As shipped the Makefile assumes BINDIR is /usr/local/bin.
|
||||
|
||||
Set BINDIR to the place where calc is installed. As shipped
|
||||
the Makefile assumes a BINDIR /usr/local/bin.
|
||||
Set SHAREDIR to the place where shared files are kept.
|
||||
As shipped the Makefile assumes that SHAREDIR is /usr/share.
|
||||
Calc places its shared files under ${SHAREDIR}/calc.
|
||||
|
||||
Set INCDIR to the place where .h header files are kept.
|
||||
As shipped the Makefile assumes that INCDIR is /usr/include.
|
||||
Calc places its .h header files under ${INCDIR}/calc.
|
||||
|
||||
Set LIBDIR to be the place under which help files, calc,
|
||||
include files and calc libs are to be installed.
|
||||
As shipped the Makefile assumes a LIBDIR of /usr/lib.
|
||||
The calc library is installed as ${LIBDIR}/libcalc.a.
|
||||
|
||||
Some compilers (to put it mildly) have bugs. Sometimes the
|
||||
DEBUG Makefile variable causes the compiler / optimizer to
|
||||
@@ -72,8 +81,8 @@ the calc help subsystem. See the README file for details.
|
||||
## received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
## 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
##
|
||||
## @(#) $Revision: 29.3 $
|
||||
## @(#) $Id: HOWTO.INSTALL,v 29.3 2001/12/11 02:51:00 chongo Exp $
|
||||
## @(#) $Revision: 29.4 $
|
||||
## @(#) $Id: HOWTO.INSTALL,v 29.4 2002/03/12 09:03:17 chongo Exp $
|
||||
## @(#) $Source: /usr/local/src/cmd/calc/RCS/HOWTO.INSTALL,v $
|
||||
##
|
||||
## Under source code control: 1999/09/27 20:48:44
|
||||
|
178
Makefile
178
Makefile
@@ -20,8 +20,8 @@
|
||||
# received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
# 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
#
|
||||
MAKEFILE_REV= $$Revision: 29.41 $$
|
||||
# @(#) $Id: Makefile.ship,v 29.41 2001/12/31 22:12:35 chongo Exp $
|
||||
MAKEFILE_REV= $$Revision: 29.46 $$
|
||||
# @(#) $Id: Makefile.ship,v 29.46 2002/03/12 10:43:05 chongo Exp $
|
||||
# @(#) $Source: /usr/local/src/cmd/calc/RCS/Makefile.ship,v $
|
||||
#
|
||||
# Under source code control: 1990/02/15 01:48:41
|
||||
@@ -47,6 +47,8 @@ MAKEFILE_REV= $$Revision: 29.41 $$
|
||||
# -DUSE_SGTTY use struct sgttyb from <sys/ioctl.h>
|
||||
# -DUSE_NOTHING windoz system, don't use any of them
|
||||
#
|
||||
# Select TERMCONTROL= -DUSE_TERMIOS for DJGPP.
|
||||
#
|
||||
# If in doubt, leave TERMCONTROL empty.
|
||||
#
|
||||
TERMCONTROL=
|
||||
@@ -87,6 +89,8 @@ HAVE_VSPRINTF=
|
||||
# a make clobber and try -DLITTLE_ENDIAN. If that fails, ask a wizard
|
||||
# for help.
|
||||
#
|
||||
# Select BYTE_ORDER= -DLITTLE_ENDIAN for DJGPP.
|
||||
#
|
||||
BYTE_ORDER=
|
||||
#BYTE_ORDER= -DBIG_ENDIAN
|
||||
#BYTE_ORDER= -DLITTLE_ENDIAN
|
||||
@@ -99,9 +103,11 @@ BYTE_ORDER=
|
||||
# In order to avoid make brain damage in some systems, we avoid placing
|
||||
# a space after the ='s below.
|
||||
#
|
||||
# Select LONG_BITS= 32 for DJGPP.
|
||||
#
|
||||
LONG_BITS=
|
||||
#LONG_BITS=32
|
||||
#LONG_BITS=64
|
||||
#LONG_BITS= 32
|
||||
#LONG_BITS= 64
|
||||
|
||||
# Determine if your compiler supports the long long type and if so, its length
|
||||
#
|
||||
@@ -119,6 +125,8 @@ LONG_BITS=
|
||||
# If in doubt, try to leave LONGLONG_BITS empty. Do a 'make check'
|
||||
# and change to 'LONGLONG_BITS= 0' if you encounter problems.
|
||||
#
|
||||
# Select LONGLONG_BITS= 64 for DJGPP.
|
||||
#
|
||||
#LONGLONG_BITS= 0
|
||||
LONGLONG_BITS=
|
||||
#LONGLONG_BITS= 64
|
||||
@@ -141,6 +149,8 @@ HAVE_FPOS=
|
||||
# to determine if fpos_t has a __pos structure element. If HAVE_FPOS_POS
|
||||
# is set to -DHAVE_NO_FPOS_POS, then calc assume there is no __pos element.
|
||||
#
|
||||
# Select HAVE_FPOS_POS= -DHAVE_NO_FPOS_POS for DJGPP.
|
||||
#
|
||||
# If in doubt, leave HAVE_FPOS_POS empty and this Makefile will figure it out.
|
||||
#
|
||||
HAVE_FPOS_POS=
|
||||
@@ -151,11 +161,11 @@ HAVE_FPOS_POS=
|
||||
# If FPOS_POS_BITS is empty, then the Makefile will determine the size of
|
||||
# the file position value of the __pos element.
|
||||
#
|
||||
# If in doubt, leave FPOS_POS_BITS empty and this Makefile will figure it out.
|
||||
#
|
||||
# If there is no __pos element in fpos_t (say because fpos_t is a scalar),
|
||||
# leave FPOS_POS_BITS blank.
|
||||
#
|
||||
# If in doubt, leave FPOS_POS_BITS empty and this Makefile will figure it out.
|
||||
#
|
||||
FPOS_POS_BITS=
|
||||
#FPOS_POS_BITS= 32
|
||||
#FPOS_POS_BITS= 64
|
||||
@@ -165,6 +175,8 @@ FPOS_POS_BITS=
|
||||
# If FPOS_BITS is empty, then the Makefile will determine the size of
|
||||
# the file position value.
|
||||
#
|
||||
# Select FPOS_BITS= 32 for DJGPP.
|
||||
#
|
||||
# If in doubt, leave FPOS_BITS empty and this Makefile will figure it out.
|
||||
#
|
||||
FPOS_BITS=
|
||||
@@ -176,6 +188,8 @@ FPOS_BITS=
|
||||
# If OFF_T_BITS is empty, then the Makefile will determine the size of
|
||||
# the file offset value.
|
||||
#
|
||||
# Select OFF_T_BITS= 32 for DJGPP.
|
||||
#
|
||||
# If in doubt, leave OFF_T_BITS empty and this Makefile will figure it out.
|
||||
#
|
||||
OFF_T_BITS=
|
||||
@@ -187,6 +201,8 @@ OFF_T_BITS=
|
||||
# If DEV_BITS is empty, then the Makefile will determine the size of
|
||||
# the dev_t device value
|
||||
#
|
||||
# Select DEV_BITS= 32 for DJGPP.
|
||||
#
|
||||
# If in doubt, leave DEV_BITS empty and this Makefile will figure it out.
|
||||
#
|
||||
DEV_BITS=
|
||||
@@ -199,6 +215,8 @@ DEV_BITS=
|
||||
# If INODE_BITS is empty, then the Makefile will determine the size of
|
||||
# the ino_t inode value
|
||||
#
|
||||
# Select INODE_BITS= 32 for DJGPP.
|
||||
#
|
||||
# If in doubt, leave INODE_BITS empty and this Makefile will figure it out.
|
||||
#
|
||||
INODE_BITS=
|
||||
@@ -291,6 +309,8 @@ HAVE_MEMMOVE=
|
||||
# -DHAVE_NO_USTAT, then calc will use internal functions to simulate
|
||||
# the memory move function that does correct overlapping memory modes.
|
||||
#
|
||||
# Select HAVE_USTAT= -DHAVE_NO_USTAT for DJGPP.
|
||||
#
|
||||
# If in doubt, leave HAVE_USTAT empty and this Makefile will figure it out.
|
||||
#
|
||||
HAVE_USTAT=
|
||||
@@ -303,6 +323,8 @@ HAVE_USTAT=
|
||||
# -DHAVE_NO_GETSID, then calc will use internal functions to simulate
|
||||
# the memory move function that does correct overlapping memory modes.
|
||||
#
|
||||
# Select HAVE_GETSID= -DHAVE_NO_GETSID for DJGPP.
|
||||
#
|
||||
# If in doubt, leave HAVE_GETSID empty and this Makefile will figure it out.
|
||||
#
|
||||
HAVE_GETSID=
|
||||
@@ -315,6 +337,8 @@ HAVE_GETSID=
|
||||
# -DHAVE_NO_GETPGID, then calc will use internal functions to simulate
|
||||
# the memory move function that does correct overlapping memory modes.
|
||||
#
|
||||
# Select HAVE_GETPGID= -DHAVE_NO_GETPGID for DJGPP.
|
||||
#
|
||||
# If in doubt, leave HAVE_GETPGID empty and this Makefile will figure it out.
|
||||
#
|
||||
HAVE_GETPGID=
|
||||
@@ -327,6 +351,8 @@ HAVE_GETPGID=
|
||||
# -DHAVE_NO_GETTIME, then calc will use internal functions to simulate
|
||||
# the memory move function that does correct overlapping memory modes.
|
||||
#
|
||||
# Select HAVE_GETTIME= -DHAVE_NO_GETTIME for DJGPP.
|
||||
#
|
||||
# If in doubt, leave HAVE_GETTIME empty and this Makefile will figure it out.
|
||||
#
|
||||
HAVE_GETTIME=
|
||||
@@ -339,6 +365,8 @@ HAVE_GETTIME=
|
||||
# -DHAVE_NO_GETPRID, then calc will use internal functions to simulate
|
||||
# the memory move function that does correct overlapping memory modes.
|
||||
#
|
||||
# Select HAVE_GETPRID= -DHAVE_NO_GETPRID for DJGPP.
|
||||
#
|
||||
# If in doubt, leave HAVE_GETPRID empty and this Makefile will figure it out.
|
||||
#
|
||||
HAVE_GETPRID=
|
||||
@@ -350,6 +378,8 @@ HAVE_GETPRID=
|
||||
# HAVE_URANDOM_H= YES assume that /dev/urandom exists
|
||||
# HAVE_URANDOM_H= NO assume that /dev/urandom does not exist
|
||||
#
|
||||
# Select HAVE_URANDOM_H= NO for DJGPP.
|
||||
#
|
||||
# When in doubt, leave HAVE_URANDOM_H empty.
|
||||
#
|
||||
HAVE_URANDOM_H=
|
||||
@@ -391,10 +421,12 @@ HAVE_STRDUP=
|
||||
# ALIGN32= -DMUST_ALIGN32 force 32 bit alignment
|
||||
# ALIGN32= -UMUST_ALIGN32 allow non-alignment of 32 bit accesses
|
||||
#
|
||||
# Select ALIGN32= -UMUST_ALIGN32 for DJGPP.
|
||||
#
|
||||
# When in doubt, be safe and pick ALIGN32=-DMUST_ALIGN32.
|
||||
#
|
||||
#ALIGN32=
|
||||
ALIGN32= -DMUST_ALIGN32
|
||||
ALIGN32=
|
||||
#ALIGN32= -DMUST_ALIGN32
|
||||
#ALIGN32= -UMUST_ALIGN32
|
||||
|
||||
# Determine if we have the <malloc.h> include file.
|
||||
@@ -403,6 +435,8 @@ ALIGN32= -DMUST_ALIGN32
|
||||
# HAVE_MALLOC_H= YES assume that the include file exists
|
||||
# HAVE_MALLOC_H= NO assume that the include file does not exist
|
||||
#
|
||||
# Select HAVE_MALLOC_H= YES for DJGPP.
|
||||
#
|
||||
# When in doubt, leave HAVE_MALLOC_H empty.
|
||||
#
|
||||
HAVE_MALLOC_H=
|
||||
@@ -415,6 +449,8 @@ HAVE_MALLOC_H=
|
||||
# HAVE_STDLIB_H= YES assume that the include file exists
|
||||
# HAVE_STDLIB_H= NO assume that the include file does not exist
|
||||
#
|
||||
# Select HAVE_STDLIB_H= YES for DJGPP.
|
||||
#
|
||||
# When in doubt, leave HAVE_STDLIB_H empty.
|
||||
#
|
||||
HAVE_STDLIB_H=
|
||||
@@ -427,6 +463,8 @@ HAVE_STDLIB_H=
|
||||
# HAVE_STRING_H= YES assume that the include file exists
|
||||
# HAVE_STRING_H= NO assume that the include file does not exist
|
||||
#
|
||||
# Select HAVE_STRING_H= YES for DJGPP.
|
||||
#
|
||||
# When in doubt, leave HAVE_STRING_H empty.
|
||||
#
|
||||
HAVE_STRING_H=
|
||||
@@ -439,6 +477,8 @@ HAVE_STRING_H=
|
||||
# HAVE_TIMES_H= YES assume that the include file exists
|
||||
# HAVE_TIMES_H= NO assume that the include file does not exist
|
||||
#
|
||||
# Select HAVE_TIMES_H= NO for DJGPP.
|
||||
#
|
||||
# When in doubt, leave HAVE_TIMES_H empty.
|
||||
#
|
||||
HAVE_TIMES_H=
|
||||
@@ -451,6 +491,8 @@ HAVE_TIMES_H=
|
||||
# HAVE_SYS_TIMES_H= YES assume that the include file exists
|
||||
# HAVE_SYS_TIMES_H= NO assume that the include file does not exist
|
||||
#
|
||||
# Select HAVE_SYS_TIMES_H= YES for DJGPP.
|
||||
#
|
||||
# When in doubt, leave HAVE_SYS_TIMES_H empty.
|
||||
#
|
||||
HAVE_SYS_TIMES_H=
|
||||
@@ -463,6 +505,8 @@ HAVE_SYS_TIMES_H=
|
||||
# HAVE_TIME_H= YES assume that the include file exists
|
||||
# HAVE_TIME_H= NO assume that the include file does not exist
|
||||
#
|
||||
# Select HAVE_TIME_H= YES for DJGPP.
|
||||
#
|
||||
# When in doubt, leave HAVE_TIME_H empty.
|
||||
#
|
||||
HAVE_TIME_H=
|
||||
@@ -475,6 +519,8 @@ HAVE_TIME_H=
|
||||
# HAVE_SYS_TIME_H= YES assume that the include file exists
|
||||
# HAVE_SYS_TIME_H= NO assume that the include file does not exist
|
||||
#
|
||||
# Select HAVE_SYS_TIME_H= YES for DJGPP.
|
||||
#
|
||||
# When in doubt, leave HAVE_SYS_TIME_H empty.
|
||||
#
|
||||
HAVE_SYS_TIME_H=
|
||||
@@ -487,6 +533,8 @@ HAVE_SYS_TIME_H=
|
||||
# HAVE_UNISTD_H= YES assume that the include file exists
|
||||
# HAVE_UNISTD_H= NO assume that the include file does not exist
|
||||
#
|
||||
# Select HAVE_UNISTD_H= YES for DJGPP.
|
||||
#
|
||||
# When in doubt, leave HAVE_UNISTD_H empty.
|
||||
#
|
||||
HAVE_UNISTD_H=
|
||||
@@ -502,6 +550,13 @@ HAVE_UNISTD_H=
|
||||
# ${INCDIR} where most .h files are kept
|
||||
# ${LIBDIR} where *.a files are installed
|
||||
#
|
||||
# For DJGPP, select:
|
||||
#
|
||||
# BINDIR= /dev/env/DJDIR/bin
|
||||
# SHAREDIR= /dev/env/DJDIR/share
|
||||
# INCDIR= /dev/env/DJDIR/include
|
||||
# LIBDIR= /dev/env/DJDIR/lib
|
||||
#
|
||||
# If in doubt, set:
|
||||
#
|
||||
# BINDIR= /usr/bin
|
||||
@@ -510,15 +565,19 @@ HAVE_UNISTD_H=
|
||||
# LIBDIR= /usr/lib
|
||||
#
|
||||
#BINDIR= /usr/local/bin
|
||||
#BINDIR= /dev/env/DJDIR/bin
|
||||
BINDIR= /usr/bin
|
||||
|
||||
#SHAREDIR= /usr/local/lib
|
||||
#SHAREDIR= /dev/env/DJDIR/share
|
||||
SHAREDIR= /usr/share
|
||||
|
||||
#INCDIR= /usr/local/include
|
||||
#INCDIR= /dev/env/DJDIR/include
|
||||
INCDIR= /usr/include
|
||||
|
||||
#LIBDIR= /usr/local/lib
|
||||
#LIBDIR= /dev/env/DJDIR/lib
|
||||
LIBDIR= /usr/lib
|
||||
|
||||
# By default, these values are based on the above 4 values
|
||||
@@ -571,17 +630,22 @@ T=
|
||||
|
||||
# where man pages are installed
|
||||
#
|
||||
# Select MANDIR= /dev/env/DJDIR/man/man1 for DJGPP.
|
||||
#
|
||||
# Use MANDIR= to disable installation of the calc man (source) page.
|
||||
#
|
||||
#MANDIR=
|
||||
#MANDIR= /usr/local/man/man1
|
||||
#MANDIR= /usr/man/man1
|
||||
MANDIR= /usr/share/man/man1
|
||||
#MANDIR= /dev/env/DJDIR/man/man1
|
||||
#MANDIR= /usr/man/u_man/man1
|
||||
#MANDIR= /usr/contrib/man/man1
|
||||
|
||||
# where cat (formatted man) pages are installed
|
||||
#
|
||||
# Select CATDIR= /dev/env/DJDIR/man/cat1 for DJGPP.
|
||||
#
|
||||
# Use CATDIR= to disable installation of the calc cat (formatted) page.
|
||||
#
|
||||
CATDIR=
|
||||
@@ -589,6 +653,7 @@ CATDIR=
|
||||
#CATDIR= /usr/local/catman/cat1
|
||||
#CATDIR= /usr/man/cat1
|
||||
#CATDIR= /usr/share/man/cat1
|
||||
#CATDIR= /dev/env/DJDIR/man/cat1
|
||||
#CATDIR= /var/cache/man/cat1
|
||||
#CATDIR= /usr/man/u_man/cat1
|
||||
#CATDIR= /usr/contrib/man/cat1
|
||||
@@ -626,6 +691,8 @@ CATEXT= 1
|
||||
#
|
||||
# The cat page is not built or installed
|
||||
#
|
||||
# Select NROFF= groff for DJGPP.
|
||||
#
|
||||
# If in doubt and you don't want to fool with man pages, set MANDIR
|
||||
# and CATDIR to empty and ignore the NROFF, NROFF_ARG and MANMAKE
|
||||
# lines below.
|
||||
@@ -643,12 +710,18 @@ CATMODE= 0444
|
||||
# If the $CALCPATH environment variable is not defined, then the following
|
||||
# path will be search for calc resource file routines.
|
||||
#
|
||||
# Select CALCPATH= .;./cal;~/.cal;${CSHAREDIR};${CUSTOMLIBDIR} for DJGPP.
|
||||
#
|
||||
CALCPATH= .:./cal:~/.cal:${CSHAREDIR}:${CUSTOMLIBDIR}
|
||||
#CALCPATH= .;./cal;~/.cal;${CSHAREDIR};${CUSTOMLIBDIR}
|
||||
|
||||
# If the $CALCRC environment variable is not defined, then the following
|
||||
# path will be search for calc resource files.
|
||||
#
|
||||
# Select CALCRC= ${CSHAREDIR}/startup;~/.calcrc;./.calcinit for DJGPP.
|
||||
#
|
||||
CALCRC= ${CSHAREDIR}/startup:~/.calcrc:./.calcinit
|
||||
#CALCRC= ${CSHAREDIR}/startup;~/.calcrc;./.calcinit
|
||||
|
||||
# Determine of the GNU-readline facility will be used instead of the
|
||||
# built-in calc binding method.
|
||||
@@ -683,13 +756,18 @@ READLINE_INCLUDE=
|
||||
|
||||
# If $PAGER is not set, use this program to display a help file
|
||||
#
|
||||
# Select CALCPAGER= less.exe -ci for DJGPP.
|
||||
#
|
||||
CALCPAGER= more
|
||||
#CALCPAGER= pg
|
||||
#CALCPAGER= cat
|
||||
#CALCPAGER= less
|
||||
#CALCPAGER= less.exe -ci
|
||||
|
||||
# Debug/Optimize options for ${CC} and ${LCC}
|
||||
#
|
||||
# Select DEBUG= -O2 -gstabs+ for DJGPP.
|
||||
#
|
||||
#DEBUG=
|
||||
#
|
||||
#DEBUG= -O
|
||||
@@ -718,6 +796,8 @@ DEBUG= -O2 -g
|
||||
#DEBUG= -g3
|
||||
#DEBUG= -gx
|
||||
#DEBUG= -WM,-g
|
||||
#
|
||||
#DEBUG= -O2 -gstabs+
|
||||
|
||||
# On systems that have dynamic shared link libs, you may want want to disable
|
||||
# them for faster calc startup.
|
||||
@@ -759,7 +839,7 @@ RANLIB=ranlib
|
||||
# Normally certain files depend on the Makefile. If the Makefile is
|
||||
# changed, then certain steps should be redone. If MAKE_FILE is
|
||||
# set to Makefile, then these files will depend on Makefile. If
|
||||
# MAKE_FILE is empty, they they wont.
|
||||
# MAKE_FILE is empty, then they wont.
|
||||
#
|
||||
# If in doubt, set MAKE_FILE to Makefile
|
||||
#
|
||||
@@ -1048,8 +1128,13 @@ XARGS= xargs
|
||||
CMP= cmp
|
||||
# assume the X11 makedepend tool for the depend rule
|
||||
MAKEDEPEND= makedepend
|
||||
|
||||
# echo command location
|
||||
#
|
||||
# Select ECHO= echo for DJGPP.
|
||||
#
|
||||
ECHO= /bin/echo
|
||||
#ECHO= echo
|
||||
|
||||
# Makefile debug
|
||||
#
|
||||
@@ -1475,13 +1560,13 @@ endian_calc.h: endian ${MAKE_FILE}
|
||||
${Q}echo '' >> endian_calc.h
|
||||
${Q}echo '/* what byte order are we? */' >> endian_calc.h
|
||||
-${Q}if [ X"${BYTE_ORDER}" = X ]; then \
|
||||
if [ -f /usr/include/endian.h ]; then \
|
||||
if [ -f ${INCDIR}/endian.h ]; then \
|
||||
echo '#include <endian.h>' >> endian_calc.h; \
|
||||
echo '#define CALC_BYTE_ORDER BYTE_ORDER' >> endian_calc.h; \
|
||||
elif [ -f /usr/include/machine/endian.h ]; then \
|
||||
elif [ -f ${INCDIR}/machine/endian.h ]; then \
|
||||
echo '#include <machine/endian.h>' >> endian_calc.h; \
|
||||
echo '#define CALC_BYTE_ORDER BYTE_ORDER' >> endian_calc.h; \
|
||||
elif [ -f /usr/include/sys/endian.h ]; then \
|
||||
elif [ -f ${INCDIR}/sys/endian.h ]; then \
|
||||
echo '#include <sys/endian.h>' >> endian_calc.h; \
|
||||
echo '#define CALC_BYTE_ORDER BYTE_ORDER' >> endian_calc.h; \
|
||||
else \
|
||||
@@ -1543,12 +1628,12 @@ have_malloc.h: ${MAKE_FILE}
|
||||
${Q}echo '#define __HAVE_MALLOC_H__' >> have_malloc.h
|
||||
${Q}echo '' >> have_malloc.h
|
||||
${Q}echo '' >> have_malloc.h
|
||||
${Q}echo '/* do we have /usr/include/malloc.h? */' >> have_malloc.h
|
||||
${Q}echo '/* do we have ${INCDIR}/malloc.h? */' >> have_malloc.h
|
||||
-${Q}if [ X"${HAVE_MALLOC_H}" = X"YES" ]; then \
|
||||
echo '#define HAVE_MALLOC_H /* yes */' >> have_malloc.h; \
|
||||
elif [ X"${HAVE_MALLOC_H}" = X"NO" ]; then \
|
||||
echo '#undef HAVE_MALLOC_H /* no */' >> have_malloc.h; \
|
||||
elif [ -f /usr/include/malloc.h ]; then \
|
||||
elif [ -f ${INCDIR}/malloc.h ]; then \
|
||||
echo '#define HAVE_MALLOC_H /* yes */' >> have_malloc.h; \
|
||||
else \
|
||||
echo '#undef HAVE_MALLOC_H /* no */' >> have_malloc.h; \
|
||||
@@ -1579,12 +1664,12 @@ have_times.h: ${MAKE_FILE}
|
||||
${Q}echo '#define __HAVE_TIMES_H__' >> have_times.h
|
||||
${Q}echo '' >> have_times.h
|
||||
${Q}echo '' >> have_times.h
|
||||
${Q}echo '/* do we have /usr/include/times.h? */' >> have_times.h
|
||||
${Q}echo '/* do we have ${INCDIR}/times.h? */' >> have_times.h
|
||||
-${Q}if [ X"${HAVE_TIMES_H}" = X"YES" ]; then \
|
||||
echo '#define HAVE_TIMES_H /* yes */' >> have_times.h; \
|
||||
elif [ X"${HAVE_TIMES_H}" = X"NO" ]; then \
|
||||
echo '#undef HAVE_TIMES_H /* no */' >> have_times.h; \
|
||||
elif [ -f /usr/include/times.h ]; then \
|
||||
elif [ -f ${INCDIR}/times.h ]; then \
|
||||
echo '#define HAVE_TIMES_H /* yes */' >> have_times.h; \
|
||||
else \
|
||||
echo '#undef HAVE_TIMES_H /* no */' >> have_times.h; \
|
||||
@@ -1593,7 +1678,7 @@ have_times.h: ${MAKE_FILE}
|
||||
echo '#define HAVE_SYS_TIMES_H /* yes */' >> have_times.h; \
|
||||
elif [ X"${HAVE_SYS_TIMES_H}" = X"NO" ]; then \
|
||||
echo '#undef HAVE_SYS_TIMES_H /* no */' >> have_times.h; \
|
||||
elif [ -f /usr/include/sys/times.h ]; then \
|
||||
elif [ -f ${INCDIR}/sys/times.h ]; then \
|
||||
echo '#define HAVE_SYS_TIMES_H /* yes */' >> have_times.h; \
|
||||
else \
|
||||
echo '#undef HAVE_SYS_TIMES_H /* no */' >> have_times.h; \
|
||||
@@ -1602,7 +1687,7 @@ have_times.h: ${MAKE_FILE}
|
||||
echo '#define HAVE_TIME_H /* yes */' >> have_times.h; \
|
||||
elif [ X"${HAVE_TIME_H}" = X"NO" ]; then \
|
||||
echo '#undef HAVE_TIME_H /* no */' >> have_times.h; \
|
||||
elif [ -f /usr/include/time.h ]; then \
|
||||
elif [ -f ${INCDIR}/time.h ]; then \
|
||||
echo '#define HAVE_TIME_H /* yes */' >> have_times.h; \
|
||||
else \
|
||||
echo '#undef HAVE_TIME_H /* no */' >> have_times.h; \
|
||||
@@ -1611,7 +1696,7 @@ have_times.h: ${MAKE_FILE}
|
||||
echo '#define HAVE_SYS_TIME_H /* yes */' >> have_times.h; \
|
||||
elif [ X"${HAVE_SYS_TIME_H}" = X"NO" ]; then \
|
||||
echo '#undef HAVE_SYS_TIME_H /* no */' >> have_times.h; \
|
||||
elif [ -f /usr/include/sys/time.h ]; then \
|
||||
elif [ -f ${INCDIR}/sys/time.h ]; then \
|
||||
echo '#define HAVE_SYS_TIME_H /* yes */' >> have_times.h; \
|
||||
else \
|
||||
echo '#undef HAVE_SYS_TIME_H /* no */' >> have_times.h; \
|
||||
@@ -1642,12 +1727,12 @@ have_stdlib.h: ${MAKE_FILE}
|
||||
${Q}echo '#define __HAVE_STDLIB_H__' >> have_stdlib.h
|
||||
${Q}echo '' >> have_stdlib.h
|
||||
${Q}echo '' >> have_stdlib.h
|
||||
${Q}echo '/* do we have /usr/include/stdlib.h? */' >> have_stdlib.h
|
||||
${Q}echo '/* do we have ${INCDIR}/stdlib.h? */' >> have_stdlib.h
|
||||
-${Q}if [ X"${HAVE_STDLIB_H}" = X"YES" ]; then \
|
||||
echo '#define HAVE_STDLIB_H /* yes */' >> have_stdlib.h; \
|
||||
elif [ X"${HAVE_STDLIB_H}" = X"NO" ]; then \
|
||||
echo '#undef HAVE_STDLIB_H /* no */' >> have_stdlib.h; \
|
||||
elif [ -f /usr/include/stdlib.h ]; then \
|
||||
elif [ -f ${INCDIR}/stdlib.h ]; then \
|
||||
echo '#define HAVE_STDLIB_H /* yes */' >> have_stdlib.h; \
|
||||
else \
|
||||
echo '#undef HAVE_STDLIB_H /* no */' >> have_stdlib.h; \
|
||||
@@ -1678,12 +1763,12 @@ have_unistd.h: ${MAKE_FILE}
|
||||
${Q}echo '#define __HAVE_UNISTD_H__' >> have_unistd.h
|
||||
${Q}echo '' >> have_unistd.h
|
||||
${Q}echo '' >> have_unistd.h
|
||||
${Q}echo '/* do we have /usr/include/unistd.h? */' >> have_unistd.h
|
||||
${Q}echo '/* do we have ${INCDIR}/unistd.h? */' >> have_unistd.h
|
||||
-${Q}if [ X"${HAVE_UNISTD_H}" = X"YES" ]; then \
|
||||
echo '#define HAVE_UNISTD_H /* yes */' >> have_unistd.h; \
|
||||
elif [ X"${HAVE_UNISTD_H}" = X"NO" ]; then \
|
||||
echo '#undef HAVE_UNISTD_H /* no */' >> have_unistd.h; \
|
||||
elif [ -f /usr/include/unistd.h ]; then \
|
||||
elif [ -f ${INCDIR}/unistd.h ]; then \
|
||||
echo '#define HAVE_UNISTD_H /* yes */' >> have_unistd.h; \
|
||||
else \
|
||||
echo '#undef HAVE_UNISTD_H /* no */' >> have_unistd.h; \
|
||||
@@ -1714,12 +1799,12 @@ have_string.h: ${MAKE_FILE}
|
||||
${Q}echo '#define __HAVE_STRING_H__' >> have_string.h
|
||||
${Q}echo '' >> have_string.h
|
||||
${Q}echo '' >> have_string.h
|
||||
${Q}echo '/* do we have /usr/include/string.h? */' >> have_string.h
|
||||
${Q}echo '/* do we have ${INCDIR}/string.h? */' >> have_string.h
|
||||
-${Q}if [ X"${HAVE_STRING_H}" = X"YES" ]; then \
|
||||
echo '#define HAVE_STRING_H /* yes */' >> have_string.h; \
|
||||
elif [ X"${HAVE_STRING_H}" = X"NO" ]; then \
|
||||
echo '#undef HAVE_STRING_H /* no */' >> have_string.h; \
|
||||
elif [ -f /usr/include/string.h ]; then \
|
||||
elif [ -f ${INCDIR}/string.h ]; then \
|
||||
echo '#define HAVE_STRING_H /* yes */' >> have_string.h; \
|
||||
else \
|
||||
echo '#undef HAVE_STRING_H /* no */' >> have_string.h; \
|
||||
@@ -1759,12 +1844,12 @@ terminal.h: ${MAKE_FILE}
|
||||
echo '#undef USE_TERMIOS /* <termios.h> */' >> terminal.h; \
|
||||
echo '#undef USE_TERMIO /* <termio.h> */' >> terminal.h; \
|
||||
echo '#undef USE_SGTTY /* <sys/ioctl.h> */' >> terminal.h; \
|
||||
elif [ -f /usr/include/termios.h ]; then \
|
||||
elif [ -f ${INCDIR}/termios.h ]; then \
|
||||
echo '/* use termios */' >> terminal.h; \
|
||||
echo '#define USE_TERMIOS /* <termios.h> */' >> terminal.h; \
|
||||
echo '#undef USE_TERMIO /* <termio.h> */' >> terminal.h; \
|
||||
echo '#undef USE_SGTTY /* <sys/ioctl.h> */' >> terminal.h; \
|
||||
elif [ -f /usr/include/termio.h ]; then \
|
||||
elif [ -f ${INCDIR}/termio.h ]; then \
|
||||
echo '/* use termio */' >> terminal.h; \
|
||||
echo '#undef USE_TERMIOS /* <termios.h> */' >> terminal.h; \
|
||||
echo '#define USE_TERMIO /* <termio.h> */' >> terminal.h; \
|
||||
@@ -2815,13 +2900,15 @@ bsdi: ${LIB_H_SRC} ${BUILD_H_SRC} calc.1
|
||||
else \
|
||||
true; \
|
||||
fi
|
||||
-${Q}for i in ${LIB_H_SRC} ${BUILD_H_SRC}; do \
|
||||
-${Q}for i in ${LIB_H_SRC} ${BUILD_H_SRC} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo rm -f gen_h/$$i; \
|
||||
rm -f gen_h/$$i; \
|
||||
echo cp $$i gen_h; \
|
||||
cp $$i gen_h; \
|
||||
echo ${CHMOD} 0444 gen_h/$$i; \
|
||||
${CHMOD} 0444 gen_h/$$i; \
|
||||
fi; \
|
||||
done
|
||||
cd help; ${MAKE} -f Makefile ${HELP_PASSDOWN} bsdi
|
||||
${V} echo '=-=-=-=-= end of $@ rule =-=-=-=-='
|
||||
@@ -2858,13 +2945,15 @@ depend: hsrc
|
||||
${SED} -n '/^#[ ]*include[ ]*"/p' "$$i" > "skel/$$i"; \
|
||||
done
|
||||
${Q}mkdir skel/custom
|
||||
-${Q}for i in ${H_SRC} ${BUILD_H_SRC} custom.h; do \
|
||||
-${Q}for i in ${H_SRC} ${BUILD_H_SRC} custom.h /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
tag="`echo $$i | ${SED} 's/[\.+,:]/_/g'`"; \
|
||||
echo "#if !defined($$tag)" > "skel/$$i"; \
|
||||
echo "#define $$tag" >> "skel/$$i"; \
|
||||
${SED} -n '/^#[ ]*include[ ]*"/p' "$$i" | \
|
||||
LANG=C ${SORT} -u >> "skel/$$i"; \
|
||||
echo '#endif /* '"$$tag"' */' >> "skel/$$i"; \
|
||||
fi; \
|
||||
done
|
||||
-${Q}rm -f skel/makedep.out
|
||||
${Q}echo skel formed
|
||||
@@ -2873,8 +2962,10 @@ depend: hsrc
|
||||
skel/makedep.out
|
||||
${Q}cd skel; \
|
||||
${MAKEDEPEND} -w 1 -f makedep.out ${C_SRC} ${BUILD_C_SRC}
|
||||
-${Q}for i in ${C_SRC} ${BUILD_C_SRC}; do \
|
||||
-${Q}for i in ${C_SRC} ${BUILD_C_SRC} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo "$$i" | ${SED} 's/^\(.*\)\.c/\1.o: \1.c/'; \
|
||||
fi; \
|
||||
done >> skel/makedep.out
|
||||
${Q}echo dependency list formed
|
||||
${Q}echo forming new Makefile
|
||||
@@ -2894,8 +2985,10 @@ depend: hsrc
|
||||
# generate the list of h files for lower level depend use
|
||||
#
|
||||
h_list:
|
||||
-${Q}for i in ${H_SRC} ${BUILD_H_SRC}; do \
|
||||
-${Q}for i in ${H_SRC} ${BUILD_H_SRC} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo $$i; \
|
||||
fi; \
|
||||
done
|
||||
|
||||
# print the calc version
|
||||
@@ -2914,11 +3007,15 @@ ver_calc: version.c
|
||||
##
|
||||
|
||||
distlist: ${DISTLIST}
|
||||
${Q}(for i in ${DISTLIST}; do \
|
||||
${Q}(for i in ${DISTLIST} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo $$i; \
|
||||
fi; \
|
||||
done; \
|
||||
for i in ${BUILD_H_SRC} ${BUILD_C_SRC}; do \
|
||||
for i in ${BUILD_H_SRC} ${BUILD_C_SRC} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo win32/$$i; \
|
||||
fi; \
|
||||
done; \
|
||||
(cd help; ${MAKE} ${HELP_PASSDOWN} $@); \
|
||||
(cd cal; ${MAKE} ${CAL_PASSDOWN} $@); \
|
||||
@@ -2936,8 +3033,10 @@ distdir:
|
||||
(cd sample; ${MAKE} ${SAMPLE_PASSDOWN} $@)) | LANG=C ${SORT}
|
||||
|
||||
calcliblist:
|
||||
${Q}(for i in ${CALCLIBLIST}; do \
|
||||
${Q}(for i in ${CALCLIBLIST} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo $$i; \
|
||||
fi; \
|
||||
done; \
|
||||
(cd help; ${MAKE} ${HELP_PASSDOWN} $@); \
|
||||
(cd cal; ${MAKE} ${CAL_PASSDOWN} $@); \
|
||||
@@ -3211,8 +3310,10 @@ inst_files: ${MAKE_FILE} help/Makefile cal/Makefile custom/Makefile \
|
||||
${MAKE} -f Makefile ${CSCRIPT_PASSDOWN} echo_inst_files | \
|
||||
${GREP} '__file__..' | ${SED} -e s'/.*__file__ //' >> ../inst_files
|
||||
${Q}echo ${LIBDIR}/libcalc.a >> inst_files
|
||||
${Q}for i in ${LIB_H_SRC} ${BUILD_H_SRC}; do \
|
||||
echo ${INCDIRCALC}/$$i; \
|
||||
${Q}for i in ${LIB_H_SRC} ${BUILD_H_SRC} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo ${INCDIRCALC}/$$i; \
|
||||
fi; \
|
||||
done >> inst_files
|
||||
${Q}if [ ! -z "${MANDIR}" ]; then \
|
||||
echo ${MANDIR}/calc.${MANEXT}; \
|
||||
@@ -3564,7 +3665,10 @@ install: calc libcalc.a ${LIB_H_SRC} ${BUILD_H_SRC} calc.1
|
||||
${CHMOD} 0444 $T${LIBDIR}/libcalc.a; \
|
||||
echo "installed $T${LIBDIR}/libcalc.a"; \
|
||||
fi
|
||||
-${Q}for i in ${LIB_H_SRC} ${BUILD_H_SRC}; do \
|
||||
-${Q}for i in ${LIB_H_SRC} ${BUILD_H_SRC} /dev/null; do \
|
||||
if [ "$$i" = "/dev/null" ]; then \
|
||||
continue; \
|
||||
fi; \
|
||||
rm -f tmp; \
|
||||
${SED} -e 's/^\(#[ ]*include[ ][ ]*\)"/\1"calc\//' $$i > tmp; \
|
||||
if ${CMP} -s tmp $T${INCDIRCALC}/$$i; then \
|
||||
|
@@ -3,15 +3,6 @@ Dear calc user on a Windoz based system,
|
||||
See the HOWTO.INSTALL file for information on how to build and install calc.
|
||||
See also the README file.
|
||||
|
||||
NOTE: The Windoz port is extremely experimental, untested and perhaps
|
||||
incomplete. We are in the process of making it easier. The
|
||||
following should help anyone who is trying to make a go of this
|
||||
under the current code conditions.
|
||||
|
||||
NOTE: We are currently ONLY making an effort to support building under
|
||||
Windoz using the Cygwin project (http://sources.redhat.com/cygwin/)
|
||||
with the GCC compiler and Un*x tools for Windows.
|
||||
|
||||
NOTE: The main developers do not have access to a Windoz based platform.
|
||||
While we will make an effort to not break calc Windoz based system,
|
||||
our lack of a Windoz test environment will mean we will make mistakes
|
||||
@@ -19,7 +10,9 @@ NOTE: The main developers do not have access to a Windoz based platform.
|
||||
Of course you are welcome to send us any patches that fix your
|
||||
Windoz build environment.
|
||||
|
||||
=-=
|
||||
=-=-=-=-=
|
||||
=-=-=-=-=
|
||||
=-=-=-=-=
|
||||
|
||||
An effort is being made to allow windows users to compile calc using the
|
||||
Cygwin project (http://sources.redhat.com/cygwin/) with the GCC compiler
|
||||
@@ -61,8 +54,6 @@ needs. Just copy the win32/*.[ch] files up into the top level calc
|
||||
source directory, edited (if needed) and build using the Cygwin GCC
|
||||
compiler.
|
||||
|
||||
=-=
|
||||
|
||||
People who maintain calc need to keep in mind the following:
|
||||
|
||||
The following was added to opcodes.h, config.h, zmath.h and value.h:
|
||||
@@ -88,8 +79,71 @@ was changed to:
|
||||
|
||||
DLL extern int configtype(char*);
|
||||
|
||||
=-=-=-=-=
|
||||
=-=-=-=-=
|
||||
=-=-=-=-=
|
||||
|
||||
## Copyright (C) 2001 Landon Curt Noll and Thomas Jones-Low
|
||||
There is a different approach to the Cygwin approach above
|
||||
----------------------------------------------------------
|
||||
|
||||
You might want to try using the DJGPP system to compile calc. See:
|
||||
|
||||
http://www.delorie.com/djgpp/
|
||||
|
||||
for DJGPP details and availability.
|
||||
|
||||
To compile with DJGPP, one needs to select a number of Makefile
|
||||
variable changes. Eli Zaretskii <eliz at is dot elta dot co dot il>
|
||||
recommends the following settings:
|
||||
|
||||
TERMCONTROL= -DUSE_TERMIOS
|
||||
BYTE_ORDER= -DLITTLE_ENDIAN
|
||||
LONG_BITS= 32
|
||||
LONGLONG_BITS= 64
|
||||
HAVE_FPOS_POS= -DHAVE_NO_FPOS_POS
|
||||
FPOS_BITS= 32
|
||||
OFF_T_BITS= 32
|
||||
DEV_BITS= 32
|
||||
INODE_BITS= 32
|
||||
HAVE_USTAT= -DHAVE_NO_USTAT
|
||||
HAVE_GETSID= -DHAVE_NO_GETSID
|
||||
HAVE_GETPGID= -DHAVE_NO_GETPGID
|
||||
HAVE_GETTIME= -DHAVE_NO_GETTIME
|
||||
HAVE_GETPRID= -DHAVE_NO_GETPRID
|
||||
HAVE_URANDOM_H= NO
|
||||
ALIGN32= -UMUST_ALIGN32
|
||||
HAVE_MALLOC_H= YES
|
||||
HAVE_STDLIB_H= YES
|
||||
HAVE_STRING_H= YES
|
||||
HAVE_TIMES_H= NO
|
||||
HAVE_SYS_TIMES_H= YES
|
||||
HAVE_TIME_H= YES
|
||||
HAVE_SYS_TIME_H= YES
|
||||
HAVE_UNISTD_H= YES
|
||||
BINDIR= /dev/env/DJDIR/bin
|
||||
SHAREDIR= /dev/env/DJDIR/share
|
||||
INCDIR= /dev/env/DJDIR/include
|
||||
LIBDIR= /dev/env/DJDIR/lib
|
||||
MANDIR= /dev/env/DJDIR/man/man1
|
||||
CATDIR= /dev/env/DJDIR/man/cat1
|
||||
NROFF= groff
|
||||
CALCPATH= .;./cal;~/.cal;${CSHAREDIR};${CUSTOMLIBDIR}
|
||||
CALCRC= ${CSHAREDIR}/startup;~/.calcrc;./.calcinit
|
||||
CALCPAGER= less.exe -ci
|
||||
DEBUG= -O2 -gstabs+
|
||||
|
||||
The 'Linux set' or 'gcc set' (see the Select your compiler type section)
|
||||
should work for DJGPP systems if you set the above Makefile variables.
|
||||
|
||||
Look for Makefile comments of the form:
|
||||
|
||||
# Select ...something... for DJGPP.
|
||||
|
||||
Follow those recommendations. In cases where they conflict with
|
||||
the above Makefile list, follow the recommendation in the Makefile.
|
||||
|
||||
|
||||
## Copyright (C) 2002 Landon Curt Noll and Thomas Jones-Low
|
||||
##
|
||||
## Calc is open software; you can redistribute it and/or modify it under
|
||||
## the terms of the version 2.1 of the GNU Lesser General Public License
|
||||
@@ -105,8 +159,8 @@ was changed to:
|
||||
## received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
## 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
##
|
||||
## @(#) $Revision: 29.6 $
|
||||
## @(#) $Id: README.WINDOWS,v 29.6 2001/04/08 22:13:38 chongo Exp $
|
||||
## @(#) $Revision: 29.7 $
|
||||
## @(#) $Id: README.WINDOWS,v 29.7 2002/03/12 10:50:25 chongo Exp $
|
||||
## @(#) $Source: /usr/local/src/cmd/calc/RCS/README.WINDOWS,v $
|
||||
##
|
||||
## Under source code control: 2001/02/25 14:00:05
|
||||
|
19
cal/Makefile
19
cal/Makefile
@@ -18,8 +18,8 @@
|
||||
# received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
# 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
#
|
||||
# @(#) $Revision: 29.12 $
|
||||
# @(#) $Id: Makefile,v 29.12 2001/06/08 22:38:53 chongo Exp $
|
||||
# @(#) $Revision: 29.13 $
|
||||
# @(#) $Id: Makefile,v 29.13 2002/03/12 08:32:35 chongo Exp $
|
||||
# @(#) $Source: /usr/local/src/cmd/calc/cal/RCS/Makefile,v $
|
||||
#
|
||||
# Under source code control: 1991/07/21 05:00:54
|
||||
@@ -120,8 +120,10 @@ all: ${CALC_FILES} ${MAKE_FILE} .all
|
||||
##
|
||||
|
||||
distlist: ${DISTLIST}
|
||||
${Q}for i in ${DISTLIST}; do \
|
||||
${Q}for i in ${DISTLIST} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo cal/$$i; \
|
||||
fi; \
|
||||
done
|
||||
|
||||
distdir:
|
||||
@@ -141,8 +143,10 @@ calcliblist:
|
||||
##
|
||||
|
||||
echo_inst_files:
|
||||
${Q}for i in ${CALC_FILES}; do \
|
||||
echo __file__ ${CSHAREDIR}/$$i; \
|
||||
${Q}for i in ${CALC_FILES} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo __file__ ${CSHAREDIR}/$$i; \
|
||||
fi; \
|
||||
done
|
||||
|
||||
##
|
||||
@@ -181,7 +185,10 @@ install: all
|
||||
else \
|
||||
true; \
|
||||
fi
|
||||
${Q}for i in ${CALC_FILES}; do \
|
||||
${Q}for i in ${CALC_FILES} /dev/null; do \
|
||||
if [ "$$i" = "/dev/null" ]; then \
|
||||
continue; \
|
||||
fi; \
|
||||
if ${CMP} -s $$i $T${CSHAREDIR}/$$i; then \
|
||||
true; \
|
||||
else \
|
||||
|
8
calc.h
8
calc.h
@@ -17,8 +17,8 @@
|
||||
* received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
* 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
* @(#) $Revision: 29.9 $
|
||||
* @(#) $Id: calc.h,v 29.9 2001/12/11 02:28:47 chongo Exp $
|
||||
* @(#) $Revision: 29.10 $
|
||||
* @(#) $Id: calc.h,v 29.10 2002/03/12 09:40:57 chongo Exp $
|
||||
* @(#) $Source: /usr/local/src/cmd/calc/RCS/calc.h,v $
|
||||
*
|
||||
* Under source code control: 1990/02/15 01:48:31
|
||||
@@ -60,7 +60,11 @@
|
||||
#define HOMECHAR '~' /* char which indicates home directory */
|
||||
#define DOTCHAR '.' /* char which indicates current directory */
|
||||
#define PATHCHAR '/' /* char which separates path components */
|
||||
#if defined(__MSDOS__) || defined(__WIN32)
|
||||
#define LISTCHAR ';' /* char which separates paths in a list */
|
||||
#else
|
||||
#define LISTCHAR ':' /* char which separates paths in a list */
|
||||
#endif
|
||||
#define MAXCMD 16384 /* maximum length of command invocation */
|
||||
#define MAXERROR 512 /* maximum length of error message string */
|
||||
|
||||
|
18
calc.man
18
calc.man
@@ -15,8 +15,8 @@
|
||||
.\" received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
.\" 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
.\"
|
||||
.\" @(#) $Revision: 29.7 $
|
||||
.\" @(#) $Id: calc.man,v 29.7 2001/06/01 11:26:53 chongo Exp $
|
||||
.\" @(#) $Revision: 29.8 $
|
||||
.\" @(#) $Id: calc.man,v 29.8 2002/03/12 09:02:58 chongo Exp $
|
||||
.\" @(#) $Source: /usr/local/src/cmd/calc/RCS/calc.man,v $
|
||||
.\"
|
||||
.\" Under source code control: 1991/07/23 05:48:26
|
||||
@@ -54,7 +54,7 @@ calc \- arbitrary precision calculator
|
||||
.RB [ calc_cmd\ \&.\|.\|. ]
|
||||
.in -5n
|
||||
.sp
|
||||
\fI#!${BINDIR}/calc\fP\ \fB\-S\fP\ [other_flags\ \&...]
|
||||
\fI#!${BINDIR}/calc\fP\ \fB\-f\fP\ [other_flags\ \&...]
|
||||
.SH DESCRIPTION
|
||||
\&
|
||||
.br
|
||||
@@ -572,27 +572,25 @@ If first line of an executable file begins
|
||||
followed by the absolute pathname of the
|
||||
.B calc
|
||||
program and the flag
|
||||
.B \-S
|
||||
.B \-f
|
||||
as in:
|
||||
.sp 1
|
||||
.in +5n
|
||||
.nf
|
||||
\fI#!${BINDIR}/calc\fP\ \fB\-S\fP\ [other_flags\ \&...]
|
||||
\fI#!${BINDIR}/calc\fP\ \fB\-f\fP\ [other_flags\ \&...]
|
||||
.fi
|
||||
.in -5n
|
||||
.sp 1
|
||||
the rest of the file will be processed in
|
||||
.BR "shell script mode" .
|
||||
Note that
|
||||
.B \-S
|
||||
(UPPER CASE
|
||||
.BR \-S )
|
||||
.B \-f
|
||||
must be the first \-flag on the ``#!'' line.
|
||||
Any other optional
|
||||
.B "other_flags"
|
||||
must come after
|
||||
the
|
||||
.BR \-S .
|
||||
.BR \-f .
|
||||
.sp 1
|
||||
In
|
||||
.B "shell script mode"
|
||||
@@ -625,7 +623,7 @@ the file
|
||||
.sp 1
|
||||
.in +5n
|
||||
.nf
|
||||
\fI#!${BINDIR}/calc\fP\ \fB\-S\fP\ \&\fB\-q\fP
|
||||
\fI#!${BINDIR}/calc\fP\ \fB\-f\fP\ \&\fB\-q\fP
|
||||
#
|
||||
# mersenne - an example of a calc \fBshell script file\fP
|
||||
|
||||
|
9
cmath.h
9
cmath.h
@@ -17,8 +17,8 @@
|
||||
* received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
* 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
* @(#) $Revision: 29.5 $
|
||||
* @(#) $Id: cmath.h,v 29.5 2001/06/08 21:00:58 chongo Exp $
|
||||
* @(#) $Revision: 29.6 $
|
||||
* @(#) $Id: cmath.h,v 29.6 2002/03/12 09:38:26 chongo Exp $
|
||||
* @(#) $Source: /usr/local/src/cmd/calc/RCS/cmath.h,v $
|
||||
*
|
||||
* Under source code control: 1993/07/30 19:42:45
|
||||
@@ -62,6 +62,7 @@ extern void cprintfr(COMPLEX *c);
|
||||
/*
|
||||
* Basic numeric routines.
|
||||
*/
|
||||
|
||||
extern COMPLEX *cadd(COMPLEX *c1, COMPLEX *c2);
|
||||
extern COMPLEX *csub(COMPLEX *c1, COMPLEX *c2);
|
||||
extern COMPLEX *cmul(COMPLEX *c1, COMPLEX *c2);
|
||||
@@ -74,8 +75,8 @@ extern COMPLEX *cscale(COMPLEX *c, long i);
|
||||
extern COMPLEX *cshift(COMPLEX *c, long i);
|
||||
extern COMPLEX *csquare(COMPLEX *c);
|
||||
extern COMPLEX *cconj(COMPLEX *c);
|
||||
extern COMPLEX *creal(COMPLEX *c);
|
||||
extern COMPLEX *cimag(COMPLEX *c);
|
||||
extern COMPLEX *c_real(COMPLEX *c);
|
||||
extern COMPLEX *c_imag(COMPLEX *c);
|
||||
extern COMPLEX *cneg(COMPLEX *c);
|
||||
extern COMPLEX *cinv(COMPLEX *c);
|
||||
extern COMPLEX *cint(COMPLEX *c);
|
||||
|
@@ -17,8 +17,8 @@
|
||||
* received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
* 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
* @(#) $Revision: 29.2 $
|
||||
* @(#) $Id: commath.c,v 29.2 2000/06/07 14:02:13 chongo Exp $
|
||||
* @(#) $Revision: 29.3 $
|
||||
* @(#) $Id: commath.c,v 29.3 2002/03/12 09:38:26 chongo Exp $
|
||||
* @(#) $Source: /usr/local/src/cmd/calc/RCS/commath.c,v $
|
||||
*
|
||||
* Under source code control: 1990/02/15 01:48:10
|
||||
@@ -381,7 +381,7 @@ cconj(COMPLEX *c)
|
||||
* Return the real part of a complex number.
|
||||
*/
|
||||
COMPLEX *
|
||||
creal(COMPLEX *c)
|
||||
c_real(COMPLEX *c)
|
||||
{
|
||||
COMPLEX *r;
|
||||
|
||||
@@ -400,7 +400,7 @@ creal(COMPLEX *c)
|
||||
* Return the imaginary part of a complex number as a real.
|
||||
*/
|
||||
COMPLEX *
|
||||
cimag(COMPLEX *c)
|
||||
c_imag(COMPLEX *c)
|
||||
{
|
||||
COMPLEX *r;
|
||||
|
||||
|
@@ -17,9 +17,9 @@
|
||||
# received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
# 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
#
|
||||
# @(#) $Revision: 29.20 $
|
||||
# @(#) $Id: Makefile,v 29.20 2001/06/10 19:35:02 chongo Exp $
|
||||
# @(#) $Source: /usr/local/src/cmd/calc/cscript/RCS/Makefile,v $
|
||||
# @(#) $Revision: 29.21 $
|
||||
# @(#) $Id: Makefile,v 29.21 2002/03/12 08:36:11 chongo Exp $
|
||||
# @(#) $Source: /usr/local/src/cmd/calc/cal/../cscript/RCS/Makefile,v $
|
||||
#
|
||||
# Under source code control: 1999/11/29 11:10:26
|
||||
# File existed as early as: 1999
|
||||
@@ -139,8 +139,10 @@ all: ${TARGETS} .all
|
||||
##
|
||||
|
||||
distlist: ${DISTLIST}
|
||||
${Q}for i in ${DISTLIST}; do \
|
||||
${Q}for i in ${DISTLIST} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo cscript/$$i; \
|
||||
fi; \
|
||||
done | LANG=C ${SORT}
|
||||
|
||||
distdir:
|
||||
@@ -152,23 +154,27 @@ calcliblist:
|
||||
#
|
||||
detaillist:
|
||||
${Q}-(echo "xxxxxxx"; \
|
||||
for i in ${SCRIPT}; do \
|
||||
for i in ${SCRIPT} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
if [ ! -f RCS/$$i.calc,v ]; then \
|
||||
echo "WARNING: $$i.calc not under RCS control" 1>&2; \
|
||||
else \
|
||||
echo $$i; \
|
||||
fi; \
|
||||
fi; \
|
||||
done | LANG=C ${SORT}) | ${FMT} -70 | \
|
||||
${SED} -e '1s/xxxxxxx/SCRIPT=/' -e '2,$$s/^/ /' \
|
||||
-e 's/$$/ \\/' -e '$$s/ \\$$//'
|
||||
${Q}echo
|
||||
${Q}-(echo "xxxxxxxxxxx"; \
|
||||
for i in ${SCRIPT}; do \
|
||||
for i in ${SCRIPT} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
if [ ! -f RCS/$$i.calc,v ]; then \
|
||||
echo "WARNING: $$i.calc not under RCS control" 1>&2; \
|
||||
else \
|
||||
echo $$i.calc; \
|
||||
fi; \
|
||||
fi; \
|
||||
done | LANG=C ${SORT}) | ${FMT} -70 | \
|
||||
${SED} -e '1s/xxxxxxxxxxx/SCRIPT_SRC=/' -e '2,$$s/^/ /' \
|
||||
-e 's/$$/ \\/' -e '$$s/ \\$$//'
|
||||
@@ -197,11 +203,13 @@ depend:
|
||||
${Q}echo "# DO NOT DELETE THIS LINE -- make depend depends on it." > \
|
||||
makedep.out
|
||||
${Q}echo "" >> makedep.out
|
||||
${Q}for i in ${SCRIPT}; do \
|
||||
${Q}for i in ${SCRIPT} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo "$$i: $$i.calc"; \
|
||||
echo ' rm -f $$@'; \
|
||||
echo ' $${SED} -e "1s:^#!/usr/local/src/cmd/calc/calc:#!$${BINDIR}/calc:" $$?>$$@'; \
|
||||
echo ' $${CHMOD} +x $$@'; \
|
||||
fi; \
|
||||
done >> makedep.out
|
||||
${Q}echo sample dependency list formed
|
||||
${Q}echo forming new cscript/Makefile
|
||||
@@ -233,8 +241,10 @@ depend:
|
||||
##
|
||||
|
||||
echo_inst_files:
|
||||
${Q}for i in ${SCRIPT}; do \
|
||||
echo __file__ ${SCRIPTDIR}/$$i; \
|
||||
${Q}for i in ${SCRIPT} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo __file__ ${SCRIPTDIR}/$$i; \
|
||||
fi; \
|
||||
done
|
||||
|
||||
##
|
||||
@@ -274,7 +284,10 @@ install: all
|
||||
else \
|
||||
true; \
|
||||
fi
|
||||
${Q}for i in ${SCRIPT}; do \
|
||||
${Q}for i in ${SCRIPT} /dev/null; do \
|
||||
if [ "$$i" = "/dev/null" ]; then \
|
||||
continue; \
|
||||
fi; \
|
||||
if ${CMP} -s $$i $T${SCRIPTDIR}/$$i; then \
|
||||
true; \
|
||||
else \
|
||||
|
@@ -18,8 +18,8 @@
|
||||
# received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
# 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
#
|
||||
# @(#) $Revision: 29.17 $
|
||||
# @(#) $Id: Makefile,v 29.17 2001/06/08 22:38:53 chongo Exp $
|
||||
# @(#) $Revision: 29.18 $
|
||||
# @(#) $Id: Makefile,v 29.18 2002/03/12 08:30:43 chongo Exp $
|
||||
# @(#) $Source: /usr/local/src/cmd/calc/custom/RCS/Makefile,v $
|
||||
#
|
||||
# Under source code control: 1997/03/09 02:28:54
|
||||
@@ -381,8 +381,10 @@ c_sysinfo.o: c_sysinfo.c ${MAKE_FILE}
|
||||
##
|
||||
|
||||
distlist: ${DISTLIST}
|
||||
${Q}for i in ${DISTLIST}; do \
|
||||
${Q}for i in ${DISTLIST} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo custom/$$i; \
|
||||
fi; \
|
||||
done
|
||||
|
||||
distdir:
|
||||
@@ -418,11 +420,13 @@ depend:
|
||||
-${Q}rm -rf skel
|
||||
${Q}mkdir skel
|
||||
${Q}mkdir skel/custom
|
||||
-${Q}for i in ${C_SRC}; do \
|
||||
-${Q}for i in ${C_SRC} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
${SED} -n '/^#[ ]*include[ ]*"/p' \
|
||||
"$$i" > "skel/custom/$$i"; \
|
||||
fi; \
|
||||
done
|
||||
-${Q}for i in /dev/null ${H_SRC}; do \
|
||||
-${Q}for i in ${H_SRC} /dev/null; do \
|
||||
if [ "$$i" = "/dev/null" ]; then \
|
||||
continue; \
|
||||
fi; \
|
||||
@@ -437,7 +441,10 @@ depend:
|
||||
${Q}for i in `cd ..; ${MAKE} h_list 2>&1 | \
|
||||
${SED} -e '/Entering directory/d' \
|
||||
-e '/Nothing to be done/d' \
|
||||
-e '/Leaving directory/d'`; do \
|
||||
-e '/Leaving directory/d'` /dev/null; do \
|
||||
if [ "$$i" = "/dev/null" ]; then \
|
||||
continue; \
|
||||
fi; \
|
||||
tag="`echo $$i | ${SED} 's/[\.+,:]/_/g'`"; \
|
||||
echo "#if !defined($$tag)" > "skel/$$i"; \
|
||||
echo "#define $$tag" >> "skel/$$i"; \
|
||||
@@ -451,8 +458,10 @@ depend:
|
||||
${Q}echo "# DO NOT DELETE THIS LINE -- make depend depends on it." > \
|
||||
skel/custom/makedep.out
|
||||
${Q}cd skel/custom; ${MAKEDEPEND} -w 1 -f makedep.out ${C_SRC}
|
||||
-${Q}for i in ${C_SRC}; do \
|
||||
-${Q}for i in ${C_SRC} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo "$$i" | ${SED} 's/^\(.*\)\.c/\1.o: \1.c/'; \
|
||||
fi; \
|
||||
done >> skel/custom/makedep.out
|
||||
${Q}echo custom dependency list formed
|
||||
${Q}echo forming new custom/Makefile
|
||||
@@ -485,17 +494,25 @@ depend:
|
||||
##
|
||||
|
||||
echo_inst_files:
|
||||
${Q}for i in ${INSTALL_H_SRC}; do \
|
||||
echo __file__ ${CUSTOMINCDIR}/$$i; \
|
||||
${Q}for i in ${INSTALL_H_SRC} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo __file__ ${CUSTOMINCDIR}/$$i; \
|
||||
fi; \
|
||||
done
|
||||
${Q}for i in ${CUSTOM_HELP}; do \
|
||||
echo __file__ ${CUSTOMHELPDIR}/$$i; \
|
||||
${Q}for i in ${CUSTOM_HELP} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo __file__ ${CUSTOMHELPDIR}/$$i; \
|
||||
fi; \
|
||||
done
|
||||
${Q}for i in ${CUSTOM_CALC_FILES}; do \
|
||||
echo __file__ ${CUSTOMLIBDIR}/$$i; \
|
||||
${Q}for i in ${CUSTOM_CALC_FILES} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo __file__ ${CUSTOMLIBDIR}/$$i; \
|
||||
fi; \
|
||||
done
|
||||
${Q}for i in ${CALC_LIBCUSTOM}; do \
|
||||
echo __file__ ${CUSTOMLIBDIR}/$$i; \
|
||||
${Q}for i in ${CALC_LIBCUSTOM} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo __file__ ${CUSTOMLIBDIR}/$$i; \
|
||||
fi; \
|
||||
done
|
||||
|
||||
##
|
||||
@@ -608,7 +625,10 @@ install: all
|
||||
else \
|
||||
true; \
|
||||
fi
|
||||
-${Q}for i in ${INSTALL_H_SRC}; do \
|
||||
-${Q}for i in ${INSTALL_H_SRC} /dev/null; do \
|
||||
if [ "$$i" = "/dev/null" ]; then \
|
||||
continue; \
|
||||
fi; \
|
||||
if ${CMP} -s tmp $T${CUSTOMINCDIR}/$$i; then \
|
||||
true; \
|
||||
else \
|
||||
@@ -620,7 +640,10 @@ install: all
|
||||
fi; \
|
||||
done
|
||||
-${Q}rm -f tmp
|
||||
-${Q}for i in ${CUSTOM_CALC_FILES}; do \
|
||||
-${Q}for i in ${CUSTOM_CALC_FILES} /dev/null; do \
|
||||
if [ "$$i" = "/dev/null" ]; then \
|
||||
continue; \
|
||||
fi; \
|
||||
if ${CMP} -s $$i $T${CUSTOMLIBDIR}/$$i; then \
|
||||
true; \
|
||||
else \
|
||||
@@ -631,7 +654,10 @@ install: all
|
||||
echo "installed $T${CUSTOMLIBDIR}/$$i"; \
|
||||
fi; \
|
||||
done
|
||||
-${Q}for i in ${CUSTOM_HELP}; do \
|
||||
-${Q}for i in ${CUSTOM_HELP} /dev/null; do \
|
||||
if [ "$$i" = "/dev/null" ]; then \
|
||||
continue; \
|
||||
fi; \
|
||||
if ${CMP} -s $$i $T${CUSTOMHELPDIR}/$$i; then \
|
||||
true; \
|
||||
else \
|
||||
|
@@ -18,9 +18,9 @@
|
||||
# received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
# 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
#
|
||||
# @(#) $Revision: 29.18 $
|
||||
# @(#) $Id: Makefile,v 29.18 2001/06/08 22:57:54 chongo Exp $
|
||||
# @(#) $Source: /usr/local/src/cmd/calc/help/RCS/Makefile,v $
|
||||
# @(#) $Revision: 29.19 $
|
||||
# @(#) $Id: Makefile,v 29.19 2002/03/12 08:39:14 chongo Exp $
|
||||
# @(#) $Source: /usr/local/src/cmd/calc/cal/../help/RCS/Makefile,v $
|
||||
#
|
||||
# Under source code control: 1991/07/23 06:47:57
|
||||
# File existed as early as: 1991
|
||||
@@ -418,11 +418,13 @@ full: ${FULL_HELP_FILES} ${MAKE_FILE}
|
||||
# Singular files are the same files as their plural form.
|
||||
#
|
||||
${SINGULAR_FILES}: ${PLURAL_FILES}
|
||||
${Q}for i in ${SINGULAR_FILES}; do \
|
||||
echo "rm -f $${i}"; \
|
||||
rm -f $${i}; \
|
||||
echo "cp $${i}s $${i}"; \
|
||||
cp $${i}s $${i}; \
|
||||
${Q}for i in ${SINGULAR_FILES} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo "rm -f $${i}"; \
|
||||
rm -f $${i}; \
|
||||
echo "cp $${i}s $${i}"; \
|
||||
cp $${i}s $${i}; \
|
||||
fi; \
|
||||
done
|
||||
-@if [ -z "${Q}" ]; then \
|
||||
echo ''; \
|
||||
@@ -482,8 +484,10 @@ builtin: builtin.top builtin.end ../func.c funclist.sed
|
||||
##
|
||||
|
||||
distlist: ${DISTLIST}
|
||||
${Q}for i in ${DISTLIST}; do \
|
||||
${Q}for i in ${DISTLIST} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo help/$$i; \
|
||||
fi; \
|
||||
done | LANG=C ${SORT}
|
||||
|
||||
distdir:
|
||||
@@ -508,12 +512,14 @@ bsdi: all
|
||||
#
|
||||
detaillist:
|
||||
${Q}-(echo "xxxxx"; \
|
||||
for i in ${DETAIL_HELP}; do \
|
||||
for i in ${DETAIL_HELP} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
if [ ! -f RCS/$$i,v ]; then \
|
||||
echo "WARNING: $$i not under RCS control" 1>&2; \
|
||||
else \
|
||||
echo $$i; \
|
||||
fi; \
|
||||
fi; \
|
||||
done | LANG=C ${SORT}) | ${FMT} -70 | \
|
||||
${SED} -e '1s/xxxxx/DETAIL_HELP=/' -e '2,$$s/^/ /' \
|
||||
-e 's/$$/ \\/' -e '$$s/ \\$$//'
|
||||
@@ -526,8 +532,10 @@ detaillist:
|
||||
|
||||
echo_inst_files:
|
||||
${Q}for i in ${STD_HELP_FILES} full ${BLT_HELP_FILES} \
|
||||
builtin ${DETAIL_HELP} ${SINGULAR_FILES}; do \
|
||||
echo __file__ ${HELPDIR}/$$i; \
|
||||
builtin ${DETAIL_HELP} ${SINGULAR_FILES} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo __file__ ${HELPDIR}/$$i; \
|
||||
fi; \
|
||||
done
|
||||
${Q}echo __file__ ${HELPDIR}/obj
|
||||
|
||||
@@ -585,7 +593,10 @@ install: all
|
||||
true; \
|
||||
fi
|
||||
-${Q}for i in ${STD_HELP_FILES} ${BLT_HELP_FILES} builtin \
|
||||
full ${DETAIL_HELP} ${SINGULAR_FILES}; do \
|
||||
full ${DETAIL_HELP} ${SINGULAR_FILES} /dev/null; do \
|
||||
if [ "$$i" = "/dev/null" ]; then \
|
||||
continue; \
|
||||
fi; \
|
||||
if ${CMP} -s $$i $T${HELPDIR}/$$i; then \
|
||||
true; \
|
||||
else \
|
||||
|
6
help/im
6
help/im
@@ -20,7 +20,7 @@ LIMITS
|
||||
none
|
||||
|
||||
LINK LIBRARY
|
||||
COMPLEX *cimag(COMPLEX *x)
|
||||
COMPLEX *c_imag(COMPLEX *x)
|
||||
|
||||
SEE ALSO
|
||||
re
|
||||
@@ -41,8 +41,8 @@ SEE ALSO
|
||||
## received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
## 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
##
|
||||
## @(#) $Revision: 29.2 $
|
||||
## @(#) $Id: im,v 29.2 2000/06/07 14:02:33 chongo Exp $
|
||||
## @(#) $Revision: 29.3 $
|
||||
## @(#) $Id: im,v 29.3 2002/03/12 09:38:26 chongo Exp $
|
||||
## @(#) $Source: /usr/local/src/cmd/calc/help/RCS/im,v $
|
||||
##
|
||||
## Under source code control: 1995/10/05 04:52:26
|
||||
|
6
help/re
6
help/re
@@ -20,7 +20,7 @@ LIMITS
|
||||
none
|
||||
|
||||
LINK LIBRARY
|
||||
COMPLEX *cimag(COMPLEX *x)
|
||||
COMPLEX *c_imag(COMPLEX *x)
|
||||
|
||||
SEE ALSO
|
||||
im
|
||||
@@ -41,8 +41,8 @@ SEE ALSO
|
||||
## received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
## 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
##
|
||||
## @(#) $Revision: 29.2 $
|
||||
## @(#) $Id: re,v 29.2 2000/06/07 14:02:33 chongo Exp $
|
||||
## @(#) $Revision: 29.3 $
|
||||
## @(#) $Id: re,v 29.3 2002/03/12 09:38:26 chongo Exp $
|
||||
## @(#) $Source: /usr/local/src/cmd/calc/help/RCS/re,v $
|
||||
##
|
||||
## Under source code control: 1995/10/05 04:52:27
|
||||
|
8
hist.h
8
hist.h
@@ -17,8 +17,8 @@
|
||||
* received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
* 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
* @(#) $Revision: 29.3 $
|
||||
* @(#) $Id: hist.h,v 29.3 2001/03/17 21:31:47 chongo Exp $
|
||||
* @(#) $Revision: 29.4 $
|
||||
* @(#) $Id: hist.h,v 29.4 2002/03/12 09:40:57 chongo Exp $
|
||||
* @(#) $Source: /usr/local/src/cmd/calc/RCS/hist.h,v $
|
||||
*
|
||||
* Under source code control: 1993/05/02 20:09:20
|
||||
@@ -50,7 +50,11 @@
|
||||
#define HOMECHAR '~' /* char which indicates home directory */
|
||||
#define DOTCHAR '.' /* char which indicates current directory */
|
||||
#define PATHCHAR '/' /* char which separates path components */
|
||||
#if defined(__MSDOS__) || defined(__WIN32)
|
||||
#define LISTCHAR ';' /* char which separates paths in a list */
|
||||
#else
|
||||
#define LISTCHAR ':' /* char which separates paths in a list */
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
|
29
input.c
29
input.c
@@ -17,8 +17,8 @@
|
||||
* received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
* 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
* @(#) $Revision: 29.5 $
|
||||
* @(#) $Id: input.c,v 29.5 2001/03/17 21:31:47 chongo Exp $
|
||||
* @(#) $Revision: 29.6 $
|
||||
* @(#) $Id: input.c,v 29.6 2002/03/12 09:40:57 chongo Exp $
|
||||
* @(#) $Source: /usr/local/src/cmd/calc/RCS/input.c,v $
|
||||
*
|
||||
* Under source code control: 1990/02/15 01:48:16
|
||||
@@ -46,6 +46,12 @@
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
#if defined(__MSDOS__)
|
||||
#include <limits.h>
|
||||
#define _fullpath(f,n,s) (_fixpath(n,f),f)
|
||||
#define _MAX_PATH PATH_MAX
|
||||
#endif
|
||||
|
||||
#include "calc.h"
|
||||
#include "conf.h"
|
||||
#include "hist.h"
|
||||
@@ -816,11 +822,12 @@ runrcfiles(void)
|
||||
* given:
|
||||
* sbuf stat of the inode in question
|
||||
*/
|
||||
|
||||
static int
|
||||
isinoderead(struct stat *sbuf)
|
||||
{
|
||||
int i;
|
||||
#if defined(_WIN32)
|
||||
#if defined(_WIN32) || defined(__MSDOS__)
|
||||
char fullpathname[_MAX_PATH];
|
||||
#endif
|
||||
|
||||
@@ -832,11 +839,11 @@ isinoderead(struct stat *sbuf)
|
||||
|
||||
/* scan the entire readset */
|
||||
for (i=0; i < maxreadset; ++i) {
|
||||
#if defined(_WIN32)
|
||||
#if defined(_WIN32) || defined(__MSDOS__)
|
||||
if (readset[i].active &&
|
||||
strcmp(readset[i].path,
|
||||
_fullpath(fullpathname,cip->i_name,
|
||||
_MAX_PATH)) == 0) {
|
||||
strcasecmp(readset[i].path,
|
||||
_fullpath(fullpathname,cip->i_name,
|
||||
_MAX_PATH)) == 0) {
|
||||
/* found a match */
|
||||
return i;
|
||||
}
|
||||
@@ -954,14 +961,18 @@ addreadset(char *name, char *path, struct stat *sbuf)
|
||||
return -1;
|
||||
}
|
||||
strcpy(readset[ret].name, name);
|
||||
#if defined(_WIN32)
|
||||
#if defined(_WIN32) || defined(__MSDOS__)
|
||||
/*
|
||||
* For WIN32, _fullpath expands the path to a fully qualified
|
||||
* path name, which under WIN32 FAT and NTFS is unique, just
|
||||
* like UNIX inodes. _fullpath also allocated the memory for
|
||||
* this new longer path name.
|
||||
*/
|
||||
readset[ret].path = _fullpath(NULL, path, 0);
|
||||
{
|
||||
char fullpathname[_MAX_PATH];
|
||||
|
||||
readset[ret].path = _fullpath(fullpathname, path, _MAX_PATH);
|
||||
}
|
||||
#else /* Windoz free systems */
|
||||
readset[ret].path = (char *)malloc(strlen(path)+1);
|
||||
if (readset[ret].path == NULL) {
|
||||
|
@@ -17,8 +17,8 @@
|
||||
* received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
* 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
* @(#) $Revision: 29.7 $
|
||||
* @(#) $Id: lib_calc.c,v 29.7 2001/04/08 22:05:40 chongo Exp $
|
||||
* @(#) $Revision: 29.8 $
|
||||
* @(#) $Id: lib_calc.c,v 29.8 2002/03/12 09:40:57 chongo Exp $
|
||||
* @(#) $Source: /usr/local/src/cmd/calc/RCS/lib_calc.c,v $
|
||||
*
|
||||
* Under source code control: 1996/06/17 18:06:19
|
||||
@@ -217,6 +217,11 @@ libcalc_call_me_first(void)
|
||||
*/
|
||||
if (program != NULL) {
|
||||
p = strrchr(program, '/');
|
||||
#if defined(_WIN32) || defined(__MSDOS__)
|
||||
if (p == NULL) {
|
||||
p = strrchr(program, '\\');
|
||||
}
|
||||
#endif
|
||||
if (p == NULL) {
|
||||
base_name = program;
|
||||
} else {
|
||||
|
@@ -17,9 +17,9 @@
|
||||
# received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
# 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
#
|
||||
# @(#) $Revision: 29.14 $
|
||||
# @(#) $Id: Makefile,v 29.14 2001/06/08 22:38:53 chongo Exp $
|
||||
# @(#) $Source: /usr/local/src/cmd/calc/sample/RCS/Makefile,v $
|
||||
# @(#) $Revision: 29.15 $
|
||||
# @(#) $Id: Makefile,v 29.15 2002/03/12 08:41:05 chongo Exp $
|
||||
# @(#) $Source: /usr/local/src/cmd/calc/cal/../sample/RCS/Makefile,v $
|
||||
#
|
||||
# Under source code control: 1997/04/19 22:46:49
|
||||
# File existed as early as: 1997
|
||||
@@ -359,8 +359,10 @@ many_random: many_random.o ../libcalc.a
|
||||
##
|
||||
|
||||
distlist: ${DISTLIST}
|
||||
${Q}for i in ${DISTLIST}; do \
|
||||
${Q}for i in ${DISTLIST} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo sample/$$i; \
|
||||
fi; \
|
||||
done
|
||||
|
||||
distdir:
|
||||
@@ -396,11 +398,14 @@ depend:
|
||||
-${Q}rm -rf skel
|
||||
${Q}mkdir skel
|
||||
${Q}mkdir skel/sample
|
||||
-${Q}for i in ${C_SRC}; do \
|
||||
-${Q}for i in ${C_SRC} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
${SED} -n '/^#[ ]*include[ ]*"/p' \
|
||||
"$$i" > "skel/sample/$$i"; \
|
||||
fi; \
|
||||
done
|
||||
-${Q}for i in ${H_SRC} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
tag="`echo $$i | ${SED} 's/[\.+,:]/_/g'`"; \
|
||||
echo "#if !defined($$tag)" > "skel/sample/$$i"; \
|
||||
@@ -409,18 +414,21 @@ depend:
|
||||
>> "skel/sample/$$i"; \
|
||||
echo '#endif /* '"$$tag"' */' >> "skel/sample/$$i"; \
|
||||
fi; \
|
||||
fi; \
|
||||
done
|
||||
${Q}(cd ..; ${MAKE} hsrc)
|
||||
${Q}for i in `cd ..; ${MAKE} h_list 2>&1 | \
|
||||
${SED} -e '/Entering directory/d' \
|
||||
-e '/Nothing to be done/d' \
|
||||
-e '/Leaving directory/d'`; do \
|
||||
-e '/Leaving directory/d'` /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
tag="`echo $$i | ${SED} 's/[\.+,:]/_/g'`"; \
|
||||
echo "#if !defined($$tag)" > "skel/$$i"; \
|
||||
echo "#define $$tag" >> "skel/$$i"; \
|
||||
${SED} -n '/^#[ ]*include[ ]*"/p' "../$$i" \
|
||||
>> "skel/$$i"; \
|
||||
echo '#endif /* '"$$tag"' */' >> "skel/$$i"; \
|
||||
fi; \
|
||||
done
|
||||
-${Q}rm -f skel/sample/makedep.out
|
||||
${Q}echo sample/skel formed
|
||||
@@ -428,8 +436,10 @@ depend:
|
||||
${Q}echo "# DO NOT DELETE THIS LINE -- make depend depends on it." > \
|
||||
skel/sample/makedep.out
|
||||
${Q}cd skel/sample; ${MAKEDEPEND} -w 1 -f makedep.out -I.. ${C_SRC}
|
||||
-${Q}for i in ${C_SRC}; do \
|
||||
-${Q}for i in ${C_SRC} /dev/null; do \
|
||||
if [ X"$$i" != X"/dev/null" ]; then \
|
||||
echo "$$i" | ${SED} 's/^\(.*\)\.c/\1.o: \1.c/'; \
|
||||
fi; \
|
||||
done >> skel/sample/makedep.out
|
||||
${Q}echo sample dependency list formed
|
||||
${Q}echo forming new sample/Makefile
|
||||
|
22
version.c
22
version.c
@@ -19,8 +19,8 @@
|
||||
* received a copy with calc; if not, write to Free Software Foundation, Inc.
|
||||
* 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
* @(#) $Revision: 29.37 $
|
||||
* @(#) $Id: version.c,v 29.37 2001/12/31 22:12:35 chongo Exp $
|
||||
* @(#) $Revision: 29.38 $
|
||||
* @(#) $Id: version.c,v 29.38 2002/03/12 11:00:08 chongo Exp $
|
||||
* @(#) $Source: /usr/local/src/cmd/calc/RCS/version.c,v $
|
||||
*
|
||||
* Under source code control: 1990/05/22 11:00:58
|
||||
@@ -46,7 +46,7 @@ static char *program;
|
||||
#define MAJOR_VER 2 /* major version */
|
||||
#define MINOR_VER 11 /* minor version */
|
||||
#define MAJOR_PATCH 5 /* patch level or 0 if no patch */
|
||||
#define MINOR_PATCH 6 /* test number or 0 if no minor patch */
|
||||
#define MINOR_PATCH 7 /* test number or 0 if no minor patch */
|
||||
|
||||
|
||||
/*
|
||||
@@ -93,6 +93,22 @@ char *Copyright = "\n"
|
||||
"\n";
|
||||
|
||||
|
||||
#if !defined(HAVE_SNPRINTF)
|
||||
/* Simulate snprintf with vsprintf, hoping that BUFSIZ is large enough. */
|
||||
#include <stdarg.h>
|
||||
int
|
||||
snprintf (char *buf, size_t n, const char *fmt, ...)
|
||||
{
|
||||
int retval;
|
||||
va_list arg;
|
||||
|
||||
va_start (arg, fmt);
|
||||
retval = vsprintf (buf, fmt, arg);
|
||||
va_end (arg);
|
||||
return retval;
|
||||
}
|
||||
#endif
|
||||
|
||||
/*
|
||||
* version - return version string
|
||||
*
|
||||
|
Reference in New Issue
Block a user