-
-
Save borgfriend/b83467639cb8039dc79974bf780a4994 to your computer and use it in GitHub Desktop.
#!/bin/bash | |
#Make sure we’re running with root permissions. | |
if [ `whoami` != root ]; then | |
echo Please run this script using sudo | |
echo Just type “sudo !!” | |
exit | |
fi | |
#Check for 64-bit arch | |
if [uname -m != x86_64]; then | |
echo Maya will only run on 64-bit linux. | |
echo Please install the 64-bit ubuntu and try again. | |
exit | |
fi | |
## Create Download Directory | |
mkdir -p maya2017Install | |
cd maya2017Install | |
## Download Maya Install Files | |
wget http://edutrial.autodesk.com/NET17SWDLD/2017/MAYA/ESD/Autodesk_Maya_2017_EN_JP_ZH_Linux_64bit.tgz | |
tar xvf Autodesk_Maya_2017_EN_JP_ZH_Linux_64bit.tgz | |
## Install Dependencies | |
apt-get install -y libssl1.0.0 | |
apt-get install -y gcc | |
apt-get install -y libssl-dev | |
apt-get install -y libjpeg62 | |
apt-get install -y alien | |
apt-get install -y csh | |
apt-get install -y tcsh | |
apt-get install -y libaudiofile-dev | |
apt-get install -y libglw1-mesa | |
apt-get install -y elfutils | |
apt-get install -y libglw1-mesa-dev | |
apt-get install -y mesa-utils | |
apt-get install -y xfstt | |
apt-get install -y ttf-liberation | |
apt-get install -y xfonts-100dpi | |
apt-get install -y xfonts-75dpi | |
apt-get install -y ttf-mscorefonts-installer | |
apt-get install -y libfam0 | |
apt-get install -y libfam-dev | |
apt-get install -y libgstreamer-plugins-base0.10-0 | |
wget http://launchpadlibrarian.net/183708483/libxp6_1.0.2-2_amd64.deb | |
## Install Maya | |
alien -cv *.rpm | |
dpkg -i *.deb | |
echo "int main (void) {return 0;}" > mayainstall.c | |
gcc mayainstall.c | |
mv /usr/bin/rpm /usr/bin/rpm_backup | |
cp a.out /usr/bin/rpm | |
chmod +x ./setup | |
./setup | |
rm /usr/bin/rpm | |
mv /usr/bin/rpm_backup /usr/bin/rpm | |
## Fix Startup Errors | |
ln -s /usr/lib/x86_64-linux-gnu/libtiff.so.5.2.4 /usr/lib/libtiff.so.3 | |
ln -s /usr/lib/x86_64-linux-gnu/libssl.so /usr/autodesk/maya2017/lib/libssl.so.10 | |
ln -s /usr/lib/x86_64-linux-gnu/libcrypto.so /usr/autodesk/maya2017/lib/libcrypto.so.10 | |
mkdir -p /usr/tmp | |
chmod 777 /usr/tmp | |
mkdir -p ~/maya/2017/ | |
chmod 777 ~/maya/2017/ | |
## Fix Segmentation Fault Error | |
echo "MAYA_DISABLE_CIP=1" >> ~/maya/2017/Maya.env | |
## Fix Color Managment Errors | |
echo "LC_ALL=C" >> ~/maya/2017/Maya.env | |
chmod 777 ~/maya/2017/Maya.env | |
## Maya Camera Modifier Key | |
gsettings set org.gnome.desktop.wm.preferences mouse-button-modifier "<Super>" | |
## Ensure that Fonts are Loaded | |
xset +fp /usr/share/fonts/X11/100dpi/ | |
xset +fp /usr/share/fonts/X11/75dpi/ | |
xset fp rehash | |
echo Maya was installed successfully. |
@prashanthbhagavan, @TobiMayr: I had the same problem, it takes a while but the installation will eventually proceed.
When I install, everything goes through well and successful, but when I go to run it, I cannot find ANYTHING whatsoever.
@borgfriend Thanks for this script. It's work!
I use Deepin. I downloaded last version maya 2017 and executed all commands.
I just changed the symbolic links for libtiff.so, libssl.so and libcrypto.so.
why not ln -s /usr/bin/true /usr/bin/rpm
or better yet alias rpm=true
sudo ln -s /usr/lib/nvidia-390/libGL.so /usr/autodesk/maya2017/lib/
thanks a million, your solution fixed my problem!
Hey eveyone, I am on installing Maya 2019 on a mint build, converted using alien ok then the last command failed as it counldn't find the archive, as like many asking questions on these kind of posts I come from a zero coding background, so need some help what do i need to do next?
p.s. I found the deb files they had been added to my home directory but not in a folder, so moved to a folder and seems to be installing.
Upon starting maya 2017, 2018 or 2019 (i have all 3 installed, and all 3 have the same issue) I get this
// Error: file: /usr/autodesk/maya2019/scripts/startup/initMainWindow.mel line 176: ImportError: file /usr/autodesk/maya2019/lib/python2.7/site-packages/maya/app/general/mayaMixin.py line 35: libpyside2.so.2.0: cannot open shared object file: No such file or directory, No module named PyQt4.QtCore //
// Error: line 0: ImportError: file /usr/autodesk/maya2019/lib/python2.7/site-packages/maya/app/general/mayaMixin.py line 35: libpyside2.so.2.0: cannot open shared object file: No such file or directory, No module named PyQt4.QtCore //
Upon further investigating, just typing in from PyQt4 import QtCore
also fails. with
# Error: ImportError: file <maya console> line 1: No module named PyQt4 #
I assume that's not supposed to be the case?
Upon starting maya 2017, 2018 or 2019 (i have all 3 installed, and all 3 have the same issue) I get this
// Error: file: /usr/autodesk/maya2019/scripts/startup/initMainWindow.mel line 176: ImportError: file /usr/autodesk/maya2019/lib/python2.7/site-packages/maya/app/general/mayaMixin.py line 35: libpyside2.so.2.0: cannot open shared object file: No such file or directory, No module named PyQt4.QtCore //
// Error: line 0: ImportError: file /usr/autodesk/maya2019/lib/python2.7/site-packages/maya/app/general/mayaMixin.py line 35: libpyside2.so.2.0: cannot open shared object file: No such file or directory, No module named PyQt4.QtCore //
Upon further investigating, just typing in
from PyQt4 import QtCore
also fails. with
# Error: ImportError: file <maya console> line 1: No module named PyQt4 #
I assume that's not supposed to be the case?
I am also having this issue. Did you find a solution to it?
from PySide2 import QtWidgets
# Error: ImportError: file <maya console> line 1: libpyside2-python2.7.so.2.0: cannot open shared object file: No such file or directory #
Upon starting maya 2017, 2018 or 2019 (i have all 3 installed, and all 3 have the same issue) I get this
// Error: file: /usr/autodesk/maya2019/scripts/startup/initMainWindow.mel line 176: ImportError: file /usr/autodesk/maya2019/lib/python2.7/site-packages/maya/app/general/mayaMixin.py line 35: libpyside2.so.2.0: cannot open shared object file: No such file or directory, No module named PyQt4.QtCore //
// Error: line 0: ImportError: file /usr/autodesk/maya2019/lib/python2.7/site-packages/maya/app/general/mayaMixin.py line 35: libpyside2.so.2.0: cannot open shared object file: No such file or directory, No module named PyQt4.QtCore //
Upon further investigating, just typing infrom PyQt4 import QtCore
also fails. with
# Error: ImportError: file <maya console> line 1: No module named PyQt4 #
I assume that's not supposed to be the case?I am also having this issue. Did you find a solution to it?
from PySide2 import QtWidgets # Error: ImportError: file <maya console> line 1: libpyside2-python2.7.so.2.0: cannot open shared object file: No such file or directory #
That's a Python issue, try this:
mv /usr/autodesk/maya2019/lib/python2.7/lib-dynload/_hashlib.so /usr/autodesk/maya2019/lib/python2.7/lib-dynload/rhel_hashlib.so
ln -s /usr/lib/python2.7/lib-dynload/_hashlib.x86_64-linux-gnu.so /usr/autodesk/maya2019/lib/python2.7/lib-dynload/_hashlib.so
I figured out the issue. The solution was specifying the LD_LIBRARY_PATH. This is done automagically in the standard maya launcher, but that crashes/fails for 2017 & 2018. The solution I found there was to write my own launcher script. Like so:
#!/bin/sh
maya_loc=/usr/autodesk/maya2018/
export MAYA_LOCATION=$maya_loc
# Set up the location of the DSO's and run
export LD_LIBRARY_PATH=$maya_loc/lib/
# DISABLE CIP
export MAYA_DISABLE_CIP=1
# Launch Maya!
$maya_loc/bin/maya.bin
However, if you want to use the proper launcher method, I found the 2019 launcher works for 2017 & 2018. So I've copied the code here as well:
#!/bin/bash -f
#Tag 0x00C98a00
#*
#*+***********************************************************************
#*
#* Module:
#* maya
#*
#*-***********************************************************************
#*
maya_exec=maya.bin
#
# Determine if launched from the desktop or a shell. This will tell
# us how to display error messages later.
#
tty=1
OSname=$(/bin/uname -s)
if [ "$OSname" = Linux ]; then
lib=lib
lsFlags='-l'
else
echo "Maya is not supported on $OSname."
exit 1
fi
#
# Parse the argument list
#
mayaArgs=""
mayaApp=""
debuggerArgs=""
while [[ $# -gt 0 ]]
do
key="$1"
case $key in
-d)
if [ $# -le 1 ]; then
if [ $tty = 1 ]; then
echo "No debugger specified"
fi
fi
shift
dbgApp=$1
;;
-dbgArg)
shift
debuggerArgs="${debuggerArgs} $1"
;;
-data)
mayaArgs="${mayaArgs} $1"
;;
-d*)
dbgApp=$(echo "$1" | cut -c3-)
;;
*)
# unknown option
mayaArgs="${mayaArgs} '$1'"
;;
esac
shift # past argument or value
done
#
# If the MAYA_LOCATION is set, use it. Otherwise, determine it.
#
if [ ! -z ${MAYA_LOCATION+x} ]; then
if [ -x ${MAYA_LOCATION}/bin/${maya_exec} ]; then
maya=${MAYA_LOCATION}/bin/${maya_exec}
else
unset MAYA_LOCATION
fi
fi
if [ -z ${MAYA_LOCATION+x} ]; then
#
# Create the full pathname of the invoked binary.
#
if [[ "$0" == /* ]]; then
me="$0"
else
me=$(pwd)/$0
fi
#
# If it's a link, find the actual file.
# Follow the link(s) until an acutal file is found
while [ -h "$me" ]; do
linkdirname=$(dirname "$me")
me=$(ls "$lsFlags" "$me" | tr ' ' '\012' | tail -n 1)
if [[ ! "$me" == /* ]]; then
me="$linkdirname/$me"
fi
done
#
# Binary should be in $MAYA_LOCATION/bin. Verify that.
#
bindir=$(dirname "$me")
if [ -d "$bindir" ]; then
bindir=$(cd "$bindir"; echo "$PWD")
fi
binfile=$(basename "$bindir")
if [ "$binfile" == "bin" ]; then
# We cannot call export directly if there are spaces in the Path.
# We must use a temp variable.
maya_loc=$(dirname "$bindir")
export MAYA_LOCATION="$maya_loc"
if [ -x "${MAYA_LOCATION}/bin/${maya_exec}" ]; then
maya="${MAYA_LOCATION}/bin/${maya_exec}"
else
unset MAYA_LOCATION
fi
fi
fi
#
# This allows Maya to save SGI format image files with matte.
export WF_IMF_SGI_MATTE=1
#
# 101914: color correction needed for Cineon files.
export WF_IMF_CIN_CORRECTION=both
export WF_IMF_CIN_WHITE_POINT=685
# Set up the location of the libquicktime plugins
export LIBQUICKTIME_PLUGIN_DIR="$MAYA_LOCATION/lib/libquicktime"
# Turn on tablet event compression by default to solve viewport
export QT_COMPRESS_TABLET_EVENTS=1
#
# Set up the location of the DSO's and run
#
if [ "$MAYA_LOCATION" ]; then
if [ ! -z ${LD_LIBRARY_PATH+x} ]; then
export LD_LIBRARY_PATH="$MAYA_LOCATION/lib:$LD_LIBRARY_PATH"
else
export LD_LIBRARY_PATH="$MAYA_LOCATION/lib"
fi
# Prepend modules lib to LD_LIBRARY_PATH or LD_LIBRARYN32_PATH
# See Manitoba/Apps/maya.cpp for OSX
for moduleDir in "$MAYA_LOCATION/plug-ins"/* ; do
if [ -d "$moduleDir" ] && [ -d "$moduleDir/lib" ]; then
if [ ! -z ${LD_LIBRARY_PATH+x} ]; then
export LD_LIBRARY_PATH="$moduleDir/lib:$LD_LIBRARY_PATH"
else
export LD_LIBRARY_PATH="$moduleDir/lib"
fi
fi
done
if [ "$mayaApp" != "" ]; then
maya="${mayaApp}";
fi
if [ -x "$maya" ]; then
if [ ! -z ${dbgApp+x} ]; then
#echo "debugging: ${maya}"
export AW_DEBUGGING=F
export MAYA_DEBUG_NO_SIGNAL_HANDLERS=1
echo "Executing: ${dbgApp} ${debuggerArgs} ${maya}"
if [[ ! "${mayaArgs}" =~ "" ]]; then
echo "Maya args: ${mayaArgs}"
fi
eval "${dbgApp}" "${debuggerArgs}" "${maya}" "${mayaArgs}"
exit "$?"
else
#echo "running: ${maya}"
noSpaceMaya=$(echo $maya | sed -e 's/ /\\ /g')
eval "$noSpaceMaya" "${mayaArgs}"
exit "$?"
fi
fi
fi
if [ ! $maya ]; then
set maya = "${maya_exec}"
fi
if [ "$tty" == 1 ]; then
echo The Maya executable \(\`${maya}\'\) cannot be found
fi
exit 1
#*+
#* ==========================================================================
#* The information in this file is provided for the exclusive use of the
#* licensees of Alias Systems Corp. Such users have the right to use, modify,
#* and incorporate this code into other products for purposes authorized
#* by the Alias Systems Corp. license agreement, without fee.
#*
#* Alias Systems Corp. disclaims all warranties with regard to this software,
#* including all implied warranties of merchantability and fitness. In no
#* event shall Alias Systems Corp. be liable for any special, indirect or
#* consequential damages or any damages whatsoever resulting from loss of
#* use, data or profits, whether in an action of contract, negligence or
#* other tortious action, arising out of or in connection with the use or
#* performance of this software.
#* ==========================================================================
#*-
Just copy that into your maya bin folder i.e. "/usr/autodesk/maya2018/bin" and save it as "maya2018" or whatever version your using. If its in the same location as maya.bin it should work. You may need to overwrite the one that's there.
You may need to then make sure you run Jibwood's solution to the python hashlib issue:
mv /usr/autodesk/maya2018/lib/python2.7/lib-dynload/_hashlib.so /usr/autodesk/maya2018/lib/python2.7/lib-dynload/rhel_hashlib.so
ln -s /usr/lib/python2.7/lib-dynload/_hashlib.x86_64-linux-gnu.so /usr/autodesk/maya2018/lib/python2.7/lib-dynload/_hashlib.so
maya: Autodesk Maya 2017Licensing ErrorA licensing error
hi, did you fix it now? I got the same problem now!
and I have tried like this "maya /usr/autodesk/maya2017/bin/adlmreg -i N ----- ----- 2017.0.0.F ----- /var/opt/Autodesk/Adlm/Maya2017/MayaConfig.pit" and "/usr/autodesk/maya2017/bin/adlmreg -i N ------ ------ 2017.0.0.F ----- /var/opt/Autodesk/Adlm/Maya2017/MayaConfig.pit"
(https://knowledge.autodesk.com/support/maya/troubleshooting/caas/sfdcarticles/sfdcarticles/Unable-to-launch-Maya-on-Linux-error-error-checkoutLicense-Failed-to-authorize-license.html)
they all not work and got new problem
"libadlmutil.so: cannot open shared object file: No such file or directory"
hey, Borgfriend!
thank you so much for the script. I tried to adapt it to maya 2016 (the latest version I have a license for) and it ran with no real issues. When I try to start maya up, however, I get the following:
Any Idea what could be going wrong? I am using the Nvidia third-party drivers.