File: config.m4

package info (click to toggle)
php4 6%3A4.4.4-8%2Betch1
  • links: PTS
  • area: main
  • in suites: etch-m68k
  • size: 34,976 kB
  • ctags: 39,148
  • sloc: ansic: 340,486; php: 34,786; cpp: 10,150; sh: 9,010; lex: 2,180; yacc: 1,712; xml: 1,335; makefile: 559; awk: 466; java: 455; perl: 154
file content (56 lines) | stat: -rw-r--r-- 1,500 bytes parent folder | download | duplicates (3)
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
dnl
dnl $Id: config.m4,v 1.11.2.2 2004/04/08 23:54:08 sniper Exp $
dnl

PHP_ARG_WITH(yaz,for YAZ support,
[  --with-yaz[=DIR]        Include YAZ support (ANSI/NISO Z39.50). 
                          DIR is the YAZ bin install directory.])


if test "$PHP_YAZ" != "no"; then
  yazconfig=NONE
  if test "$PHP_YAZ" = "yes"; then
    AC_PATH_PROG(yazconfig, yaz-config, NONE)
  else
    if test -r ${PHP_YAZ}/yaz-config; then
      yazconfig=${PHP_YAZ}/yaz-config
    else
      yazconfig=${PHP_YAZ}/bin/yaz-config
    fi
  fi

  if test -f $yazconfig; then
    AC_DEFINE(HAVE_YAZ,1,[Whether you have YAZ])
    . $yazconfig

    dnl Check version (1.9 or greater required)
    AC_MSG_CHECKING([for YAZ version])
    yaz_version=`echo $YAZVERSION | awk 'BEGIN { FS = "."; } { printf "%d", ($1 * 1000 + $2) * 1000 + $3;}'`
    if test "$yaz_version" -ge 1009000; then
      AC_MSG_RESULT([$YAZVERSION])
    else
      AC_MSG_ERROR([YAZ version 1.9 or later required.])
    fi

    dir=""
    for c in $YAZLIB; do
      case $c in
       -L*)
         dir=`echo $c|cut -c 3-|sed 's%/\.libs%%g'`
         PHP_ADD_LIBPATH($dir,YAZ_SHARED_LIBADD)
        ;;
       -lyaz*)
        ;;
       *)
         PHP_EVAL_LIBLINE($c, YAZ_SHARED_LIBADD)
        ;;
      esac
    done
    PHP_ADD_LIBRARY_DEFER(yaz,1,YAZ_SHARED_LIBADD)
    PHP_EVAL_INCLINE($YAZINC)
    PHP_SUBST(YAZ_SHARED_LIBADD)
    PHP_NEW_EXTENSION(yaz, php_yaz.c, $ext_shared)
  else
    AC_MSG_ERROR([YAZ not found (missing $yazconfig)])
  fi
fi