File: cc_make_api_unit_tests.sh

package info (click to toggle)
epr-api 2.3~dev20150708-12
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 3,128 kB
  • sloc: ansic: 14,310; sh: 194; makefile: 146; xml: 125
file content (23 lines) | stat: -rw-r--r-- 466 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/bin/bash

if [ ! -f "../../../bin" ]
then
    mkdir ../../../bin
fi

if [ -f "../../../bin/api_unit_tests" ]
then
    rm ../../../bin/api_unit_tests
fi


cc -lm ../../../bccunit/src/bccunit.c ../../../src/*.c ../../../src/test/api_unit_tests.c -o ../../../bin/api_unit_tests

if [ ! -f "../../../bin/api_unit_tests" ]
then
    echo ""
    echo "Error:"
    echo "--> api_unit_tests could not be compiled"
else
    echo "--> api_unit_tests compiled successful"
fi