Jump to content


Photo

Help compiling file to work on mips based receiver.


  • Please log in to reply
18 replies to this topic

#1 mrdude

  • Senior Member
  • 90 posts

0
Neutral

Posted 6 January 2014 - 00:38

Guys, I have been trying to compile a program to work on my vu+ duo 2 which has a mips based processor - as I am making a plugin for myself. I did manage to compile this to work on my synology NAS - but am running into trouble doing it for my box.

 

Can someone 'in the know' if you have a cross compiler set up to compile for mips - please compile this for me. I'll attach the source code.

 

 

This is how I did it on my NAS:

 

ipkg install gcc
ipkg install make
ipkg install sudo
 
mkdir /opt/arm-none-linux-gnueabi/lib_disabled
mv /opt/arm-none-linux-gnueabi/lib/libpthread* /opt/arm-none-linux-gnueabi/lib_disabled
 
cp /lib/libpthread.so.0 /opt/arm-none-linux-gnueabi/lib/
sudo ln -s /usr/lib/libstdc++.so.6 /usr/lib/libstdc++.so
 
cd /opt/arm-none-linux-gnueabi/lib/
ln -s libpthread.so.0 libpthread.so
ln -s libpthread.so.0 libpthread-2.5.so
 
cd /
cd /root/ps3netsrv
 
make
 
 
If someone kind would compile this to work on mips - I would be most gratefull. Thanks

Attached Files



Re: Help compiling file to work on mips based receiver. #2 MiLo

  • PLi® Core member
  • 14,055 posts

+298
Excellent

Posted 6 January 2014 - 07:38

Just setup the build environment on a Linux PC (can be a VM if you like). Any questions, just ask.
Real musicians never die - they just decompose

Re: Help compiling file to work on mips based receiver. #3 Erik Slagter

  • PLi® Core member
  • 46,969 posts

+542
Excellent

Posted 6 January 2014 - 10:21

If you use the cross compiler which OpenEmbedded makes for it's own purposes, it will simply work, is my experience. Quite blunt, vs. using automake etc. or bitbake recipes, but for simple things it works out.


* Wavefrontier T90 with 28E/23E/19E/13E via SCR switches 2 x 2 x 6 user bands
I don't read PM -> if you have something to ask or to report, do it in the forum so others can benefit. I don't take freelance jobs.
Ik lees geen PM -> als je iets te vragen of te melden hebt, doe het op het forum, zodat anderen er ook wat aan hebben.


Re: Help compiling file to work on mips based receiver. #4 MiLo

  • PLi® Core member
  • 14,055 posts

+298
Excellent

Posted 6 January 2014 - 14:29

For simple C files, I often just run "bitbake devshell" and then use "$CC *.c -o utility" to quikly compile source code into something executable.
Real musicians never die - they just decompose

Re: Help compiling file to work on mips based receiver. #5 mrdude

  • Senior Member
  • 90 posts

0
Neutral

Posted 6 January 2014 - 16:19

Ok guys I have an Udoo board which is Arm based - I can install ubuntu and these packages:

 

gcc, make, sudo.

 

How do I install the cross compiler so that the program works on mips - and what do i do to get bitbake?

 

I am not used to linux, or compiling stuff so a 'dummies guide' would be appreciated. Obviously it would be beneficial for me to get this compiled my self - but failing that I can manage it - can someone who has already got everything installed and working compile the attached file for me?

 

Thanks



Re: Help compiling file to work on mips based receiver. #6 MiLo

  • PLi® Core member
  • 14,055 posts

+298
Excellent

Posted 6 January 2014 - 17:10

You (cross) compile on a PC, not on the box. Setting it up takes about 5 minutes.
Real musicians never die - they just decompose

Re: Help compiling file to work on mips based receiver. #7 mrdude

  • Senior Member
  • 90 posts

0
Neutral

Posted 6 January 2014 - 17:21

Can you make a little guide up on how to do this, yes I know I can't compile this on a box - and that I will need Linux installed on a pc - the udoo is a quad core mini pc, with a built in arduino due - it has Ubuntu installed.



Re: Help compiling file to work on mips based receiver. #8 MiLo

  • PLi® Core member
  • 14,055 posts

+298
Excellent

Posted 6 January 2014 - 19:28

Uh,

git clone -b upstream git://git.code.sf.net/p/openpli/openpli-oe-core
cd openpli-oe-core
MACHINE=vuduo2 make image

And wait.

If you just need the compiler:

git clone -b upstream git://git.code.sf.net/p/openpli/openpli-oe-core
cd openpli-oe-core
export MACHINE=vuduo2
make
cd build
source ./env.source
bitbake devshell
Real musicians never die - they just decompose

Re: Help compiling file to work on mips based receiver. #9 Lost in Space

  • Senior Member
  • 876 posts

+69
Good

Posted 6 January 2014 - 19:39

Total waste of time.

 

With a Debian Wheezy Installation from Barry Allen on my Dreambox 7020hd it took less then 2min to do the job.

Attached Files


Edited by gutemine, 6 January 2014 - 19:40.


Re: Help compiling file to work on mips based receiver. #10 MiLo

  • PLi® Core member
  • 14,055 posts

+298
Excellent

Posted 6 January 2014 - 20:18

Another way to compile is to mail it to gutemine and he'll send you back the binary. Usually with even more features.
Real musicians never die - they just decompose

