JavaEar 专注于收集分享传播有价值的技术资料

[libpng]无法链接符号链接include / libpng16 / png.h ([libpng]could not link symlink include/libpng16/png.h)

When I install imageMagick,it told me must link libpng before install imageMagick.

Then I link the libpng,it occur this issue

brew link libpng Linking /usr/local/Cellar/libpng/1.6.17... Error: Could not symlink include/libpng16/png.h Target /usr/local/include/libpng16/png.h already exists. You may want to remove it: rm '/usr/local/include/libpng16/png.h'

To force the link and overwrite all conflicting files:

brew link --overwrite libpng

To list all files that would be deleted:

brew link --overwrite --dry-run libpng

1个回答

    最佳答案

  1. 英文原文

    solved it.

    sudo chmod -R 777 /usr/local/include/libpng16

    brew link --overwrite libpng

    brew install imagemagick


    中文翻译

    解决了它。

    sudo chmod -R 777 / usr / local / include / libpng16

    brew link --overwrite libpng

    brew install imagemagick

    solved it.

    sudo chmod -R 777 /usr/local/include/libpng16

    brew link --overwrite libpng

    brew install imagemagick

    解决了它。

    sudo chmod -R 777 / usr / local / include / libpng16

    brew link --overwrite libpng

    brew install imagemagick