Skip to content

Commit 09e0577

Browse files
committed
Disable Chicken target language
Clean up to disable target languages that have been neglected/not functional. Target language be fully deleted in SWIG 4.1 unless a new maintainer brings it up to an acceptable status (experimental or supported). Issue swig#1447
1 parent cb4bd26 commit 09e0577

17 files changed

+11
-273
lines changed

ANNOUNCE

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ What is SWIG?
1010
SWIG is a software development tool that reads C/C++ header files and
1111
generates the wrapper code needed to make C and C++ code accessible
1212
from other programming languages including Perl, Python, Tcl, Ruby,
13-
PHP, C#, Go, Java, Javascript, Lua, Scheme (Guile, MzScheme, CHICKEN),
13+
PHP, C#, Go, Java, Javascript, Lua, Scheme (Guile, MzScheme),
1414
D, Ocaml, Octave, R, Scilab, Common Lisp (Allegro CL, CFFI).
1515
SWIG can also export its parse tree in
1616
the form of XML. Major applications of SWIG

CHANGES.current

+4
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@ the issue number to the end of the URL: https://github.com/swig/swig/issues/
77
Version 4.0.0 (in progress)
88
===========================
99

10+
2019-02-04: wsfulton
11+
[Chicken] #1447 CHICKEN has been disabled as a target language in SWIG as part of a
12+
clean up to remove target languages that have been neglected/not functional.
13+
1014
2019-02-04: wsfulton
1115
[CLISP] #1447 GNU Common Lisp has been disabled as a target language in SWIG as part of a
1216
clean up to remove target languages that have been neglected/not functional.

Doc/Devel/runtime.txt

+2-2
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ Alternatively, if the language supports modules, a module named
5757
named "type_table" SWIG_TYPE_TABLE_NAME can be created inside it. The most
5858
common approach is to store the mod pointer in some global variable in the
5959
target language, but if the language provides an alternative place to store data
60-
(like the chicken module), then that is good too.
60+
then that is good too.
6161

6262
The way the code is set up, SetModule should only be called when GetModule
6363
returns NULL, and if SetModule is called a second time, the behavior is
@@ -105,7 +105,7 @@ Standard Functions
105105
These functions are not required and their API is not formalized, but almost all
106106
language modules implement them for consistency across languages. Throughout
107107
this discussion, I will use LangType to represent the underlying language type
108-
(C_word in chicken, Scheme_Object * in mzscheme, PyObject * in python, etc)
108+
(Scheme_Object * in mzscheme, PyObject * in python, etc)
109109

110110

111111

Doc/Manual/Preprocessor.html

-1
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,6 @@ <H2><a name="Preprocessor_condition_compilation">9.3 Conditional Compilation</a>
111111

112112
SWIGALLEGROCL Defined when using Allegro CL
113113
SWIGCFFI Defined when using CFFI
114-
SWIGCHICKEN Defined when using CHICKEN
115114
SWIGCSHARP Defined when using C#
116115
SWIGGUILE Defined when using Guile
117116
SWIGJAVA Defined when using Java

Doc/Manual/SWIG.html

-1
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,6 @@ <H2><a name="SWIG_nn2">5.1 Running SWIG</a></H2>
119119
<div class="shell"><pre>
120120
Supported Target Language Options
121121
-allegrocl - Generate ALLEGROCL wrappers
122-
-chicken - Generate CHICKEN wrappers
123122
-cffi - Generate CFFI wrappers
124123
-csharp - Generate C# wrappers
125124
-d - Generate D wrappers

Doc/Manual/Sections.html

-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@ <H3><a name="Sections_language_modules">Supported Language Modules Documentation
4242
<li><a href="Allegrocl.html#Allegrocl">Allegro Common Lisp support</a></li>
4343
<li><a href="Android.html#Android">Android support</a></li>
4444
<li><a href="CSharp.html#CSharp">C# support</a></li>
45-
<li><a href="Chicken.html#Chicken">Chicken support</a></li>
4645
<li><a href="D.html#D">D support</a></li>
4746
<li><a href="Go.html#Go">Go support</a></li>
4847
<li><a href="Guile.html#Guile">Guile support</a></li>

Doc/Manual/chapters

-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ CCache.html
2020
Allegrocl.html
2121
Android.html
2222
CSharp.html
23-
Chicken.html
2423
D.html
2524
Go.html
2625
Guile.html

