=================================================================== RCS file: /cvs/openbsd/fill_chroot/fix_ldconfig,v retrieving revision 1.2 retrieving revision 1.5 diff -u -r1.2 -r1.5 --- openbsd/fill_chroot/fix_ldconfig 2005/12/21 18:16:03 1.2 +++ openbsd/fill_chroot/fix_ldconfig 2006/08/13 18:24:38 1.5 @@ -1,7 +1,7 @@ #!/bin/sh -# $RedRiver: fix_ldconfig,v 1.1 2005/12/21 18:04:06 andrew Exp $ +# $RedRiver: fix_ldconfig,v 1.4 2006/06/29 18:44:19 andrew Exp $ -CHROOT=${CHROOT:=/home/andrew/www} +CHROOT=${CHROOT:=/var/www} if [ ${CHROOT}"X" == "X" ]; then echo No CHROOT Specified! @@ -11,6 +11,13 @@ mkdir -p ${CHROOT}/bin mkdir -p ${CHROOT}/var/run +LDPATH=/usr/lib +for d in /usr/X11R6/lib /usr/local/lib; do + if [ -d $d ]; then + LDPATH="$LDPATH $d" + fi +done + cp /sbin/ldconfig ${CHROOT}/bin -chroot ${CHROOT} /bin/ldconfig /usr/local/lib +chroot ${CHROOT} /bin/ldconfig ${LDPATH} rm -f ${CHROOT}/bin/ldconfig