Server-Root/libraries/build_mysqlconnector.sh

17 lines
656 B
Bash
Raw Normal View History

2018-08-08 17:42:18 -04:00
cd mysqlconnector
HEADER=$(cat cdk/foundation/connection_openssl.cc)
if ! [ "${HEADER:0:34}" == "#if !defined(SSL_ERROR_WANT_ASYNC)" ]; then
echo "Creating new one!"
echo "#if !defined(SSL_ERROR_WANT_ASYNC)
2018-08-08 17:46:22 -04:00
#define SSL_ERROR_WANT_ASYNC 0xFFEEDDCC
2018-08-08 17:42:18 -04:00
#endif
#if !defined(SSL_ERROR_WANT_ASYNC_JOB)
2018-08-08 17:46:22 -04:00
#define SSL_ERROR_WANT_ASYNC_JOB 0xFFEECCDD
2018-08-08 17:42:18 -04:00
#endif
`cat cdk/foundation/connection_openssl.cc`" > cdk/foundation/connection_openssl.cc
fi
cd build
2018-08-08 17:18:57 -04:00
cmake .. -DCMAKE_CXX_FLAGS="-static-libgcc -static-libstdc++ -I../../boringssl/include/" -DWITH_JDBC=ON -DWITH_SSL="`pwd`/../../boringssl/" -DOPENSSL_ROOT_DIR="`pwd`/../../boringssl/"
2018-08-08 10:21:32 -04:00
make -j 12
2018-08-08 15:51:41 -04:00
sudo make install