0
|
1 |
#!/usr/bin/ksh93 -p
|
|
2 |
#
|
|
3 |
# CDDL HEADER START
|
|
4 |
#
|
|
5 |
# The contents of this file are subject to the terms of the
|
|
6 |
# Common Development and Distribution License (the "License").
|
|
7 |
# You may not use this file except in compliance with the License.
|
|
8 |
#
|
|
9 |
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
|
|
10 |
# or http://www.opensolaris.org/os/licensing.
|
|
11 |
# See the License for the specific language governing permissions
|
|
12 |
# and limitations under the License.
|
|
13 |
#
|
|
14 |
# When distributing Covered Code, include this CDDL HEADER in each
|
|
15 |
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
|
|
16 |
# If applicable, add the following below this CDDL HEADER, with the
|
|
17 |
# fields enclosed by brackets "[]" replaced with your own identifying
|
|
18 |
# information: Portions Copyright [yyyy] [name of copyright owner]
|
|
19 |
#
|
|
20 |
# CDDL HEADER END
|
|
21 |
#
|
14
|
22 |
# Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved.
|
0
|
23 |
#
|
14
|
24 |
#ident "@(#)install-sfw 1.3 10/04/22 SMI"
|
0
|
25 |
|
|
26 |
set -o errexit
|
|
27 |
source ${SRC}/tools/install.subr
|
|
28 |
|
|
29 |
TOP=$(pwd)
|
|
30 |
MANDIR=${ROOT}/usr/share/man
|
|
31 |
BINDIR=${ROOT}/usr/bin
|
|
32 |
LIBDIR=${ROOT}/usr/lib
|
|
33 |
VARDIR=${ROOT}/var/lib/tor
|
|
34 |
LOGDIR=${ROOT}/var/log/tor
|
|
35 |
MANSCRIPT=${TOP}/sunman-stability
|
|
36 |
METHODDIR=${ROOT}/lib/svc/method
|
14
|
37 |
MANIFESTDIR=${ROOT}/lib/svc/manifest/network
|
0
|
38 |
MKDIR=/usr/bin/mkdir
|
|
39 |
CHMOD=/usr/bin/chmod
|
|
40 |
|
|
41 |
${MKDIR} -p ${MANIFESTDIR}
|
|
42 |
${MKDIR} -p ${METHODDIR}
|
|
43 |
${MKDIR} -p ${VARDIR}
|
|
44 |
${MKDIR} -p ${LOGDIR}
|
|
45 |
${CHMOD} 0755 ${VARDIR}
|
|
46 |
${CHMOD} 0755 ${LOGDIR}
|
|
47 |
|
|
48 |
_install N tor.xml ${MANIFESTDIR}/tor.xml 444
|
|
49 |
_install N tor.sh ${METHODDIR}/tor.sh 555
|
9
|
50 |
_install N auth_attr ${ROOT}/etc/security/auth_attr.d/tor 444
|
|
51 |
_install N prof_attr ${ROOT}/etc/security/prof_attr.d/tor 444
|
0
|
52 |
|
|
53 |
cd ${TOP}
|
|
54 |
|
|
55 |
_install M ${TOP}/${VER}/doc/tor.1 ${MANDIR}/man1m/tor.1m 444
|
|
56 |
_install M ${TOP}/${VER}/doc/tor-resolve.1 ${MANDIR}/man1/tor-resolve.1 444
|
|
57 |
_install M ${TOP}/${VER}/doc/tor-gencert.1 ${MANDIR}/man1/tor-gencert.1 444
|
|
58 |
|
|
59 |
cd ${TOP}/${VER}
|
|
60 |
|
|
61 |
_install E ${TOP}/${VER}/src/or/tor ${LIBDIR}/tor 555
|
|
62 |
_install E ${TOP}/${VER}/src/tools/tor-gencert ${BINDIR}/tor-gencert 555
|
|
63 |
_install E ${TOP}/${VER}/src/tools/tor-resolve ${BINDIR}/tor-resolve 555
|
|
64 |
|
|
65 |
_install N ${TOP}/${VER}/src/config/torrc.sample ${ROOT}/etc/torrc 0644
|
|
66 |
|
|
67 |
${MKDIR} -p ${ROOT}/usr/share/tor
|
|
68 |
_install N ${TOP}/${VER}/src/config/geoip ${ROOT}/usr/share/tor/geoip 0444
|
|
69 |
|
|
70 |
exit 0
|