Changeset: 17f08e50bd42 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/17f08e50bd42
Removed Files:
        cmake/Modules/FindLibR.cmake
Modified Files:
        README.rst
        clients/mapiclient/mhelp.c
        cmake/monetdb-functions.cmake
        debian/copyright
        sql/server/sql_parser.y
Branch: default
Log Message:

More changes for removing embedded R support.


diffs (truncated from 330 to 300 lines):

diff --git a/README.rst b/README.rst
--- a/README.rst
+++ b/README.rst
@@ -105,7 +105,7 @@ The following packages are optional:
 ``cfitsio-devel``, ``gdal-devel``, ``geos-devel``, ``libasan``,
 ``libcmocka-devel``, ``libcurl-devel``, ``libxml2-devel``,
 ``netcdf-devel``, ``proj-devel``, ``python3-devel``, ``python3-numpy``,
-``R-core-devel``, ``unixODBC-devel``, ``valgrind-devel``.
+``unixODBC-devel``, ``valgrind-devel``.
 
 On Ubuntu and Debian the following packages are required:
 ``bison``, ``cmake``, ``gcc``, ``pkg-config``, ``python3``.
@@ -118,7 +118,7 @@ The following packages are optional:
 ``libasan5``, ``libcfitsio-dev``, ``libcmocka-dev``,
 ``libcurl4-gnutls-dev``, ``libgdal-dev``, ``libgeos-dev``,
 ``libnetcdf-dev``, ``libproj-dev``, ``libxml2-dev``, ``python3-dev``,
-``python3-numpy``, ``r-base-dev``, ``unixodbc-dev``, ``valgrind``.
+``python3-numpy``, ``unixodbc-dev``, ``valgrind``.
 
 ``cmake`` must be at least version 3.12, ``python`` must be at least
 version 3.5.
diff --git a/clients/mapiclient/mhelp.c b/clients/mapiclient/mhelp.c
--- a/clients/mapiclient/mhelp.c
+++ b/clients/mapiclient/mhelp.c
@@ -148,7 +148,7 @@ SQLhelp sqlhelp1[] = {
         "See also 
https://www.monetdb.org/documentation/user-guide/sql-manual/data-loading/loader-functions/"},
        {"CREATE AGGREGATE",
         "Create a user-defined aggregate function. The body of the aggregate 
function\n"
-        "can also be defined in other programming languages such as Python, R, 
C or CPP.",
+        "can also be defined in other programming languages such as Python.",
         "CREATE [ OR REPLACE ] AGGREGATE [ FUNCTION ] qname '(' { '*' | [ 
param [',' ...]] } ')'\n"
         "    RETURNS function_return_data_type\n"
         "    EXTERNAL NAME ident '.' ident\n"
