Using suffix 2.0 for development tools idzebra-config and idzebra.m4.
authorAdam Dickmeiss <adam@indexdata.dk>
Mon, 14 Aug 2006 12:18:46 +0000 (12:18 +0000)
committerAdam Dickmeiss <adam@indexdata.dk>
Mon, 14 Aug 2006 12:18:46 +0000 (12:18 +0000)
This means that Zebra 2.0 is completely separate from potential newer
releases.

Makefile.am
configure.ac
debian/libidzebra-2.0-dev.install
debian/libidzebra-2.0-dev.manpages
debian/libidzebra-2.0-dev.postinst [new file with mode: 0644]
debian/libidzebra-2.0-dev.prerm [new file with mode: 0644]
doc/Makefile.am
doc/idzebra-config-man.xml
idzebra-config-2.0.in [new file with mode: 0755]
idzebra-config.in [deleted file]
util/Makefile.am

index 9a2eb04..0e2149b 100644 (file)
@@ -1,4 +1,4 @@
-## $Id: Makefile.am,v 1.27 2006-08-10 18:02:28 adam Exp $
+## $Id: Makefile.am,v 1.28 2006-08-14 12:18:46 adam Exp $
 
 AUTOMAKE_OPTIONS=foreign
 
@@ -8,12 +8,12 @@ SUBDIRS=util bfile dfa dict isams isamb isamc rset data1 \
  tab index test examples include doc
 
 aclocaldir=$(datadir)/aclocal
-aclocal_DATA = m4/idzebra.m4
+aclocal_DATA = m4/idzebra-2.0.m4
 
 SPEC_FILE=idzebra.spec
 
 EXTRA_DIST= README NEWS $(SPEC_FILE) $(SPEC_FILE).in \
- idzebra-config.in m4/idzebra.m4 m4/yaz.m4 Doxyfile.in
+ idzebra-config-2.0.in m4/idzebra-2.0.m4 m4/yaz.m4 Doxyfile.in
 
 dist-hook:
        if test -x /usr/bin/cvs2cl -a -d CVS; then cvs2cl ; fi
index 100bdc8..749280a 100644 (file)
@@ -1,5 +1,5 @@
 dnl Zebra, Index Data ApS, 1995-2006
-dnl $Id: configure.ac,v 1.25 2006-07-06 07:56:00 adam Exp $
+dnl $Id: configure.ac,v 1.26 2006-08-14 12:18:46 adam Exp $
 dnl
 AC_PREREQ(2.59)
 AC_INIT([idzebra],[2.0.0],[adam@indexdata.dk])
@@ -374,9 +374,9 @@ AC_OUTPUT([
   examples/marc21/Makefile examples/marcxml/Makefile 
   examples/alvis-oai/Makefile
   idzebra.spec
-  idzebra-config
+  idzebra-config-2.0
   Doxyfile
-],[sed s%echo_source=yes%echo_source=no%g < idzebra-config > util/idzebra-config && chmod +x idzebra-config util/idzebra-config])
+],[sed s%echo_source=yes%echo_source=no%g < idzebra-config-2.0 > util/idzebra-config-2.0 && chmod +x idzebra-config-2.0 util/idzebra-config-2.0])
 
 echo \
 "------------------------------------------------------------------------
index 5c9acf1..2d4b71f 100644 (file)
@@ -1,4 +1,4 @@
-usr/bin/idzebra-config
+usr/bin/idzebra-config-2.0
 usr/lib/libidzebra-*.so
 usr/lib/libidzebra-*.la
 usr/lib/libidzebra-*.a
index c0a9735..14b607f 100644 (file)
@@ -1 +1 @@
-doc/idzebra-config.1
+doc/idzebra-config-2.0.1
diff --git a/debian/libidzebra-2.0-dev.postinst b/debian/libidzebra-2.0-dev.postinst
new file mode 100644 (file)
index 0000000..959e939
--- /dev/null
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+set -e
+
+if [ "$1" != configure ]; then exit 0; fi
+
+update-alternatives --quiet --install /usr/bin/idzebra-config idzebra-config \
+       /usr/bin/idzebra-config-2.0 50 \
+       --slave /usr/share/man/man1/idzebra-config.1.gz idzebra-config.1.gz \
+       /usr/share/man/man1/idzebra-config-2.0.1.gz
+
diff --git a/debian/libidzebra-2.0-dev.prerm b/debian/libidzebra-2.0-dev.prerm
new file mode 100644 (file)
index 0000000..a7eaf48
--- /dev/null
@@ -0,0 +1,10 @@
+#!/bin/sh
+
+set -e
+
+case "$1" in
+    remove|deconfigure)
+        update-alternatives --quiet --remove zebraidx /usr/bin/idzebra-config-2.0
+        ;;
+    *)
+esac
index 96a44fd..1059b69 100644 (file)
@@ -1,4 +1,4 @@
-## $Id: Makefile.am,v 1.54 2006-06-30 14:36:12 marc Exp $
+## $Id: Makefile.am,v 1.55 2006-08-14 12:18:48 adam Exp $
 docdir=$(datadir)/doc/$(PACKAGE)$(PACKAGE_SUFFIX)
 
 SUBDIRS = common
