Commit d2d0f7c4 authored by Ciarán Ó Rourke's avatar Ciarán Ó Rourke
Browse files

Add libevent build script, callable from tmux build script

parent bd0bb70f
Pipeline #3639 failed with stage
in 16 minutes and 28 seconds
......@@ -119,7 +119,7 @@ declare -a CMAKE_FLAGS
declare -a MAKE_FLAGS
CMAKE_FLAGS+=( "-Wno-dev" )
CMAKE_FLAGS+=( "-DCMAKE_BUILD_TYPE=RelWithDebInfo" )
CMAKE_FLAGS+=( " -DCMAKE_BUILD_TYPE=RelWithDebInfo" )
MAKE_FLAGS+=( "-j" "${num_threads}" )
print_section "Building subprojects"
......
......@@ -4,6 +4,16 @@ tmux_src_dir="${external_dir}/tmux"
tmux_build_dir="${build_prefix}/tmux"
tmux_install_dir="${install_prefix}"
if [ "$build_dependencies" == true ]; then
echo "Installing dependencies..."
if should_build_dep libevent
then
print_section libevent
source "${script_dir}/tmux/build_libevent.sh"
fi
echo "Dependencies installed..."
fi
mkdir -p "${tmux_build_dir}"
pushd "${tmux_build_dir}"
......@@ -15,6 +25,8 @@ pushd src
./autogen.sh
./configure \
--prefix="${tmux_install_dir}" \
CFLAGS="-I$HOME/.local/include" \
LDFLAGS="-L$HOME/.local/lib" \
${CONFIGURE_FLAGS[@]}
make ${MAKE_FLAGS[@]}
......
set -o errexit
libevent_src_dir="${external_dir}/libevent"
libevent_build_dir="${build_prefix}/libevent"
libevent_install_dir="${install_prefix}"
pushd "${libevent_src_dir}"
cmake \
-DCMAKE_INSTALL_PREFIX="${libevent_install_dir}" \
"${CMAKE_FLAGS}" \
"${libevent_src_dir}"
make ${MAKE_FLAGS[@]}
make install
popd # libevent_build_dir
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment