GithubHelp home page GithubHelp logo

joss13aws / maya-cmake Goto Github PK

View Code? Open in Web Editor NEW

This project forked from volodinroman/maya-cmake

0.0 0.0 0.0 24 KB

Autodesk Maya cross-platform development environment with CMake

License: MIT License

CMake 73.88% C++ 26.12%

maya-cmake's Introduction

CMake for Maya

CMake module for Autodesk Maya. Works on Windows, OSX and Linux.

Usage:

  • Download and install CMake from https://cmake.org and check if it works typing "cmake -h" in your terminal

  • Download Autodesk Maya SDK for your version of Maya and place the SDK content in MayaPlugins/SDK/maya20xx folder (the structure of MayaPlugins build environment is attached here)

  • Run a terminal and make ~/MayaPlugins/build folder as a current folder

  • For Windows users: type cmake -G "Visual Studio 15 2017 Win64" ../ using your version of Vusial Studio

  • If we want to build a plugin for some specific maya version, we use cmake G "Visual Studio 15 2017 Win64" -DMAYA_VERSION=2016 ../

  • For Linux users: type cmake -G "Unix makefiles" ../

  • For OSX users: type cmake -G "Xcode" ../ or cmake -G "Unix Makefiles" ../

  • After building the solution (sln) we can compile it with cmake --build . --config Release. It is important that the current dir is the build one, where the solution files are located.

  • If we want to copy compiled plug-in somewhere (maya plugins folder), we use cmake --build . --config Release --target Install. It will copy the built plug-in to a folder, specified with CMAKE_INSTALL_PREFIX (CMakeLists.txt)

Some notes:

  • In Linux source building procedure creates Makefile, which we can compile into .so file (the actual plug-in), using make -f Makefile.
  • Code editors (sublime, vscode etc.) have CMake syntax highlighters, that can be downloaded from app markets.
  • In the root folder of the project should be a CMakeLists.txt, which contains rules of building and compiling plugins.
  • We can create extra CMake modules for finding specific includes and libs (not only Maya SDK but some others). These modules should be named Find{NAME}.cmake, like FindMaya.cmake. This module should be included to CMakeLists.txt.
  • When we build solutions for VS or XCode, when we open them in the editors, we can see ZERO_CHECK and ALL_BUILD projects. ZERO_CHECK - reloads cmake files if we did some changes there. Like if we decided to change a path where compiled plugins will be located, we don't have to rebuild the solution from a terminal. To turn off this project, in CMakeLists.txt we should set(CMAKE_SUPPRESS_REGENERATION true). ALL_BUILD builds all projects in the currently opened solution.

maya-cmake's People

Contributors

volodinroman avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.