美文网首页QT
[QT macdeployqt]dyld: Symbol not

[QT macdeployqt]dyld: Symbol not

作者: _小老虎_ | 来源:发表于2020-06-18 01:23 被阅读0次

    Qt项目在Mac下编译macdeployqt出现的问题如下:

    dyld: Symbol not found: __cg_jpeg_resync_to_restart
    Referenced from: /System/Library/Frameworks/ImageIO.framework/Versions/A/ImageIO
    Expected in: /usr/local/lib/libJPEG.dylib
    in /System/Library/Frameworks/ImageIO.framework/Versions/A/ImageIO
    
    dyld: Symbol not found: __cg_TIFFClientOpen
    Referenced from: /System/Library/Frameworks/ImageIO.framework/Versions/A/ImageIO
    Expected in: /usr/local/lib/libTIFF.dylib
    in /System/Library/Frameworks/ImageIO.framework/Versions/A/ImageIO
    
    dyld: Symbol not found: __cg_png_create_info_struct
    Referenced from: /System/Library/Frameworks/ImageIO.framework/Versions/A/ImageIO
    Expected in: /usr/local/lib/libPng.dylib
    in /System/Library/Frameworks/ImageIO.framework/Versions/A/ImageIO
    

    解决方案链接:https://community.alfresco.com/thread/185711-symbol-not-found-cgjpegresynctorestart-leopard-1058

    命令行如下

    cd /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources
    

    记得备份 $sudo

    cp /usr/local/lib/libJPEG.dylib /usr/local/lib/libJPEG.dylib.bak
    ln -s libJPEG.dylib /usr/local/lib/libJPEG.dylib
    cp /usr/local/lib/libGIF.dylib /usr/local/lib/libGIF.dylib.bak
    ln -s libJPEG.dylib /usr/local/lib/libGIF.dylib
    cp /usr/local/lib/libTIFF.dylib /usr/local/lib/libTIFF.dylib.bak
    ln -s libJPEG.dylib /usr/local/lib/libTIFF.dylib
    cp /usr/local/lib/libPng.dylib /usr/local/lib/libPng.dylib.bak
    ln -s libJPEG.dylib /usr/local/lib/libPng.dylib
    

    参考:https://blog.csdn.net/huamin1990/article/details/88694791

    相关文章

      网友评论

        本文标题:[QT macdeployqt]dyld: Symbol not

        本文链接:https://www.haomeiwen.com/subject/vhhyxktx.html