Building houdini engine plugin for maya

   4038   5   1
User Avatar
Member
20 posts
Joined: Feb. 2011
Offline
Hi
Am trying to build the houdini engine plugin for maya on a Linux platform and i have given all path correctly now i get this error, can anyone tell me if am doing some thing wrong or i have missed some information here

make
echo “+ houdiniEngine 1.5 /srv/scratch/hengineplug/engine/maya/maya2014.6” > /srv/scratch/hengineplug/engine/maya/maya2014.6/houdiniEngine-maya2014.6
g++ -c -MMD -MP -MT .obj/maya2014.6/AssetNode.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/AssetNode.o AssetNode.C
AssetNode.C: In member function ‘virtual int AssetNode::internalArrayCount(const MPlug&, const MDGContext&) const’:
AssetNode.C:1525: error: ‘struct HAPI_AssetInfo’ has no member named ‘geoInputCount’
make: *** Error 1
User Avatar
Member
818 posts
Joined: Sept. 2013
Offline
It seems like you're compiling against Houdini 13.0.401. It's likely because the version of the Maya plug-in code that you have doesn't match with the Houdini version that you're compiling against. The Engine API is independent from the HDK, and could change from one Houdini build to the next. For example, in this case, “geoInputCount” is added after 13.0.401, so the code doesn't compile against your version of Houdini.

The simplest way is to update your Houdini to the latest 13.0 or 14.0, so that you can simply use the latest code.

Or, if you want to use your version of Houdini, you could checkout an older commit from the repo. If you look at the log of the HoudiniVersion file:
https://github.com/sideeffects/HoudiniEngineForMaya/commits/Houdini13.0/HoudiniVersion [github.com]
you can see when the changes to the code and API happens. To find the right version of the code, the safest commit would be the commit right before the next version bump. For example, the next version bump after 13.0.401 is 13.0.402, which corresponds to 451b027519f68629119ebc298bb713265dc68d1b [github.com]. So you'd want the commit before that (451b027519f68629119ebc298bb713265dc68d1b^), which is equivalent to 290fa76d7c5e53171ada8ce367019f1112ad601d [github.com]. This commit would be the exact code that the Maya plug-in was compiled with in Houdini 13.0.401.
Andrew / アンドリュー
User Avatar
Member
20 posts
Joined: Feb. 2011
Offline
@andrew thanks a lot, I got it .
User Avatar
Member
20 posts
Joined: Feb. 2011
Offline
I managed to build this and now i get a error trying to load this in maya, wondering if I have to add any LD_LIBRARY path or something to my maya environment

// Error: file: /apps/shared/maya/2014.6/scripts/others/pluginWin.mel line 658: Unable to dynamically load : /srv/scratch/hengineplug/engine/maya/maya2014.6/plug-ins/houdiniEngine.so
libHAPI.so: cannot open shared object file: No such file or directory //
// Error: file: /apps/shared/maya/2014.6/scripts/others/pluginWin.mel line 658: libHAPI.so: cannot open shared object file: No such file or directory (houdiniEngine) //



And below is the warnings i got when i build the plugin


