All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stefan Kisdaroczi <kisda@domain.hid>
To: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
Cc: xenomai@xenomai.org
Subject: Re: [Xenomai-help] kernel 2.6.32.11 with xenomai 2.5.3 fails to boot on ubuntu lucid system
Date: Fri, 20 Aug 2010 18:43:25 +0200	[thread overview]
Message-ID: <4C6EB0AD.2020206@domain.hid> (raw)
In-Reply-To: <4C6D7CC1.3080104@domain.hid>


[-- Attachment #1.1: Type: text/plain, Size: 577 bytes --]

On 19.08.2010 20:49, Gilles Chanteperdrix wrote:
> Stefan Kisdaroczi wrote:
>   
> [...]
>> ok, as you said above it's 'non-trivial' but on the other side we are
>> not in a hurry.
>>     
> Ok. I will try and have a look at modifying prepare-kernel.sh, probably
> this week-end. When done, I will let someone else (probably you ?)
>   
Thank you.
> modify prepare-patch.sh. In the meantime, I will merge the patch you
> sent which fixes prepare-patch.sh, and the other one which moves
> prepare-patch.sh.
>   

I sent only one, attached both now.

Stefan


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1.2: 0001-debian-fix-asm-include-directory-linking-in-prepare-.patch --]
[-- Type: text/x-patch; name="0001-debian-fix-asm-include-directory-linking-in-prepare-.patch", Size: 930 bytes --]

From 80e14710c85f35e9e62657c5b89ea5c271b977e4 Mon Sep 17 00:00:00 2001
From: Stefan Kisdaroczi <kisda@domain.hid>
Date: Wed, 18 Aug 2010 20:24:15 +0200
Subject: [PATCH 1/2] debian: fix asm include directory linking in prepare-patch.sh

---
 debian/prepare-patch.sh |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/debian/prepare-patch.sh b/debian/prepare-patch.sh
index 296638d..6ca734b 100755
--- a/debian/prepare-patch.sh
+++ b/debian/prepare-patch.sh
@@ -112,7 +112,7 @@ for linux_arch in $supported_arch ; do
     esac
 
     patch_link r m ksrc/arch/$base_arch arch/$linux_arch/xenomai
-    patch_link r n include/asm-$base_arch include/asm-$linux_arch/xenomai
+    patch_link r n include/asm-$base_arch arch/$linux_arch/include/asm/xenomai
 
     p="+drivers-\$(CONFIG_XENOMAI)		+= arch/$linux_arch/xenomai/"
     echo $p | patch_append arch/$linux_arch/Makefile
-- 
1.7.1


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1.3: 0002-debian-move-debian-prepare-patch.sh-to-scripts.patch --]
[-- Type: text/x-patch; name="0002-debian-move-debian-prepare-patch.sh-to-scripts.patch", Size: 14341 bytes --]

From 1ebcd79e2b1dce0c52c7ad327245774ca053091b Mon Sep 17 00:00:00 2001
From: Stefan Kisdaroczi <kisda@domain.hid>
Date: Fri, 20 Aug 2010 18:19:32 +0200
Subject: [PATCH 2/2] debian: move debian/prepare-patch.sh to scripts/

---
 debian/prepare-patch.sh  |  201 ----------------------------------------------
 debian/rules             |    2 +-
 scripts/prepare-patch.sh |  201 ++++++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 202 insertions(+), 202 deletions(-)
 delete mode 100755 debian/prepare-patch.sh
 create mode 100755 scripts/prepare-patch.sh

