fix calc when CUSTOM is undefined, remove PASSDOWN values

Removed the ${CAL_PASSDOWN}, ${HELP_PASSDOWN}, ${HELP_PASSDOWN},
${CSCRIPT_PASSDOWN} Makefile variables as the new Makefile
include files keep Makefile variables in sync.

Fixed the ability of calc to compile when CUSTOM is undefined
(i.e., -UCUSTOM).  The libcustcalc is always built, regardless
of the $(ALLOW_CUSTOM} Makefile variable.  However when CUSTOM
is undefined, the bulk of custom functions are not defined.
This commit is contained in:
Landon Curt Noll
2023-08-14 01:26:52 -07:00
parent f81d67b322
commit 6ee34e709d
16 changed files with 221 additions and 382 deletions

View File

@@ -24,20 +24,31 @@
*/
/*
* ISO C requires a translation unit to contain at least one declaration,
* so we declare a global variable whose value is based on if CUSTOM is defined.
*/
#if defined(CUSTOM)
int c_pzasusb8_allowed = 1; /* CUSTOM defined */
#else /* CUSTOM */
int c_pzasusb8_allowed = 0; /* CUSTOM defined */
#endif /* CUSTOM */
#if defined(CUSTOM)
#include <stdio.h>
#include "have_const.h"
#include "value.h"
#include "custom.h"
#include "zmath.h"
#include "../have_const.h"
#include "../value.h"
#include "../custom.h"
#include "../zmath.h"
#include "have_unused.h"
#include "../have_unused.h"
#include "attribute.h"
#include "banned.h" /* include after system header <> includes */
#include "../attribute.h"
#include "../banned.h" /* include after system header <> includes */
/*