@@ -83,7 +83,7 @@ EPSFILES=zebra.eps
 
 MANFILES=zebraidx$(PACKAGE_SUFFIX).1 \
        zebrasrv$(PACKAGE_SUFFIX).8 \
-       idzebra-config.1
+       idzebra-config$(PACKAGE_SUFFIX).1
 
 REFFILES=zebraidx-man.xml zebrasrv-man.xml idzebra-config-man.xml
 
@@ -103,8 +103,9 @@ zebrasrv$(PACKAGE_SUFFIX).8: zebrasrv-man.xml  zebrasrv-options.xml \
        $(MAN_COMPILE) $(srcdir)/zebrasrv-man.xml
        mv zebrasrv.8 zebrasrv$(PACKAGE_SUFFIX).8
 
-idzebra-config.1: idzebra-config-man.xml
+idzebra-config$(PACKAGE_SUFFIX).1: idzebra-config-man.xml
        $(MAN_COMPILE) $(srcdir)/idzebra-config-man.xml
+       mv idzebra-config.1 idzebra-config$(PACKAGE_SUFFIX).1
 
 $(HTMLFILES): $(XMLFILES)
        $(HTML_COMPILE) $(srcdir)/zebra.xml
index 69aa9fd..6be1056 100644 (file)
@@ -1,7 +1,10 @@
 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN"
  "http://www.oasis-open.org/docbook/xml/4.1/docbookx.dtd"
-[ ]>
-<!-- $Id: idzebra-config-man.xml,v 1.1 2006-05-24 19:12:46 adam Exp $ -->
+[
+     <!ENTITY % local SYSTEM "local.ent">
+     %local;
+]>
+<!-- $Id: idzebra-config-man.xml,v 1.2 2006-08-14 12:18:48 adam Exp $ -->
 <refentry id="idzebra-config">
  
  <refmeta>
@@ -22,7 +25,8 @@
    <arg choice="opt"><option>--libs</option></arg>
    <arg choice="opt"><option>--lalibs</option></arg>
    <arg choice="opt"><option>--cflags</option></arg>
-   <arg choice="opt"><option>--tabs</option></arg>
+   <arg choice="opt"><option>--tab</option></arg>
+   <arg choice="opt"><option>--modules</option></arg>
    <arg choice="opt" rep="repeat">libraries</arg>
   </cmdsynopsis>
  </refsynopsisdiv>
@@ -38,7 +42,7 @@
   </para>
 
   <para>
-   None (yet)
+   None
   </para>
   
  </refsect1>
    </varlistentry>
 
    <varlistentry>
-    <term>--tabs</term>
+    <term>--tab</term>
     <listitem><para>
       Return directory of idzebra tables.
      </para></listitem>
    </varlistentry>
 
+   <varlistentry>
+    <term>--modules</term>
+    <listitem><para>
+      Return directory for Zebra modules.
+     </para></listitem>
+   </varlistentry>
+
   </variablelist>
  </refsect1>
  
  <refsect1><title>FILES</title>
   <para>
-   <filename><replaceable>prefix</replaceable>/bin/idzebra-config</filename>
+   <filename>&prefix;/bin/idzebra-config-2.0</filename>
   </para>
   <para>
-   <filename><replaceable>prefix</replaceable>/lib/libidzebra*.a</filename>
+   <filename>&prefix;/lib/libidzebra*2.0.a</filename>
   </para>
   <para>
