-
-
Save patrickmslatteryvt/c8b0044dcca6e03c7ab9eb41fc3aea53 to your computer and use it in GitHub Desktop.
Compile of Haproxy using LibreSSL static. See https://github.com/codingtony/docker-build-haproxy for how to use with a Docker Image
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash -e | |
DIR=$PWD | |
yum groupinstall -y "Development Tools" | |
yum install -y make gcc perl wget zlib-devel | |
#Compile static version of libressl | |
export STATICLIBSSL=/tmp/staticlibssl | |
LIBRESSL=libressl-2.4.2 | |
HAPROXY=haproxy-1.6.9 | |
PCRE=pcre-8.39 | |
wget http://ftp.openbsd.org/pub/OpenBSD/LibreSSL/${LIBRESSL}.tar.gz | |
tar xvzf ${LIBRESSL}.tar.gz | |
cd ${LIBRESSL} | |
./configure --prefix=$STATICLIBSSL --enable-shared=no | |
make && make install | |
cd ${DIR} | |
export STATICLIBPCRE=/tmp/staticlibpcre | |
wget ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/${PCRE}.tar.gz | |
tar xvzf ${PCRE}.tar.gz | |
cd ${PCRE} | |
./configure --prefix=$STATICLIBPCRE --enable-shared=no --enable-utf8 --enable-jit | |
make && make install | |
cd ${DIR} | |
wget http://www.haproxy.org/download/1.6/src/${HAPROXY}.tar.gz | |
tar xvzf ${HAPROXY}.tar.gz | |
cd ${HAPROXY} | |
make TARGET=linux2628 USE_PCRE_JIT=1 USE_STATIC_PCRE=1 USE_OPENSSL=1 PCRE_LIB=$STATICLIBPCRE/lib PCRE_INC=$STATICLIBPCRE/include SSL_INC=$STATICLIBSSL/include SSL_LIB=$STATICLIBSSL/lib ADDLIB="-ldl -lrt" USE_ZLIB=1 | |
make install | |
cd ${DIR} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment