~ubuntu-branches/debian/squeeze/erlang/squeeze

« back to all changes in this revision

Viewing changes to erts/etc/unix/Install.src

  • Committer: Bazaar Package Importer
  • Author(s): Sergei Golovan
  • Date: 2010-03-09 17:34:57 UTC
  • mfrom: (10.1.2 sid)
  • Revision ID: james.westby@ubuntu.com-20100309173457-4yd6hlcb2osfhx31
Tags: 1:13.b.4-dfsg-3
Manpages in section 1 are needed even if only arch-dependent packages are
built. So, re-enabled them.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
#!/bin/sh
2
2
#
3
3
# %CopyrightBegin%
4
 
5
 
# Copyright Ericsson AB 1996-2009. All Rights Reserved.
6
 
 
4
#
 
5
# Copyright Ericsson AB 1996-2010. All Rights Reserved.
 
6
#
7
7
# The contents of this file are subject to the Erlang Public License,
8
8
# Version 1.1, (the "License"); you may not use this file except in
9
9
# compliance with the License. You should have received a copy of the
10
10
# Erlang Public License along with this software. If not, it can be
11
11
# retrieved online at http://www.erlang.org/.
12
 
 
12
#
13
13
# Software distributed under the License is distributed on an "AS IS"
14
14
# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
15
15
# the License for the specific language governing rights and limitations
16
16
# under the License.
17
 
 
17
#
18
18
# %CopyrightEnd%
19
19
#
20
 
#  Patch $ERL_ROOT/emulator/obj/Makefile.dist & make
21
 
#
22
 
#
 
20
usage="
 
21
Usage:
 
22
  Install [-cross] [-minimal|-sasl] <ERL_ROOT>
 
23
"
23
24
start_option=query
24
25
unset cross
25
26
while [ $# -ne 0 ]; do
42
43
 
43
44
if [ -z "$ERL_ROOT" -o ! -d "$ERL_ROOT" ]
44
45
then
45
 
    echo "Install: need ERL_ROOT directory as argument"
 
46
    echo "Install: need <ERL_ROOT> directory as argument" >&2
 
47
    echo $usage >&2
46
48
    exit 1
47
49
fi
48
50
 
50
52
    :/*)
51
53
       ;;
52
54
    *)
53
 
       echo "Install: need an absolute path to ERL_ROOT"
 
55
       echo "Install: need an absolute path to <ERL_ROOT>" >&2
 
56
       echo $usage >&2
54
57
       exit 1
55
58
       ;;
56
59
esac
57
60
 
58
61
if [ ! -d "$ERL_ROOT/erts-%I_VSN%/bin" ]
59
62
then
60
 
    echo "Install: The directory $ERL_ROOT/erts-%I_VSN%/bin does not exist"
61
 
    echo "         Bad location or erts module not un-tared"
 
63
    echo "Install: The directory $ERL_ROOT/erts-%I_VSN%/bin does not exist" >&2
 
64
    echo "         Bad location or erts module not un-tared" >&2
 
65
    echo $usage >&2
62
66
    exit 1
63
67
fi
64
68
 
67
71
    mkdir $ERL_ROOT/bin
68
72
fi
69
73
 
70
 
#
71
 
# Fetch target system.
72
 
#
73
 
SYS=`(uname -s) 2>/dev/null` || SYS=unknown
74
 
REL=`(uname -r) 2>/dev/null` || REL=unknown
75
 
case $SYS:$REL in
76
 
                SunOS:5.*)
77
 
                        TARGET=sunos5 ;;
78
 
                Linux:*)
79
 
                        TARGET=linux ;;
80
 
                *)
81
 
                        TARGET="" ;;
82
 
esac
83
 
 
84
74
cd $ERL_ROOT/erts-%I_VSN%/bin
85
75
 
86
76
sed -e "s;%FINAL_ROOTDIR%;$TARGET_ERL_ROOT;" erl.src > erl
111
101
  /bin/rm -f epmd
112
102
fi
113
103
 
114
 
ln -s $TARGET_ERL_ROOT/erts-%I_VSN%/bin/epmd epmd
 
104
ln -s ../erts-%I_VSN%/bin/epmd epmd
115
105
 
116
106
cp -p $ERL_ROOT/erts-%I_VSN%/bin/run_erl .
117
107
cp -p $ERL_ROOT/erts-%I_VSN%/bin/to_erl .
150
140
cp -p ../releases/%I_SYSTEM_VSN%/$Name.script start.script
151
141
 
152
142
#
153
 
# We always run ranlib unless Solaris/SunOS 5
154
 
# but ignore failures.
155
 
#
156
 
if [ "X$TARGET" != "Xsunos5" -a -d $ERL_ROOT/usr/lib ]; then 
157
 
    cd $ERL_ROOT/usr/lib
158
 
    for library in lib*.a
159
 
    do
160
 
        (ranlib $library) > /dev/null 2>&1
161
 
    done
162
 
fi
163
 
 
164
 
 
165
 
#
166
143
# Fixing the man pages
167
144
#
168
145
 
172
149
    ./misc/format_man_pages $ERL_ROOT
173
150
fi
174
151
 
175
 
 
 
152
exit 0