Page 1 of 1
Copying over binaries which shared libraries are needed?
Posted: 2018-07-06T07:31:02-07:00
by mjmj
I'm doing a multistage docker build where I build the latest imagemagick and all it's build dependencies for ubuntu 14.04 (there are a lot) and I want to copy over just the 'convert' binary and whatever shared libraries it needs to work so I don't have all the build dep cruft on my production system. Copying over the binary works but what can I do about the shared libraries?
Code: Select all
root@b3ff35c88dce:/# convert -version
convert: error while loading shared libraries: libMagickCore-7.Q16HDRI.so.6: cannot open shared object file: No such file or directory
Re: Copying over binaries which shared libraries are needed?
Posted: 2018-07-06T11:20:59-07:00
by mjmj
What I'm trying to do is:
A) Install in imagemagick in modular way on Ubuntu 14.04. I only need magick to support jpg & png resizing and transparency options. But there are a lot of flags to understand for a newbie.
or B) uninstall all the build-dep that aren't needed after I install from source.
Re: Copying over binaries which shared libraries are needed?
Posted: 2018-07-06T13:14:42-07:00
by snibgo
How are you building IM? With "./configure", "make" etc, I suppose. If you want a minimum build, your ./configure options should exclude anything you don't want. Have you explored those?
Re: Copying over binaries which shared libraries are needed?
Posted: 2018-07-06T14:45:33-07:00
by mjmj
Yeah I'm still trying to understand all the options. I really want just a png parser, resize and transparency, nothing else. As a binary if possible. I see '--disable-installed' option saying 'less secure' but with no details as to what security I'm giving up.
So far I'm using
Code: Select all
./configure --prefix /usr --disable-installed --without-tiff --without-wmf --without-lzma --without-lcms --without-jbig --without-freetype -without-dps --without-bzlib
then
Code: Select all
make && checkinstall -D --install=yes --fstrans=no --pakdir "imagemagick_build" \
--pkgname imagemagick --backup=no --deldoc=yes --deldesc=yes --delspec=yes --default \
--pkgversion "7.0.8" && make distclean && sudo ldconfig
Not sure about freetype or bzlib yet. Just a lot for a newcomer to understand, thanks for your advice.
Re: Copying over binaries which shared libraries are needed?
Posted: 2018-07-06T15:10:02-07:00
by snibgo
For v7.0.7-28 on Windows 8.1, "./configure --help" shows about 25 "--without" options, eg fftw, jpeg, raw and pango.
I suggest you try "--without" everything except PNG, and see if IM still does what you need.