Ubuntu 14.04:
我已下载并安装了最新的imagemagick源,并使用以下选项进行配置:
root@usve59445:~/im/ImageMagick-6.9.3-7# ./configure --enable-shared --with-png=yes
但是,安装后,我的内置委托列表中有零个项目:
root@usve59445:~/im/ImageMagick-6.9.3-7# identify -version
Version: ImageMagick 6.9.3-7 Q16 x86_64 2016-03-14
Copyright: Copyright (C) 1999-2016 ImageMagick Studio LLC License:
Features: Cipher DPC OpenMP
Delegates (built-in):
我收到的问题是在执行convert
命令时“未找到格式PNG的委托” 。
我从以下位置安装了libpng委托:http : //www.imagemagick.org/download/delegates/
将libpng1621.tar.gz提取到其自己的文件夹中,然后:ran configure,make,make install(无错误消息)
现在,当我尝试重新编译imagemagick时,它仍然显示“正在检查PNG ...否”,并且--with-png值具有“ no”(即使我使用--with-png = yes对其进行了配置)。
不确定我在做什么错吗?
尝试使用以下方法重新编译IM:
root @ usve59445:〜/ im / ImageMagick-6.9.3-7#./configure --enable-shared = yes --with-png = yes LDFLAGS ='-L / usr / local / lib'LIBS = -lpng16
(我认为我使用的是正确的LDFLAGS,但不确定)
root@usve59445:~/im/libpng-1.6.21# libpng16-config --L_opts
-L/usr/local/lib
root@usve59445:~/im/libpng-1.6.21# libpng16-config --libs
-lpng16
root@usve59445:~/im/libpng-1.6.21# locate libpng
/lib/x86_64-linux-gnu/libpng12.so.0
/lib/x86_64-linux-gnu/libpng12.so.0.46.0
/usr/bin/libpng-config
/usr/bin/libpng12-config
/usr/include/libpng
/usr/include/libpng12
/usr/include/libpng12/png.h
/usr/include/libpng12/pngconf.h
/usr/lib/x86_64-linux-gnu/libpng.a
/usr/lib/x86_64-linux-gnu/libpng.so
/usr/lib/x86_64-linux-gnu/libpng.so.3
/usr/lib/x86_64-linux-gnu/libpng12.a
/usr/lib/x86_64-linux-gnu/libpng12.so
/usr/lib/x86_64-linux-gnu/libpng12.so.0
/usr/lib/x86_64-linux-gnu/pkgconfig/libpng.pc
/usr/lib/x86_64-linux-gnu/pkgconfig/libpng12.pc
/usr/local/bin/libpng-config
/usr/local/bin/libpng16-config
/usr/local/include/libpng16
/usr/local/include/libpng16/png.h
/usr/local/include/libpng16/pngconf.h
/usr/local/include/libpng16/pnglibconf.h
/usr/local/lib/libpng.a
/usr/local/lib/libpng.la
/usr/local/lib/libpng.so
/usr/local/lib/libpng16.a
/usr/local/lib/libpng16.la
/usr/local/lib/libpng16.so
/usr/local/lib/libpng16.so.16
/usr/local/lib/libpng16.so.16.21.0
/usr/local/lib/pkgconfig/libpng.pc
/usr/local/lib/pkgconfig/libpng16.pc
/usr/local/share/man/man3/libpng.3
/usr/local/share/man/man3/libpngpf.3
/usr/share/doc/libpng12-0
/usr/share/doc/libpng12-dev
/usr/share/doc/libpng3
/usr/share/doc/libpng12-0/ANNOUNCE
/usr/share/doc/libpng12-0/KNOWNBUG
/usr/share/doc/libpng12-0/README.Debian
/usr/share/doc/libpng12-0/README.gz
/usr/share/doc/libpng12-0/TODO
/usr/share/doc/libpng12-0/changelog.Debian.gz
/usr/share/doc/libpng12-0/copyright
/usr/share/doc/libpng12-0/libpng-1.2.46.txt.gz
/usr/share/doc/libpng12-dev/changelog.Debian.gz
/usr/share/doc/libpng12-dev/copyright
/usr/share/doc/libpng12-dev/examples
/usr/share/doc/libpng12-dev/examples/example.c.gz
/usr/share/doc/libpng12-dev/examples/pngtest.c.gz
/usr/share/doc/libpng12-dev/examples/pngtest.png
/usr/share/doc-base/libpng12
/usr/share/man/man1/libpng-config.1.gz
/usr/share/man/man1/libpng12-config.1.gz
/usr/share/man/man3/libpng.3.gz
/var/cache/apt/archives/libpng12-0_1.2.46-3ubuntu4.2_amd64.deb
/var/cache/apt/archives/libpng12-dev_1.2.46-3ubuntu4.2_amd64.deb
/var/cache/apt/archives/libpng3_1.2.46-3ubuntu4.2_amd64.deb
/var/lib/dpkg/info/libpng12-0:amd64.list
/var/lib/dpkg/info/libpng12-0:amd64.md5sums
/var/lib/dpkg/info/libpng12-0:amd64.postinst
/var/lib/dpkg/info/libpng12-0:amd64.postrm
/var/lib/dpkg/info/libpng12-0:amd64.shlibs
/var/lib/dpkg/info/libpng12-dev.list
/var/lib/dpkg/info/libpng12-dev.md5sums
/var/lib/dpkg/info/libpng3:amd64.list
也通过以下方式安装了libpng:apt-get install libpng12-0-仍在检查PNG相同...否(未找到委托)。通过apt-get安装了libjpeg62,重新编译了IM,它成功显示在代理列表中-只是PNG不起作用!
—
gvanto
您必须安装
—
muru
-dev
软件包(libpng12-dev
也许是),以使用库构建软件。
嗨,先生,谢谢已经做了,不能正常工作。像这个家伙一样尝试使用--x-libraries选项:stackoverflow.com/questions/28237800/… 但是'locate libpng'给了我很多不同的位置(在上面的问题中补充),不确定我应该使用哪个位置?(尝试过一些,似乎都没有将PNG编译到IM中)。
—
gvanto
现在花了很多时间没有运气。愿意为有(工作)建议的任何人发送50美元的
—
贝宝