summaryrefslogtreecommitdiffstats
path: root/config/cmake_ext_mod
diff options
context:
space:
mode:
Diffstat (limited to 'config/cmake_ext_mod')
-rw-r--r--config/cmake_ext_mod/ConfigureChecks.cmake9
-rw-r--r--config/cmake_ext_mod/HDFCXXTests.cpp46
-rw-r--r--config/cmake_ext_mod/HDFUseCXX.cmake99
3 files changed, 0 insertions, 154 deletions
diff --git a/config/cmake_ext_mod/ConfigureChecks.cmake b/config/cmake_ext_mod/ConfigureChecks.cmake
index 366cf16..0a27692 100644
--- a/config/cmake_ext_mod/ConfigureChecks.cmake
+++ b/config/cmake_ext_mod/ConfigureChecks.cmake
@@ -123,19 +123,10 @@ CHECK_INCLUDE_FILE_CONCAT ("stddef.h" ${HDF_PREFIX}_HAVE_STDDEF_H)
CHECK_INCLUDE_FILE_CONCAT ("unistd.h" ${HDF_PREFIX}_HAVE_UNISTD_H)
# Windows
-CHECK_INCLUDE_FILE_CONCAT ("io.h" ${HDF_PREFIX}_HAVE_IO_H)
if (NOT CYGWIN)
CHECK_INCLUDE_FILE_CONCAT ("winsock2.h" ${HDF_PREFIX}_HAVE_WINSOCK2_H)
endif ()
-if (CMAKE_SYSTEM_NAME MATCHES "OSF")
- CHECK_INCLUDE_FILE_CONCAT ("sys/sysinfo.h" ${HDF_PREFIX}_HAVE_SYS_SYSINFO_H)
- CHECK_INCLUDE_FILE_CONCAT ("sys/proc.h" ${HDF_PREFIX}_HAVE_SYS_PROC_H)
-else ()
- set (${HDF_PREFIX}_HAVE_SYS_SYSINFO_H "" CACHE INTERNAL "" FORCE)
- set (${HDF_PREFIX}_HAVE_SYS_PROC_H "" CACHE INTERNAL "" FORCE)
-endif ()
-
CHECK_INCLUDE_FILE_CONCAT ("globus/common.h" ${HDF_PREFIX}_HAVE_GLOBUS_COMMON_H)
CHECK_INCLUDE_FILE_CONCAT ("pdb.h" ${HDF_PREFIX}_HAVE_PDB_H)
CHECK_INCLUDE_FILE_CONCAT ("pthread.h" ${HDF_PREFIX}_HAVE_PTHREAD_H)
diff --git a/config/cmake_ext_mod/HDFCXXTests.cpp b/config/cmake_ext_mod/HDFCXXTests.cpp
deleted file mode 100644
index 08ccb34..0000000
--- a/config/cmake_ext_mod/HDFCXXTests.cpp
+++ /dev/null
@@ -1,46 +0,0 @@
-/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
- * Copyright by The HDF Group. *
- * All rights reserved. *
- * *
- * This file is part of HDF5. The full HDF5 copyright notice, including *
- * terms governing use, modification, and redistribution, is contained in *
- * the COPYING file, which can be found at the root of the source code *
- * distribution tree, or in https://www.hdfgroup.org/licenses. *
- * If you do not have access to either file, you may request a copy from *
- * help@hdfgroup.org. *
- * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-
-#ifdef CXX_HAVE_OFFSETOF
-
-#include <stdio.h>
-#include <stddef.h>
-
-#ifdef FC_DUMMY_MAIN
-#ifndef FC_DUMMY_MAIN_EQ_F77
-# ifdef __cplusplus
-extern "C"
-# endif
-int FC_DUMMY_MAIN()
-{ return 1;}
-#endif
-#endif
-int
-main ()
-{
-
- struct index_st
- {
- unsigned char type;
- unsigned char num;
- unsigned int len;
- };
- typedef struct index_st index_t;
- int x,y;
- x = offsetof(struct index_st, len);
- y = offsetof(index_t, num)
-
- ;
- return 0;
-}
-
-#endif
diff --git a/config/cmake_ext_mod/HDFUseCXX.cmake b/config/cmake_ext_mod/HDFUseCXX.cmake
deleted file mode 100644
index 423f74a..0000000
--- a/config/cmake_ext_mod/HDFUseCXX.cmake
+++ /dev/null
@@ -1,99 +0,0 @@
-#
-# Copyright by The HDF Group.
-# All rights reserved.
-#
-# This file is part of HDF5. The full HDF5 copyright notice, including
-# terms governing use, modification, and redistribution, is contained in
-# the COPYING file, which can be found at the root of the source code
-# distribution tree, or in https://www.hdfgroup.org/licenses.
-# If you do not have access to either file, you may request a copy from
-# help@hdfgroup.org.
-#
-#
-# This file provides functions for C++ support.
-#
-#-------------------------------------------------------------------------------
-ENABLE_LANGUAGE (CXX)
-set (HDF_PREFIX "H5")
-
-#-------------------------------------------------------------------------------
-# Fix CXX flags if we are compiling staticly on Windows using
-# Windows_MT.cmake from config/cmake/UserMacros
-#-------------------------------------------------------------------------------
-if (BUILD_STATIC_CRT_LIBS)
- TARGET_STATIC_CRT_FLAGS ()
-endif ()
-
-#-----------------------------------------------------------------------------
-# Configure Checks which require CXX compilation must go in here
-# not in the main ConfigureChecks.cmake files, because if the user has
-# no CXX compiler, problems arise.
-#-----------------------------------------------------------------------------
-include (CheckIncludeFileCXX)
-include (TestForSTDNamespace)
-
-# For other CXX specific tests, use this MACRO.
-macro (HDF_CXX_FUNCTION_TEST OTHER_TEST)
- if (NOT DEFINED ${OTHER_TEST})
- set (MACRO_CHECK_FUNCTION_DEFINITIONS "-D${OTHER_TEST} ${CMAKE_REQUIRED_FLAGS}")
- set (OTHER_TEST_ADD_LIBRARIES)
- if (HDF5_REQUIRED_LIBRARIES)
- set (OTHER_TEST_ADD_LIBRARIES "-DLINK_LIBRARIES:STRING=${HDF5_REQUIRED_LIBRARIES}")
- endif ()
-
- foreach (def
- HAVE_SYS_TIME_H
- HAVE_UNISTD_H
- HAVE_SYS_TYPES_H
- HAVE_SYS_SOCKET_H
- HAVE_SYS_FILE_H
- )
- if ("${${HDF_PREFIX}_${def}}")
- set (MACRO_CHECK_FUNCTION_DEFINITIONS "${MACRO_CHECK_FUNCTION_DEFINITIONS} -D${def}")
- endif ()
- endforeach ()
-
- if (LARGEFILE)
- set (MACRO_CHECK_FUNCTION_DEFINITIONS
- "${MACRO_CHECK_FUNCTION_DEFINITIONS} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE"
- )
- endif ()
-
- if (CMAKE_VERSION VERSION_GREATER_EQUAL "3.15.0")
- message (TRACE "Performing ${OTHER_TEST}")
- endif ()
- TRY_COMPILE (${OTHER_TEST}
- ${CMAKE_BINARY_DIR}
- ${HDF_RESOURCES_EXT_DIR}/HDFCXXTests.cpp
- CMAKE_FLAGS -DCOMPILE_DEFINITIONS:STRING=${MACRO_CHECK_FUNCTION_DEFINITIONS}
- "${OTHER_TEST_ADD_LIBRARIES}"
- OUTPUT_VARIABLE OUTPUT
- )
- if (${OTHER_TEST} EQUAL 0)
- set (${OTHER_TEST} 1 CACHE INTERNAL "CXX test ${FUNCTION}")
- if (CMAKE_VERSION VERSION_GREATER_EQUAL "3.15.0")
- message (VERBOSE "Performing CXX Test ${OTHER_TEST} - Success")
- endif ()
- else ()
- if (CMAKE_VERSION VERSION_GREATER_EQUAL "3.15.0")
- message (VERBOSE "Performing CXX Test ${OTHER_TEST} - Failed")
- endif ()
- set (${OTHER_TEST} "" CACHE INTERNAL "CXX test ${FUNCTION}")
- file (APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log
- "Performing CXX Test ${OTHER_TEST} failed with the following output:\n"
- "${OUTPUT}\n"
- )
- endif ()
- endif ()
-endmacro ()
-
-#-----------------------------------------------------------------------------
-# Check a bunch of cxx functions
-#-----------------------------------------------------------------------------
-if (CMAKE_CXX_COMPILER_LOADED)
- foreach (cxx_test
- CXX_HAVE_OFFSETOF
- )
- HDF_CXX_FUNCTION_TEST (${cxx_test})
- endforeach ()
-endif ()