File: docopt.cpp-examples

package info (click to toggle)
docopt.cpp 0.6.2-2
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 232 kB
  • ctags: 196
  • sloc: cpp: 1,493; python: 57; sh: 20; makefile: 13
file content (30 lines) | stat: -rwxr-xr-x 574 bytes parent folder | download | duplicates (3)
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
#!/bin/sh
# Copyright 2016 Ghislain Antony Vaillant
#
# This file is part of the packaging testsuite for docopt.cpp.

set -e

cp examples/naval_fate.cpp $AUTOPKGTEST_TMP
cd $AUTOPKGTEST_TMP

cat << EOF > CMakeLists.txt
cmake_minimum_required(VERSION 3.0)
project(docopt.cpp-examples)

find_package(docopt)
add_executable(naval_fate naval_fate.cpp)
target_link_libraries(naval_fate docopt)

EOF

mkdir build
cd build
cmake ..
cmake --build .
echo "=== help ==="
./naval_fate --help
echo "=== version ==="
./naval_fate --version
echo "=== run ==="
./naval_fate ship new boaty