Re: [Vm-dev] Fwd: loading library with FFI fails (was Linux vm: assertions and strategy)

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: [Vm-dev] Fwd: loading library with FFI fails (was Linux vm: assertions and strategy)

Schwab,Wilhelm K
Ian,

I cannot ignore what was never delivered to me - you might want to reconsider your logic in this connection.  You might also note that #moduleName can check the OS, so "it will never work on Windows" is just plain wrong.

Later in the day I will revert to your vm and try 'odb' - I will admit to being less than optimistic, especially given what I "ignored" - make that never received.

Bill



-----Original Message-----
From: Ian Piumarta [mailto:[hidden email]]
Sent: Friday, April 09, 2010 2:25 AM
To: Schwab,Wilhelm K
Cc: laurent laffont
Subject: Re: [Vm-dev] Fwd: loading library with FFI fails (was [Pharo-project] Linux vm: assertions and strategy)

On Apr 8, 2010, at 11:40 PM, Ian Piumarta wrote:

> I have no idea.  I sent email to Bill with a suggestion but he ignored
> me.  I therefore have no information about whether there is something
> funny in his Linux installation or whether there is a real problem in
> the VM (which appears to work fine for me).

I could be completely wrong about this.  If so, please disregard.  
But...

 From the patch I am inferring that the odbc library specifies
"module: '/usr/lib/libodbc.so'".  This would indeed be a problem for three reasons.

1. Mine might be in /usr/local/lib, or might be a personally-compiled version to fix some issue with the system version.  In either case I'm screwed.

2. I might be using Darwin, in which case '/usr/lib/libodbc.dylib'  
might be the only thing that would work -- or even '/System/Library/ Frameworks/ODBCFramework/Libraries/libodbc.dylib'.  Same comment as before.

3. It will never work on Windows, even if some day Windows supplies an 'odbc.dll' that is 100% compatible with the Linux one.

The usual way for the plugin to specify this library would be "module:  
'odbc'" which should work perfectly in all the above cases using the latest VM (and explains why I could not reproduce the problem using a simpler test case).  I'm happy to modify the VM to cater for this specific situation of an over-specified library name, but the real solution would be fix the primitive declarations in the ODBC plugin.

Cheers,
Ian


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: [Vm-dev] Fwd: loading library with FFI fails (was Linux vm: assertions and strategy)

Schwab,Wilhelm K
Ian,

I will try what you want.



-----Original Message-----
From: Ian Piumarta [mailto:[hidden email]]
Sent: Friday, April 09, 2010 5:42 AM
To: Schwab,Wilhelm K
Cc: laurent laffont; [hidden email]
Subject: Re: [Vm-dev] Fwd: loading library with FFI fails (was [Pharo-project] Linux vm: assertions and strategy)

Hi Bill,

On Apr 9, 2010, at 3:24 AM, Schwab,Wilhelm K wrote:

> I cannot ignore what was never delivered to me - you might want to
> reconsider your logic in this connection.

My initial assumption appears to be incorrect and so the suggestion I sent not to be relevant to debugging your problem.  But the original is attached in case you care.  It seems something between you and me is unreliable in delivery or in spam detection.

>  You might also note that #moduleName can check the OS, so "it will
> never work on Windows" is just plain wrong.

My mistake.  The Unix moduleName should be 'odbc' unless there's a good reason for it not to be.

> Later in the day I will revert to your vm and try 'odb'

Recompile from source.  My best attempt at a fix for your issue is in the repo.

> - I will admit to being less than optimistic, especially given what I
> "ignored" - make that never received.

Well now that your mailer likes me, why not try to be happy to work with me to resolve this rather than assuming my attempts are futile and in vain?

Cheers,
Ian


From: Ian Piumarta
Date: April 7, 2010 11:56:14 AM PDT
To: "Schwab,Wilhelm K" <[hidden email]>
Subject: Re: [squeak-dev] RE: Linux 3.11-3 vm and shared libraries
Received: (qmail 20182 invoked from network); 7 Apr 2010 18:56:15 -0000
Received: from dsl092-038-093.lax1.dsl.speakeasy.net (HELO [10.0.1.2]) by mail7.sea5.speakeasy.net (qmail-ldap-1.03) with SMTP for <[hidden email]  >; 7 Apr 2010 18:56:15 -0000
Message-Id: <[hidden email]>
In-Reply-To: <[hidden email]
 >
Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes
Content-Transfer-Encoding: 7bit
Mime-Version: 1.0 (Apple Message framework v936)
References: <[hidden email]
 > <[hidden email]>

Bill,

On Apr 7, 2010, at 10:34 AM, Schwab,Wilhelm K wrote:

It is one thing for my hacked together .so to avoid detection due to some mistake on my part

If your .so is in the library search path then it should be found.  If your .so contains unresolved references then they should be reported on the console when it fails to load.

has anyone tried ODBC on Linux with the new vm?  It's sitting in /usr/ lib like it has always been; the vm should find it, right?

Yes it should, but try setting your LD_LIBRARY_PATH=/lib:/usr/lib and running the VM.

I think there is something wrong with the library searches in 3.11-3.

Just different, and a lot more predictable:

From: Ian Piumarta <[hidden email]>
Date: September 16, 2009 7:36:01 PM PDT
To: The general-purpose Squeak developers list <[hidden email]
 >
Subject: 3.11.3.2135 for Unix
[...]
NOTE: FFI libraries are no longer searched for in every single nook and cranny, which means you might have to set LD_LIBRARY_PATH (or your local equivalent) for FFI-based programs to work properly.

Cheers,
Ian


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project