add missing edits to cscript/Makefile

This commit is contained in:
Landon Curt Noll
2023-08-13 23:48:50 -07:00
parent 21ab25d1c9
commit f81d67b322
2 changed files with 46 additions and 178 deletions

View File

@@ -36,177 +36,53 @@
# Makefile by Landon Curt Noll
# The shell used by this Makefile
#
# On some systems, /bin/sh is a rather reduced shell with
# deprecated behavior.
#
# If your system has a up to date, bash shell, then
# you may wish to use:
#
# SHELL= bash
#
# On some systems such as macOS, the bash shell is very
# far behind to the point where is cannot be depended on.
# On such systems, the sh may be a much better alternative
# shell for this Makefile to use:
#
# SHELL= sh
#
SHELL= bash
#SHELL= sh
#if 0 /* start of skip for non-Gnu makefiles */
#
ifeq ($(target),Darwin)
SHELL:= /bin/sh
endif
#endif /* end of skip for non-Gnu makefiles */
####
# Normally, the upper level makefile will set these values. We provide
# a default here just in case you want to build from this directory.
####
# PREFIX - Top level location for calc
#
# The PREFIX is often prepended to paths within calc and calc Makefiles.
#
# Starting with calc v2.13.0.1, nearly all Makefile places that used
# /usr/local now use ${PREFIX}. An exception is the olduninstall rule
# and, of course, this section. :-)
#
# NOTE: The ${PREFIX} is not the same as ${T}. The ${T} specifies
# a top level directory under which calc installs things.
# While usually ${T} is empty, it can be specific path
# as if calc where "chrooted" during an install.
# The ${PREFIX} value, during install, is a path between
# the top level ${T} install directory and the object
# such as an include file.
#
# NOTE: See also, ${T}, below.
#
# There are some paths that do NOT call under ${PREFIX}, such as
# ${CALCPATH}, that include paths not under ${PREFIX}, but those
# too are exceptions to this general rule.
#
# When in doubt, try:
#
# PREFIX= /usr/local
#
PREFIX= /usr/local
#PREFIX= /usr
#PREFIX= /usr/global
###########################################
# Files used or included by this Makefile #
###########################################
# 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, then they wont.
# MAKE_FILE is empty, then they won't.
#
# If in doubt, set MAKE_FILE to Makefile
#
MAKE_FILE= Makefile
# Where the system include (.h) files are kept
#
# For DJGPP, select:
#
# INCDIR= /dev/env/DJDIR/include
#
# If in doubt, set:
#
# INCDIR= /usr/include
# Calc configuration and compile configuration values
#
CONFIG_MKF= ../Makefile.config
#INCDIR= ${PREFIX}/include
#INCDIR= /dev/env/DJDIR/include
INCDIR= /usr/include
# Host targets that are shared in common with both Makefile
# and custom/Makefile.
#
TARGET_MKF= ../Makefile.target
# where to install calc related things
# Local file that is included just prior to the first rule,
# that allows one to override any values set in this Makefile.
#
# ${BINDIR} where to install calc binary files
# ${LIBDIR} where calc link library (*.a) files are installed
# ${CALC_SHAREDIR} where to install calc help, .cal, startup, config files
#
# NOTE: The install rule prepends installation paths with ${T}, which
# by default is empty. If ${T} is non-empty, then installation
# locations will be relative to the ${T} directory.
#
# For DJGPP, select:
#
# BINDIR= /dev/env/DJDIR/bin
# LIBDIR= /dev/env/DJDIR/lib
# CALC_SHAREDIR= /dev/env/DJDIR/share/calc
#
# If in doubt, set:
#
# BINDIR= /usr/bin
# LIBDIR= /usr/lib
# CALC_SHAREDIR= /usr/share/calc
#
#BINDIR= ${PREFIX}/bin
#BINDIR= /dev/env/DJDIR/bin
BINDIR= /usr/bin
LOCAL_MKF= ../Makefile.local
#LIBDIR= ${PREFIX}/lib
#LIBDIR= /dev/env/DJDIR/lib
LIBDIR= /usr/lib
# The set of Makefiles
#
MK_SET= ${MAKE_FILE} ${CONFIG_MKF} ${TARGET_MKF} ${LOCAL_MKF}
#CALC_SHAREDIR= ${PREFIX}/lib/calc
#CALC_SHAREDIR= /dev/env/DJDIR/share/calc
CALC_SHAREDIR= /usr/share/calc
# By default, these values are based CALC_SHAREDIR, INCDIR, BINDIR
# ---------------------------------------------------------------
# ${HELPDIR} where the help directory is installed
# ${CALC_INCDIR} where the calc include files are installed
# ${SCRIPTDIR} where calc shell scripts are installed
#
# NOTE: The install rule prepends installation paths with ${T}, which
# by default is empty. If ${T} is non-empty, then installation
# locations will be relative to the ${T} directory.
#
# If in doubt, set:
#
# HELPDIR= ${CALC_SHAREDIR}/help
# CALC_INCDIR= ${INCDIR}/calc
# SCRIPTDIR= ${BINDIR}/cscript
#
HELPDIR= ${CALC_SHAREDIR}/help
CALC_INCDIR= ${INCDIR}/calc
SCRIPTDIR= ${BINDIR}/cscript
#######################################################
# Calc configuration and compile configuration values #
#######################################################
include ${CONFIG_MKF}
# T - top level directory under which calc will be installed
#
# The calc install is performed under ${T}, the calc build is
# performed under /. The purpose for ${T} is to allow someone
# to install calc somewhere other than into the system area.
#
# For example, if:
#
# BINDIR= /usr/bin
# LIBDIR= /usr/lib
# CALC_SHAREDIR= /usr/share/calc
#
# and if:
#
# T= /var/tmp/testing
#
# Then the installation locations will be:
#
# calc binary files: /var/tmp/testing/usr/bin
# calc link library: /var/tmp/testing/usr/lib
# calc help, .cal ...: /var/tmp/testing/usr/share/calc
# ... etc ... /var/tmp/testing/...
#
# If ${T} is empty, calc is installed under /, which is the same
# top of tree for which it was built. If ${T} is non-empty, then
# calc is installed under ${T}, as if one had to chroot under
# ${T} for calc to operate.
#
# If in doubt, use T=
#
T=
###############################
# host target section include #
###############################
include ${TARGET_MKF}
##########################################################################
#=-=-=-=-=- Be careful if you change something below this line -=-=-=-=-=#
##########################################################################
# Makefile debug
#
@@ -240,29 +116,6 @@ H=@
V=@:
#V=@
# standard tools
#
CAT= cat
CHMOD= chmod
CMP= cmp
CO= co
CP= cp
FMT= fmt
MKDIR= mkdir
MV= mv
RM= rm
RMDIR= rmdir
SED= sed
SORT= sort
TOUCH= touch
TRUE= true
# NOTE: On some shells, echo is a builtin that does
# not understand -n, so we call /bin/echo -n
# directly to get around such shells.
#
ECHON= /bin/echo -n
# The ${SCRIPT} list is the list of calc shell script files (without the .calc
# extension) which will be installed.
#
@@ -304,10 +157,26 @@ TARGETS= ${CSCRIPT_TARGETS} README
#
PHONY= all clobber distlist install
############################################################
# Allow Makefile.local to change any of the above settings #
############################################################
include ${LOCAL_MKF}
###########################################
# all - First and default Makefile target #
###########################################
# The reason for this Makefile
#
all: ${TARGETS} .all
###############################
# additional Makefile targets #
###############################
.PHONY: ${PHONY}
README: README.src

View File

@@ -84,7 +84,6 @@ include ${TARGET_MKF}
#=-=-=-=-=- Be careful if you change something below this line -=-=-=-=-=#
##########################################################################
# Makefile debug
#
# Q=@ do not echo internal Makefile actions (quiet mode)