Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Installing in Azure Synapse + SparkR: Error "fatal error: Magick++.h: No such file or directory compilation terminated." #183

Open
AmosBunde opened this issue Feb 24, 2023 · 1 comment

Comments

@AmosBunde
Copy link

AmosBunde commented Feb 24, 2023

start install.packages pkgs=summarytools time:2023-02-24 09:20:52
Installing package into ‘/nfs4/R/user-lib/application_1677225147371_0001’
(as ‘lib’ is unspecified)
also installing the dependency ‘magick’

trying URL 'https://cloud.r-project.org/src/contrib/magick_2.7.3.tar.gz'
Content type 'application/x-gzip' length 4813163 bytes (4.6 MB)

downloaded 4.6 MB

trying URL 'https://cloud.r-project.org/src/contrib/summarytools_1.0.1.tar.gz'
Content type 'application/x-gzip' length 1263885 bytes (1.2 MB)

downloaded 1.2 MB

Loading required package: usethis

  • installing source package ‘magick’ ...
    ** package ‘magick’ successfully unpacked and MD5 sums checked
    ** using staged installation
    Package Magick++ was not found in the pkg-config search path.
    Perhaps you should add the directory containing `Magick++.pc'
    to the PKG_CONFIG_PATH environment variable
    No package 'Magick++' found
    Using PKG_CFLAGS=
    Using PKG_LIBS=-lMagick++-6.Q16
    --------------------------- [ANTICONF] --------------------------------
    Configuration failed to find the Magick++ library. Try installing:
  • deb: libmagick++-dev (Debian, Ubuntu)
  • rpm: ImageMagick-c++-devel (Fedora, CentOS, RHEL)
  • csw: imagemagick_dev (Solaris)
  • brew imagemagick@6 (MacOS)
    For Ubuntu versions Trusty (14.04) and Xenial (16.04) use our PPA:
    sudo add-apt-repository -y ppa:cran/imagemagick
    sudo apt-get update
    sudo apt-get install -y libmagick++-dev
    If Magick++ is already installed, check that 'pkg-config' is in your
    PATH and PKG_CONFIG_PATH contains a Magick++.pc file. If pkg-config
    is unavailable you can set INCLUDE_DIR and LIB_DIR manually via:
    R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
    -------------------------- [ERROR MESSAGE] ---------------------------
    :1:10: fatal error: Magick++.h: No such file or directory
    compilation terminated.

ERROR: configuration failed for package ‘magick’

  • removing ‘/nfs4/R/user-lib/application_1677225147371_0001/magick’
    Loading required package: usethis
    ERROR: dependency ‘magick’ is not available for package ‘summarytools’
  • removing ‘/nfs4/R/user-lib/application_1677225147371_0001/summarytools’

The downloaded source packages are in
‘/tmp/RtmpGV1cQ6/downloaded_packages’
[notebook] install.packages pkgs=summarytools cost [5s] time:2023-02-24 09:20:57
[1] "Error in library(summarytools): there is no package called ‘summarytools’\n----LIVY_END_OF_ERROR----"
Warning messages:
1: In func(...) :
installation of package ‘magick’ had non-zero exit status
2: In func(...) :
installation of package ‘summarytools’ had non-zero exit status

"Error in loadNamespace(x): there is no package called ‘summarytools’"

@dcomtois
Copy link
Owner

dcomtois commented Aug 20, 2023

Not sure if this has been resolved... If not, a solution to make it Azure-compatible (if there is no way to allow Magick, that is), would be to have an alternate version of summarytools which doesn't require Magick -- which is not absolutely necessary; it's just that without it, there is a little bit of blur created when resizing graphs.

Further development is not on the radar on my end, at least for a while, but if anyone wants to have a go at it, help is always welcome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants