comparison install-octave @ 3141:292ff0bf484b

[project @ 1998-02-03 08:11:07 by jwe]
author jwe
date Tue, 03 Feb 1998 08:11:22 +0000
parents bb05bfa835c9
children
comparison
equal deleted inserted replaced
3140:990ea337e950 3141:292ff0bf484b
74 74
75 # Where to install architecture-independent data files. ${fcnfiledir} 75 # Where to install architecture-independent data files. ${fcnfiledir}
76 # and ${localfcnfiledir} are subdirectories of this. 76 # and ${localfcnfiledir} are subdirectories of this.
77 datadir="$prefix/share" 77 datadir="$prefix/share"
78 78
79 # Where to install and expect libraries like libcruft.a, liboctave.a,
80 # and libreadline.a, executable files to be run by Octave rather than
81 # directly by users, and other architecture-dependent data.
82 # ${archlibdir} is a subdirectory of this.
83 libdir="$exec_prefix/lib" 79 libdir="$exec_prefix/lib"
80
81 # Where to install and expect libraries like libcruft.a and liboctave.a.
82 octlibdir="$libdir/octave-$version"
84 83
85 # Where to install and expect executable programs to be run by Octave 84 # Where to install and expect executable programs to be run by Octave
86 # rather than directly by users. 85 # rather than directly by users.
87 libexecdir="$exec_prefix/libexec" 86 libexecdir="$exec_prefix/libexec"
88 87
88 includedir="$prefix/include"
89
89 # Where to install Octave's include files. The default is 90 # Where to install Octave's include files. The default is
90 # ${prefix}/include/octave 91 # ${prefix}/include/octave-$version
91 includedir="$prefix/include" 92 octincludedir=$includedir/octave-$version
92 93
93 # Where to install Octave's man pages, and what extension they should 94 # Where to install Octave's man pages, and what extension they should
94 # have. The default is ${prefix}/man/man1 95 # have. The default is ${prefix}/man/man1
95 mandir="$prefix/man/man1" 96 mandir="$prefix/man/man1"
96 manext="1" 97 manext="1"
157 $prefix: 158 $prefix:
158 159
159 bindir: `echo $bindir | sed "s,^$prefix/,,"` 160 bindir: `echo $bindir | sed "s,^$prefix/,,"`
160 datadir: `echo $datadir | sed "s,^$prefix/,,"` 161 datadir: `echo $datadir | sed "s,^$prefix/,,"`
161 libdir: `echo $libdir | sed "s,^$prefix/,,"` 162 libdir: `echo $libdir | sed "s,^$prefix/,,"`
163 octlibdir: `echo $octlibdir | sed "s,^$prefix/,,"`
162 includedir: `echo $includedir | sed "s,^$prefix/,,"` 164 includedir: `echo $includedir | sed "s,^$prefix/,,"`
165 octincludedir: `echo $octincludedir | sed "s,^$prefix/,,"`
163 mandir: `echo $mandir | sed "s,^$prefix/,,"` 166 mandir: `echo $mandir | sed "s,^$prefix/,,"`
164 infodir: `echo $infodir | sed "s,^$prefix/,,"` 167 infodir: `echo $infodir | sed "s,^$prefix/,,"`
165 fcnfiledir: `echo $fcnfiledir | sed "s,^$prefix/,,"` 168 fcnfiledir: `echo $fcnfiledir | sed "s,^$prefix/,,"`
166 localfcnfiledir: `echo $localfcnfiledir | sed "s,^$prefix/,,"` 169 localfcnfiledir: `echo $localfcnfiledir | sed "s,^$prefix/,,"`
167 archlibdir: `echo $archlibdir | sed "s,^$prefix/,,"` 170 archlibdir: `echo $archlibdir | sed "s,^$prefix/,,"`
182 *) 185 *)
183 exit 1 186 exit 1
184 ;; 187 ;;
185 esac 188 esac
186 189
187 DIRS_TO_MAKE="$bindir $datadir $libdir $libexecdir $includedir $mandir \ 190 DIRS_TO_MAKE="$bindir $datadir $libdir $octlibdir $libexecdir \
188 $infodir $fcnfiledir $localfcnfiledir $archlibdir $localarchlibdir \ 191 $includedir $octincludedir $mandir $infodir $fcnfiledir \
192 $localfcnfiledir $archlibdir $localarchlibdir \
189 $octfiledir $localoctfiledir $imagedir" 193 $octfiledir $localoctfiledir $imagedir"
190 194
191 ./mkinstalldirs $DIRS_TO_MAKE 195 ./mkinstalldirs $DIRS_TO_MAKE
192 196
193 if test "$prefix" = /usr/local 197 if test "$prefix" = /usr/local
195 echo "installing src/octave as $bindir/octave" 199 echo "installing src/octave as $bindir/octave"
196 cp src/octave $bindir/octave 200 cp src/octave $bindir/octave
197 chmod 755 $bindir/octave 201 chmod 755 $bindir/octave
198 else 202 else
199 echo "installing octave-sh as $bindir/octave" 203 echo "installing octave-sh as $bindir/octave"
200 sed "s|@OCTAVE_HOME@|$prefix|; s|@LD_LIBRARY_PATH@|$libdir|" octave-sh \ 204 sed "s|@OCTAVE_HOME@|$prefix|; s|@LD_LIBRARY_PATH@|$octlibdir|" octave-sh \
201 > $bindir/octave 205 > $bindir/octave
202 chmod 755 $bindir/octave 206 chmod 755 $bindir/octave
203 207
204 echo "installing src/octave as $bindir/octave.bin" 208 echo "installing src/octave as $bindir/octave.bin"
205 cp src/octave $bindir/octave.bin 209 cp src/octave $bindir/octave.bin
208 212
209 echo "installing octave-bug as $bindir/octave-bug" 213 echo "installing octave-bug as $bindir/octave-bug"
210 cp octave-bug $bindir/octave-bug 214 cp octave-bug $bindir/octave-bug
211 chmod 755 $bindir/octave-bug 215 chmod 755 $bindir/octave-bug
212 216
217 echo "installing info as $archlibdir/info"
218 cp info/info $archlibdir/info
219 chmod 755 $archlibdir/info
220
213 if test -f LIBRARIES; then 221 if test -f LIBRARIES; then
214 echo "installing shared libraries in $libdir" 222 echo "installing shared libraries in $octlibdir"
215 for f in `cat LIBRARIES` 223 for f in `cat LIBRARIES`
216 do 224 do
217 file=`basename $f` 225 file=`basename $f`
218 cp $f $libdir/$file 226 cp $f $octlibdir/$file
219 chmod 644 $libdir/$file 227 chmod 644 $octlibdir/$file
220 done 228 done
221 fi 229 fi
222 230
223 oct_files=`find . -name '*.oct' -print` 231 oct_files=`find . -name '*.oct' -print`
224 if test -n "$oct_files"; then 232 if test -n "$oct_files"; then
258 chmod 644 $imagedir/$file 266 chmod 644 $imagedir/$file
259 done 267 done
260 cd $distdir 268 cd $distdir
261 269
262 echo "creating ls-R file in $datadir/octave" 270 echo "creating ls-R file in $datadir/octave"
263 ls -LR $datadir/octave $libexecdir/octave > $datadir/octave/ls-R 271 ls -LR $datadir/octave > $datadir/octave/ls-R
272
273 echo "creating ls-R file in $libexecdir/octave"
274 ls -LR $libexecdir/octave > $libexecdir/octave/ls-R
264 275
265 echo "installing info files in $infodir" 276 echo "installing info files in $infodir"
266 for f in doc/interpreter/octave.info* 277 for f in doc/interpreter/octave.info*
267 do 278 do
268 file=`basename $f` 279 file=`basename $f`