You Are Here:

Community: Developer Discussion Boards

#1 Old DLL ImportError on pys60 1.9.2 on 5th ed. device - 2009-03-12, 10:16

Join Date: Feb 2009
Posts: 10
mauso
Offline
Registered User
I have developed an extension module on pys60 1.9.2 with S60 5th edition SDK. I am able to load and use the extension in 5th ed. emulator but trying to import it into target device's python runtime (Nokia 5800) fails with the not-too-specific "ImportError: Error in loading dll"

I'm using the high_capas devcert-signed version of python runtime and script shell and also signed my own sis containing the .pyd-file with the same certificate and high capabilities. Not sure though what capabilities do the runtime+script shell exactly have but for my own sis I used all those capabilities listed in PyS60_1_9_x_README.txt chapter 5 (included in pys60 src distribution). I also followed the instructions about file locations and made my sis to install the .pyd-file into c:\sys\bin

I think the basics should be OK as I'm able to load and use the extension in emulator.

What checks should I do in the first place in order to solve the problem?

Is there any means to check that the sis-installer really copied the .pyd file into c:\sys\bin? Because I think that the same ImportError is given when the imported .pyd-file just does not exist.
Reply With Quote

#2 Old Re: DLL ImportError on pys60 1.9.2 on 5th ed. device - 2009-03-13, 04:30

Join Date: Apr 2007
Posts: 131
mahesh.sayibabu's Avatar
mahesh.sayibabu
Offline
Regular Contributor
Quote:
Originally Posted by mauso View Post
I have developed an extension module on pys60 1.9.2 with S60 5th edition SDK. I am able to load and use the extension in 5th ed. emulator but trying to import it into target device's python runtime (Nokia 5800) fails with the not-too-specific "ImportError: Error in loading dll"

I'm using the high_capas devcert-signed version of python runtime and script shell and also signed my own sis containing the .pyd-file with the same certificate and high capabilities. Not sure though what capabilities do the runtime+script shell exactly have but for my own sis I used all those capabilities listed in PyS60_1_9_x_README.txt chapter 5 (included in pys60 src distribution). I also followed the instructions about file locations and made my sis to install the .pyd-file into c:\sys\bin

I think the basics should be OK as I'm able to load and use the extension in emulator.

What checks should I do in the first place in order to solve the problem?

Is there any means to check that the sis-installer really copied the .pyd file into c:\sys\bin? Because I think that the same ImportError is given when the imported .pyd-file just does not exist.
There are tools available(for example SISContents) that helps you to analyze the SIS file that you create. Check the package structure and also the capabilities of each PYD file in it.

Also, make sure that the init function is at ordinal 1. You might have to manually edit the .def file.

----
Mahesh
PyS60 Team
Reply With Quote

#3 Old Re: DLL ImportError on pys60 1.9.2 on 5th ed. device - 2009-03-13, 12:49

Join Date: Feb 2009
Posts: 10
mauso
Offline
Registered User
Thanks for good tips. SISContents seems to be a handy tool. Everything in my sis seemed to be ok though, including structure and capabilities. I also checked the def-file and MODULE_INIT_FUNC was the first one there.

Don't know how to go on
Reply With Quote

#4 Old Re: DLL ImportError on pys60 1.9.2 on 5th ed. device - 2009-03-14, 10:10

Join Date: Oct 2007
Posts: 114
ashwinurao
Offline
Regular Contributor
Quote:
Originally Posted by mauso View Post
Thanks for good tips. SISContents seems to be a handy tool. Everything in my sis seemed to be ok though, including structure and capabilities. I also checked the def-file and MODULE_INIT_FUNC was the first one there.

Don't know how to go on
Is your pyd named "251_xxx.pyd" (Where xxx is the module name)?


import antigravity
Reply With Quote

#5 Old Re: DLL ImportError on pys60 1.9.2 on 5th ed. device - 2009-09-29, 13:51

Join Date: Feb 2009
Posts: 7
pavc
Offline
Registered User
Hello,

I'm facing a similar problem...

How did you solve the issue?

Pedro
Reply With Quote
Reply « Previous Thread | Next Thread »
Display Modes
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Rate This Thread
Rate This Thread:

Posting Rules

You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump
Similar Threads
Thread Thread Starter Forum Replies Last Post
Dll deployment on device problem iulian_moldovan General Symbian C++ 6 2006-02-14 14:05
How to compile a dll for the target device? nmnir General Symbian C++ 4 2006-01-18 07:42
Bluetooth Security: What exactly is an untrusted device? rahulmcs Bluetooth Technology 1 2005-12-02 07:26
Problem building a dll for target device rushj General Symbian C++ 1 2005-08-09 15:19
On device, E32Dll will never be called (as dll entry point)? trendin General Symbian C++ 2 2004-11-17 01:46

Rate This

 
Bookmark this page: DeliciousDiggFacebookGoogleYahooStumbleUponRedditDiigoTechnocratiTwitter  Share this page Share this page Print this Page Print this page Invite a friend Invite a friend
京ICP备05048969号    Email Newsletters Press Terms & Conditions Privacy Policy Sitemap Contact Us © 2009 Nokia