On Sep 23, 2006, at 7:05 AM, Ivan Volosyuk wrote:

On 9/23/06, Geir Magnusson Jr. <[EMAIL PROTECTED]> wrote:

On Sep 23, 2006, at 6:00 AM, Ivan Volosyuk wrote:

> I have found a solution to this issue. As before, it helps to setup
> LD_LIBRARY_PATH before running launcher.

Lets be clear - it only helped to setup LD_LIBRARY_PATH before for
reasons unknown.  W/o my recent change, it worked fine on Ubuntu 6
but not on Suse...

It works fine on my gentoo. The only thing. Look at the paths. First
one without trailing slash, the second with it. This should be exactly
the same after the check is fixed. :) I don't know the reason for
that, so I have left this intact.

Oh, just because it doesn't matter - we could add the trailing slash if we wanted too...



> If it finds required PATHs it
> doesn't re-execute itself. Pathes looks like:
> path[0] = /home/ivan/svn/drlvm/trunk/build/deploy/jre/bin/default
> path[1] = /home/ivan/svn/drlvm/trunk/build/deploy/jre/bin/
>
> BTW, I have found a bug in the path checks. Giving only first path
> will satisfy the condition in the code and will prevent execv(), but
> VM will fail to run:

Ha!  yes, of course.  My bad.  Obviously if the needed path is a
substring of a path that's already there, it does the wrong thing.
Doh :)

> export #LD_LIBRARY_PATH=/home/ivan/svn/drlvm/trunk/build/deploy/ jre/
> bin/default
> #./deploy/jre/bin/java Test
> java/lang/UnsatisfiedLinkError : Failed loading library
> "libhyzlib.so": DSO load failed
>
> I'm working on the fix.

Ok.  I think it's straightforward - look to see if the full string is
there by seeing if

   *(ptr + strstr() + 1) == either null or separator
Will not work. We should do this in loop at least.

Yes, that was shorthand for "for each match of the dir in the oldpath, see if the next char is a separator or the null at the end. if so, you found a match, otherwise keep going"

You did effectively the same thing in the patch.

If we found another
variant of the path it will fail the check. I have made the correct
fix. Look at https://issues.apache.org/jira/browse/HARMONY-1557.


Back to the issue - this means that we can't debug across the execv ()?

We don't.

--
Ivan


geir


> --
> Ivan
>
> On 9/23/06, Nikolay Kuznetsov <[EMAIL PROTECTED]> wrote:
>> Yes, I've seen the same, please keep us informed if you find a
>> solution.
>>
>> On 9/23/06, Ivan Volosyuk <[EMAIL PROTECTED]> wrote:
>> > GNU gdb 6.4
>> >
>> > Attaching is ok, but it is not quite convinient to do attaching
>> when
>> > running small test, I prefer: gdb --args prog args... but it no
>> longer
>> > works for me after switch to new launcher.
>> > --
>> > Ivan
>> >
>> > On 9/23/06, Sunny Chan <[EMAIL PROTECTED]> wrote:
>> > > Which version of gdb are you using? Older version of gdb
>> doesn't play along well
>> > > with nptl or java launcher which spawn another process.
>> > >
>> > > Try running your java program first and attach gdb to the
>> process.
>> > >
>> > > Ivan Volosyuk wrote:
>> > > > I have problems running drlvm from gdb:
>> > > >
>> > > > (gdb) run
>> > > > Starting program: /home/ivan/svn/drlvm/trunk/build/deploy/
>> jre/bin/java Test
>> > > > [Thread debugging using libthread_db enabled]
>> > > > [New Thread -1214326592 (LWP 25698)]
>> > > > [New Thread -1214510160 (LWP 25701)]
>> > > > Cannot find user-level thread for LWP 25698: generic error
>> > > >
>> > > > Does anybody have seen the problem?

---------------------------------------------------------------------
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to