Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 26 Jul 2007 11:28:12 -0700
From:      Doug Barton <dougb@FreeBSD.org>
To:        Khaled Hussein <khaled@palnet.com>
Cc:        freebsd-ports@freebsd.org
Subject:   Re: Ports upgrade
Message-ID:  <46A8E7BC.9040103@FreeBSD.org>
In-Reply-To: <46A8E619.3050701@FreeBSD.org>
References:  <46A87CD7.90900@palnet.com> <46A8E619.3050701@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Doug Barton wrote:
> The other is to not use bash as your login shell, but rather to use
> sh, then have a .profile that starts bash if it's available:
> 
> if [ -x /usr/local/bin/bash ]; then
>	exec /usr/local/bin/bash --login
> fi

Hrrm, my actual .profile entry is more complicated than that, and I
just realized that I oversimplified it here. What you want to do is
also test to make sure that the bash you can find will run:

if [ -x /usr/local/bin/bash ]; then
        if /usr/local/bin/bash --version >/dev/null 2>&1; then
                exec /usr/local/bin/bash --login
        fi
fi

otherwise you're stuck in the same boat by exec'ing something that's
going to fail because of the missing library.

Sorry for the confusion,

Doug

-- 

    This .signature sanitized for your protection




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?46A8E7BC.9040103>