-
Notifications
You must be signed in to change notification settings - Fork 0
/
airrac-config.in
125 lines (104 loc) · 2.37 KB
/
airrac-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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
#!/bin/sh
prefix=@prefix@
exec_prefix=${prefix}
bindir=${exec_prefix}/bin
libdir=${exec_prefix}/lib@LIB_SUFFIX@
libexecdir=${exec_prefix}/libexec
sbindir=${exec_prefix}/sbin
sysconfdir=${prefix}/etc
includedir=${prefix}/include
datarootdir=${prefix}/share
datadir=${datarootdir}
pkgdatadir=${datarootdir}/@PACKAGE@
sampledir=@sampledir@
docdir=${datarootdir}/doc/@PACKAGE@-@PACKAGE_VERSION@
mandir=${datarootdir}/man
infodir=${datarootdir}/info
htmldir=${docdir}/html
htmldocpath=${htmldir}/index.html
pdfdir=${docdir}/html
refmanpath=${pdfdir}/refman.pdf
pkgincludedir=${includedir}/@PACKAGE@
pkglibdir=${libdir}/@PACKAGE@
pkglibexecdir=${libexecdir}/@PACKAGE@
usage()
{
cat <<EOF
Usage: @PACKAGE@-config [OPTION]
Known values for OPTION are:
--help display this help and exit
--prefix print @PACKAGE_PRETTY_NAME@ installation prefix
--version output version information
--libs print library linking information
--cflags print pre-processor and compiler flags
--sampledir print where the (StdAir CSV) sample files are located
--mandir print where the manual (MAN) pages are located
--infodir print where the information (info) pages are located
--docdir print where the documentation is located
--htmldocpath print where the HTML documentation is located
--refmanpath print where the reference manual (PDF) is located
EOF
exit $1
}
if test $# -eq 0; then
usage 1
fi
cflags=false
libs=false
while test $# -gt 0; do
case "$1" in
-*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
*) optarg= ;;
esac
case $1 in
--prefix=*)
prefix=$optarg
;;
--prefix)
echo $prefix
;;
--sampledir)
echo $sampledir
;;
--version)
echo @PACKAGE_VERSION@
;;
--mandir)
echo $mandir
;;
--infodir)
echo $infodir
;;
--docdir)
echo $docdir
;;
--htmldocpath)
echo $htmldocpath
;;
--refmanpath)
echo $refmanpath
;;
--help)
usage 0
;;
--cflags)
if [ "${prefix}" != "/usr" ]; then
echo -I${includedir}
else
echo
fi
;;
--libs)
if [ "${prefix}" != "/usr" ]; then
echo -L${libdir} -l@PACKAGE@
else
echo -l@PACKAGE@
fi
;;
*)
usage
exit 1
;;
esac
shift
done