preremove revision 7c478bd95313f5f23a4c958a745db2134aa03244
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews#!/bin/sh
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews#
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# CDDL HEADER START
f754fa97bc698cc251d227173a95e4d39a88ac01Mark Andrews#
f754fa97bc698cc251d227173a95e4d39a88ac01Mark Andrews# The contents of this file are subject to the terms of the
a8f1c013b0fdc405ca4b5ec8316d3c9e3ad9d31bMark Andrews# Common Development and Distribution License, Version 1.0 only
a8f1c013b0fdc405ca4b5ec8316d3c9e3ad9d31bMark Andrews# (the "License"). You may not use this file except in compliance
a8f1c013b0fdc405ca4b5ec8316d3c9e3ad9d31bMark Andrews# with the License.
a8f1c013b0fdc405ca4b5ec8316d3c9e3ad9d31bMark Andrews#
959fb01017fa83578e7c8776ed3baba3076a2409Mark Andrews# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
959fb01017fa83578e7c8776ed3baba3076a2409Mark Andrews# or http://www.opensolaris.org/os/licensing.
959fb01017fa83578e7c8776ed3baba3076a2409Mark Andrews# See the License for the specific language governing permissions
46cb442c5c53f16ece23bfe7f7f7bf44f78b0e46Mark Andrews# and limitations under the License.
46cb442c5c53f16ece23bfe7f7f7bf44f78b0e46Mark Andrews#
0f222d322b25373c4ef59d7c79f265b082ee98cdMark Andrews# When distributing Covered Code, include this CDDL HEADER in each
0f222d322b25373c4ef59d7c79f265b082ee98cdMark Andrews# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
0f222d322b25373c4ef59d7c79f265b082ee98cdMark Andrews# If applicable, add the following below this CDDL HEADER, with the
0f222d322b25373c4ef59d7c79f265b082ee98cdMark Andrews# fields enclosed by brackets "[]" replaced with your own identifying
0f222d322b25373c4ef59d7c79f265b082ee98cdMark Andrews# information: Portions Copyright [yyyy] [name of copyright owner]
0f222d322b25373c4ef59d7c79f265b082ee98cdMark Andrews#
ae4f85dde3abb7d4afef9e869a83783cbf0aa29cMark Andrews# CDDL HEADER END
ae4f85dde3abb7d4afef9e869a83783cbf0aa29cMark Andrews#
ae4f85dde3abb7d4afef9e869a83783cbf0aa29cMark Andrews#
ae4f85dde3abb7d4afef9e869a83783cbf0aa29cMark Andrews#pragma ident "%Z%%M% %I% %E% SMI"
ae4f85dde3abb7d4afef9e869a83783cbf0aa29cMark Andrews#
2132a56b5c6628925838165ae0640e55e3f36188Mark Andrews# Copyright 1992-2003 Sun Microsystems, Inc. All rights reserved.
2132a56b5c6628925838165ae0640e55e3f36188Mark Andrews# Use is subject to license terms.
b514e0cd0e7959a98dd59665553c8a3635ada10eMark Andrews#
b514e0cd0e7959a98dd59665553c8a3635ada10eMark Andrews# remove the libcrypt.* symlinks
30884083d4149a8ff838b84dac1ad55c86948da8Mark Andrews#
d9ec2891475b8ed894a524a83370cfce30328569Mark Andrews
6e8a8077faf96d8da0b6cf738913f5f1f86e4008Mark Andrewssparc_preremove () {
6e8a8077faf96d8da0b6cf738913f5f1f86e4008Mark Andrews if [ -h $BASEDIR/usr/lib/sparcv9/libcrypt.so ]; then
5cb7e15551f502ab6948689cf3bc7dac6b56571eMark Andrews rm -f $BASEDIR/usr/lib/sparcv9/libcrypt.so
5cb7e15551f502ab6948689cf3bc7dac6b56571eMark Andrews fi
5a6874e4ed544186ccb8519765be8c3a1804e033Mark Andrews
5a6874e4ed544186ccb8519765be8c3a1804e033Mark Andrews if [ -f $BASEDIR/usr/lib/sparcv9/libcrypt.so.1 ]; then
2ab6dfca4b7432de4fb7da4cd21ee0e02a695c01Mark Andrews rm -f $BASEDIR/usr/lib/sparcv9/libcrypt.so.1
2ab6dfca4b7432de4fb7da4cd21ee0e02a695c01Mark Andrews fi
c553b3308e34edfaddbec57b3308bbbe362ef715Mark Andrews}
c553b3308e34edfaddbec57b3308bbbe362ef715Mark Andrews
24efdccd68d157b400bf68926798bc8f3f71c24cMark Andrewsif [ -h $BASEDIR/usr/lib/libcrypt.so ]; then
24efdccd68d157b400bf68926798bc8f3f71c24cMark Andrews rm -f $BASEDIR/usr/lib/libcrypt.so
a5bb4ad5dbd08f9178e807b1e55cb449b69d8173Mark Andrewsfi
a5bb4ad5dbd08f9178e807b1e55cb449b69d8173Mark Andrews
5e5b467e8c8abda496b7896241a46b05256cd22cMark Andrewsif [ -f $BASEDIR/usr/lib/libcrypt.so.1 ]; then
5e5b467e8c8abda496b7896241a46b05256cd22cMark Andrews rm -f $BASEDIR/usr/lib/libcrypt.so.1
713ad87a7f95d06f4bb3e0b92b91172cbebd6c68Mark Andrewsfi
713ad87a7f95d06f4bb3e0b92b91172cbebd6c68Mark Andrews
713ad87a7f95d06f4bb3e0b92b91172cbebd6c68Mark Andrewsif [ "$ARCH" = "sparc" ]; then sparc_preremove; fi;
cb2d565b507027f9e5664fa7e167bb24faa7c8fbMark Andrews
cb2d565b507027f9e5664fa7e167bb24faa7c8fbMark Andrewsexit 0
4f21f7feaff27d5356827e39a4537a60a5e4054cMark Andrews