<commit_before># Create a setup.py file.
CONFIGURE_FILE(${VTK_SOURCE_DIR}/Wrapping/Python/setup.py.in 
               ${VTK_BINARY_DIR}/Wrapping/Python/setup.py)

# create the VTK/Python  executable
CONFIGURE_FILE(${VTK_SOURCE_DIR}/Wrapping/Python/vtkPythonAppInitConfigure.h.in
               ${VTK_BINARY_DIR}/Wrapping/Python/vtkPythonAppInitConfigure.h)
ADD_EXECUTABLE(vtkpython vtkPythonAppInit.cxx)

# Choose a python library to link.
IF (APPLE)
  OPTION(VTK_HAVE_FRAMEWORK_PYTHON "The system has Python installed by default (Mac OSX 10.2)" OFF)
  IF (VTK_HAVE_FRAMEWORK_PYTHON)
    TARGET_LINK_LIBRARIES (vtkpython "-framework Python")
  ELSE (VTK_HAVE_FRAMEWORK_PYTHON)
    TARGET_LINK_LIBRARIES (vtkpython ${PYTHON_LIBRARY})
  ENDIF (VTK_HAVE_FRAMEWORK_PYTHON)
ELSE (APPLE)
  IF(WIN32)
    TARGET_LINK_LIBRARIES (vtkpython
                           debug ${PYTHON_DEBUG_LIBRARY}
                           optimized ${PYTHON_LIBRARY})
  ELSE(WIN32)
    TARGET_LINK_LIBRARIES (vtkpython ${PYTHON_LIBRARY})
  ENDIF(WIN32)
ENDIF (APPLE)

# Link against all the kit wrappers.
TARGET_LINK_LIBRARIES (vtkpython
  vtkCommonPython
  vtkFilteringPython
  vtkIOPython
  vtkGraphicsPython
  vtkImagingPython
)

IF (VTK_USE_RENDERING)
  TARGET_LINK_LIBRARIES(vtkpython vtkRenderingPython)
ENDIF (VTK_USE_RENDERING)

IF (VTK_USE_PATENTED)
  TARGET_LINK_LIBRARIES(vtkpython vtkPatentedPython)
ENDIF (VTK_USE_PATENTED)

IF (VTK_USE_HYBRID)
  TARGET_LINK_LIBRARIES(vtkpython vtkHybridPython)
ENDIF (VTK_USE_HYBRID)

IF (VTK_USE_PARALLEL)
  TARGET_LINK_LIBRARIES(vtkpython vtkParallelPython)
ENDIF (VTK_USE_PARALLEL)

# Create the pvtkpython Python wrapper executable with MPI support.
IF (VTK_USE_PARALLEL)
  IF (VTK_USE_MPI)
    ADD_EXECUTABLE(pvtkpython vtkParaPythonAppInit.cxx)

    TARGET_LINK_LIBRARIES (pvtkpython
      vtkCommonPython
      vtkFilteringPython
      vtkIOPython
      vtkGraphicsPython
      vtkImagingPython
      vtkParallelPython
    )

    IF (VTK_USE_PATENTED)
      TARGET_LINK_LIBRARIES(pvtkpython vtkPatentedPython)
    ENDIF (VTK_USE_PATENTED)
    IF (VTK_USE_HYBRID)
      TARGET_LINK_LIBRARIES(pvtkpython vtkHybridPython)
    ENDIF (VTK_USE_HYBRID)

    INSTALL_TARGETS(/bin pvtkpython)
  ENDIF (VTK_USE_MPI)
ENDIF (VTK_USE_PARALLEL)

FIND_LIBRARY(UTIL_LIBRARY
  NAMES util
  PATHS /usr/lib
)
IF (UTIL_LIBRARY)
  TARGET_LINK_LIBRARIES(vtkpython ${UTIL_LIBRARY})
  TARGET_LINK_LIBRARIES(pvtkpython ${UTIL_LIBRARY})
ENDIF (UTIL_LIBRARY) 
INSTALL_TARGETS(/bin vtkpython)    

# Allow the user to customize their build with some local options
#
INCLUDE (${VTK_BINARY_DIR}/Wrapping/Tcl/LocalUserOptions.cmake OPTIONAL)
INCLUDE (${VTK_SOURCE_DIR}/Wrapping/Tcl/LocalUserOptions.cmake OPTIONAL)<commit_msg>Add library to pvtkpython only if pvtkpython exists<commit_after># Create a setup.py file.
CONFIGURE_FILE(${VTK_SOURCE_DIR}/Wrapping/Python/setup.py.in 
               ${VTK_BINARY_DIR}/Wrapping/Python/setup.py)

