Current Maya version among multiple maya installations..

Current Maya version among multiple maya installations..

Post by Akshay Lok » Wed, 09 Jul 2008 05:15:04

Hi all,
I am a very recent convert to the Linux world, and am trying to port a
windows maya plugin app onto Linux..

If i compile one of my cpp files, I get the error:
error: `MTypeId' does not name a type

and plenty of other such Maya API related errors... In order to solve
these, I would need to include the necessary library paths while
giving the 'gcc' compile command using the -I option, right?

Now I would like to know which is the maya version which is running on
my system. The machine which has been given to me has lots of maya
installations on it, and hence I don't know exactly which maya
installation (libraries, includes, etc. ) should I point my code to?

Many thanks,

Current Maya version among multiple maya installations..

Post by John McCal » Fri, 11 Jul 2008 00:12:26


Well it's not the library paths you want for that error, it's the header
files, but yes you would add the search path to the header files through
the -I option.

At the link step you will require the library paths, which you can specify
with the -L option (and specific library files with the lowercase
equivalent: -l).

Presumably these are all working installations. So, you should be able to
run all the versions on the machine. If so, you should be able to build
against any of them and find your plugin runs with that installation.

While I'm not familiar with Maya plugin development, most systems for C/C++
will provide a define from the header files which indicates the version,
possibly called something akin to MAYA_VERSION. With this you should be
able to get your plugin running with all of the versions installed.

John McCallum


Current Maya version among multiple maya installations..

Post by Akshay Lok » Wed, 16 Jul 2008 07:32:10

On Jul 9, 9:12m, John McCallum < XXXX@XXXXX.COM >

Thanks John... I tried the thing about the header files using the -I
option and that worked.. i have got myself a nice little makefile now
to compile the source code.. and its going smoothly..

Yup... Most of them are working installations, and I just selected the
version which was most similar to the one on windows.. i just needed
to declare an env variable containing the path to the maya
installation, in order to give the paths to the maya header files...

Many thanks again,