MLDonkey Forum Index
Homepage •  Bugs •  Tasks •  Patches •  SF.net Project Page •  ChangeLog •  German forum •  Links •  Wiki •  Downloads
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 
MLDonkey on Synology DS207+ (Marvell CPU)
Goto page Previous  1, 2, 3, 4, 5, 6, 7  Next
 
Post new topic   Reply to topic    MLDonkey Forum Index -> Alternative platforms
View previous topic :: View next topic  
Author Message
fabtar
Sage


Joined: 04 Feb 2004
Posts: 1575
Location: Italy

PostPosted: Tue Apr 08, 2008 11:57 am    Post subject: Reply with quote

thx satinz
I wait for the other user to provide their output-strace too.

The libraries are a useful to fix issues on few boxes, most users doesn't need my libs to make things work fair... I have added them for completeness.

@spiralvoice

do you think that substituting this c-code could suffice?:
Code:


/*******************************************************************


                         os_uname


*******************************************************************/

#ifdef HAVE_SYS_UTSNAME_H
#include <sys>

void os_uname(char buf[])
{
        struct utsname uts;
  if (uname (&uts) < 0)
    {
    sprintf(buf, "none none none none none");
    }else
    {
    sprintf(buf, "%s %s %s %s %s",
    uts.sysname, uts.nodename, uts.release, uts.version, uts.machine);
    }

}


I have done few C-programs in my eary years but my C-skills are a bit rusty. Very Happy

Ps.

@spiralvoice, a detail , applying your patch I have got a error, then I have applied the patch "manually" directly on last CVS code.Perhaps I have done something wrong. perhaps it is better to directly send me the patch file the next time? I suppose you have got my email address.
I have used patch -p0 -E -i ... as usual
_________________
ARM,ARMEL,MIPS,MIPSEL,POWERPC mldonkey cores: http://fabtar.ygrek.org.ua/
Back to top
View user's profile Send private message
spiralvoice
Sage


Joined: 06 Jan 2003
Posts: 3983
Location: Germany

PostPosted: Tue Apr 08, 2008 4:59 pm    Post subject: Reply with quote

fabtar wrote:
@spiralvoice

do you think that substituting this c-code could suffice?:

I do not know C.
Just compile a core with it and let users test it.
fabtar wrote:
I have applied the patch "manually" directly on last CVS

Thats the way to go in this case because I copied the patch from the diff
output in my terminal window directly into the forum editor.
No patch file here Wink because its a dirty hack to prove a theory.
In this state the patch will never make it into CVS.
_________________
Link overview and precompiled cores here: http://mldonkey.sourceforge.net/DownloadLinks
Back to top
View user's profile Send private message
fabtar
Sage


Joined: 04 Feb 2004
Posts: 1575
Location: Italy

PostPosted: Tue Apr 08, 2008 5:55 pm    Post subject: Reply with quote

spiralvoice wrote:

I do not know C.
Just compile a core with it and let users test it.

ok, my modification stops this code from accessing unallocated space, it doesn't stop from invoke the uname command.PLus I don't create an exception but simply use the output (eroor state) to provide a default dummy result instead of accessing a non initialized(or allocated) structure.
I suppose that I have to apply my patch on a clean CVS.
I'll post a new core in few minutes.

@synology users, try both the past with spiralvoice patch and the new one with my patch...I'm going to provide it in one hour.
_________________
ARM,ARMEL,MIPS,MIPSEL,POWERPC mldonkey cores: http://fabtar.ygrek.org.ua/
Back to top
View user's profile Send private message
fabtar
Sage


Joined: 04 Feb 2004
Posts: 1575
Location: Italy

PostPosted: Tue Apr 08, 2008 6:37 pm    Post subject: Reply with quote

I have a compilation problem, I have to fix my code I think my version 'll be out tomorrow.
_________________
ARM,ARMEL,MIPS,MIPSEL,POWERPC mldonkey cores: http://fabtar.ygrek.org.ua/
Back to top
View user's profile Send private message
spiralvoice
Sage


Joined: 06 Jan 2003
Posts: 3983
Location: Germany

PostPosted: Tue Apr 08, 2008 7:22 pm    Post subject: Reply with quote

satinz wrote:
Is there anything else I can try out?

Parallel to fabtars core building efforts would it be a good idea to try
to build MLDonkey on the Synology machine yourself.

Is it based on a popular distro, like Debian?
_________________
Link overview and precompiled cores here: http://mldonkey.sourceforge.net/DownloadLinks
Back to top
View user's profile Send private message
ma2xfr
neophyte


Joined: 28 Mar 2008
Posts: 18

PostPosted: Tue Apr 08, 2008 8:29 pm    Post subject: Reply with quote

spiralvoice wrote:

Is it based on a popular distro, like Debian?


