Hi all, In #chicken Guest-liao was asking some questions about compiling runtime.c manually, and I noticed that they didn't have chicken-config.h, and passing in -DHAVE_CHICKEN_CONFIG_H is needed. While looking into this, I noticed we also used to have a HAVE_CONFIG_H macro which got checked and defined, but this no longer seems to be in use. The attached patch removes the obsolete #ifdef HAVE_CONFIG_H block from runtime.c
Cheers, Peter
From dba340c1fe1b3e966e69ee51bb951b121e84079a Mon Sep 17 00:00:00 2001 From: Peter Bex <pe...@more-magic.net> Date: Wed, 20 Oct 2021 09:38:45 +0200 Subject: [PATCH] Remove obsolete HAVE_CONFIG_H check in runtime.c We never define this, only HAVE_CHICKEN_CONFIG_H, so this entire block of #ifdef can be removed. Also, PACKAGE and VERSION are not used anywhere, so it's pointless to undefine them. --- chicken.h | 2 +- runtime.c | 14 -------------- 2 files changed, 1 insertion(+), 15 deletions(-) diff --git a/chicken.h b/chicken.h index 7e51a38f..cc3be8ff 100644 --- a/chicken.h +++ b/chicken.h @@ -44,7 +44,7 @@ /* * N.B. This file MUST not rely upon "chicken-config.h" */ -#if defined(HAVE_CONFIG_H) || defined(HAVE_CHICKEN_CONFIG_H) +#if defined(HAVE_CHICKEN_CONFIG_H) # include "chicken-config.h" #endif diff --git a/runtime.c b/runtime.c index c46cde6f..981996f4 100644 --- a/runtime.c +++ b/runtime.c @@ -130,20 +130,6 @@ static C_TLS int timezone; # include <mach-o/dyld.h> #endif -#ifdef HAVE_CONFIG_H -# ifdef PACKAGE -# undef PACKAGE -# endif -# ifdef VERSION -# undef VERSION -# endif -# include <chicken-config.h> - -# ifndef HAVE_ALLOCA -# error this package requires "alloca()" -# endif -#endif - /* Parameters: */ #define RELAX_MULTIVAL_CHECK -- 2.31.1
signature.asc
Description: PGP signature