magick-rust
magick-rust copied to clipboard
Does not build out of the box on Ubuntu 18.04
Building magick-rust out of the box on ubuntu/bionic64 is not working. Seems like several problems at once:
- Does not find the LLVM/clang include directory (
/usr/lib/llvm-6.0/lib/clang/6.0.0/include
). - Does not seem to invoke
pkg-config
correctly (or at all) to get ImageMagick flags.
The build is now successful, but the tests fail in the call to MagickReadImage()
. Need to add debugging around that call to see what error is generated by MagickWand. Strange that this does not happen with the docker image or macOS, only (so far) Ubuntu.
Commands for a successful build:
$ sudo apt-get update
$ sudo apt-get install build-essential pkg-config llvm-dev libclang-dev clang
$ curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
$ source $HOME/.cargo/env
$ curl https://download.imagemagick.org/ImageMagick/download/ImageMagick.tar.gz | tar xz
$ cd ImageMagick-7.0.10-58/
$ ./configure --with-magick-plus-plus=no --with-perl=no
$ make
$ sudo make install
$ cd ../magick-rust/
$ cargo build
$ cargo test