Hi,

What is it based on a Debian like? Are you talking about the Synology Operating System? I strickly no idea. But even if it was the case, there is no compilation tools to build any applcation.
The tools deployed into the Synology are the BusyBox.


Last edited by ma2xfr on Tue Apr 08, 2008 9:07 pm; edited 2 times in total
Back to top
View user's profile Send private message
ma2xfr
neophyte


Joined: 28 Mar 2008
Posts: 18

PostPosted: Tue Apr 08, 2008 9:00 pm    Post subject: Reply with quote

fabtar wrote:
@ ma2xfr, satinz and lapin

take here the new archive with spiral patch:
http://rapidshare.com/files/105781290/mldonkey-cores-2.9.4CVS-arm-20080408.tar.bz2

This archive contains only normal build.
You can use the suggested walkthru above in order to install mldonkey on your box.
Cheers


Yes, done. But same issue as Satinz.

DiskStation> strace ./mlnet2.sh
execve("./mlnet2.sh", ["./mlnet2.sh"], [/* 14 vars */]) = -1 ENOEXEC (Exec format error)
dup(2) = 3
fcntl64(3, F_GETFL) = 0x2 (flags O_RDWR)
fstat64(3, {st_mode=S_IFCHR|0622, st_rdev=makedev(3, 0), ...}) = 0
ioctl(3, SNDCTL_TMR_TIMEBASE or TCGETS, {B38400 opost isig icanon echo ...}) = 0
old_mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40015000
_llseek(3, 0, 0xbebbdacc, SEEK_CUR) = -1 ESPIPE (Illegal seek)
write(3, "strace: exec: Exec format error\n", 32strace: exec: Exec format error
) = 32
close(3) = 0
munmap(0x40015000, 4096) = 0
exit_group(1) = ?
Back to top
View user's profile Send private message
spiralvoice
Sage


Joined: 06 Jan 2003
Posts: 3983
Location: Germany

PostPosted: Tue Apr 08, 2008 9:09 pm    Post subject: Reply with quote

ma2xfr wrote:
DiskStation> strace ./mlnet2.sh

Please call the MLDonkey binary directly with strace, not a shell script
_________________
Link overview and precompiled cores here: http://mldonkey.sourceforge.net/DownloadLinks
Back to top
View user's profile Send private message
ma2xfr
neophyte


Joined: 28 Mar 2008
Posts: 18

PostPosted: Tue Apr 08, 2008 9:57 pm    Post subject: Reply with quote

spiralvoice wrote:

Please call the MLDonkey binary directly with strace, not a shell script


The same as yesturday.

execve("./mlnet", ["./mlnet"], [/* 14 vars */]) = 0
uname({sys="Linux", node="DiskStation", ...}) = 0
--- SIGILL (Illegal instruction) @ 0 (0) ---
+++ killed by SIGILL (core dumped) +++
Back to top
View user's profile Send private message
fabtar
Sage


Joined: 04 Feb 2004
Posts: 1575
Location: Italy

PostPosted: Tue Apr 08, 2008 10:03 pm    Post subject: Reply with quote

Code:
uname({sys="Linux", node="DiskStation", ...}) = 0


Does this mean uname has returned the 0 value?
It seems uname has worked properly.Perhaps it is something which happens just after that..

I have updated my code:
Code:
void os_uname(char buf[])
{
   struct utsname uts;
   if (uname(&uts)<0)
      sprintf(buf, "none none none none none");
     else
   sprintf(buf, "%s %s %s %s %s",
   uts.sysname, uts.nodename, uts.release, uts.version, uts.machine);
}


and I'm going to compile but I think that this is not going to solve the issue too.
_________________
ARM,ARMEL,MIPS,MIPSEL,POWERPC mldonkey cores: http://fabtar.ygrek.org.ua/
Back to top
View user's profile Send private message
fabtar
Sage


Joined: 04 Feb 2004
Posts: 1575
Location: Italy

PostPosted: Tue Apr 08, 2008 10:31 pm    Post subject: Reply with quote

this is my strace (working core ARM):

