File: build

package info (click to toggle)
ignition-cmake 2.11.0-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 3,132 kB
  • sloc: xml: 35,671; python: 3,768; javascript: 2,308; sh: 172; ansic: 109; cpp: 64; makefile: 7
file content (37 lines) | stat: -rwxr-xr-x 1,326 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#!/bin/sh
# autopkgtest check: Build and run a program against ign-cmake, to verify that the
# cmake modules are installed
# (C) 2012 Jose Luis Rivero
# Author: Jose Luis Rivero <jrivero@osrfoundation.org>

set -e

WORKDIR=$(mktemp -d)
trap "rm -rf $WORKDIR" 0 INT QUIT ABRT PIPE TERM
cd $WORKDIR
mkdir -p $WORKDIR/doc $WORKDIR/src $WORKDIR/include $WORKDIR/test
touch $WORKDIR/doc/CMakeLists.txt $WORKDIR/src/CMakeLists.txt $WORKDIR/include/CMakeLists.txt $WORKDIR/test/CMakeLists.txt
cat <<EOF > CMakeLists.txt
cmake_minimum_required(VERSION 3.5)

project(test VERSION 1.0.0)

#============================================================================
# Find ignition-cmake2
#============================================================================
# If you get an error at this line, you need to install ignition-cmake2
find_package(ignition-cmake2 REQUIRED)

#============================================================================
# Set up the project
#============================================================================
ign_configure_project()

#============================================================================
# Configure the build
#============================================================================
ign_configure_build(QUIT_IF_BUILD_ERRORS)
EOF

cmake .
echo "configure: OK"