-   <filename><replaceable>prefix</replaceable>/include/idzebra/*.h</filename>
+   <filename>&prefix;/include/idzebra-2.0/idzebra/*.h</filename>
   </para>
  </refsect1>
  <!--
diff --git a/idzebra-config-2.0.in b/idzebra-config-2.0.in
new file mode 100755 (executable)
index 0000000..8831eb5
--- /dev/null
@@ -0,0 +1,132 @@
+#!/bin/sh
+# $Id: idzebra-config-2.0.in,v 1.1 2006-08-14 12:18:46 adam Exp $
+version=@VERSION@
+prefix=@prefix@
+exec_prefix=@exec_prefix@
+libdir=@libdir@
+echo_cflags=no
+echo_libs=no
+echo_help=no
+echo_tab=no
+echo_source=yes
+echo_lalibs=no
+echo_modules=no
+idzebra_src_root=@IDZEBRA_SRC_ROOT@
+idzebra_build_root=@IDZEBRA_BUILD_ROOT@
+package_suffix=@PACKAGE_SUFFIX@
+
+extralibs="@YAZLIB@ @TCL_LIB@ @EXPAT_LIBS@ @XSLT_LIBS@ @LIBS@ "
+extralalibs="@YAZLALIB@ @TCL_LIB@ @EXPAT_LIBS@ @XSLT_LIBS@ @LIBS@"
+
+usage()
+{
+    cat <<EOF
+Usage: idzebra-config [OPTIONS] [LIBRARIES]
+Options:
+       [--prefix[=DIR]]
+       [--version]
+       [--libs]
+       [--lalibs]
+       [--cflags]
+       [--tab]
+       [--modules]
+EOF
+    exit $1
+}
+
+if test $# -eq 0; then
+    echo_help=yes
+fi
+
+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
+           exec_prefix=$prefix
+           libdir=${exec_prefix}/lib
+           ;;
+       --prefix)
+           echo $prefix
+           exit 0
+           ;;
+       --version)
+           echo $version
+           exit 0
+           ;;
+       --cflags)
+           echo_cflags=yes
+           ;;
+       --libs)
+           echo_libs=yes
+           ;;
+       --tab)
+           echo_tab=yes
+           ;;
+       --lalibs)
+           echo_lalibs=yes
+           ;;
+       --modules)
+           echo_modules=yes
+           ;;
+       -*)
+           echo_help=yes
+           ;;
+        *)
+            echo "$0: unsupported argument"
+            exit 1
+            ;;
+
+    esac
+    shift
+done
+
+IDZEBRAINC="@YAZINC@"
+
+if test "$echo_source" = "yes"; then
+    IDZEBRALIB="-L${idzebra_build_root}/index/.libs -lidzebra${package_suffix}"
+    IDZEBRALALIB="${idzebra_build_root}/index/libidzebra${package_suffix}.la"
+    IDZEBRALIB="$IDZEBRALIB $extralibs"
+    IDZEBRALALIB="$IDZEBRALALIB $extralalibs"
+    IDZEBRAINC="$IDZEBRAINC -I${idzebra_src_root}/include"
+    IDZEBRATAB="${idzebra_src_root}/tab"
+    IDZEBRAMOD="${idzebra_src_root}/recctrl"
+else
+    IDZEBRALIB="-lidzebra${package_suffix}"
+    if test "$libdir" != "/usr/lib"; then
+        IDZEBRALIB="-L${libdir} $IDZEBRALIB"
+    fi
+    IDZEBRALIB="$IDZEBRALIB $extralibs"
+    IDZEBRALALIB="$IDZEBRALIB"
+    IDZEBRAINC="$IDZEBRAINC -I${prefix}/include/idzebra${package_suffix}"
+    IDZEBRATAB="@datarootdir@/idzebra${package_suffix}/tab"
+    IDZEBRAMOD="${libdir}/idzebra${package_suffix}/modules"
+fi
+
+if test "$echo_help" = "yes"; then
+    usage 1 1>&2
+fi
+if test "$echo_cflags" = "yes"; then
+    echo $IDZEBRAINC
+fi
+if test "$echo_libs" = "yes"; then
+    echo $IDZEBRALIB
+fi
+if test "$echo_lalibs" = "yes"; then
+    echo $IDZEBRALALIB
+fi
+if test "$echo_tab" = "yes"; then
+    echo $IDZEBRATAB
+fi
+if test "$echo_modules" = "yes"; then
+    echo $IDZEBRAMOD
+fi
+# Local Variables:
+# mode:shell-script
+# sh-indentation: 2
+# sh-basic-offset: 4
+# End:
diff --git a/idzebra-config.in b/idzebra-config.in
deleted file mode 100755 (executable)
index ca8f468..0000000
+++ /dev/null
@@ -1,128 +0,0 @@
-#!/bin/sh
-# $Id: idzebra-config.in,v 1.12 2006-07-03 20:41:38 adam Exp $
-version=@VERSION@
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-libdir=@libdir@
-echo_cflags=no
-echo_libs=no
-echo_help=no
-echo_tab=no
-echo_source=yes
-echo_lalibs=no
-idzebra_src_root=@IDZEBRA_SRC_ROOT@
-idzebra_build_root=@IDZEBRA_BUILD_ROOT@
-package_suffix=@PACKAGE_SUFFIX@
-
-extralibs="@YAZLIB@ @TCL_LIB@ @EXPAT_LIBS@ @XSLT_LIBS@ @LIBS@ "
-extralalibs="@YAZLALIB@ @TCL_LIB@ @EXPAT_LIBS@ @XSLT_LIBS@ @LIBS@"
-
-usage()
-{
-    cat <<EOF
-Usage: idzebra-config [OPTIONS] [LIBRARIES]
-Options:
-       [--prefix[=DIR]]
-       [--version]
-       [--libs]
-       [--lalibs]
-       [--cflags]
-       [--tab]
-       [--modules]
-EOF
-    exit $1
-}
-
-if test $# -eq 0; then
-    echo_help=yes
-fi
-
-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
-           exec_prefix=$prefix
-           libdir=${exec_prefix}/lib
-           ;;
-       --prefix)
-           echo $prefix
-           exit 0
-           ;;
-       --version)
-           echo $version
-           exit 0
-           ;;
-       --cflags)
-           echo_cflags=yes
-           ;;
-       --libs)
-           echo_libs=yes
-           ;;
-       --tab)
-           echo_tab=yes
-           ;;
-       --lalibs)
-           echo_lalibs=yes
-           ;;
-       -*)
-           echo_help=yes
-           ;;
-        *)
-            echo "$0: unsupported argument"
-            exit 1
-            ;;
-
-    esac
-    shift
-done
-
-IDZEBRAINC="@YAZINC@"
-
-if test "$echo_source" = "yes"; then
-    IDZEBRALIB="-L${idzebra_build_root}/index/.libs -lidzebra${package_suffix}"
-    IDZEBRALALIB="${idzebra_build_root}/index/libidzebra${package_suffix}.la"
-    IDZEBRALIB="$IDZEBRALIB $extralibs"
-    IDZEBRALALIB="$IDZEBRALALIB $extralalibs"
-    IDZEBRAINC="$IDZEBRAINC -I${idzebra_src_root}/include"
-    IDZEBRATAB="${idzebra_src_root}/tab"
-    IDZEBRAMOD="${idzebra_src_root}/recctrl"
-else
-    IDZEBRALIB="-lidzebra${package_suffix}"
-    if test "$libdir" != "/usr/lib"; then
-        IDZEBRALIB="-L${libdir} $IDZEBRALIB"
-    fi
-    IDZEBRALIB="$IDZEBRALIB $extralibs"
-    IDZEBRALALIB="$IDZEBRALIB"
-    IDZEBRAINC="$IDZEBRAINC -I${prefix}/include/idzebra${package_suffix}"
-    IDZEBRATAB="@datarootdir@/idzebra${package_suffix}/tab"
-    IDZEBRAMOD="${libdir}/idzebra${package_suffix}/modules"
-fi
-
-if test "$echo_help" = "yes"; then
-    usage 1 1>&2
-fi
-if test "$echo_cflags" = "yes"; then
-    echo $IDZEBRAINC
-fi
-if test "$echo_libs" = "yes"; then
-    echo $IDZEBRALIB
-fi
-if test "$echo_lalibs" = "yes"; then
-    echo $IDZEBRALALIB
-fi
-if test "$echo_tab" = "yes"; then
-    echo $IDZEBRATAB
-fi
-if test "$echo_modules" = "yes"; then
-    echo $IDZEBRAMOD
-fi
-# Local Variables:
-# mode:shell-script
-# sh-indentation: 2
-# sh-basic-offset: 4
-# End:
index a3af0dd..f8d7b15 100644 (file)
@@ -1,4 +1,4 @@
-## $Id: Makefile.am,v 1.25 2006-07-05 15:03:53 adam Exp $
+## $Id: Makefile.am,v 1.26 2006-08-14 12:18:50 adam Exp $
 
 noinst_LTLIBRARIES = libidzebra-util.la
 
@@ -8,11 +8,11 @@ check_PROGRAMS = tstcharmap tstflock tstlockscope
 
 TESTS = $(check_PROGRAMS)
 
-bin_SCRIPTS = idzebra-config
+bin_SCRIPTS = idzebra-config-2.0
 
 EXTRA_DIST = zebrasrv.rh tstcharmap.chr
 
-DISTCLEANFILES = idzebra-config
+DISTCLEANFILES = idzebra-config-2.0
 
 AM_CPPFLAGS = -I$(srcdir)/../include $(YAZINC) -DDEFAULT_PROFILE_PATH=\"$(pkgdatadir)/tab\"
 LDADD = libidzebra-util.la $(YAZLALIB)