Examples/Makefile.in

-116
Original file line numberDiff line numberDiff line change
@@ -1081,122 +1081,6 @@ php_clean:
10811081
rm -f core @EXTRA_CLEAN@
10821082
rm -f *.@OBJEXT@ *$(PHP_SO)
10831083

1084-
##################################################################
1085-
##### Chicken ######
1086-
##################################################################
1087-
1088-
CHICKEN = @CHICKEN@
1089-
CHICKEN_CSC = @CHICKEN_CSC@
1090-
CHICKEN_CSI = @CHICKEN_CSI@
1091-
CHICKEN_LIBOPTS = @CHICKENLIB@ $(SYSLIBS)
1092-
CHICKEN_SHAREDLIBOPTS = @CHICKENSHAREDLIB@ $(SYSLIBS)
1093-
CHICKEN_CFLAGS = @CHICKENOPTS@
1094-
CHICKENOPTS = -quiet
1095-
CHICKEN_MAIN =
1096-
CHICKEN_SCRIPT = $(RUNME).scm
1097-
1098-
# SWIG produces $(ISRCS) (the C wrapper file)
1099-
# and $(CHICKEN_GENERATED_SCHEME) (the Scheme wrapper file):
1100-
CHICKEN_GENERATED_SCHEME = $(INTERFACE:.i=.scm)
1101-
CHICKEN_COMPILED_SCHEME = $(INTERFACE:.i=_chicken.c)
1102-
CHICKEN_COMPILED_OBJECT = $(CHICKEN_COMPILED_SCHEME:.c=.@OBJEXT@)
1103-
1104-
# flags for the main chicken sources (only used when compiling statically)
1105-
CHICKEN_COMPILED_MAIN = $(CHICKEN_MAIN:.scm=_chicken.c)
1106-
CHICKEN_COMPILED_MAIN_OBJECT = $(CHICKEN_COMPILED_MAIN:.c=.@OBJEXT@)
1107-
1108-
# -----------------------------------------------------------------
1109-
# Build a CHICKEN dynamically loadable module
1110-
# -----------------------------------------------------------------
1111-
1112-
# This is the old way to build chicken, but it does not work correctly with exceptions
1113-
chicken_direct: $(SRCDIR_SRCS)
1114-
$(SWIG) -chicken $(SWIGOPT) $(INCLUDE) $(INTERFACEPATH)
1115-
$(CHICKEN) $(CHICKEN_GENERATED_SCHEME) $(CHICKENOPTS) \
1116-
-dynamic -feature chicken-compile-shared \
1117-
-output-file $(CHICKEN_COMPILED_SCHEME)
1118-
$(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(CHICKEN_CFLAGS) \
1119-
$(INCLUDES) $(CHICKEN_INCLUDE) $(ISRCS) $(SRCDIR_SRCS) $(CHICKEN_COMPILED_SCHEME)
1120-
$(LDSHARED) $(CFLAGS) $(LDFLAGS) $(CHICKEN_COMPILED_OBJECT) $(OBJS) $(IOBJS) \
1121-
$(LIBS) $(CHICKEN_SHAREDLIBOPTS) -o $(LIBPREFIX)$(TARGET)$(SO)
1122-
1123-
chicken_direct_cpp: $(SRCDIR_CXXSRCS) $(CHICKSRCS)
1124-
$(SWIG) -c++ -chicken $(SWIGOPT) $(INCLUDE) $(INTERFACEPATH)
1125-
$(CHICKEN) $(CHICKEN_GENERATED_SCHEME) $(CHICKENOPTS) \
1126-
-dynamic -feature chicken-compile-shared \
1127-
-output-file $(CHICKEN_COMPILED_SCHEME)
1128-
$(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(CHICKEN_CFLAGS) \
1129-
$(INCLUDES) $(CHICKEN_INCLUDE) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(CHICKEN_COMPILED_SCHEME)
1130-
$(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(CHICKEN_COMPILED_OBJECT) $(OBJS) $(IOBJS) \
1131-
$(LIBS) $(CPP_DLLIBS) $(CHICKEN_SHAREDLIBOPTS) -o $(LIBPREFIX)$(TARGET)$(SO)
1132-
1133-
# -----------------------------------------------------------------
1134-
# Build statically linked CHICKEN interpreter
1135-
# -----------------------------------------------------------------
1136-
1137-
# The following two targets are also used by the test suite
1138-
chicken_static: $(SRCDIR_SRCS) $(CHICKSRCS)
1139-
$(SWIG) -chicken $(SWIGOPT) $(INCLUDE) $(INTERFACEPATH)
1140-
$(CHICKEN) $(CHICKEN_GENERATED_SCHEME) $(CHICKENOPTS) \
1141-
-output-file $(CHICKEN_COMPILED_SCHEME)
1142-
$(CHICKEN) $(CHICKEN_MAIN) $(CHICKENOPTS) \
1143-
-output-file $(CHICKEN_MAIN:.scm=_chicken.c)
1144-
$(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(CHICKEN_CFLAGS) \
1145-
$(INCLUDES) $(CHICKEN_INCLUDE) $(ISRCS) $(SRCDIR_SRCS) \
1146-
$(CHICKEN_COMPILED_SCHEME) $(CHICKEN_COMPILED_MAIN)
1147-
$(CC) $(CFLAGS) $(LDFLAGS) $(CHICKEN_COMPILED_OBJECT) $(CHICKEN_COMPILED_MAIN_OBJECT) \
1148-
$(OBJS) $(IOBJS) $(LIBS) $(CHICKEN_SHAREDLIBOPTS) -o $(TARGET)
1149-
1150-
chicken_static_cpp: $(SRCDIR_CXXSRCS) $(CHICKSRCS)
1151-
$(SWIG) -c++ -chicken $(SWIGOPT) $(INCLUDE) $(INTERFACEPATH)
1152-
$(CHICKEN) $(CHICKEN_GENERATED_SCHEME) $(CHICKENOPTS) \
1153-
-output-file $(CHICKEN_COMPILED_SCHEME)
1154-
$(CHICKEN) $(CHICKEN_MAIN) $(CHICKENOPTS) \
1155-
-output-file $(CHICKEN_MAIN:.scm=_chicken.c)
1156-
$(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(CHICKEN_CFLAGS) \
1157-
$(INCLUDES) $(CHICKEN_INCLUDE) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) \
1158-
$(CHICKEN_COMPILED_SCHEME) $(CHICKEN_COMPILED_MAIN)
1159-
$(CXX) $(CXXFLAGS) $(LDFLAGS) $(CHICKEN_COMPILED_OBJECT) $(CHICKEN_COMPILED_MAIN_OBJECT) \
1160-
$(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) $(CHICKEN_SHAREDLIBOPTS) -o $(TARGET)
1161-
1162-
# ----------------------------------------------------------------
1163-
# Build a shared library using csc
1164-
# ----------------------------------------------------------------
1165-
1166-
chicken:
1167-
$(SWIG) -chicken $(SWIGOPT) $(INCLUDE) $(INTERFACEPATH)
1168-
$(COMPILETOOL) $(CHICKEN_CSC) -s `echo $(INCLUDES) | sed 's/-I/-C -I/g'` $(CHICKEN_GENERATED_SCHEME) $(SRCDIR_SRCS) $(ISRCS) -o $(TARGET)$(SO)
1169-
1170-
chicken_cpp:
1171-
$(SWIG) -c++ -chicken $(SWIGOPT) $(INCLUDE) $(INTERFACEPATH)
1172-
$(COMPILETOOL) $(CHICKEN_CSC) -s `echo $(INCLUDES) | sed 's/-I/-C -I/g'` $(CHICKEN_GENERATED_SCHEME) $(SRCDIR_SRCS) $(ICXXSRCS) $(SRCDIR_CXXSRCS) -o $(TARGET)$(SO)
1173-
1174-
chicken_externalhdr:
1175-
$(SWIG) -chicken -external-runtime $(TARGET)
1176-
1177-
# -----------------------------------------------------------------
1178-
# Run CHICKEN example
1179-
# -----------------------------------------------------------------
1180-
1181-
chicken_run:
1182-
env LD_LIBRARY_PATH=$$PWD $(RUNTOOL) $(CHICKEN_CSI) $(CHICKEN_SCRIPT) $(RUNPIPE)
1183-
1184-
# -----------------------------------------------------------------
1185-
# Version display
1186-
# -----------------------------------------------------------------
1187-
1188-
chicken_version:
1189-
$(CHICKEN) -version | grep -i version
1190-
1191-
# -----------------------------------------------------------------
1192-
# Cleaning the CHICKEN examples
1193-
# -----------------------------------------------------------------
1194-
1195-
chicken_clean:
1196-
rm -f *_wrap* *~ .~* *_chicken*
1197-
rm -f core @EXTRA_CLEAN@
1198-
rm -f *.@OBJEXT@ *@SO@
1199-
12001084
##################################################################
12011085
##### CSHARP ######
12021086
##################################################################

Lib/allkw.swg

-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616

1717
*/
1818

19-
%include <chicken/chickenkw.swg>
2019
%include <csharp/csharpkw.swg>
2120
%include <d/dkw.swg>
2221
%include <go/gokw.swg>

Lib/cdata.i

-8
Original file line numberDiff line numberDiff line change
@@ -21,14 +21,6 @@ typedef struct SWIGCDATA {
2121
}
2222
%typemap(in) (const void *indata, int inlen) = (char *STRING, int LENGTH);
2323

24-
#elif SWIGCHICKEN
25-
26-
%typemap(out) SWIGCDATA {
27-
C_word *string_space = C_alloc(C_SIZEOF_STRING($1.len));
28-
$result = C_string(&string_space, $1.len, $1.data);
29-
}
30-
%typemap(in) (const void *indata, int inlen) = (char *STRING, int LENGTH);
31-
3224
#elif SWIGPHP7
3325

3426
%typemap(out) SWIGCDATA {

Lib/exception.i

-16
Original file line numberDiff line numberDiff line change
@@ -138,22 +138,6 @@ SWIGINTERN void SWIG_exception_(int code, const char *msg) {
138138
#endif
139139

140140

141-
#ifdef SWIGCHICKEN
142-
%{
143-
SWIGINTERN void SWIG_exception_(int code, const char *msg) {
144-
C_word *a;
145-
C_word scmmsg;
146-
C_word list;
147-
148-
a = C_alloc (C_SIZEOF_STRING (strlen (msg)) + C_SIZEOF_LIST(2));
149-
scmmsg = C_string2 (&a, (char *) msg);
150-
list = C_list(&a, 2, C_fix(code), scmmsg);
151-
SWIG_ThrowException(list);
152-
}
153-
#define SWIG_exception(a,b) SWIG_exception_((a),(b))
154-
%}
155-
#endif
156-
157141
#ifdef SWIGCSHARP
158142
%{
159143
SWIGINTERN void SWIG_CSharpException(int code, const char *msg) {

Makefile.in

+1-9
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,6 @@ skip-ruby = test -n "@SKIP_RUBY@"
6969
skip-php = test -n "@SKIP_PHP@"
7070
skip-ocaml = test -n "@SKIP_OCAML@"
7171
skip-octave = test -n "@SKIP_OCTAVE@"
72-
skip-chicken = test -n "@SKIP_CHICKEN@"
7372
skip-csharp = test -n "@SKIP_CSHARP@"
7473
skip-lua = test -n "@SKIP_LUA@"
7574
skip-allegrocl = test -n "@SKIP_ALLEGROCL@"
@@ -113,7 +112,6 @@ check-aliveness:
113112
@$(skip-ocaml) || ./$(TARGET) -ocaml -help
114113
@$(skip-octave) || ./$(TARGET) -octave -help
115114
@$(skip-php) || ./$(TARGET) -php7 -help
116-
@$(skip-chicken) || ./$(TARGET) -chicken -help
117115
@$(skip-csharp) || ./$(TARGET) -csharp -help
118116
@$(skip-allegrocl)|| ./$(TARGET) -allegrocl -help
119117
@$(skip-cffi) || ./$(TARGET) -cffi -help
@@ -141,7 +139,6 @@ check-versions: \
141139
check-ocaml-version \
142140
check-octave-version \
143141
check-php-version \
144-
check-chicken-version \
145142
check-csharp-version \
146143
check-lua-version \
147144
check-allegrocl-version \
@@ -177,7 +174,6 @@ check-examples: \
177174
check-ocaml-examples \
178175
check-octave-examples \
179176
check-php-examples \
180-
check-chicken-examples \
181177
check-csharp-examples \
182178
check-lua-examples \
183179
check-allegrocl-examples \
@@ -199,7 +195,6 @@ ruby_examples :=$(shell sed '/^\#/d' $(srcdir)/Examples/ruby/check.list)
199195
ocaml_examples :=$(shell sed '/^\#/d' $(srcdir)/Examples/ocaml/check.list)
200196
octave_examples :=$(shell sed '/^\#/d' $(srcdir)/Examples/octave/check.list)
201197
php_examples :=$(shell sed '/^\#/d' $(srcdir)/Examples/php/check.list)
202-
chicken_examples :=$(shell sed '/^\#/d' $(srcdir)/Examples/chicken/check.list)
203198
csharp_examples :=$(shell sed '/^\#/d' $(srcdir)/Examples/csharp/check.list)
204199
lua_examples :=$(shell sed '/^\#/d' $(srcdir)/Examples/lua/check.list)
205200
allegrocl_examples :=
@@ -247,7 +242,6 @@ check-test-suite: \
247242
check-lua-test-suite \
248243
check-allegrocl-test-suite \
249244
check-cffi-test-suite \
250-
check-chicken-test-suite \
251245
check-r-test-suite \
252246
check-scilab-test-suite \
253247
check-go-test-suite \
@@ -297,7 +291,6 @@ all-test-suite: \
297291
all-lua-test-suite \
298292
all-allegrocl-test-suite \
299293
all-cffi-test-suite \
300-
all-chicken-test-suite \
301294
all-r-test-suite \
302295
all-scilab-test-suite \
303296
all-go-test-suite \
@@ -323,7 +316,6 @@ broken-test-suite: \
323316
broken-lua-test-suite \
324317
broken-allegrocl-test-suite \
325318
broken-cffi-test-suite \
326-
broken-chicken-test-suite \
327319
broken-r-test-suite \
328320
broken-scilab-test-suite \
329321
broken-go-test-suite \
@@ -460,7 +452,7 @@ install-main:
460452
@$(INSTALL_PROGRAM) $(TARGET) $(DESTDIR)$(BIN_DIR)/`echo $(TARGET_NOEXE) | sed '$(transform)'`@EXEEXT@
461453

462454
lib-languages = typemaps tcl perl5 python guile java mzscheme ruby php ocaml octave \
463-
chicken csharp allegrocl lua cffi r go d javascript javascript/jsc \
455+
csharp allegrocl lua cffi r go d javascript javascript/jsc \
464456
javascript/v8 scilab xml
465457

466458
lib-modules = std

README

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Version: 4.0.0 (in progress)
44

55
Tagline: SWIG is a compiler that integrates C and C++ with languages
66
including Perl, Python, Tcl, Ruby, PHP, Java, C#, D, Go, Lua,
7-
Octave, R, Scheme (Guile, MzScheme/Racket, CHICKEN), Scilab,
7+
Octave, R, Scheme (Guile, MzScheme/Racket), Scilab,
88
Ocaml, Common Lisp (Allegro CL, CFFI).
99
SWIG can also export its parse tree into XML.
1010

Source/Makefile.am

-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@ eswig_SOURCES = CParse/cscanner.c \
4949
Modules/allocate.cxx \
5050
Modules/browser.cxx \
5151
Modules/cffi.cxx \
52-
Modules/chicken.cxx \
5352
Modules/contract.cxx \
5453
Modules/csharp.cxx \
5554
Modules/d.cxx \

Source/Modules/swigmain.cxx

+1-2
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@
2828
extern "C" {
2929
Language *swig_allegrocl(void);
3030
Language *swig_cffi(void);
31-
Language *swig_chicken(void);
3231
Language *swig_csharp(void);
3332
Language *swig_d(void);
3433
Language *swig_go(void);
@@ -57,7 +56,7 @@ extern "C" {
5756

5857
static TargetLanguageModule modules[] = {
5958
{"-allegrocl", swig_allegrocl, "ALLEGROCL", Supported},
60-
{"-chicken", swig_chicken, "CHICKEN", Supported},
59+
{"-chicken", NULL, "CHICKEN", Disabled},
6160
{"-clisp", NULL, "CLISP", Disabled},
6261
{"-cffi", swig_cffi, "CFFI", Supported},
6362
{"-csharp", swig_csharp, "C#", Supported},

0 commit comments

Comments
 (0)