Mercurial > hg > dml-home
comparison etc/setup_as_root.sh @ 30:2c279c979bcd
Pulled out MATLAB initialisation into a separate script.
author | samer |
---|---|
date | Mon, 16 Feb 2015 22:03:22 +0000 |
parents | 11e21255b404 |
children | ad0bfbaddf6a |
comparison
equal
deleted
inserted
replaced
29:8576194f1c9c | 30:2c279c979bcd |
---|---|
51 $DO apt-get install libxpm-dev libxt-dev libjpeg-dev libx11-dev libxft-dev libxinerama1 libfontconfig1-dev | 51 $DO apt-get install libxpm-dev libxt-dev libjpeg-dev libx11-dev libxft-dev libxinerama1 libfontconfig1-dev |
52 fi | 52 fi |
53 | 53 |
54 # If you have MATLAB | 54 # If you have MATLAB |
55 if [ $HAVE_MATLAB == yes ]; then | 55 if [ $HAVE_MATLAB == yes ]; then |
56 echo "Checking for MATLAB..." 1>&2 | 56 DO=$DO DRY_RUN=$DRY_RUN as_root.d/init_matlab.sh |
57 MATLAB_ROOT=$(matlab -e | grep '^MATLAB=' | sed -e 's/MATLAB=//') | |
58 echo "MATLAB installed in $MATLAB_ROOT" 1>&2 | |
59 $DO apt-get csh libtritonus-java libvorbisspi-java libmp3spi-java | |
60 $DO ln -sf /lib/x86_64-linux-gnu/libc.so.6 /lib64 | |
61 $DO ln -sf $MATLAB_ROOT/bin/matlab /usr/local/bin | |
62 | |
63 # MATLAB (R2012a at least) looks for Java extension jars in this directory | |
64 $DO mkdir -p /usr/java/packages/lib/ext | |
65 # NB - there may be some duplication of service providers here - I'm not sure | |
66 # which of them works best. | |
67 $DO ln -sf /usr/shara/java/{vorbisspi,mp3spi}.jar /usr/java/packages/lib/ext | |
68 $DO ln -sf /usr/shara/java/tritonus_{aos,core,jorbis,mp3,remaining,share}.jar /usr/java/packages/lib/ext | |
69 | |
70 # need to add native library paths to this file | |
71 if grep '/usr/lib/jni' $MATLAB_ROOT/toolbox/local/librarypath.txt; then | |
72 echo "MATLAB Library path already set." 1>&2 | |
73 else | |
74 if [ $DRY_RUN == yes ]; then | |
75 echo "echo '/usr/lib/jni' >> $MATLAB_ROOT/toolbox/local/librarypath.txt" | |
76 else | |
77 echo '/usr/lib/jni' >> $MATLAB_ROOT/toolbox/local/librarypath.txt | |
78 fi | |
79 fi | |
80 fi | 57 fi |
81 | 58 |
82 $DO install -bC rc.local /etc | 59 $DO install -bC rc.local /etc |
83 | 60 |
84 | 61 |