Re: Help compiling file to work on mips based receiver. #11 Lost in Space

  • Senior Member
  • 876 posts

+69
Good

Posted 6 January 2014 - 20:34

Fas est et ab hoste doceri



Re: Help compiling file to work on mips based receiver. #12 waterpas

  • Senior Member
  • 97 posts

+2
Neutral

Posted 6 January 2014 - 21:46

Voor de mensen die geen misdienaar zijn geweest en enkel vissers latijn kennen, Fas est et ab hoste doceri oftewel; Je mag van je vijand leren, Amen



Re: Help compiling file to work on mips based receiver. #13 athoik

  • PLi® Core member
  • 8,458 posts

+327
Excellent

Posted 6 January 2014 - 22:08

With a Debian Wheezy Installation.


With What kernel? Debian kernel or same kernel as in the flash?
Wavefield T90: 0.8W - 1.9E - 4.8E - 13E - 16E - 19.2E - 23.5E - 26E - 33E - 39E - 42E - 45E on EMP Centauri DiseqC 16/1
Unamed: 13E Quattro - 9E Quattro on IKUSI MS-0916

Re: Help compiling file to work on mips based receiver. #14 littlesat

  • PLi® Core member
  • 57,475 posts

+708
Excellent

Posted 6 January 2014 - 22:42

This is an english thread... Not a latin or dutch thread...

The stuff gutemine wrotes here is translated..

You may learn from your enemy, amen....

WaveFrontier 28.2E | 23.5E | 19.2E | 16E | 13E | 10/9E | 7E | 5E | 1W | 4/5W | 15W


Re: Help compiling file to work on mips based receiver. #15 mrdude

  • Senior Member
  • 90 posts

0
Neutral

Posted 7 January 2014 - 01:21

Thanks guys, I have tried the attached file - it runs fine, but gives a port error - I guess I forgot to add a file to the attachment I added.

 

Thanks to the guide I will try doing this myself though - thanks for all the replies guys and the posted file - you have been a great help and I wish you all the best for the new year.



Re: Help compiling file to work on mips based receiver. #16 mrdude

  • Senior Member
  • 90 posts

0
Neutral

Posted 7 January 2014 - 01:42

OOOOOps,

 

 

My mistake it's working fine - the command line args have changed since the old version I was using - it's tested and working great now.

 

Thanks very much :-)



Re: Help compiling file to work on mips based receiver. #17 Lost in Space

  • Senior Member
  • 876 posts

+69
Good

Posted 7 January 2014 - 12:11

As Debian uses also the very stable 3.2 kernel as the recent Dreamboxes do, your question is useless and just shows that you don't know how Barry Allen works by using Flash kernel and chroot to other Images. But the answer to your question is that wheezy works nicely with all recent kernels so the same approach would work on a VU+ also, and you could even use BA to install it or use the normal Network install scripts that Debian offers (as BA does the same).

 

And finally your great OE could simply be used to build a mipsel gcc, make,... too and put it on the softwarefeed.

 

Which means for such simple things crosscompiling is a waste of time, especially for inexperienced users, which brings us back that you can even learn from the enemy ...


Edited by gutemine, 7 January 2014 - 12:12.


Re: Help compiling file to work on mips based receiver. #18 athoik

  • PLi® Core member
  • 8,458 posts

+327
Excellent

Posted 7 January 2014 - 16:21

As Debian uses also the very stable 3.2 kernel as the recent Dreamboxes do, your question is useless and just shows that you don't know how Barry Allen works by using Flash kernel and chroot to other Images. But the answer to your question is that wheezy works nicely with all recent kernels so the same approach would work on a VU+ also, and you could even use BA to install it or use the normal Network install scripts that Debian offers (as BA does the same).

 

OFC and i don't know how BA works (there is no code to study!), but what i know is that BA is causing problems with different kernels. Users are calling this multiboot, I call this too restrictive...  I think kexec is nice solution.

 

You answer my question. Thanks.

 

PS. I think i can chroot without the need of BA, although crossompilling is much faster (especially for big projects)

PPS. I can boot what ever image i like from usb (autoexec.bat, although i am using nfidump to extract nfi)


Edited by athoik, 7 January 2014 - 16:21.

Wavefield T90: 0.8W - 1.9E - 4.8E - 13E - 16E - 19.2E - 23.5E - 26E - 33E - 39E - 42E - 45E on EMP Centauri DiseqC 16/1
Unamed: 13E Quattro - 9E Quattro on IKUSI MS-0916

Re: Help compiling file to work on mips based receiver. #19 Lost in Space

  • Senior Member
  • 876 posts

+69
Good

Posted 7 January 2014 - 18:16

You don't need any code to study chroot as t is a standard libc call.

 

But I think this is OT here in this thread.

 

And yes, x-compiling code on the PC might be faster, but if you start needing lots of libs as prerequisite and you need to make ./configure and other stuff work it is often still a waste of time and in this case the compiling was < 1min and would have been even faster on non-Dreamboxes with faster CPUs.

 

And normally there are not any real kernel differences for images of equal age and driver levels. if you start to become an Archeologist Dumbo or Wally West can boot nicely with the image kernel, but this brings us just back to OT discussions.


Edited by gutemine, 7 January 2014 - 18:16.



1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users