# create the VTK/Python  executable
CONFIGURE_FILE(${VTK_SOURCE_DIR}/Wrapping/Python/vtkPythonAppInitConfigure.h.in
               ${VTK_BINARY_DIR}/Wrapping/Python/vtkPythonAppInitConfigure.h)
ADD_EXECUTABLE(vtkpython vtkPythonAppInit.cxx)

# Choose a python library to link.
IF (APPLE)
  OPTION(VTK_HAVE_FRAMEWORK_PYTHON "The system has Python installed by default (Mac OSX 10.2)" OFF)
  IF (VTK_HAVE_FRAMEWORK_PYTHON)
    TARGET_LINK_LIBRARIES (vtkpython "-framework Python")
  ELSE (VTK_HAVE_FRAMEWORK_PYTHON)
    TARGET_LINK_LIBRARIES (vtkpython ${PYTHON_LIBRARY})
  ENDIF (VTK_HAVE_FRAMEWORK_PYTHON)
ELSE (APPLE)
  IF(WIN32)
    TARGET_LINK_LIBRARIES (vtkpython
                           debug ${PYTHON_DEBUG_LIBRARY}
                           optimized ${PYTHON_LIBRARY})
  ELSE(WIN32)
    TARGET_LINK_LIBRARIES (vtkpython ${PYTHON_LIBRARY})
  ENDIF(WIN32)
ENDIF (APPLE)

# Link against all the kit wrappers.
TARGET_LINK_LIBRARIES (vtkpython
  vtkCommonPython
  vtkFilteringPython
  vtkIOPython
  vtkGraphicsPython
  vtkImagingPython
)

IF (VTK_USE_RENDERING)
  TARGET_LINK_LIBRARIES(vtkpython vtkRenderingPython)
ENDIF (VTK_USE_RENDERING)

IF (VTK_USE_PATENTED)
  TARGET_LINK_LIBRARIES(vtkpython vtkPatentedPython)
ENDIF (VTK_USE_PATENTED)

IF (VTK_USE_HYBRID)
  TARGET_LINK_LIBRARIES(vtkpython vtkHybridPython)
ENDIF (VTK_USE_HYBRID)

IF (VTK_USE_PARALLEL)
  TARGET_LINK_LIBRARIES(vtkpython vtkParallelPython)
ENDIF (VTK_USE_PARALLEL)

# Create the pvtkpython Python wrapper executable with MPI support.
IF (VTK_USE_PARALLEL)
  IF (VTK_USE_MPI)
    ADD_EXECUTABLE(pvtkpython vtkParaPythonAppInit.cxx)

    TARGET_LINK_LIBRARIES (pvtkpython
      vtkCommonPython
      vtkFilteringPython
      vtkIOPython
      vtkGraphicsPython
      vtkImagingPython
      vtkParallelPython
    )

    IF (VTK_USE_PATENTED)
      TARGET_LINK_LIBRARIES(pvtkpython vtkPatentedPython)
    ENDIF (VTK_USE_PATENTED)
    IF (VTK_USE_HYBRID)
      TARGET_LINK_LIBRARIES(pvtkpython vtkHybridPython)
    ENDIF (VTK_USE_HYBRID)

    INSTALL_TARGETS(/bin pvtkpython)
  ENDIF (VTK_USE_MPI)
ENDIF (VTK_USE_PARALLEL)

FIND_LIBRARY(UTIL_LIBRARY
  NAMES util
  PATHS /usr/lib
)
IF (UTIL_LIBRARY)
  TARGET_LINK_LIBRARIES(vtkpython ${UTIL_LIBRARY})
  IF (VTK_USE_PARALLEL)
    IF (VTK_USE_MPI)
      TARGET_LINK_LIBRARIES(pvtkpython ${UTIL_LIBRARY})
    ENDIF (VTK_USE_MPI)
  ENDIF (VTK_USE_PARALLEL)
ENDIF (UTIL_LIBRARY) 
INSTALL_TARGETS(/bin vtkpython)    

# Allow the user to customize their build with some local options
#
INCLUDE (${VTK_BINARY_DIR}/Wrapping/Tcl/LocalUserOptions.cmake OPTIONAL)
INCLUDE (${VTK_SOURCE_DIR}/Wrapping/Tcl/LocalUserOptions.cmake OPTIONAL)
{'fraction_non_alphanumeric': 0.07084078711985689, 'fraction_numerical': 0.0032200357781753132, 'mean_word_length': 4.799792531120332, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6514522', 'n_tokens_mistral': 2366, 'n_tokens_neox': 2174, 'n_words': 362}