~ubuntu-branches/ubuntu/trusty/log4shib/trusty

« back to all changes in this revision

Viewing changes to log4shib-config.in

  • Committer: Package Import Robot
  • Author(s): Russ Allbery
  • Date: 2012-06-05 21:20:25 UTC
  • Revision ID: package-import@ubuntu.com-20120605212025-uyigtav7dqwvnf41
Tags: upstream-1.0.4
ImportĀ upstreamĀ versionĀ 1.0.4

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#! /bin/sh
 
2
# log4shib-config library configuration script
 
3
# generated by ac_config_libconfig_in.m4
 
4
 
 
5
template_version="1.0.0"
 
6
 
 
7
package="@PACKAGE@"
 
8
 
 
9
# usage instructions if no options given
 
10
if test "$#" -eq 0; then
 
11
   cat <<EOF
 
12
Usage: log4shib-config [OPTIONS]
 
13
Options:
 
14
        [--prefix[=DIR]]
 
15
        [--exec-prefix[=DIR]]
 
16
        [--package]
 
17
        [--version]
 
18
        [--cflags]
 
19
        [--libs]
 
20
        [--help]
 
21
EOF
 
22
fi
 
23
 
 
24
# parse options
 
25
o=""
 
26
h=""
 
27
for i in $@; do
 
28
  case $i in
 
29
    --prefix=*) prefix=`echo $i | sed -e "s/--prefix=//"` ;;
 
30
    --exec-prefix=*) exec_prefix=`echo $i | sed -e "s/--exec-prefix=//"` ;;
 
31
    --eprefix=*) exec_prefix=`echo $i | sed -e "s/--eprefix=//"` ;;
 
32
    --prefix) echo_prefix="yes" ;;
 
33
    --exec-prefix) echo_exec_prefix="yes" ;;
 
34
    --eprefix) echo_eprefix="yes" ;;
 
35
    --package) echo_package="yes" ;;
 
36
    --version) echo_version="yes" ;;
 
37
    --cflags) echo_cflags="yes" ;;
 
38
    --libs) echo_libs="yes" ;;
 
39
    --bindir) echo_bindir="yes" ;;
 
40
    --sbindir) echo_sbindir="yes" ;;
 
41
    --libexecdir) echo_libexecdir="yes" ;;
 
42
    --datadir) echo_datadir="yes" ;;
 
43
    --sysconfdir) echo_sysconfdir="yes" ;;
 
44
    --sharedstatedir) echo_sharedstatedir="yes" ;;
 
45
    --localstatedir) echo_localstatedir="yes" ;;
 
46
    --libdir) echo_libdir="yes" ;;
 
47
    --infodir) echo_infodir="yes" ;;
 
48
    --mandir) echo_mandir="yes" ;;
 
49
    --target) echo_target="yes" ;;
 
50
    --host) echo_host="yes" ;;
 
51
    --build) echo_build="yes" ;;
 
52
    --pkgdatadir) echo_pkgdatadir="yes" ;;
 
53
    --pkglibdir) echo_pkglibdir="yes" ;;
 
54
    --pkgincludedir) echo_pkgincludedir="yes" ;;
 
55
    --template-version) echo_template_version="yes" ;;
 
56
    --help) echo_help="yes" ;;
 
57
    //*|/*//*|./*//*)        echo_extra="yes" ;;
 
58
    *) eval "echo Unknown option: $i" ; exit 1 ;;
 
59
  esac
 
60
done
 
61
 
 
62
# defaults from configure; set only if not set previously
 
63
if test -z "$prefix" ; then
 
64
  prefix="@prefix@"
 
65
fi
 
66
if test -z "$exec_prefix" ; then
 
67
  exec_prefix="@exec_prefix@"
 
68
fi
 
69
if test -z "$bindir" ; then
 
70
  bindir="@bindir@"
 
71
fi
 
72
if test -z "$sbindir" ; then
 
73
  sbindir="@sbindir@"
 
74
fi
 
75
if test -z "$libexecdir" ; then
 
76
  libexecdir="@libexecdir@"
 
77
fi
 
78
if test -z "$datadir" ; then
 
79
  datadir="@datadir@"
 
80
fi
 
81
if test -z "$sysconfdir" ; then
 
82
  sysconfdir="@sysconfdir@"
 
83
fi
 
84
if test -z "$sharedstatedir" ; then
 
85
  sharedstatedir="@sharedstatedir@"
 
86
fi
 
87
if test -z "$localstatedir" ; then
 
88
  localstatedir="@localstatedir@"
 
89
fi
 
90
if test -z "$libdir" ; then
 
91
  libdir="@libdir@"
 
92
fi
 
93
if test -z "$infodir" ; then
 
94
  infodir="@infodir@"
 
95
fi
 
96
if test -z "$mandir" ; then
 
97
  mandir="@mandir@"
 
98
fi
 
99
if test -z "$includedir" ; then
 
100
  includedir="@includedir@"
 
101
fi
 
102
if test -z "$target" ; then
 
103
  target="@target@"
 
104
fi
 
105
if test -z "$host" ; then
 
106
  host="@host@"
 
107
fi
 
108
if test -z "$build" ; then
 
109
  build="@build@"
 
110
fi
 
111
 
 
112
# generate output
 
113
if test x$echo_module != xyes ; then
 
114
  echo_module_log4shib="yes"
 
115
fi
 
116
if test x$echo_module_log4shib = xyes ; then
 
