2 ##############################################################################
\r
4 # Copyright (c) 2020 HCL Technology.
\r
6 # Licensed under the Apache License, Version 2.0 (the "License");
\r
7 # you may not use this file except in compliance with the License.
\r
8 # You may obtain a copy of the License at
\r
10 # http://www.apache.org/licenses/LICENSE-2.0
\r
12 # Unless required by applicable law or agreed to in writing, software
\r
13 # distributed under the License is distributed on an "AS IS" BASIS,
\r
14 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
\r
15 # See the License for the specific language governing permissions and
\r
16 # limitations under the License.
\r
18 ##############################################################################
\r
20 # Installs prerequisites needed to compile & test SDL code
\r
21 # and build RPM/DEB packages on a Debian/Ubuntu machine.
\r
23 echo "--> setup-sdl-build-deb.sh"
\r
25 # Ensure we fail the job if any steps fail.
\r
26 set -eux -o pipefail
\r
29 sudo apt-get update && sudo apt-get -q -y install \
\r
30 autoconf-archive libhiredis-dev rpm valgrind \
\r
31 libboost-filesystem-dev libboost-program-options-dev libboost-system-dev
\r
33 # generate configure script
\r
35 autoreconf --install
\r
37 curl -L https://github.com/cpputest/cpputest/releases/download/v3.8/cpputest-3.8.tar.gz | \
\r
38 tar --strip-components=1 -xzf -
\r
39 cmake -DCMAKE_BUILD_TYPE=Debug -DBUILD_COVERAGE=ON -DMEMORY_LEAK_DETECTION=OFF .
\r
41 echo "--> setup-sdl-build-deb.sh ends"