Reply
Thread Tools
Posts: 3 | Thanked: 0 times | Joined on Oct 2007
#1
I'm trying to install some software by compiling it in situ on my N800. (The software in question is actually the R statistics package, but that's not directly relevant for this query.) The installation procedure is standard for linux:
./configure
make
make install etc...

However, the configure step fails: the error message says that a version of grep is needed that "handles long lines and -e".

Not to be deterred, I downloaded the source code for gnu grep from here:
http://directory.fsf.org/project/grep/
The plan was to compile this version, and then use my new grep to then install the R software. Unfortunately, when I tried to build this version of grep I got the same error: ie. in order to build grep from source, I need a version of grep that handles long lines etc... Catch 22!

Any suggestions would be gratefully received. Apologies that this problem has as much to do with gnu / grep as it does to the N800 platform.

Hemlock
 
Posts: 14 | Thanked: 0 times | Joined on Feb 2008
#2
I am having this same problem. Does anyone know of a solution?
 
Posts: 3,841 | Thanked: 1,079 times | Joined on Nov 2006
#3
The easiest way out is to not try to build in-situ.. the scratchbox cross-building environment is what you will normally use, it runs on either a Linux PC or on a Windows PC through a vmware image.
__________________
N800/OS2007|N900/Maemo5
-- Metalayer-crawler delenda est.
-- Current state: Fed up with everything MeeGo.
 

The Following User Says Thank You to TA-t3 For This Useful Post:
suitti's Avatar
Posts: 96 | Thanked: 7 times | Joined on Sep 2007
#4
It seems to me that someone has already packaged real gnu grep. Unfortunately, it conflicts with busybox. Now, busybox is really small. That's good. But it gives you degraded versions of sh, grep, find, xargs, etc., and it's my main complaint with the set.

For example, 'find' doesn't have the '-print0' option, and 'xargs' doesn't have the '-0' option. That means if you have any files with spaces in them, you can't use these to, for example, make sure your files are readable. And files with spaces in them is increasingly common. For example, download a web page for offline reading. If there are spaces in the names, then the directory for images has spaces too, and the links have spaces in them, so you can't easily just rename them.

At the moment, i'm too chicken to de-install busybox to install the real utilities. I mean, my n800 is currently working...
 

The Following User Says Thank You to suitti For This Useful Post:
Benson's Avatar
Posts: 4,930 | Thanked: 2,272 times | Joined on Oct 2007
#5
Removing busybox usually means a toasted device... reflash required. You can extract the binaries from the package and put them in /usr/local, or maybe force the install, leaving all busybox stuff except grep intact. But removing busybox and replacing all symlinks with GNU utils AFAIK has never been accomplished successfully.
 

The Following User Says Thank You to Benson For This Useful Post:
Posts: 14 | Thanked: 0 times | Joined on Feb 2008
#6
TA-t3 said:
The easiest way out is to not try to build in-situ.. the scratchbox cross-building environment is what you will normally use, it runs on either a Linux PC or on a Windows PC through a vmware image.
Does anyone know of resources where I can learn more about using scratchbox and a vmware image?
 
qwerty12's Avatar
Posts: 4,274 | Thanked: 5,358 times | Joined on Sep 2007 @ Looking at y'all and sighing
#7
Originally Posted by Benson View Post
Removing busybox usually means a toasted device... reflash required. You can extract the binaries from the package and put them in /usr/local, or maybe force the install, leaving all busybox stuff except grep intact. But removing busybox and replacing all symlinks with GNU utils AFAIK has never been accomplished successfully.
I kept busybox installed and got coreutils to install fine with a bit of hacking. But ls -la and some mv commands would segfault so I installed color-ls (gnu anyway) and symlinked mv back to busybox.

Then I reflashed because of unrelated reasons and just stick with my ipv6 busybox,
 
Posts: 3,841 | Thanked: 1,079 times | Joined on Nov 2006
#8
Scratchbox/development environment info:

http://maemo.org/development/
http://maemo.org/development/sdks/
__________________
N800/OS2007|N900/Maemo5
-- Metalayer-crawler delenda est.
-- Current state: Fed up with everything MeeGo.
 

The Following 2 Users Say Thank You to TA-t3 For This Useful Post:
Posts: 631 | Thanked: 837 times | Joined on May 2007 @ Milton, Ontario, Canada
#9
I ran into the Grep -e problem when trying to compile PHP and Lighttpd for my device last week. It's actually an extremely easy problem to fix as long as you realize how BusyBox works.

Essentially busyBox is just one giant binary, containing a bunch of applications; it knows which application to run based on which command line argument you give it. Thus, to get different commands (i.e. grep, find, etc), there are symbolic links that point to the busybox binary; busybox reads the name of the link that called it, and executes the appropriate in-built application.

Okay, so what does this mean really? To install a new version of grep, you don't have to remove busybox, or even over-write it/etc in any way shape or form: simply remove the symbolic link, and replace it with your proper grep binary. I downloaded the source for Grep 2.5.1 from the gnu repository, and just did a ./configure, make, make install on the tablet. From then on, no worries!
Although be careful, for some idiotic reason the latest grep (2.5.5 or something) requires the latest version of grep to build, so it's impossible! lol that's why I chose 2.5.1
 

The Following User Says Thank You to jolouis For This Useful Post:
Reply


 
Forum Jump


All times are GMT. The time now is 02:54.