117
  cflags="$cflags @log4shib_cflags@"
 
118
  libs="$libs @log4shib_libs@"
 
119
  version="$version @LOG4SHIB_VERSION@"
 
120
fi
 
121
if test x$echo_prefix = xyes ; then
 
122
  o=" $prefix"
 
123
fi
 
124
if test x$echo_exec_prefix = xyes ; then
 
125
  o="$o $exec_prefix"
 
126
fi
 
127
if test x$echo_eprefix = xyes ; then
 
128
  o="$o $exec_prefix"
 
129
fi
 
130
if test x$echo_package = xyes ; then
 
131
  o=" $package"
 
132
fi
 
133
if test x$echo_version = xyes ; then
 
134
  o=" $version"
 
135
fi
 
136
if test x$echo_cflags = xyes ; then
 
137
  i=`eval echo "$includedir"`
 
138
  i=`eval echo "$i"`
 
139
  if test "_$i" != "_/usr/include" ; then
 
140
    o="$o -I$includedir"
 
141
  fi
 
142
  o="$o $cflags"
 
143
fi
 
144
if test x$echo_libs = xyes ; then
 
145
  o="$o -L$libdir $libs"
 
146
fi
 
147
if test x$echo_bindir = xyes ; then
 
148
  o=" $bindir"
 
149
fi
 
150
if test x$echo_sbindir = xyes ; then
 
151
  o=" $sbindir"
 
152
fi
 
153
if test x$echo_libexecdir = xyes ; then
 
154
  o=" $libexecdir"
 
155
fi
 
156
if test x$echo_datadir = xyes ; then
 
157
  o=" $datadir"
 
158
fi
 
159
if test x$echo_sysconfdir = xyes ; then
 
160
  o=" $sysconfdir"
 
161
fi
 
162
if test x$echo_sharedstatedir = xyes ; then
 
163
  o=" $sharedstatedir"
 
164
fi
 
165
if test x$echo_localstatedir = xyes ; then
 
166
  o=" $localstatedir"
 
167
fi
 
168
if test x$echo_libdir = xyes ; then
 
169
  o=" $libdir"
 
170
fi
 
171
if test x$echo_infodir = xyes ; then
 
172
  o=" $infodir"
 
173
fi
 
174
if test x$echo_mandir = xyes ; then
 
175
  o=" $mandir"
 
176
fi
 
177
if test x$echo_target = xyes ; then
 
178
  o=" $target"
 
179
fi
 
180
if test x$echo_host = xyes ; then
 
181
  o=" $host"
 
182
fi
 
183
if test x$echo_build = xyes ; then
 
184
  o=" $build"
 
185
fi
 
186
if test x$echo_pkgdatadir = xyes ; then
 
187
  o=" ${datadir}/${package}"
 
188
fi
 
189
if test x$echo_pkglibdir = xyes ; then
 
190
  o=" ${libdir}/${package}"
 
191
fi
 
192
if test x$echo_pkgincludedir = xyes ; then
 
193
  o=" ${includedir}/${package}"
 
194
fi
 
195
if test x$echo_template_version = xyes ; then
 
196
  o="$o $template_version"
 
197
fi
 
198
if test x$echo_help = xyes ; then
 
199
  h="1"
 
200
fi
 
201
if test x$echo_extra = xyes ; then
 
202
  v=`echo $i | sed -e s://:\$:g`
 
203
  v=`eval "echo $v"`
 
204
  o="$o $v"
 
205
fi
 
206
 
 
207
# output data
 
208
o=`eval "echo $o"`
 
209
o=`eval "echo $o"`
 
210
if test -n "$o" ; then 
 
211
  eval "echo $o"
 
212
fi
 
213
 
 
214
# help text
 
215
if test ! -z "$h" ; then 
 
216
  cat <<EOF
 
217
All available options:
 
218
  --prefix=DIR and   change \$prefix and \$exec-prefix
 
219
  --exec-prefix=DIR  (affects all other options)
 
220
  --prefix           \$prefix        $prefix
 
221
  --exec_prefix  or... 
 
222
  --eprefix          \$exec_prefix   $exec_prefix
 
223
  --version          \$version       $version
 
224
  --cflags           -I\$includedir  unless it is /usr/include
 
225
  --libs             -L\$libdir \$LIBS $libs
 
226
  --package          \$package       $package
 
227
  --bindir           \$bindir        $bindir
 
228
  --sbindir          \$sbindir       $sbindir
 
229
  --libexecdir       \$libexecdir    $libexecdir
 
230
  --datadir          \$datadir       $datadir
 
231
  --sysconfdir       \$sysconfdir    $sysconfdir
 
232
  --sharedstatedir   \$sharedstatedir$sharedstatedir
 
233
  --localstatedir    \$localstatedir $localstatedir
 
234
  --libdir           \$libdir        $libdir
 
235
  --infodir          \$infodir       $infodir
 
236
  --mandir           \$mandir        $mandir
 
237
  --target           \$target        $target
 
238
  --host             \$host          $host
 
239
  --build            \$build         $build
 
240
  --pkgdatadir       \$datadir/\$package    ${datadir}/${package}
 
241
  --pkglibdir        \$libdir/\$package     ${libdir}/${package}
 
242
  --pkgincludedir    \$includedir/\$package ${includedir}/${package}
 
243
  --template-version \$template_version     $template_version
 
244
  --help
 
245
EOF
 
246
fi