g++ -c -MMD -MP -MT .obj/maya2014.6/AssetNode.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/AssetNode.o AssetNode.C
g++ -c -MMD -MP -MT .obj/maya2014.6/AssetCommand.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/AssetCommand.o AssetCommand.C
g++ -c -MMD -MP -MT .obj/maya2014.6/AssetSubCommand.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/AssetSubCommand.o AssetSubCommand.C
g++ -c -MMD -MP -MT .obj/maya2014.6/AssetSubCommandLoadAsset.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/AssetSubCommandLoadAsset.o AssetSubCommandLoadAsset.C
g++ -c -MMD -MP -MT .obj/maya2014.6/AssetSubCommandSync.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/AssetSubCommandSync.o AssetSubCommandSync.C
g++ -c -MMD -MP -MT .obj/maya2014.6/Asset.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/Asset.o Asset.C
Asset.C: In member function ‘void Asset::computeGeometryObjects(const MPlug&, MDataBlock&, bool&)’:
Asset.C:579: warning: comparison between signed and unsigned integer expressions
g++ -c -MMD -MP -MT .obj/maya2014.6/Input.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/Input.o Input.C
g++ -c -MMD -MP -MT .obj/maya2014.6/InputAsset.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/InputAsset.o InputAsset.C
g++ -c -MMD -MP -MT .obj/maya2014.6/InputMesh.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/InputMesh.o InputMesh.C
g++ -c -MMD -MP -MT .obj/maya2014.6/InputCurve.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/InputCurve.o InputCurve.C
g++ -c -MMD -MP -MT .obj/maya2014.6/InputParticle.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/InputParticle.o InputParticle.C
g++ -c -MMD -MP -MT .obj/maya2014.6/OutputObject.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/OutputObject.o OutputObject.C
OutputObject.C: In constructor ‘OutputObject::OutputObject(int, int, Asset*)’:
OutputObject.C:46: warning: unused variable ‘hstat’
OutputObject.C: In member function ‘virtual void OutputObject::update()’:
OutputObject.C:68: warning: unused variable ‘hstat’
g++ -c -MMD -MP -MT .obj/maya2014.6/util.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/util.o util.C
g++ -c -MMD -MP -MT .obj/maya2014.6/OutputGeometryObject.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/OutputGeometryObject.o OutputGeometryObject.C
OutputGeometryObject.C: In member function ‘virtual MStatus OutputGeometryObject::compute(MDataHandle&, bool&)’:
OutputGeometryObject.C:74: warning: comparison between signed and unsigned integer expressions
g++ -c -MMD -MP -MT .obj/maya2014.6/OutputInstancerObject.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/OutputInstancerObject.o OutputInstancerObject.C
OutputInstancerObject.C: In member function ‘virtual MStatus OutputInstancerObject::compute(MDataHandle&, bool&)’:
OutputInstancerObject.C:191: warning: comparison between signed and unsigned integer expressions
OutputInstancerObject.C:197: warning: comparison between signed and unsigned integer expressions
g++ -c -MMD -MP -MT .obj/maya2014.6/OutputGeometry.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/OutputGeometry.o OutputGeometry.C
OutputGeometry.C: In member function ‘MStatus OutputGeometry::compute(MDataHandle&, bool&)’:
OutputGeometry.C:121: warning: comparison between signed and unsigned integer expressions
g++ -c -MMD -MP -MT .obj/maya2014.6/OutputGeometryPart.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/OutputGeometryPart.o OutputGeometryPart.C
g++ -c -MMD -MP -MT .obj/maya2014.6/SyncAttribute.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/SyncAttribute.o SyncAttribute.C
SyncAttribute.C: In member function ‘virtual void CreateAttrOperation::pushFolder(const HAPI_ParmInfo&)’:
SyncAttribute.C:68: warning: unused variable ‘parentAttrFn’
SyncAttribute.C:69: warning: unused variable ‘parentParmInfo’
SyncAttribute.C: In member function ‘virtual void CreateAttrOperation::pushMultiparm(const HAPI_ParmInfo&)’:
SyncAttribute.C:121: warning: unused variable ‘parentParmInfo’
g++ -c -MMD -MP -MT .obj/maya2014.6/SyncOutputObject.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/SyncOutputObject.o SyncOutputObject.C
g++ -c -MMD -MP -MT .obj/maya2014.6/SyncOutputGeometryPart.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/SyncOutputGeometryPart.o SyncOutputGeometryPart.C
g++ -c -MMD -MP -MT .obj/maya2014.6/SyncOutputInstance.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/SyncOutputInstance.o SyncOutputInstance.C
SyncOutputInstance.C: In member function ‘MStatus SyncOutputInstance::createOutput()’:
SyncOutputInstance.C:251: warning: comparison between signed and unsigned integer expressions
SyncOutputInstance.C:256: warning: comparison between signed and unsigned integer expressions
SyncOutputInstance.C:259: warning: unused variable ‘doneInstancing’
g++ -c -MMD -MP -MT .obj/maya2014.6/FluidVelocityConvert.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/FluidVelocityConvert.o FluidVelocityConvert.C
g++ -c -MMD -MP -MT .obj/maya2014.6/plugin.o -D_BOOL -DREQUIRE_IOSTREAM -I/apps/shared/maya/2014.6//include -I/apps/shared/houdini/13.0.401/custom/houdini/include -I/apps/shared/houdini/13.0.401/toolkit/include -Wall -m64 -pthread -pipe -fPIC -g -o .obj/maya2014.6/plugin.o plugin.C
g++ -shared -Wl,-rpath,'$ORIGIN/../../../../dsolib' -Wl,-Bsymbolic -o /srv/scratch/hengineplug/engine/maya/maya2014.6/plug-ins/houdiniEngine.so .obj/maya2014.6/AssetNode.o .obj/maya2014.6/AssetCommand.o .obj/maya2014.6/AssetSubCommand.o .obj/maya2014.6/AssetSubCommandLoadAsset.o .obj/maya2014.6/AssetSubCommandSync.o .obj/maya2014.6/Asset.o .obj/maya2014.6/Input.o .obj/maya2014.6/InputAsset.o .obj/maya2014.6/InputMesh.o .obj/maya2014.6/InputCurve.o .obj/maya2014.6/InputParticle.o .obj/maya2014.6/OutputObject.o .obj/maya2014.6/util.o .obj/maya2014.6/OutputGeometryObject.o .obj/maya2014.6/OutputInstancerObject.o .obj/maya2014.6/OutputGeometry.o .obj/maya2014.6/OutputGeometryPart.o .obj/maya2014.6/SyncAttribute.o .obj/maya2014.6/SyncOutputObject.o .obj/maya2014.6/SyncOutputGeometryPart.o .obj/maya2014.6/SyncOutputInstance.o .obj/maya2014.6/FluidVelocityConvert.o .obj/maya2014.6/plugin.o -L/apps/shared/maya/2014.6//lib -lOpenMaya -lOpenMayaFX -lFoundation -L/apps/shared/houdini/13.0.401/dsolib -lHAPI
cp AEhoudiniAssetTemplate.mel /srv/scratch/hengineplug/engine/maya/maya2014.6/scripts/AEhoudiniAssetTemplate.mel
cp hapiDebugWindow.mel /srv/scratch/hengineplug/engine/maya/maya2014.6/scripts/hapiDebugWindow.mel
cp houdiniEngineCreateUI.mel /srv/scratch/hengineplug/engine/maya/maya2014.6/scripts/houdiniEngineCreateUI.mel
cp houdiniEngineDeleteUI.mel /srv/scratch/hengineplug/engine/maya/maya2014.6/scripts/houdiniEngineDeleteUI.mel
cp houdiniEngineAssetLibraryManager.mel /srv/scratch/hengineplug/engine/maya/maya2014.6/scripts/houdiniEngineAssetLibraryManager.mel
cp houdiniEngineUtils.mel /srv/scratch/hengineplug/engine/maya/maya2014.6/scripts/houdiniEngineUtils.mel
cp houdiniEngineAssetSync.mel /srv/scratch/hengineplug/engine/maya/maya2014.6/scripts/houdiniEngineAssetSync.mel
User Avatar
Member
818 posts
Joined: Sept. 2013
Offline
tarjun
I managed to build this and now i get a error trying to load this in maya, wondering if I have to add any LD_LIBRARY path or something to my maya environment

You'll probably need to adjust the rpath linker option. When the plugin gets built with Houdini, the plugin files are placed inside the HFS. So we can specify a relative rpath and the plugin would be able to load the necessary Houdini libraries. That's what the “$ORIGIN/../../../../dsolib” means.

But this probably won't work in your case, since you likely won't be putting the files inside HFS. Depending on how you deploy software, one option might be to use a hardcoded rpath. This would be like embedding the LD_LIBRARY_PATH into the binary, which is quite convenient. If this isn't possible, then you'd have to set the LD_LIBRARY_PATH manually before you load Maya.
Edited by - April 22, 2015 01:42:35
Andrew / アンドリュー
User Avatar
Member
20 posts
Joined: Feb. 2011
Offline
Awesome all working fine now
  • Quick Links