cmake 3.27 fails to extract archive on Parallels network drive

Discussion in 'General Questions' started by Vladlen, Aug 21, 2023.

  1. Vladlen

    Vladlen Bit poster

    Messages:
    3
    I faced the problem with cmake script, when it is ran on Parallels network drive - cmake fails to extract archive with files added as link. This script work in the same virtual machine on drive C: (NTFS), but fails on Z:. Also script works if run under native Mac OS X shell.
    Could it be the bug in Parallels filesystem?

    My configuration:
    Windows 10, 64 bits. run as virtual machine on Mac Os X Monterey 12.0.1 under Parallels version 17.
    Drive C: NTFS filesystem
    Drive Z: PrlSF filesystem - network filesystem mapped by Parallels from MacOsX partition.
    cmake 3.27.

    Example of failed cmake script CMakeLists.txt :

    cmake_minimum_required(VERSION 3.27)
    project(test_archive_exctract)
    set(ARCHIVE_WITH_LINK_URL https://mirror.msys2.org/msys/x86_64/binutils-2.40-1-x86_64.pkg.tar.zst)
    set(ARCHIVE_WITH_LINK_PATH ${CMAKE_BINARY_DIR}/binutils-2.40-1-x86_64.pkg.tar.zst)
    set(ARCHIVE_WITH_LINK_PATH_OUT ${CMAKE_BINARY_DIR}/binutils)
    file(DOWNLOAD ${ARCHIVE_WITH_LINK_URL} ${ARCHIVE_WITH_LINK_PATH} INACTIVITY_TIMEOUT 10)
    file(ARCHIVE_EXTRACT INPUT "${ARCHIVE_WITH_LINK_PATH}" DESTINATION "${ARCHIVE_WITH_LINK_PATH_OUT}" )

    If archive contains the file, added as link, the command file(ARCHIVE_EXTRACT ...) failed to extract this file and remaining archive (ld.exe in this example) on network drive. Extract to NTFS drive (and native Unix drive under Unix script) work OK.

    The example script is the extract from ICU (famous internationalisation and localisation library) installation package on Windows. binutils file is compiler tools necessary to build ICU data.
     

Share This Page