Common subdirectories: calc-2.12.2.1.no-means-no/cal and calc-2.12.2.1/cal Common subdirectories: calc-2.12.2.1.no-means-no/cscript and calc-2.12.2.1/cscript Common subdirectories: calc-2.12.2.1.no-means-no/custom and calc-2.12.2.1/custom Common subdirectories: calc-2.12.2.1.no-means-no/help and calc-2.12.2.1/help diff -u calc-2.12.2.1.no-means-no/Makefile calc-2.12.2.1/Makefile --- calc-2.12.2.1.no-means-no/Makefile 2007-09-19 13:39:17.000000000 -0400 +++ calc-2.12.2.1/Makefile 2007-09-19 14:09:08.000000000 -0400 @@ -767,12 +767,29 @@ MANMODE= 0444 CATMODE= 0444 +# By default, custom builtin functions may only be executed if calc +# is given the -C option. This is because custom builtin functions +# may invoke non-standard or non-portable code. One may completely +# disable custom builtin functions by not compiling any of code +# +# ALLOW_CUSTOM= -DCUSTOM # allow custom only if -C is given +# ALLOW_CUSTOM= # disable custom even if -C is given +# +# If in doubt, use ALLOW_CUSTOM= -DCUSTOM +# +ALLOW_CUSTOM= -DCUSTOM +#ALLOW_CUSTOM= + # If the $CALCPATH environment variable is not defined, then the following # path will be search for calc resource file routines. # # Select CALCPATH= .;./cal;~/.cal;${CALC_SHAREDIR};${CUSTOMCALDIR} for DJGPP. # +ifeq ($(ALLOW_CUSTOM),"-DCUSTOM") CALCPATH= .:./cal:~/.cal:${CALC_SHAREDIR}:${CUSTOMCALDIR} +else +CALCPATH= .:./cal:~/.cal:${CALC_SHAREDIR} +endif #CALCPATH= .;./cal;~/.cal;${CALC_SHAREDIR};${CUSTOMCALDIR} # If the $CALCRC environment variable is not defined, then the following @@ -925,18 +942,6 @@ # MALLOC_FASTCHK=1 MALLOC_FULLWARN=1 MALLOC_CLEAR_FREE=1 \ # MALLOC_CLEAR_MALLOC=1 LD_LIBRARY_PATH=.:./custom -# By default, custom builtin functions may only be executed if calc -# is given the -C option. This is because custom builtin functions -# may invoke non-standard or non-portable code. One may completely -# disable custom builtin functions by not compiling any of code -# -# ALLOW_CUSTOM= -DCUSTOM # allow custom only if -C is given -# ALLOW_CUSTOM= # disable custom even if -C is given -# -# If in doubt, use ALLOW_CUSTOM= -DCUSTOM -# -ALLOW_CUSTOM= -DCUSTOM -#ALLOW_CUSTOM= # The install rule uses: # @@ -1280,7 +1285,11 @@ CFLAGS= ${ICFLAGS} ${CCOPT} # ILDFLAGS= ${COMMON_LDFLAGS} ${LD_STATIC} +ifeq ($(ALLOW_CUSTOM),"-DCUSTOM") LDFLAGS= ${LD_DEBUG} ${ILDFLAGS} ${LIBCALC_STATIC} ${LIBCUSTCALC_STATIC} +else +LDFLAGS= ${LD_DEBUG} ${ILDFLAGS} ${LIBCALC_STATIC} +endif # #if 0 /* start of skip for non-Gnu makefiles */ endif @@ -1691,6 +1700,7 @@ # OBJS= ${LIBOBJS} ${CALCOBJS} ${UTIL_OBJS} ${SAMPLE_OBJS} +ifeq ($(ALLOW_CUSTOM),"-DCUSTOM") # static library build # CALC_STATIC_LIBS= libcalc.a libcustcalc.a @@ -1705,6 +1715,20 @@ libcalc${LIB_EXT_VERS} libcustcalc${LIB_EXT_VERSION} \ libcustcalc${LIB_EXT_VERS} libcustcalc${LIB_EXT_VER} \ libcustcalc${LIB_EXT_VE} libcustcalc${LIB_EXT} +else +# static library build +# +CALC_STATIC_LIBS= libcalc.a + +# Libaraies created and used to build calc +# +CALC_DYNAMIC_LIBS= libcalc${LIB_EXT_VERSION} + +# Symlinks of dymanic shared libraries +# +SYM_DYNAMIC_LIBS= libcalc${LIB_EXT_VER} libcalc${LIB_EXT_VE} libcalc${LIB_EXT} \ + libcalc${LIB_EXT_VERS} +endif # list of sample programs to that need to be built to satisfy sample rule # @@ -1735,7 +1759,11 @@ # early targets - things needed before the main build phase can begin # +ifeq ($(ALLOW_CUSTOM),"-DCUSTOM") EARLY_TARGETS= custom/Makefile hsrc .hsrc custom/.all +else +EARLY_TARGETS= hsrc .hsrc +endif # late targets - things needed after the main build phase is complete # Common subdirectories: calc-2.12.2.1.no-means-no/win32 and calc-2.12.2.1/win32