diff options
author | V3n3RiX <venerix@koprulu.sector> | 2022-03-20 00:40:44 +0000 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2022-03-20 00:40:44 +0000 |
commit | 4cbcc855382a06088e2f016f62cafdbcb7e40665 (patch) | |
tree | 356496503d52354aa6d9f2d36126302fed5f3a73 /sci-chemistry/openbabel/files | |
parent | fcc5224904648a8e6eb528d7603154160a20022f (diff) |
gentoo resync : 20.03.2022
Diffstat (limited to 'sci-chemistry/openbabel/files')
-rw-r--r-- | sci-chemistry/openbabel/files/openbabel-2.4.1-gcc10.patch | 62 | ||||
-rw-r--r-- | sci-chemistry/openbabel/files/openbabel-python.cmake | 104 |
2 files changed, 0 insertions, 166 deletions
diff --git a/sci-chemistry/openbabel/files/openbabel-2.4.1-gcc10.patch b/sci-chemistry/openbabel/files/openbabel-2.4.1-gcc10.patch deleted file mode 100644 index 88d8c2add64a..000000000000 --- a/sci-chemistry/openbabel/files/openbabel-2.4.1-gcc10.patch +++ /dev/null @@ -1,62 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 2e66dd1..ef4f16b 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -1,16 +1,11 @@ - # Please ensure that any changes remain compliant with 2.4.8. - if(NOT EMBED_OPENBABEL) -- cmake_minimum_required(VERSION 2.4.8) -+ cmake_minimum_required(VERSION 2.4.10) - endif() - - project(openbabel) - set(CMAKE_MODULE_PATH ${openbabel_SOURCE_DIR}/cmake/modules) - --# Allow loose loop constructs, i.e. no matching in if/else/endif or loops. --# Note that this is true by default in CMake 2.6.0, but we currently only --# require CMake 2.4.8 - remove this when the CMake requirement is bumped. --set(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS 1) -- - if(COMMAND cmake_policy) - cmake_policy(SET CMP0003 NEW) - cmake_policy(SET CMP0005 OLD) # add_definitions need updating to set to NEW -@@ -20,7 +15,6 @@ if(COMMAND cmake_policy) - endif() - - include (CheckCXXCompilerFlag) --include (MacroEnsureVersion) - - # Version numbering - should be bumped for each release - # Note that for "beta" releases, we should start at x.90.0 -- we've -@@ -238,16 +232,21 @@ check_type_size(clock_t CLOCK_T) - - # Get the GCC version - from KDE4 cmake files - if(CMAKE_COMPILER_IS_GNUCXX) -- exec_program(${CMAKE_C_COMPILER} ARGS --version OUTPUT_VARIABLE _gcc_version_info) -- string(REGEX MATCH "[345]\\.[0-9]\\.[0-9]" _gcc_version "${_gcc_version_info}") -- # gcc on mac just reports: "gcc (GCC) 3.3 20030304 ..." without the -- # patch level, handle this here: -- if (NOT _gcc_version) -- string (REGEX REPLACE ".*\\(GCC\\).* ([34]\\.[0-9]) .*" "\\1.0" _gcc_version "${_gcc_version_info}") -- endif () -- macro_ensure_version("4.0.0" "${_gcc_version}" GCC_IS_NEWER_THAN_4_0) -- macro_ensure_version("4.1.0" "${_gcc_version}" GCC_IS_NEWER_THAN_4_1) -- macro_ensure_version("4.2.0" "${_gcc_version}" GCC_IS_NEWER_THAN_4_2) -+ if(NOT(${CMAKE_CXX_COMPILER_VERSION} VERSION_LESS 4.0.0)) -+ set(GCC_IS_NEWER_THAN_4_0 TRUE) -+ else() -+ set(GCC_IS_NEWER_THAN_4_0 FALSE) -+ endif() -+ if(NOT(${CMAKE_CXX_COMPILER_VERSION} VERSION_LESS 4.1.0)) -+ set(GCC_IS_NEWER_THAN_4_1 TRUE) -+ else() -+ set(GCC_IS_NEWER_THAN_4_1 FALSE) -+ endif() -+ if(NOT(${CMAKE_CXX_COMPILER_VERSION} VERSION_LESS 4.2.0)) -+ set(GCC_IS_NEWER_THAN_4_2 TRUE) -+ else() -+ set(GCC_IS_NEWER_THAN_4_2 FALSE) -+ endif() - endif() - - if(UNIX) diff --git a/sci-chemistry/openbabel/files/openbabel-python.cmake b/sci-chemistry/openbabel/files/openbabel-python.cmake deleted file mode 100644 index 425b4656a9d2..000000000000 --- a/sci-chemistry/openbabel/files/openbabel-python.cmake +++ /dev/null @@ -1,104 +0,0 @@ -# The following is a cmake fragment taken from scripts/CMakeLists.txt and -# edited for Gentoo python multibuild compatibility. - -if (PYTHON_BINDINGS) - # Tags should be edited to reflect the active python implementation - set(EPYTHON @@EPYTHON@@) - set(PYTHON_INCUDE_DIR @@PYTHON_INCUDE_DIR@@) - set(PYTHON_LIBS @@PYTHON_LIBS@@) - set(PYTHON_SITEDIR @@PYTHON_SITEDIR@@) - - include_directories(${PYTHON_INCUDE_DIR}) - - add_custom_command( - OUTPUT ${CMAKE_SOURCE_DIR}/scripts/${EPYTHON}/openbabel-python.cpp ${CMAKE_SOURCE_DIR}/scripts/${EPYTHON}/openbabel.py - COMMAND ${SWIG_EXECUTABLE} -python -c++ -small -O -templatereduce -naturalvar -I${CMAKE_SOURCE_DIR}/include -I${CMAKE_BINARY_DIR}/include -o ${CMAKE_SOURCE_DIR}/scripts/${EPYTHON}/openbabel-python.cpp ${eigen_define} -outdir ${CMAKE_SOURCE_DIR}/scripts/${EPYTHON} ${CMAKE_SOURCE_DIR}/scripts/openbabel-python.i - MAIN_DEPENDENCY openbabel-python.i - VERBATIM - ) - - configure_file(${CMAKE_SOURCE_DIR}/scripts/python/openbabel/__init__.py.in - ${CMAKE_BINARY_DIR}/scripts/${EPYTHON}/openbabel/__init__.py) - - add_library(bindings_python_${EPYTHON} MODULE ${CMAKE_SOURCE_DIR}/scripts/${EPYTHON}/openbabel-python.cpp) - target_link_libraries(bindings_python_${EPYTHON} ${PYTHON_LIBS} ${BABEL_LIBRARY}) - - set_target_properties(bindings_python_${EPYTHON} - PROPERTIES - OUTPUT_NAME _openbabel - LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/scripts/${EPYTHON}/openbabel - PREFIX "" - SUFFIX .so ) - - add_dependencies(bindings_python_${EPYTHON} openbabel) - - install(TARGETS bindings_python_${EPYTHON} - LIBRARY DESTINATION ${PYTHON_SITEDIR}/openbabel - COMPONENT bindings_python) - install(FILES ${CMAKE_BINARY_DIR}/scripts/${EPYTHON}/openbabel/__init__.py - DESTINATION ${PYTHON_SITEDIR}/openbabel - COMPONENT bindings_python) - install(FILES ${CMAKE_SOURCE_DIR}/scripts/${EPYTHON}/openbabel.py - DESTINATION ${PYTHON_SITEDIR}/openbabel - COMPONENT bindings_python) - install(FILES ${CMAKE_SOURCE_DIR}/scripts/python/openbabel/pybel.py - DESTINATION ${PYTHON_SITEDIR}/openbabel - COMPONENT bindings_python) - - if (ENABLE_TESTS) - # Make sure all module files are together in the same directory for testing - add_custom_command(TARGET bindings_python_${EPYTHON} POST_BUILD - COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/scripts/${EPYTHON}/openbabel.py ${CMAKE_BINARY_DIR}/scripts/${EPYTHON}/openbabel/ - COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/scripts/python/openbabel/pybel.py ${CMAKE_BINARY_DIR}/scripts/${EPYTHON}/openbabel/) - set(TEST_SOURCE_DIR ${CMAKE_SOURCE_DIR}/test) - # define TESTDATADIR for tests that need input files - add_definitions(-DTESTDATADIR="${TEST_SOURCE_DIR}/files/") - # define FORMATDIR for location of format plugin binaries - set(FORMATDIR "${CMAKE_BINARY_DIR}/lib${LIB_SUFFIX}/") - add_definitions(-DFORMATDIR="${FORMATDIR}/") - include_directories(${TEST_SOURCE_DIR}) - - # The macro is modified from cmake/modules/UsePythonTest.cmake - MACRO(ADD_PYTHON_TEST TESTNAME FILENAME) - GET_SOURCE_FILE_PROPERTY(loc ${FILENAME} LOCATION) - STRING(REGEX REPLACE ";" " " wo_semicolumn "${ARGN}") - FILE(WRITE ${CMAKE_BINARY_DIR}/test/${TESTNAME}.cmake -" - MESSAGE(\"${PYTHONPATH}\") - EXECUTE_PROCESS( - COMMAND ${EPYTHON} ${loc} ${wo_semicolumn} - RESULT_VARIABLE import_res - OUTPUT_VARIABLE import_output - ERROR_VARIABLE import_output - ) - - # Pass the output back to ctest - IF(import_output) - MESSAGE(\${import_output}) - ENDIF(import_output) - IF(import_res) - MESSAGE(SEND_ERROR \${import_res}) - ENDIF(import_res) -" - ) - ADD_TEST(${TESTNAME} ${CMAKE_COMMAND} -P ${CMAKE_BINARY_DIR}/test/${TESTNAME}.cmake) - ENDMACRO(ADD_PYTHON_TEST) - - set(pybindtests - bindings - _pybel - example - obconv_writers - cdjsonformat - pcjsonformat - roundtrip - ) - foreach(pybindtest ${pybindtests}) - ADD_PYTHON_TEST(pybindtest_${pybindtest}_${EPYTHON} ${TEST_SOURCE_DIR}/test${pybindtest}.py) - set_tests_properties(pybindtest_${pybindtest}_${EPYTHON} PROPERTIES - ENVIRONMENT "PYTHONPATH=${CMAKE_BINARY_DIR}/scripts/${EPYTHON}:${CMAKE_BINARY_DIR}/lib${LIB_SUFFIX};LD_LIBRARY_PATH=${CMAKE_BINARY_DIR}/scripts/${EPYTHON}:${CMAKE_BINARY_DIR}/lib${LIB_SUFFIX}:\$ENV{LD_LIBRARY_PATH};BABEL_LIBDIR=${CMAKE_BINARY_DIR}/lib${LIB_SUFFIX}/;BABEL_DATADIR=${CMAKE_SOURCE_DIR}/data" - FAIL_REGULAR_EXPRESSION "ERROR;FAIL;Test failed" - ) - endforeach(pybindtest ${pybindtests}) - endif (ENABLE_TESTS) -endif(PYTHON_BINDINGS) |