-
Notifications
You must be signed in to change notification settings - Fork 51
/
gnsstk-config.in
49 lines (44 loc) · 886 Bytes
/
gnsstk-config.in
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
38
39
40
41
42
43
44
45
46
47
48
49
#!/bin/bash
exit_with_usage ()
{
echo "Usage: $0 --prefix|--includedir|--libdir|--bindir|--help"
exit $1
}
if [ "$1" = "" ] ; then
exit_with_usage 1
fi
INCLUDE_DIR=@CMAKE_INSTALL_PREFIX@/@GNSSTK_INCLUDE_PARENT@
BIN_DIR=@CMAKE_INSTALL_PREFIX@/bin
LIBRARY_DIR=@CMAKE_INSTALL_PREFIX@/lib
ROOT_DIR=@CMAKE_INSTALL_PREFIX@
# Scan for --help or unknown argument.
for ARG in $*
do
case $ARG in
--help)
exit_with_usage 0
;;
--prefix|--includedir|--libdir|--bindir|--help)
;;
*)
exit_with_usage 1
;;
esac
done
for ARG in $*
do
case $ARG in
--prefix)
echo "$ROOT_DIR"
;;
--includedir)
echo "$INCLUDE_DIR"
;;
--libdir)
echo "$LIBRARY_DIR"
;;
--bindir)
echo "$BIN_DIR"
;;
esac
done