Skip to content

Instantly share code, notes, and snippets.

@jiamo
Last active May 25, 2018 17:39
Show Gist options
  • Save jiamo/1cb759fa9d3bceaa2146cae08e47ee52 to your computer and use it in GitHub Desktop.
Save jiamo/1cb759fa9d3bceaa2146cae08e47ee52 to your computer and use it in GitHub Desktop.
Build mediainfo ELF for aws lambda
cd ~/
apt-get install git automake autoconf libtool pkg-config make g++ zlib1g-dev libcurl4-gnutls-dev
git clone https://github.com/MediaArea/ZenLib.git
git checkout v0.4.37
cd ZenLib/Project/GNU/Library
./autogen.sh
./configure --enable-static
make -j4
cd ~/
git clone https://github.com/openssl/openssl.git
git checkout OpenSSL_1_0_2i
./Configure linux-generic64
make -j4
cd ~/
wget https://curl.haxx.se/download/curl-7.50.0.tar.gz
tar -zxvf curl-7.50.0.tar.gz
cd curl-7.50.0/
./configure --enable-static --disable-share
make -j4
cd ~/
git clone https://github.com/MediaArea/MediaInfoLib.git
cd MediaInfoLib/Project/GNU/Library/
./autogen.sh
./configure --enable-static --with-libcurl=../../../../curl-7.50.0/
make -j4
cd ~/
git clone https://github.com/MediaArea/MediaInfo.git
git checkout v18.05
git clone
cd MediaInfo/Project/GNU/CLI
./autogen.sh
./configure --enable-staticlibs
make -j4
make install
g++ -static -O2 -DUNICODE -DUNICODE -DSIZE_T_IS_LONG -o mediainfo CLI_Main.o CommandLine_Parser.o Help.o Core.o ../../../../MediaInfoLib/Project/GNU/Library/.libs/libmediainfo.a -lz ../../../../ZenLib/Project/GNU/Library/.libs/libzen.a ../../../../curl-7.50.0/lib/.libs/libcurl.a ../../../../openssl/libssl.a ../../../../openssl/libcrypto.a -lpthread -lstdc++ -pthread -Wl,-rpath -Wl,../../../../ZenLib/Project/GNU/Library/.libs -Wl,-rpath -Wl,../../../../curl-7.50.0/lib/.libs -Wl,-rpath -Wl,../../../../openssl -ldl
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment