summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2014-03-19 15:02:30 +0000
committerRoy Marples <roy@marples.name>2014-03-19 15:02:30 +0000
commitc1f24bd93857dd8528cf557160b43126d822974e (patch)
tree8f4132ec48786299b4eba4897f3181dab141d81e /configure
parentffffff26a5d7832a66a66787b3d978a3b187b708 (diff)
downloaddhcpcd-c1f24bd93857dd8528cf557160b43126d822974e.tar.xz
Support ypbind on OpenBSD.
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure18
1 files changed, 14 insertions, 4 deletions
diff --git a/configure b/configure
index 82fae317..39e8128a 100755
--- a/configure
+++ b/configure
@@ -787,13 +787,23 @@ if ! $HOOKSET; then
printf "Checking for ypind ... "
YPBIND=$(_which ypbind)
if [ -n "$YPBIND" ]; then
- if strings "$YPBIND" | $GREP -q yp.conf; then
+ if strings "$YPBIND" | $GREP -q yp\\.conf; then
YPHOOK="50-yp.conf"
- else
+ elif strings "$YPBIND" | $GREP -q \\.ypservers; then
+ YPHOOK="50-ypbind"
+ echo "YPDOMAIN_DIR= /var/yp" >>$CONFIG_MK
+ echo "YPDOMAIN_SUFFIX=.ypservers" >>$CONFIG_MK
+ elif strings "$YPBIND" | $GREP -q /etc/yp; then
YPHOOK="50-ypbind"
+ echo "YPDOMAIN_DIR= /etc/yp" >>$CONFIG_MK
+ echo "YPDOMAIN_SUFFIX=" >>$CONFIG_MK
+ fi
+ if [ -n "$YPHOOK" ]; then
+ echo "$YPBIND ($YPHOOK)"
+ HOOKS="$HOOKS${HOOKS:+ }$YPHOOK"
+ else
+ echo "unsupported version"
fi
- echo "$YPBIND ($YPHOOK)"
- HOOKS="$HOOKS${HOOKS:+ }$YPHOOK"
else
echo "not found"
fi