Coder Social home page Coder Social logo

Comments (9)

thecfguy avatar thecfguy commented on July 24, 2024 6

Here is compiled one if someone do not want to go with process of building up Imagemagick.zip

Thanks @trungegd @jugglingcats @gojko

from imagemagick-aws-lambda-2.

trungegd avatar trungegd commented on July 24, 2024 5

to keep the layer size small, the default includes a minimal set of libraries, for most common image formats. it does not include freetype, so you'll need to change the makefile and add it in. You can probably copy the necessary parts from the https://github.com/serverlesspub/rsvg-convert-aws-lambda-binary layer makefile, since it bundles freetype

@gojko Thanks so much. It works fine for me.
Here is my Makefile_ImageMagick file:

Makefile_ImageMagick.txt

from imagemagick-aws-lambda-2.

jugglingcats avatar jugglingcats commented on July 24, 2024 1

@lambtron or @trungegd would you be willing to post your layer so others can use it? I need freetype and I'm sure others would benefit.

from imagemagick-aws-lambda-2.

jugglingcats avatar jugglingcats commented on July 24, 2024 1

@trungegd am trying to use your make file (on Ubuntu with Docker installed) but get the following error:

/var/task/build/fontconfig-2.13.0/missing: line 81: gperf: command not found
WARNING: 'gperf' is missing on your system.
         You might have modified some files without having the proper
         tools for further handling them.  Check the 'README' file, it
         often tells you about the needed prerequisites for installing
         this package.  You may also peek at any GNU archive site, in
         case some other package contains this missing 'gperf' program.

Tried installing on the host Ubuntu but same error so I assume this is missing in Docker...?

UPDATE 1: used workaround in #10 and build completes now -- getting there!

UPDATE 2: have successfully built and deployed layer.zip using makefile from @trungegd but still no text :(

UPDATE 3: added a ttf to layer and used full path in gm.font and 🎉!

from imagemagick-aws-lambda-2.

edjames avatar edjames commented on July 24, 2024 1

Hi.

Sorry to open old wounds, but I'm having real problems trying to get freetype included in my build.
I've tried the following:

Unfortunately I keep getting the same error in all cases:

MiniMagick::Invalid: `/opt/bin/magick identify /tmp/mini_magick20201021-9-od9shb.pdf` failed with error:
/opt/bin/magick: /lib64/libc.so.6: version `GLIBC_2.25' not found (required by /opt/bin/magick)

Not sure if the host system makes a difference when compiling here (given it's done in a Docker container) but for what it's worth I'm on a Mac running Catalina 10.15.7

Can anyone help please?

from imagemagick-aws-lambda-2.

gojko avatar gojko commented on July 24, 2024

to keep the layer size small, the default includes a minimal set of libraries, for most common image formats. it does not include freetype, so you'll need to change the makefile and add it in. You can probably copy the necessary parts from the https://github.com/serverlesspub/rsvg-convert-aws-lambda-binary layer makefile, since it bundles freetype

from imagemagick-aws-lambda-2.

lambtron avatar lambtron commented on July 24, 2024

thank you @gojko for putting this together. makes using imagemagick and lambda very easy.

i also need freetype in my lambda, and putting it in the layer makes the most sense.

i added the freetype download and installation in the make file, but i'm getting this error when i try make all and make deploy:

MagickCore/annotate.c:89:10: fatal error: ft2build.h: No such file or directory
 #include <ft2build.h>
          ^~~~~~~~~~~~
compilation terminated.

looks like the path isn't set properly for freetype, but i'm at a loss as to what it should be. looks like my configure variable is set correctly.

here is my version:
https://github.com/lambtron/imagemagick-aws-lambda-2/blob/master/Makefile_ImageMagick#L116

and the commit so you can see the changes: lambtron@bbb76bb

any thoughts as to what might be causing this issue?

thanks again!!

from imagemagick-aws-lambda-2.

lambtron avatar lambtron commented on July 24, 2024

i got it to work. i copied the entire section from the rsvg including harfbuzz. THANK YOU!

from imagemagick-aws-lambda-2.

trungegd avatar trungegd commented on July 24, 2024

@jugglingcats I used to see this error but then I added gperf installation to make file and it worked.

init:
yum install -y gcc gcc-c++ cmake3 intltool flex bison shared-mime-info gperf

from imagemagick-aws-lambda-2.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.