aws-samples / aws-media-services-vod-automation

Sample code and CloudFormation scripts for automating Video on Demand workflows on AWS
Apache License 2.0
136 stars 112 forks source link

Issues Building Under Amazon Linux 2? #16

Open ninjada opened 4 years ago

ninjada commented 4 years ago

Hello, I'm trying to migrate an existing working lambda function with mediainfo compiled for node8 under amazon linux 1 using your included steps (https://github.com/aws-samples/aws-media-services-vod-automation/tree/master/MediaConvert-JobProgressMetrics#build-a-deployment-package-from-the-github-repo), across to a lambda function under node10. I'm trying to do so under amazon linux 2. However, I'm seeing errors at a few steps.

If i build with --enable-static, i get an error with libcurl.so.4 cannot open shared object.

I've also tried adding --enable-staticlibs but this flag is giving me further error on build:

Reader_libcurl.cpp:(.text+0x97e1): undefined reference to `curl_easy_getinfo' collect2: error: ld returned 1 exit status make: *** [mediainfo] Error 1 Problem while compiling MediaInfo (CLI)

Are there additional steps required to successfully build under amazon linux 2 for node10, as it seems to run into errors with this missing library?

aburkleaux-amazon commented 4 years ago

Try using the Dockerfile in this project. It is another python sample, but it is building MediaInfo on amazon linux 2: https://github.com/iandow/mediainfo_aws_lambda/blob/master/Dockerfile

This tutorial should be updated to use a lambda layer as well.