Author Topic: Almost there: module builds on Linux but doesn't import  (Read 6783 times)

Offline Nocturnal

  • PixInsight Jedi Council Member
  • *******
  • Posts: 2727
    • http://www.carpephoton.com
Quote
*** Error: Module metadata is not available!
Please instantiate a MetaModule descendant upon module installation.
sh: xmessage: command not found

*** Error: <* Warning *> Possible hacking attempt: Invalid API identification call.
sh: xmessage: command not found
^Z


PixInsight Core 01.04.05.0467 (x86)
Copyright © 2003-2009 Pleiades Astrophoto
----------------------------------------------------------------------
Welcome to PixInsight. Started 2009 May 01 21:38:28 J2454953.40171 UTC

* PSM AutoSave enabled. Auto-save period: 30 seconds.

Installing 1 module(s):
/home/sander/pcl/bin/Debayer-pxm.so
<* failed *>
*** PixInsight API Error: Module: /home/sander/pcl/bin/Debayer-pxm.so: Module identification error: Exit code: 1
*** Warning: No modules were installed.

The only error dialog PI throws up is one about libssl.so not being available. I suppose that could be the cause of this problem. I'll try to find a libssl.so for this (virtual) box.
Best,

    Sander
---
Edge HD 1100
QHY-8 for imaging, IMG0H mono for guiding, video cameras for occulations
ASI224, QHY5L-IIc
HyperStar3
WO-M110ED+FR-III/TRF-2008
Takahashi EM-400
PIxInsight, DeepSkyStacker, PHD, Nebulosity

Offline Nocturnal

  • PixInsight Jedi Council Member
  • *******
  • Posts: 2727
    • http://www.carpephoton.com
Re: Almost there: module builds on Linux but doesn't import
« Reply #1 on: 2009 May 01 14:54:32 »
Alright, openssl was installed so I linked libssl.so to /lib/libssl.so.7. Now PI doesn't complain about the lack of the library anymore so I guess this is OK. The module still doesn't import though. The same code works fine with Windows so I'm missing some linux specific stuff here it seems. Any pointers would be appreciated. Thanks!
Best,

    Sander
---
Edge HD 1100
QHY-8 for imaging, IMG0H mono for guiding, video cameras for occulations
ASI224, QHY5L-IIc
HyperStar3
WO-M110ED+FR-III/TRF-2008
Takahashi EM-400
PIxInsight, DeepSkyStacker, PHD, Nebulosity

Offline Juan Conejero

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 7111
    • http://pixinsight.com/
Re: Almost there: module builds on Linux but doesn't import
« Reply #2 on: 2009 May 01 15:03:12 »
Hi Sander,

That error happens because there is no MetaModule definition in your module. Every PI module must define a MetaModule descendant class. Are you sure you're including your xxxModule.cpp in your makefile?

On the other hand, the error with libssl.so shouldn't happen. Are you running PI with PixInsight.sh ? Don't try to run the PixInsight executable directly, because on Linux the dynamic loader requires the LD_LIBRARY_PATH environmental variable correctly defined. PixInsight.sh precisely does that before invoking the PixInsight executable.

Please cd to the bin installation directory and issue the following command:

Code: [Select]
export LD_LIBRARY_PATH="./:./lib"; ldd ./PixInsight
The output of this ldd command will let us know where are all the modules needed by the main executable.
Juan Conejero
PixInsight Development Team
http://pixinsight.com/

Offline Nocturnal

  • PixInsight Jedi Council Member
  • *******
  • Posts: 2727
    • http://www.carpephoton.com
Re: Almost there: module builds on Linux but doesn't import
« Reply #3 on: 2009 May 01 15:06:04 »
Hi Juan,

hmm, let me verify with my makefile to make sure that module is included in the link phase.

As for the LD_LIBRARY_PATH, I could not find any linux instructions so I'm kind of fumbling in the dark. You know, stubbing toes against the bed post :) In any event, I set LD_LIBRARY_PATH in my .bashrc so PI now starts without issue. As I reported elsewhere the libssl.so link pointed at a non-existing file so I assumed I had to relink it to my local copy. That's what I did and now it works.
Best,

    Sander
---
Edge HD 1100
QHY-8 for imaging, IMG0H mono for guiding, video cameras for occulations
ASI224, QHY5L-IIc
HyperStar3
WO-M110ED+FR-III/TRF-2008
Takahashi EM-400
PIxInsight, DeepSkyStacker, PHD, Nebulosity

Offline Nocturnal

  • PixInsight Jedi Council Member
  • *******
  • Posts: 2727
    • http://www.carpephoton.com
Re: Almost there: module builds on Linux but doesn't import
« Reply #4 on: 2009 May 01 15:18:37 »
Indeed the Module file wasn't included in my makefile. The dangers of copy and paste :) It now imports. And runs :)
Best,

    Sander
---
Edge HD 1100
QHY-8 for imaging, IMG0H mono for guiding, video cameras for occulations
ASI224, QHY5L-IIc
HyperStar3
WO-M110ED+FR-III/TRF-2008
Takahashi EM-400
PIxInsight, DeepSkyStacker, PHD, Nebulosity

Offline Juan Conejero

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 7111
    • http://pixinsight.com/
Re: Almost there: module builds on Linux but doesn't import
« Reply #5 on: 2009 May 01 15:25:12 »
Congratulations! :D

Your first PI module on two platforms in less than a week. Very impressive  8)
Juan Conejero
PixInsight Development Team
http://pixinsight.com/