From: Andres Noetzli Date: Fri, 3 Jul 2020 00:14:22 +0000 (-0700) Subject: Remove SWIG bindings (#4683) X-Git-Tag: cvc5-1.0.0~3149 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=2faf908ed88c798a25b4881e3ce3026dc139bca3;p=cvc5.git Remove SWIG bindings (#4683) This commit removes support for SWIG bindings for the legacy API. The bindings were already broken by 19054b3b1d427e662d30d4322df2b2f2361353da and we are not planning on using SWIG for the Java API for the new API. --- diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 35154828f..da97a2cd2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,7 +16,7 @@ jobs: include: - name: production - config: production --language-bindings=java --lfsc --python-bindings + config: production --all-bindings --lfsc cache-key: production python-bindings: true check-examples: true diff --git a/CMakeLists.txt b/CMakeLists.txt index 1b6027b46..688a7c1ea 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -165,12 +165,9 @@ set(SYMFPU_DIR "" CACHE STRING "Set SymFPU install directory") # Prepend binaries with prefix on make install set(PROGRAM_PREFIX "" CACHE STRING "Program prefix on make install") -# Supported SWIG language bindings -option(BUILD_SWIG_BINDINGS_JAVA "Build Java bindings with SWIG") -option(BUILD_SWIG_BINDINGS_PYTHON "Build Python bindings with SWIG") - # Supprted language bindings based on new C++ API option(BUILD_BINDINGS_PYTHON "Build Python bindings based on new C++ API ") +option(BUILD_BINDINGS_JAVA "Build Java bindings based on new C++ API ") #-----------------------------------------------------------------------------# # Internal cmake variables @@ -542,14 +539,15 @@ add_subdirectory(doc) add_subdirectory(src) add_subdirectory(test) -if(BUILD_SWIG_BINDINGS_JAVA OR BUILD_SWIG_BINDINGS_PYTHON) - add_subdirectory(src/bindings) -endif() - if(BUILD_BINDINGS_PYTHON) add_subdirectory(src/api/python) endif() +if(BUILD_BINDINGS_JAVA) + message(FATAL_ERROR + "Java bindings for the new API are not implemented yet.") +endif() + #-----------------------------------------------------------------------------# # Package configuration # @@ -624,9 +622,8 @@ print_config("Valgrind :" ENABLE_VALGRIND) message("") print_config("Shared libs :" ENABLE_SHARED) print_config("Static binary :" ENABLE_STATIC_BINARY) -print_config("Java SWIG bindings :" BUILD_SWIG_BINDINGS_JAVA) -print_config("Python SWIG bindings :" BUILD_SWIG_BINDINGS_PYTHON) print_config("Python bindings :" BUILD_BINDINGS_PYTHON) +print_config("Java bindings :" BUILD_BINDINGS_JAVA) print_config("Python2 :" USE_PYTHON2) print_config("Python3 :" USE_PYTHON3) message("") diff --git a/INSTALL.md b/INSTALL.md index bf3a20ed2..ae22e2d71 100644 --- a/INSTALL.md +++ b/INSTALL.md @@ -129,11 +129,6 @@ dependency. with --check-proofs. It can be installed using the `contrib/get-lfsc` script. Configure CVC4 with `configure.sh --lfsc` to build with this dependency. -### SWIG >= 3.0.x (Simplified Wrapper and Interface Generator) - -SWIG 3.0.x (and a JDK) is necessary to build the Java API. -See [Language Bindings](#language-bindings) below for build instructions. - ### CLN >= v1.3 (Class Library for Numbers) [CLN](http://www.ginac.de/CLN) @@ -202,17 +197,13 @@ See [Testing CVC4](#Testing-CVC4) below for more details. ## Language bindings -CVC4 provides a complete and flexible C++ API (see `examples/api` for examples). -It further provides Java (see `examples/SimpleVC.java` and `examples/api/java`) -and Python (see `examples/SimpleVC.py`) API bindings. +CVC4 provides a complete and flexible C++ API (see `examples/api` for +examples). It further provides Java (see `examples/SimpleVC.java` and +`examples/api/java`) and Python (see `examples/api/python`) API bindings. -Configure CVC4 with `configure.sh --language-bindings=[java,python,all]` -to build with language bindings. -Note that this requires SWIG >= 3.0.x. +Configure CVC4 with `configure.sh ---bindings` to build with language +bindings for ``. -In principle, since we use SWIG to generate the native Java and PythonAPI, -we could support other languages as well. However, using CVC4 from other -languages is not supported, nor expected to work, at this time. If you're interested in helping to develop, maintain, and test a language binding, please contact one of the project leaders. @@ -328,4 +319,3 @@ available on the system. Override with `ARGS=-jN`. Use `-jN` for parallel **building** with `N` threads. - diff --git a/NEWS b/NEWS index 827361f54..e453e7dbb 100644 --- a/NEWS +++ b/NEWS @@ -13,6 +13,7 @@ Improvements: Changes: * SyGuS: Removed support for SyGuS-IF 1.0. +* Removed Java and Python bindings for the legacy API Changes since 1.7 ================= diff --git a/configure.sh b/configure.sh index 21a444082..988b7a392 100755 --- a/configure.sh +++ b/configure.sh @@ -46,15 +46,12 @@ The following flags enable optional features (disable with --no-