Skip to content

Commit 0f78489

Browse files
Add experimental support for Maya 2024 on Linux
1 parent 232755e commit 0f78489

File tree

2 files changed

+182
-0
lines changed

2 files changed

+182
-0
lines changed
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
#!/usr/bin/env bash
2+
#
3+
# Copyright (C) 2019, 2022, 2023 David Cattermole.
4+
#
5+
# This file is part of mmSolver.
6+
#
7+
# mmSolver is free software: you can redistribute it and/or modify it
8+
# under the terms of the GNU Lesser General Public License as
9+
# published by the Free Software Foundation, either version 3 of the
10+
# License, or (at your option) any later version.
11+
#
12+
# mmSolver is distributed in the hope that it will be useful,
13+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
14+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15+
# GNU Lesser General Public License for more details.
16+
#
17+
# You should have received a copy of the GNU Lesser General Public License
18+
# along with mmSolver. If not, see <https://www.gnu.org/licenses/>.
19+
# ---------------------------------------------------------------------
20+
#
21+
# Builds the Maya MatchMove Solver project.
22+
23+
# Maya
24+
MAYA_VERSION=2024
25+
MAYA_LOCATION=/usr/autodesk/maya2024/
26+
27+
# Executable names/paths used for build process.
28+
PYTHON_EXE=python3
29+
CMAKE_EXE=cmake3
30+
RUST_CARGO_EXE=cargo
31+
32+
# C++ Standard to use.
33+
CXX_STANDARD=14
34+
35+
# The -e flag causes the script to exit as soon as one command returns
36+
# a non-zero exit code.
37+
set -ev
38+
39+
CWD=`pwd`
40+
41+
# This 'source' defines the bash variables
42+
# 'MMSCENEGRAPH_LIB_DIR' and 'MMSCENEGRAPH_INCLUDE_DIR'.
43+
#
44+
# The script assumes 'RUST_CARGO_EXE' has been set to the Rust
45+
# 'cargo' executable.
46+
source "${CWD}/scripts/internal/build_mmscenegraph_linux.bash"
47+
48+
source "${CWD}/scripts/internal/build_mmSolver_linux.bash"
49+
50+
cd ${CWD}

share/docker/Dockerfile_maya2024

Lines changed: 132 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,132 @@
1+
# To create and run the docker container in PowerShell or BASH:
2+
#
3+
# $ docker build --file share/docker/Dockerfile_maya2024 -t mmsolver-linux-maya2024-build .
4+
# $ docker run --rm --interactive --volume "${pwd}:/mmSolver" --tty mmsolver-linux-maya2024-build
5+
#
6+
#
7+
# Once the docker image is built and run, you can execute the
8+
# following...
9+
#
10+
#
11+
# Install Python and run tools:
12+
#
13+
# $ source ./scripts/python_venv_activate_maya2024.bash
14+
# $ ./scripts/python_linter_run_pylint.bash
15+
# $ ./scripts/python_linter_run_flake8.bash
16+
# $ ./scripts/python_linter_run_cpplint.bash
17+
# $ ./scripts/python_formatter_run_black_check.bash
18+
# $ deactivate
19+
#
20+
#
21+
# Build CMake project:
22+
#
23+
# $ ./scripts/build_mmSolver_linux_maya2024.bash
24+
# $ mayapy tests/runTests.py
25+
#
26+
27+
FROM rockylinux:8
28+
29+
# Maya documentation for installing on RHEL8 / Rocky8:
30+
# https://help.autodesk.com/view/MAYAUL/2024/ENU/?guid=GUID-D2B5433C-E0D2-421B-9BD8-24FED217FD7F
31+
#
32+
# And this forum post:
33+
# https://forums.autodesk.com/t5/maya-forum/install-maya-2023-update-3-on-rocky-linux-8-7-instructions/td-p/11735138
34+
35+
RUN dnf install --assumeyes https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm && dnf install --assumeyes epel-release && dnf makecache
36+
37+
# General packages
38+
RUN dnf install --assumeyes \
39+
glibc \
40+
libSM \
41+
libICE \
42+
zlib \
43+
openssl-libs \
44+
nss \
45+
libnsl \
46+
dbus \
47+
redhat-lsb-core \
48+
pcre-utf16
49+
50+
# Multimedia Packages
51+
RUN dnf install --assumeyes \
52+
mesa-libGLU \
53+
mesa-libGLw \
54+
gamin \
55+
audiofile-devel \
56+
e2fsprogs-libs \
57+
libcap \
58+
libdrm \
59+
libmng \
60+
speech-dispatcher \
61+
cups \
62+
libpng15
63+
# flite
64+
65+
# X Window – Xcb – X11 Packages
66+
RUN dnf install --assumeyes \
67+
libXau \
68+
libXcomposite \
69+
libXcursor \
70+
libXext \
71+
libXfixes \
72+
libXi \
73+
libXmu \
74+
libXp \
75+
libXrandr \
76+
libXrender \
77+
libXScrnSaver \
78+
libxshmfence \
79+
libXt \
80+
libXtst \
81+
libXinerama \
82+
libxcb \
83+
xcb-util \
84+
xcb-util-wm \
85+
xcb-util-image \
86+
xcb-util-keysyms \
87+
xcb-util-renderutil \
88+
libxkbcommon \
89+
libxkbcommon-x11 \
90+
libX11
91+
92+
# Install fonts needed by Maya.
93+
# This is probably only needed by the GUI (which we will not open),
94+
# but it's good to have everything needed, just in case.
95+
RUN dnf install --assumeyes \
96+
fontconfig \
97+
freetype \
98+
xorg-x11-fonts-ISO8859-1-100dpi \
99+
xorg-x11-fonts-ISO8859-1-75dpi \
100+
liberation-mono-fonts \
101+
liberation-fonts-common \
102+
liberation-sans-fonts \
103+
liberation-serif-fonts
104+
105+
# Install latest stable Rust with 'rustup'.
106+
#
107+
# TODO: Define a minimum Rust version to install.
108+
RUN curl https://sh.rustup.rs -sSf | sh -s -- -y \
109+
&& source ${HOME}/.cargo/env
110+
111+
# Development tools for Maya 2024.
112+
RUN dnf install --assumeyes \
113+
git \
114+
python3 \
115+
cmake \
116+
clang-tools-extra \
117+
gcc-toolset-11
118+
119+
# Install Maya from archive.
120+
ADD ./external/archives/Autodesk_Maya_2024_Linux_64bit.tgz /temp
121+
RUN rpm -Uvh --force /temp/Packages/Maya2024*.rpm && rm -r /temp
122+
ENV MAYA_LOCATION=/usr/autodesk/maya/
123+
ENV PATH=$MAYA_LOCATION/bin:$PATH
124+
125+
# Workaround for Maya "Segmentation fault (core dumped)" issue.
126+
# See https://forums.autodesk.com/t5/maya-general/render-crash-on-linux/m-p/5608552/highlight/true
127+
ENV MAYA_DISABLE_CIP=1
128+
129+
WORKDIR /mmSolver
130+
131+
# Maya 2024 development environment.
132+
ENTRYPOINT [ "scl", "enable", "gcc-toolset-11", "bash" ]

0 commit comments

Comments
 (0)