1#!/bin/sh 2# Test whether the current package is a KDE package. 3 4# NLS nuisances: Letter ranges are different in the Estonian locale. 5LC_ALL=C 6 7while true; do 8 configfiles= 9 if test -f configure.in; then 10 configfiles="$configfiles configure.in" 11 fi 12 if test -f configure.ac; then 13 configfiles="$configfiles configure.ac" 14 fi 15 if test -n "$configfiles"; then 16 if grep '^KDE_' $configfiles >/dev/null 2>&1 || \ 17 grep '^AC_PATH_KDE' $configfiles >/dev/null 2>&1 || \ 18 grep '^AM_KDE_WITH_NLS' $configfiles >/dev/null 2>&1 ; then 19 exit 0 20 fi 21 exit 1 22 fi 23 dir=`basename \`pwd\`` 24 case "$dir" in 25 i18n) 26 # This directory name, used in GNU make, is not the top level directory. 27 ;; 28 *[A-Za-z]*[0-9]*) 29 # Reached the top level directory. 30 exit 1 31 esac 32 # Go to parent directory 33 last=`/bin/pwd` 34 cd .. 35 curr=`/bin/pwd` 36 if test "$last" = "$curr"; then 37 # Oops, didn't find the top level directory. 38 exit 1 39 fi 40done 41