@@ -166,7 +166,7 @@ SQLhelp sqlhelp1[] = {
         "See also 
https://www.monetdb.org/documentation/user-guide/sql-programming/function-definitions/"},
        {"CREATE FUNCTION",
         "Create a user-defined function (UDF). The body of the function can be 
defined in\n"
-        " PL/SQL or programming languages such as Python, R, C or CPP when 
embedded on the server.",
+        " PL/SQL or programming languages such as Python when embedded on the 
server.",
         "CREATE [ OR REPLACE ] FUNCTION qname '(' { '*' | [ param [',' ...]] } 
')'\n"
         "    RETURNS function_return_data_type\n"
         "    BEGIN [ ATOMIC ] statement [ ';' ...] END\n"
@@ -784,7 +784,7 @@ SQLhelp sqlhelp2[] = {
         NULL},
        {"language_keyword",
         NULL,
-        "C | CPP | R | PYTHON | PYTHON3",
+        "PYTHON | PYTHON3",
         NULL,
         NULL},
        {"limit_clause",
diff --git a/cmake/Modules/FindLibR.cmake b/cmake/Modules/FindLibR.cmake
deleted file mode 100644
--- a/cmake/Modules/FindLibR.cmake
+++ /dev/null
@@ -1,237 +0,0 @@
-#
-# FindLibR.cmake
-#
-# Copyright (C) 2009-19 by RStudio, Inc.
-#
-# This program is licensed to you under the terms of version 3 of the
-# GNU Affero General Public License. This program is distributed WITHOUT
-# ANY EXPRESS OR IMPLIED WARRANTY, INCLUDING THOSE OF NON-INFRINGEMENT,
-# MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Please refer to the
-# AGPL (http://www.gnu.org/licenses/agpl-3.0.txt) for more details.
-#
-#
-
-# LIBR_FOUND
-# LIBR_HOME
-# LIBR_INCLUDE_DIRS
-# LIBR_DOC_DIR
-# LIBR_LIBRARIES
-
-# detection for OSX (look for R framework)
-if(APPLE)
-
-   find_library(LIBR_LIBRARIES R)
-   
-   if(LIBR_LIBRARIES MATCHES ".*\\.framework")
-      set(LIBR_HOME "${LIBR_LIBRARIES}/Resources" CACHE PATH "R home 
directory")
-      set(LIBR_INCLUDE_DIRS "${LIBR_HOME}/include" CACHE PATH "R include 
directory")
-      set(LIBR_DOC_DIR "${LIBR_HOME}/doc" CACHE PATH "R doc directory")
-      set(LIBR_EXECUTABLE "${LIBR_HOME}/bin/R" CACHE PATH "R executable")
-   else()
-      get_filename_component(_LIBR_LIBRARIES "${LIBR_LIBRARIES}" REALPATH)
-      get_filename_component(_LIBR_LIBRARIES_DIR "${_LIBR_LIBRARIES}" PATH)
-      set(LIBR_EXECUTABLE "${_LIBR_LIBRARIES_DIR}/../bin/R")
-      execute_process(
-         COMMAND ${LIBR_EXECUTABLE} "--slave" "--vanilla" "-e" "cat(R.home())"
-                   OUTPUT_VARIABLE LIBR_HOME
-      )
-      set(LIBR_HOME ${LIBR_HOME} CACHE PATH "R home directory")
-      set(LIBR_INCLUDE_DIRS "${LIBR_HOME}/include" CACHE PATH "R include 
directory")
-      set(LIBR_DOC_DIR "${LIBR_HOME}/doc" CACHE PATH "R doc directory")
-      set(LIBR_LIB_DIR "${LIBR_HOME}/lib" CACHE PATH "R lib directory")
-   endif()
-
-# detection for UNIX & Win32
-else()
-
-   # Find R executable and paths (UNIX)
-   if(UNIX)
-
-      # find executable
-      find_program(LIBR_EXECUTABLE R)
-      if(LIBR_EXECUTABLE-NOTFOUND)
-         message(STATUS "Unable to locate R executable")
-      endif()
-
-      # ask R for the home path
-      if(NOT LIBR_HOME)
-         execute_process(
-            COMMAND ${LIBR_EXECUTABLE} "--slave" "--vanilla" "-e" 
"cat(R.home())"
-                      OUTPUT_VARIABLE LIBR_HOME
-         )
-         if(LIBR_HOME)
-           set(LIBR_HOME ${LIBR_HOME} CACHE PATH "R home directory")
-         endif()
-      endif()
-
-      # ask R for the include dir
-      if(NOT LIBR_INCLUDE_DIRS)
-         execute_process(
-            COMMAND ${LIBR_EXECUTABLE} "--slave" "--no-save" "-e" 
"cat(R.home('include'))"
-            OUTPUT_VARIABLE LIBR_INCLUDE_DIRS
-         )
-         if(LIBR_INCLUDE_DIRS)
-           set(LIBR_INCLUDE_DIRS ${LIBR_INCLUDE_DIRS} CACHE PATH "R include 
directory")
-         endif()
-      endif()
-
-      # ask R for the doc dir
-      if(NOT LIBR_DOC_DIR)
-         execute_process(
-            COMMAND ${LIBR_EXECUTABLE} "--slave" "--no-save" "-e" 
"cat(R.home('doc'))"
-            OUTPUT_VARIABLE LIBR_DOC_DIR
-         )
-         if(LIBR_DOC_DIR)
-           set(LIBR_DOC_DIR ${LIBR_DOC_DIR} CACHE PATH "R doc directory")
-         endif()
-      endif()
-
-      # ask R for the lib dir
-      if(NOT LIBR_LIB_DIR)
-         execute_process(
-            COMMAND ${LIBR_EXECUTABLE} "--slave" "--no-save" "-e" 
"cat(R.home('lib'))"
-            OUTPUT_VARIABLE LIBR_LIB_DIR
-         )
-      endif()
-
-   # Find R executable and paths (Win32)
-   else()
-
-      # find the home path
-      if(NOT LIBR_HOME)
-
-         # read home from the registry
-         get_filename_component(LIBR_HOME
-            "[HKEY_LOCAL_MACHINE\\SOFTWARE\\R-core\\R;InstallPath]"
-            ABSOLUTE CACHE)
-
-         # print message if not found
-         if(NOT LIBR_HOME)
-            message(STATUS "Unable to locate R home (not written to registry)")
-         endif()
-
-      endif()
-
-      # set other R paths based on home path
-      set(LIBR_INCLUDE_DIRS "${LIBR_HOME}/include" CACHE PATH "R include 
directory")
-      set(LIBR_DOC_DIR "${LIBR_HOME}/doc" CACHE PATH "R doc directory")
-
-      # set library hint path based on whether we are doing a special session 
32 build
-      if(LIBR_FIND_WINDOWS_32BIT)
-         set(LIBR_ARCH "i386")
-         set(LIBRARY_ARCH_HINT_PATH "${LIBR_HOME}/bin/i386")
-      else()
-         set(LIBR_ARCH "x64")
-         set(LIBRARY_ARCH_HINT_PATH "${LIBR_HOME}/bin/x64")
-      endif()
-
-      # call dll2lib.R to ensure export files are generated
-      execute_process(
-          
-         COMMAND
-            "${LIBR_HOME}/bin/${LIBR_ARCH}/Rscript.exe"
-            "dll2lib.R"
-            "${CMAKE_C_COMPILER}"
-            
-         WORKING_DIRECTORY
-            "${CMAKE_CURRENT_SOURCE_DIR}/tools"
-         
-         OUTPUT_VARIABLE
-            LIBR_DLL2LIB_STDOUT
-
-         ERROR_VARIABLE
-            LIBR_DLL2LIB_STDERR
-         
-         RESULT_VARIABLE
-            LIBR_DLL2LIB_RESULT)
-
-      if(NOT LIBR_DLL2LIB_RESULT EQUAL 0)
-         message(STATUS "${LIBR_DLL2LIB_STDOUT}")
-         message(STATUS "${LIBR_DLL2LIB_STDERR}")
-      endif()
-
-   endif()
-
-   # look for the R executable
-   find_program(LIBR_EXECUTABLE R
-                HINTS ${LIBRARY_ARCH_HINT_PATH} ${LIBR_HOME}/bin)
-   if(LIBR_EXECUTABLE-NOTFOUND)
-      message(STATUS "Unable to locate R executable")
-   endif()
-
-   # look for the core R library
-   find_library(LIBR_CORE_LIBRARY NAMES R
-                HINTS ${LIBR_LIB_DIR} ${LIBRARY_ARCH_HINT_PATH} 
${LIBR_HOME}/bin)
-   if(LIBR_CORE_LIBRARY)
-      set(LIBR_LIBRARIES ${LIBR_CORE_LIBRARY})
-   else()
-      message(STATUS "Could not find libR shared library.")
-   endif()
-
-   if(WIN32)
-      # look for lapack
-      find_library(LIBR_LAPACK_LIBRARY NAMES Rlapack
-                   HINTS ${LIBR_LIB_DIR} ${LIBRARY_ARCH_HINT_PATH} 
${LIBR_HOME}/bin)
-      if(LIBR_LAPACK_LIBRARY)
-         set(LIBR_LIBRARIES ${LIBR_LIBRARIES} ${LIBR_LAPACK_LIBRARY})
-         if(UNIX)
-            set(LIBR_LIBRARIES ${LIBR_LIBRARIES} gfortran)
-         endif()
-      endif()
-
-      # look for blas
-      find_library(LIBR_BLAS_LIBRARY NAMES Rblas
-                   HINTS ${LIBR_LIB_DIR} ${LIBRARY_ARCH_HINT_PATH} 
${LIBR_HOME}/bin)
-      if(LIBR_BLAS_LIBRARY)
-         set(LIBR_LIBRARIES ${LIBR_LIBRARIES} ${LIBR_BLAS_LIBRARY})
-      endif()
-
-      # look for rgraphapp
-      find_library(LIBR_GRAPHAPP_LIBRARY NAMES Rgraphapp
-                   HINTS ${LIBR_LIB_DIR} ${LIBRARY_ARCH_HINT_PATH} 
${LIBR_HOME}/bin)
-      if(LIBR_GRAPHAPP_LIBRARY)
-         set(LIBR_LIBRARIES ${LIBR_LIBRARIES} ${LIBR_GRAPHAPP_LIBRARY})
-      endif()
-   endif()
-
-   # cache LIBR_LIBRARIES
-   if(LIBR_LIBRARIES)
-      set(LIBR_LIBRARIES ${LIBR_LIBRARIES} CACHE PATH "R runtime libraries")
-   endif()
-
-endif()
-
-# define find requirements
-include(FindPackageHandleStandardArgs)
-find_package_handle_standard_args(LibR DEFAULT_MSG
-   LIBR_HOME
-   LIBR_EXECUTABLE
-   LIBR_INCLUDE_DIRS
-   LIBR_LIBRARIES
-   LIBR_DOC_DIR
-)
-
-if(LIBR_FOUND)
-   message(STATUS "Found R: ${LIBR_HOME}")
-   get_filename_component(LIBR_BIN_DIR "${LIBR_EXECUTABLE}" PATH CACHE)
-endif()
-
-# mark low-level variables from FIND_* calls as advanced
-mark_as_advanced(
-   LIBR_CORE_LIBRARY
-   LIBR_LAPACK_LIBRARY
-   LIBR_BLAS_LIBRARY
-)
-
-if(LIBR_FOUND)
-  if(NOT TARGET LibR::LibR AND (EXISTS "${LIBR_LIBRARIES}"))
-    add_library(LibR::LibR UNKNOWN IMPORTED)
-    set_target_properties(LibR::LibR
-      PROPERTIES
-      INTERFACE_INCLUDE_DIRECTORIES "${LIBR_INCLUDE_DIRS}")
-    set_target_properties(LibR::LibR
-        PROPERTIES
-        IMPORTED_LINK_INTERFACE_LANGUAGES "C"
-       IMPORTED_LOCATION "${LIBR_LIBRARIES}")
-  endif()
-endif()
diff --git a/cmake/monetdb-functions.cmake b/cmake/monetdb-functions.cmake
--- a/cmake/monetdb-functions.cmake
+++ b/cmake/monetdb-functions.cmake
@@ -103,7 +103,6 @@ function(monetdb_cmake_summary)
   message(STATUS "Kvm library: ${KVM_FOUND}")
   message(STATUS "Netcdf library: ${NETCDF_FOUND}")
   message(STATUS "Readline library: ${READLINE_FOUND}")
_______________________________________________
checkin-list mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to