Code:
execve("./mlnet", ["./mlnet"], [/* 17 vars */]) = 0
uname({sys="Linux", node="armguy", ...}) = 0
getrlimit(RLIMIT_STACK, {rlim_cur=8192*1024, rlim_max=RLIM_INFINITY}) = 0
setrlimit(RLIMIT_STACK, {rlim_cur=2044*1024, rlim_max=RLIM_INFINITY}) = 0
getpid()                                = 3456
rt_sigaction(SIGRTMIN, {0x2cf88c, [], 0x4000000 /* SA_??? */}, NULL, 8) = 0
rt_sigaction(SIGRT_1, {0x2d0110, [RTMIN], 0x4000000 /* SA_??? */}, NULL, 8) = 0
rt_sigaction(SIGRT_2, {0x2cf190, [], 0x4000000 /* SA_??? */}, NULL, 8) = 0
rt_sigprocmask(SIG_BLOCK, [RTMIN], NULL, 8) = 0
rt_sigprocmask(SIG_UNBLOCK, [RT_1], NULL, 8) = 0
brk(0)                                  = 0x57c000
brk(0x59d000)                           = 0x59d000
mmap2(NULL, 253952, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40000000
brk(0x5bf000)                           = 0x5bf000



the next operation is :
getrlimit(RLIMIT_STACK, {rlim_cur=8192*1024, rlim_max=RLIM_INFINITY}) = 0

but I fear that this is only a system call, the illegal could instruction be anywhere(?)

Code:
 --enable-checks     turn on bounds checking in ocaml it's safer, a bit slower, recommended for developers and paranoids

Could be useful?

Plus I have othe hardware infos,these are about working QNAP ts-109 ARM box:
Code:


[~] # uname -a
Linux NAS-1 2.6.12.6-arm1 #2 Mon Jan 28 03:35:15 CST 2008 armv5tejl unknown

[~] # cat /proc/cpuinfo
Processor       : ARM926EJ-Sid(wb) rev 0 (v5l)
BogoMIPS        : 332.59
Features        : swp half thumb fastmult
CPU implementer : 0x41
CPU architecture: 5TEJ
CPU variant     : 0x0
CPU part        : 0x926
CPU revision    : 0
Cache type      : write-back
Cache clean     : cp15 c7 ops
Cache lockdown  : format C
Cache format    : Harvard
I size          : 32768
I assoc         : 1
I line length   : 32
I sets          : 1024
D size          : 32768
D assoc         : 1
D line length   : 32
D sets          : 1024

Hardware        : MV-88fxx81
Revision        : 0000
Serial          : 0000000000000000

_________________
ARM,ARMEL,MIPS,MIPSEL,POWERPC mldonkey cores: http://fabtar.ygrek.org.ua/


Last edited by fabtar on Tue Apr 08, 2008 10:50 pm; edited 1 time in total
Back to top
View user's profile Send private message
satinz
neophyte


Joined: 07 Apr 2008
Posts: 13

PostPosted: Tue Apr 08, 2008 10:40 pm    Post subject: Reply with quote

I had been thinking of building mldonkey on the box too...
But I really have no idea where to start with regards to setting up a build environment.
I know Synology provides a cross-compilation platform, but I guess I shouldn't be cross compiling here. Any ideas about how to setup a build environment?
Back to top
View user's profile Send private message
fabtar
Sage


Joined: 04 Feb 2004
Posts: 1575
Location: Italy

PostPosted: Tue Apr 08, 2008 10:55 pm    Post subject: Reply with quote

perhaps you can try building directly on your box, it could be long but easier than a cross-compiling stuff.
I don't know if your box provides basic compilation -enviroment gcc.. perhaps you have to look at provided packages.
You have to install gcc - g++ and other tools like make and autoconf..
Then you can compile an ocaml enviroment, and then you can compile mldonkey.

But I don't know so much about your box, it is better that you get tips about in synology forum, the get back here when you have all the bascis to start compiling ocaml->mldonkey.I'll surely help you.

what do you need?
Look at:

http://mldonkey.sourceforge.net/CompilationProblems
_________________
ARM,ARMEL,MIPS,MIPSEL,POWERPC mldonkey cores: http://fabtar.ygrek.org.ua/
Back to top
View user's profile Send private message
fabtar
Sage


Joined: 04 Feb 2004
Posts: 1575
Location: Italy

PostPosted: Tue Apr 08, 2008 11:27 pm    Post subject: Reply with quote

http://rapidshare.com/files/105981699/mldonkey-cores-2.9.4CVS-arm-20080409.tar.bz2

this is my C-solution to uname.But I think uname is not the probelm Sad .
Give it a try.
_________________
ARM,ARMEL,MIPS,MIPSEL,POWERPC mldonkey cores: http://fabtar.ygrek.org.ua/
Back to top
View user's profile Send private message
spiralvoice
Sage


Joined: 06 Jan 2003
Posts: 3983
Location: Germany

PostPosted: Wed Apr 09, 2008 7:06 am    Post subject: Reply with quote

fabtar wrote:
Code:
 --enable-checks     turn on bounds checking in ocaml it's safer, a bit slower, recommended for developers and paranoids

Could be useful?

No, its unrelated
_________________
Link overview and precompiled cores here: http://mldonkey.sourceforge.net/DownloadLinks
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    MLDonkey Forum Index -> Alternative platforms All times are GMT
Goto page Previous  1, 2, 3, 4, 5, 6, 7  Next
Page 3 of 7

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Sourceforge.net Logo