diff --git a/debian/prepare-patch.sh b/debian/prepare-patch.sh
deleted file mode 100755
index 6ca734b..0000000
--- a/debian/prepare-patch.sh
+++ /dev/null
@@ -1,201 +0,0 @@
-#! /bin/bash
-
-#----------------------------------------------------------------------
-# Description: Hacked down & butchered scripts/prepare-kernel.sh..
-#               Script to copy assorted sources to a temp directory and
-#               generate a kernel patch without the need of a virgin
-#               linux source tree.
-#----------------------------------------------------------------------
-
-set -e
-
-unset CDPATH
-
-patch_file=xenomai_all.patch
-
-supported_arch="$*"
-
-patch_append() {
-    file="$1"
-
-#    echo "diff -u1wbr orig/$file new/$file" >> $patch_file
-    echo "--- linux/$file	1970-01-01 01:00:00.000000000 +0100" >> $patch_file
-    echo "+++ linux-patched/$file	2007-03-06 17:55:58.000000000 +0000" >> $patch_file
-    echo "@@ -500,0 +500,2 @@" >> $patch_file
-    echo "+" >> $patch_file
-    cat >> $patch_file
-}
-
-patch_link() {
-    recursive="$1"              # "r" or "n"
-    link_makefiles="$2"         # "m" or "n"
-    target_dir="$3"
-    link_dir="$4"
-
-    (
-        recursive_opt=""
-        directorytype_opt=""
-        if test x$recursive = xr; then
-            recursive_opts="-mindepth 1"
-            directorytype_opt="-type d -o"
-        else
-            recursive_opt="-maxdepth 1"
-        fi
-        link_makefiles_opt=""
-        if test x$link_makefiles = xm; then
-            link_makefiles_opt="-name Makefile -o"
-        fi
-
-        cd $xenomai_root/$target_dir &&
-        find . $recursive_opt \( $link_makefiles_opt -name Kconfig -o -name '*.[chS]' \) |
-        while read f; do
-            f=`echo $f | cut -d/ -f2-`
-            d=`dirname $f`
-            if test ! -d  $temp_tree/$link_dir/$d ; then
-                mkdir -p $temp_tree/$link_dir/$d
-            fi
-            cp $xenomai_root/$target_dir/$f $temp_tree/$link_dir/$f
-        done
-    )
-
-}
-
-generate_patch() {
-    (
-    cd "$temp_tree"
-    find . -name demos -o -name snippets -exec rm -fR {} \+ &&
-    find . -type f |
-    while read f ; do
-        diff -Naurd "$linux_tree/$f" "$f" |
-        sed -e "s,^--- ${linux_tree}/\.\(/.*\)$,--- linux\1," \
-            -e "s,^+++ \.\(/.*\)$,+++ linux-patched\1,"
-    done
-    )
-}
-
-diff_addons() {
-    lines=`cat $xenomai_root/scripts/Kconfig.frag | wc -l`
-
-    echo "--- linux/init/Kconfig	1970-01-01 01:00:00.000000000 +0100" >> $patch_file
-    echo "+++ linux-patched/init/Kconfig	2007-03-06 17:55:58.000000000 +0000" >> $patch_file
-    echo "@@ -1400,0 +1400,$lines @@" >> $patch_file
-    sed -e "s,@LINUX_ARCH@,$linux_arch,g" $xenomai_root/scripts/Kconfig.frag | sed 's/^/+/' >> $patch_file
-    echo " " >> $patch_file
-}
-
-xenomai_root=`dirname $0`/..
-xenomai_root=`cd $xenomai_root && pwd`
-
-rm -fR $xenomai_root/tmp
-rm -f $patch_file
-
-mkdir -p $xenomai_root/tmp/linux
-mkdir -p $xenomai_root/tmp/linux.new
-linux_tree="$xenomai_root/tmp/linux"
-temp_tree="$xenomai_root/tmp/linux.new"
-
-
-for linux_arch in $supported_arch ; do
-    case $linux_arch in
-        i386)
-            base_arch=x86
-            ;;
-        x86_64)
-            base_arch=x86
-            ;;
-        x86)
-            base_arch=x86
-            ;;
-        *)
-            base_arch=$linux_arch
-            ;;
-    esac
-
-    patch_link r m ksrc/arch/$base_arch arch/$linux_arch/xenomai
-    patch_link r n include/asm-$base_arch arch/$linux_arch/include/asm/xenomai
-
-    p="+drivers-\$(CONFIG_XENOMAI)		+= arch/$linux_arch/xenomai/"
-    echo $p | patch_append arch/$linux_arch/Makefile
-    diff_addons
-done
-
-p="+obj-\$(CONFIG_XENOMAI)		+= xenomai/"
-echo $p | patch_append drivers/Makefile
-
-p="+obj-\$(CONFIG_XENOMAI)		+= xenomai/"
-echo $p | patch_append kernel/Makefile
-
-# Create local directories then symlink to the source files from
-# there, so that we don't pollute the Xenomai source tree with
-# compilation files.
-patch_link n m ksrc/ kernel/xenomai
-patch_link n m ksrc/arch kernel/xenomai/arch
-patch_link r m ksrc/arch/generic kernel/xenomai/arch/generic
-patch_link n m ksrc/nucleus kernel/xenomai/nucleus
-patch_link r m ksrc/skins kernel/xenomai/skins
-patch_link r m ksrc/drivers drivers/xenomai
-patch_link r n include/asm-generic include/asm-generic/xenomai
-patch_link n n include include/xenomai
-cd $xenomai_root
-for d in include/* ; do
-    if test -d $d -a -z "`echo $d | grep '^include/asm-'`"; then
-        destdir=`echo $d | sed -e 's,^\(include\)\(/.*\)$,\1/xenomai\2,'`
-        patch_link r n $d $destdir
-    fi
-done
-
-generate_patch >> $patch_file
-
-cd $xenomai_root
-
-#echo "Patch-name: Xenomai realtime kernel patches" > $xenomai_root/debian/linux-patch-xenomai.kpatches
-#echo "Patch-id: xenomai" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
-#echo "Architecture: all" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
-
-find $xenomai_root/ksrc/ -name "adeos-ipipe-2.6.*-$supported_arch-*.patch" |
-while read f ; do
-
-    file=`basename $f`
-    arch=`echo $file | cut -d- -f4`
-    kver=`echo $file | cut -d- -f3`
-
-    case $arch in
-        arm)
-            march=arm
-        ;;
-        i386)
-            march=i386
-        ;;
-        ppc|ppc64|powerpc)
-            march=powerpc
-        ;;
-        x86_64)
-            march=amd64
-        ;;
-	x86)
-	    march=i386
-	;;
-    esac
-
-    # Only one patch per arch/kver - Having a common plus kver/arch patch
-    # would require two linux-patch-foo packages.. When dh-kpatches Ver.1.0
-    # gets to testing, this can be looked at again..
-    echo "" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
-    echo "Patch-file: $file" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
-    echo "Kernel-version: $kver" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
-    echo "Architecture: $march" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
-
-    if [ "$arch" = "x86" ] ; then
-	echo "" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
-	echo "Patch-file: $file" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
-	echo "Kernel-version: $kver" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
-	echo "Architecture: amd64" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
-    fi
-
-    cp $f $xenomai_root/$file
-    cat $xenomai_root/$patch_file >> $xenomai_root/$file
-
-done
-
-exit 0
-
diff --git a/debian/rules b/debian/rules
index e39977d..788b031 100755
--- a/debian/rules
+++ b/debian/rules
@@ -63,7 +63,7 @@ patch-stamp:
 	dh_testdir
 	cp debian/linux-patch-xenomai.kpatches.in debian/linux-patch-xenomai.kpatches
 	for i in arm i386 powerpc x86_64 x86 ; do \
-		bash $(CURDIR)/debian/prepare-patch.sh $$i ; \
+		bash $(CURDIR)/scripts/prepare-patch.sh $$i ; \
 	done
 	touch patch-stamp
 
diff --git a/scripts/prepare-patch.sh b/scripts/prepare-patch.sh
new file mode 100755
index 0000000..6ca734b
--- /dev/null
+++ b/scripts/prepare-patch.sh
@@ -0,0 +1,201 @@
+#! /bin/bash
+
+#----------------------------------------------------------------------
+# Description: Hacked down & butchered scripts/prepare-kernel.sh..
+#               Script to copy assorted sources to a temp directory and
+#               generate a kernel patch without the need of a virgin
+#               linux source tree.
+#----------------------------------------------------------------------
+
+set -e
+
+unset CDPATH
+
+patch_file=xenomai_all.patch
+
+supported_arch="$*"
+
+patch_append() {
+    file="$1"
+
+#    echo "diff -u1wbr orig/$file new/$file" >> $patch_file
+    echo "--- linux/$file	1970-01-01 01:00:00.000000000 +0100" >> $patch_file
+    echo "+++ linux-patched/$file	2007-03-06 17:55:58.000000000 +0000" >> $patch_file
+    echo "@@ -500,0 +500,2 @@" >> $patch_file
+    echo "+" >> $patch_file
+    cat >> $patch_file
+}
+
+patch_link() {
+    recursive="$1"              # "r" or "n"
+    link_makefiles="$2"         # "m" or "n"
+    target_dir="$3"
+    link_dir="$4"
+
+    (
+        recursive_opt=""
+        directorytype_opt=""
+        if test x$recursive = xr; then
+            recursive_opts="-mindepth 1"
+            directorytype_opt="-type d -o"
+        else
+            recursive_opt="-maxdepth 1"
+        fi
+        link_makefiles_opt=""
+        if test x$link_makefiles = xm; then
+            link_makefiles_opt="-name Makefile -o"
+        fi
+
+        cd $xenomai_root/$target_dir &&
+        find . $recursive_opt \( $link_makefiles_opt -name Kconfig -o -name '*.[chS]' \) |
+        while read f; do
+            f=`echo $f | cut -d/ -f2-`
+            d=`dirname $f`
+            if test ! -d  $temp_tree/$link_dir/$d ; then
+                mkdir -p $temp_tree/$link_dir/$d
+            fi
+            cp $xenomai_root/$target_dir/$f $temp_tree/$link_dir/$f
+        done
+    )
+
+}
+
+generate_patch() {
+    (
+    cd "$temp_tree"
+    find . -name demos -o -name snippets -exec rm -fR {} \+ &&
+    find . -type f |
+    while read f ; do
+        diff -Naurd "$linux_tree/$f" "$f" |
+        sed -e "s,^--- ${linux_tree}/\.\(/.*\)$,--- linux\1," \
+            -e "s,^+++ \.\(/.*\)$,+++ linux-patched\1,"
+    done
+    )
+}
+
+diff_addons() {
+    lines=`cat $xenomai_root/scripts/Kconfig.frag | wc -l`
+
+    echo "--- linux/init/Kconfig	1970-01-01 01:00:00.000000000 +0100" >> $patch_file
+    echo "+++ linux-patched/init/Kconfig	2007-03-06 17:55:58.000000000 +0000" >> $patch_file
+    echo "@@ -1400,0 +1400,$lines @@" >> $patch_file
+    sed -e "s,@LINUX_ARCH@,$linux_arch,g" $xenomai_root/scripts/Kconfig.frag | sed 's/^/+/' >> $patch_file
+    echo " " >> $patch_file
+}
+
+xenomai_root=`dirname $0`/..
+xenomai_root=`cd $xenomai_root && pwd`
+
+rm -fR $xenomai_root/tmp
+rm -f $patch_file
+
+mkdir -p $xenomai_root/tmp/linux
+mkdir -p $xenomai_root/tmp/linux.new
+linux_tree="$xenomai_root/tmp/linux"
+temp_tree="$xenomai_root/tmp/linux.new"
+
+
+for linux_arch in $supported_arch ; do
+    case $linux_arch in
+        i386)
+            base_arch=x86
+            ;;
+        x86_64)
+            base_arch=x86
+            ;;
+        x86)
+            base_arch=x86
+            ;;
+        *)
+            base_arch=$linux_arch
+            ;;
+    esac
+
+    patch_link r m ksrc/arch/$base_arch arch/$linux_arch/xenomai
+    patch_link r n include/asm-$base_arch arch/$linux_arch/include/asm/xenomai
+
+    p="+drivers-\$(CONFIG_XENOMAI)		+= arch/$linux_arch/xenomai/"
+    echo $p | patch_append arch/$linux_arch/Makefile
+    diff_addons
+done
+
+p="+obj-\$(CONFIG_XENOMAI)		+= xenomai/"
+echo $p | patch_append drivers/Makefile
+
+p="+obj-\$(CONFIG_XENOMAI)		+= xenomai/"
+echo $p | patch_append kernel/Makefile
+
+# Create local directories then symlink to the source files from
+# there, so that we don't pollute the Xenomai source tree with
+# compilation files.
+patch_link n m ksrc/ kernel/xenomai
+patch_link n m ksrc/arch kernel/xenomai/arch
+patch_link r m ksrc/arch/generic kernel/xenomai/arch/generic
+patch_link n m ksrc/nucleus kernel/xenomai/nucleus
+patch_link r m ksrc/skins kernel/xenomai/skins
+patch_link r m ksrc/drivers drivers/xenomai
+patch_link r n include/asm-generic include/asm-generic/xenomai
+patch_link n n include include/xenomai
+cd $xenomai_root
+for d in include/* ; do
+    if test -d $d -a -z "`echo $d | grep '^include/asm-'`"; then
+        destdir=`echo $d | sed -e 's,^\(include\)\(/.*\)$,\1/xenomai\2,'`
+        patch_link r n $d $destdir
+    fi
+done
+
+generate_patch >> $patch_file
+
+cd $xenomai_root
+
+#echo "Patch-name: Xenomai realtime kernel patches" > $xenomai_root/debian/linux-patch-xenomai.kpatches
+#echo "Patch-id: xenomai" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
+#echo "Architecture: all" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
+
+find $xenomai_root/ksrc/ -name "adeos-ipipe-2.6.*-$supported_arch-*.patch" |
+while read f ; do
+
+    file=`basename $f`
+    arch=`echo $file | cut -d- -f4`
+    kver=`echo $file | cut -d- -f3`
+
+    case $arch in
+        arm)
+            march=arm
+        ;;
+        i386)
+            march=i386
+        ;;
+        ppc|ppc64|powerpc)
+            march=powerpc
+        ;;
+        x86_64)
+            march=amd64
+        ;;
+	x86)
+	    march=i386
+	;;
+    esac
+
+    # Only one patch per arch/kver - Having a common plus kver/arch patch
+    # would require two linux-patch-foo packages.. When dh-kpatches Ver.1.0
+    # gets to testing, this can be looked at again..
+    echo "" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
+    echo "Patch-file: $file" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
+    echo "Kernel-version: $kver" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
+    echo "Architecture: $march" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
+
+    if [ "$arch" = "x86" ] ; then
+	echo "" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
+	echo "Patch-file: $file" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
+	echo "Kernel-version: $kver" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
+	echo "Architecture: amd64" >> $xenomai_root/debian/linux-patch-xenomai.kpatches
+    fi
+
+    cp $f $xenomai_root/$file
+    cat $xenomai_root/$patch_file >> $xenomai_root/$file
+
+done
+
+exit 0
+
-- 
1.7.1


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 262 bytes --]

  reply	other threads:[~2010-08-20 16:43 UTC|newest]

Thread overview: 53+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-20  7:43 [Xenomai-help] kernel 2.6.32.11 with xenomai 2.5.3 fails to boot on ubuntu lucid system Theo Veenker
2010-07-20 10:14 ` Stefan Kisdaroczi
2010-07-20 11:18   ` Theo Veenker
2010-07-20 11:21     ` Gilles Chanteperdrix
2010-07-20 16:32       ` Theo Veenker
2010-08-16 11:22         ` Theo Veenker
2010-08-16 11:39           ` Gilles Chanteperdrix
2010-08-16 13:48             ` Theo Veenker
2010-08-16 13:53               ` Gilles Chanteperdrix
2010-08-16 14:11                 ` Theo Veenker
2010-08-16 11:40           ` Stefan Kisdaroczi
2010-08-16 11:59             ` Gilles Chanteperdrix
2010-08-16 12:00             ` Hemal C.Bavishi
2010-08-16 13:55             ` Theo Veenker
2010-08-16 12:45 ` Gilles Chanteperdrix
2010-08-16 14:26   ` Theo Veenker
2010-08-16 19:14     ` Theo Veenker
2010-08-16 22:39       ` Gilles Chanteperdrix
2010-08-17 10:27       ` Philippe Gerum
2010-08-17 13:51         ` Hemal C.Bavishi
2010-08-17 15:24           ` Stefan Kisdaroczi
2010-08-18  7:09             ` Gilles Chanteperdrix
2010-08-18  9:03               ` Paul
2010-08-18  9:06                 ` Gilles Chanteperdrix
2010-08-19 15:21                   ` Stefan Kisdaroczi
2010-08-19 15:28                     ` Gilles Chanteperdrix
2010-08-19 17:13                       ` Stefan Kisdaroczi
2010-08-19 18:49                         ` Gilles Chanteperdrix
2010-08-20 16:43                           ` Stefan Kisdaroczi [this message]
2010-08-18 18:45             ` [Xenomai-help] kernel 2.6.32.11 with xenomai 2.5.3 fails to boot on ubuntu lucid system [PATCH] Stefan Kisdaroczi
2010-08-18 18:58               ` Stefan Kisdaroczi
2010-08-18 21:08               ` Paul
2010-08-17 17:01         ` [Xenomai-help] kernel 2.6.32.11 with xenomai 2.5.3 fails to boot on ubuntu lucid system Philippe Gerum
2010-08-17 17:43         ` Stefan Kisdaroczi
2010-08-17 18:06           ` Jan Kiszka
2010-08-18 12:38             ` Stefan Kisdaroczi
2010-08-18  8:27           ` Philippe Gerum
2010-08-18 12:11             ` Stefan Kisdaroczi
2010-08-18 13:54               ` Stefan Kisdaroczi
2010-08-22 17:42                 ` Philippe Gerum
2010-08-23 11:59                   ` Stefan Kisdaroczi
2010-08-18 14:53               ` Philippe Gerum
2010-08-18 18:09               ` Philippe Gerum
2010-08-18 23:21             ` Gilles Chanteperdrix
2010-08-18 23:25               ` Gilles Chanteperdrix
2010-08-19  5:18               ` Philippe Gerum
2010-08-20 12:31         ` Theo Veenker
2010-08-20 12:34           ` Gilles Chanteperdrix
2010-08-20 13:34             ` Theo Veenker
2010-08-20 13:01           ` Philippe Gerum
2010-08-22 17:36             ` Philippe Gerum
2010-08-23  7:15               ` Theo Veenker
2010-08-21  9:32           ` Daniele Nicolodi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4C6EB0AD.2020206@domain.hid \
    --to=kisda@domain.hid \
    --cc=gilles.chanteperdrix@xenomai.org \
    --cc=xenomai@xenomai.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.