| Ticket UUID: | 929562 | ||
| Title: | load-2.3 FAILED no _Init procedure | ||
| Type: | Bug | Created on: | 2004-04-05 05:35:12 |
| Submitter: | tauvan | Assigned to: | das |
| Subsystem: | 40. Dynamic Loading | Severity: | |
| Priority: | 5 Medium | Last modified: | 2006-08-21 11:01:26 |
| Status: | Closed | Closed by: | das |
| Resolution: | Out of Date | Closed on: | 2006-08-21 04:01:26 |
| Version: | obsolete: 8.4.6 | ||
| Description: | ||||
machine: mac ppc G4 (1st PCI 400Mhz) OSX 10.1.5
A more detailed description under 20 failures bug
just library location change
Possible solution:
test load-2.3 {loading with no _Init procedure} [list $dll $loaded]
{
set msg [string range [list [catch {load [file join $testDir
pkgc$ext] foo} msg] $msg] end-32 end-1]
} {couldn't find procedure Foo_Init}
| ||||
| User Comments: | ||||
dkf added on 2004-04-05 16:35:46:
Logged In: YES
user_id=79902
This test should be rewritten to use tcltest2 syntax anyway.
Something like this:
test load-2.3 {loading with no _Init procedure} \
-constraints [list $dll loaded] -body {
load [file join $testDir pkgc$ext] foo
} -returnCodes error -result {couldn't find procedure Foo_Init}
Now, what I want to know is why is OSX putting extra crud in
the error message compared with other UNIX platforms?
Altering the test in this case looks like the wrong thing to do.
tauvan added on 2004-04-19 12:21:48:
Logged In: YES user_id=1011552 Hi, did a little digging and may have an alternative that might stop the Apple crud and solve a possible later problem with Apple. I found "deprecated: Mac OS X < 10.3.x" and some what looks like really good code that states base compatiblity 10.0 on up, plus it looks like Apple is headed that way. I've tested on the load.test, actually the all.tcl and it works fine. Also instead of using tclLoadDyld.c it uses tclLoadDl.c with one minor change. The source compatiblity code had minor changes for warnings. The source is from http://cvs.opendarwin.org/ cgi-bin/cvsweb.cgi/proj/dlcompat/ dlfcn.h & dlfcn.c and could be dropped into Tcl via compat objects. What do you think? a possibilty or keep digging? das added on 2004-04-19 16:40:41:
Logged In: YES
user_id=90580
the extra diagnostic messages have been added on purpose to
resolve bug 627546:
2002-10-29 Daniel Steffen <[email protected]>
* unix/tclLoadDyld.c (TclpFindSymbol): pass all
dyld error
messages upstream [Bug #627546].
see https://sourceforge.net/tracker/
?func=detail&atid=110894&aid=627546&group_id=10894
this can be easily reversed by undoing the patch attatched there
(remove NSLinkEditError() handling from tclLoadDyld.c).
IMO the extra diagnostic information is useful however, and as
such I would oppose removing this only to make the test suite
pass... what do others think? the test suite should be changed
instead.
IMO, we certainly don't want to add a dependency on dlcompat,
our existing code works fine and is more flexible.... at some
point we also want to add optional loading of MachO bundles,
which dlcompat wouldn't support.
dkf added on 2004-04-19 16:58:11:
Logged In: YES user_id=79902 Hmm. Perhaps in that case the right thing to do is to structure the error messages in such a way that we can do a glob match in the test? (I'd need to look up the syntax for doing this, and there is the separate matter of whether the detail part of the message that you're adding should come at the beginning or the end of the error message.) tauvan added on 2004-04-19 19:02:29:
Logged In: YES user_id=1011552 FWIW I agree with Daniel Steffen, I like any additional info that helps in diagnosing problems, dlcompat would require dependancy on something non-Tcl, but I'm no expert I'm just tossing possiblities. das added on 2006-08-21 11:01:25:
Logged In: YES user_id=90580 fixed long ago | ||||
