2 # This file is part of the YAZ toolkit.
3 # Copyright (C) 1995-2008 Index Data
12 yaz_src_root=@YAZ_SRC_ROOT@
13 yaz_build_root=@YAZ_BUILD_ROOT@
15 ICU_CPPFLAGS="@ICU_CPPFLAGS@"
19 VERSION_SHA1=@VERSION_SHA1@
24 Usage: yaz-config [OPTIONS] [LIBRARIES]
34 threads icu server static
39 while test $# -gt 0; do
41 -*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
54 echo "$YAZVERSION $VERSION_SHA1"
77 if test "$ICU_CPPFLAGS"; then
99 if test "$lib_server" = "yes"; then
100 YAZLIB="-lyaz_server $YAZLIB"
103 if test "$lib_icu" = "yes"; then
104 YAZLIB="-lyaz_icu $YAZLIB"
107 if test "$lib_ssl" = "yes"; then
108 LIBS="${SSL_LIBS} $LIBS"
111 YAZINC="@YAZ_CONFIG_CFLAGS@"
113 if test "$yaz_echo_source" = "yes"; then
114 YAZBIN=${yaz_build_root}/bin
116 if test "$lib_static" = "yes"; then
117 if test "$lib_ssl" != "yes"; then
118 LIBS="${SSL_LIBS} $LIBS"
120 YAZLIB="${yaz_build_root}/src/.libs/libyaz.a"
121 if test "$lib_server" = "yes"; then
122 YAZLIB="${yaz_build_root}/src/.libs/libyaz_server.a $YAZLIB"
124 if test "$lib_icu" = "yes"; then
125 YAZLIB="${yaz_build_root}/src/.libs/libyaz_icu.a $YAZLIB"
128 YAZLIB="-L${yaz_build_root}/src/.libs $YAZLIB"
130 YAZLIB="$YAZLIB $LIBS"
132 YAZLALIB="${yaz_build_root}/src/libyaz.la"
133 if test "$lib_server" = "yes"; then
134 YAZLALIB="${yaz_build_root}/src/libyaz_server.la $YAZLALIB"
136 if test "$lib_icu" = "yes"; then
137 YAZLALIB="${yaz_build_root}/src/libyaz_icu.la $YAZLALIB"
139 YAZLALIB="$YAZLALIB $LIBS"
141 YAZINC="-I${yaz_src_root}/include $YAZINC"
142 YAZCOMP=${yaz_src_root}/util/yaz-asncomp
144 YAZBIN=${yazprefix}/bin
145 YAZCOMP=${yazprefix}/bin/yaz-asncomp
147 if test "$yazprefix" != "/usr"; then
148 YAZLIB="-L$yazprefix/lib $YAZLIB"
150 YAZLIB="$YAZLIB $LIBS"
152 if test "$yazprefix" != "/usr"; then
153 YAZINC="-I$yazprefix/include $YAZINC"
157 if test "$lib_thread" = "yes"; then
161 if test "$lib_icu" = "yes"; then
162 YAZINC="$YAZINC $ICU_CPPFLAGS"
163 YAZLIB="$YAZLIB $ICU_LIBS"
164 YAZLALIB="$YAZLALIB $ICU_LIBS"
167 if test "$yaz_echo_help" = "yes"; then
170 if test "$yaz_echo_cflags" = "yes"; then
173 if test "$yaz_echo_libs" = "yes"; then
176 if test "$yaz_echo_lalibs" = "yes"; then
179 if test "$yaz_echo_comp" = "yes"; then