Author Topic: How to compile on LLL's  (Read 3392 times)

duttydea

  • Full Member
  • ***
  • Posts: 136
  • You wont know untill you search, then ask!!
How to compile on LLL's
« on: March 05, 2009, 01:30:32 PM »
I have seen a few apps (.deb) that i would love to try and compile on my LLL.

The only problem is im a complete n00b to linux.

Can someone please post a guide to compiling & installing,

I have just created a Custom Backup of my LLL and feel confident enough to play about with it with out worrying about me having to redo all my customizations.

Thank in advance

Duttydea
______________________________________________
CnM MiniBook : 3MX RC3.1 / Custom Debian (DLA)
Desktop: XP PRO & Vista
Linux Knowledge: Restricted to 3MX & Debian Etch (Basic)

Mijzelf

  • Full Member
  • ***
  • Posts: 143

duttydea

  • Full Member
  • ***
  • Posts: 136
  • You wont know untill you search, then ask!!
Re: How to compile on LLL's
« Reply #2 on: April 05, 2009, 01:29:49 PM »
I have been trying a Lil' bit of native compiling, I have never tried to compile an app and can't find an idiots guide to compiling!

I followed the instructions from the link in the previous post!!

I downloaded and extracted wmnetload  to my USB Stick!!

I tried to use the ./configure

Quote
#./configure
loading cache ./config.cache
checking for a BSD compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking whether make sets ${MAKE}... no
checking for working aclocal... missing
checking for working autoconf... missing
checking for working automake... missing
checking for working autoheader... missing
checking for working makeinfo... missing
checking for gcc... gcc
checking whether the C compiler (gcc  ) works... yes
checking whether the C compiler (gcc  ) is a cross-compiler... no
checking whether we are using GNU C... yes
checking whether gcc accepts -g... yes
checking how to run the C preprocessor... gcc -E
checking for a BSD compatible install... /usr/bin/install -c
checking for ANSI C header files... yes
checking host system type... mipsel-pc-linux-gnu
checking for X... no
checking for XpmCreatePixmapFromData in -lXpm... yes
checking for X11/xpm.h... no
Cannot find required libXpm headers.

Im now stuck!! what do i do now? Can someone please help?

Thanks in advance
______________________________________________
CnM MiniBook : 3MX RC3.1 / Custom Debian (DLA)
Desktop: XP PRO & Vista
Linux Knowledge: Restricted to 3MX & Debian Etch (Basic)

Mijzelf

  • Full Member
  • ***
  • Posts: 143
Re: How to compile on LLL's
« Reply #3 on: April 05, 2009, 06:22:28 PM »
You'll need to download, build and install libxpm. The good news is that google will help you to find the packet. The bad news is, that when your packet is dependent of libxpm, I think it will be dependent on a lot more X packets. Some of them will not have a configure script, in that case you can try to run autoconf, which will create one.

wicknix

  • Hero Member
  • *****
  • Posts: 634
Re: How to compile on LLL's
« Reply #4 on: April 06, 2009, 02:44:08 AM »
Actually its easier than that. You just installed a compiler, but it doesn't include the development header files for anything other than libc6. So all you need to do is download the -dev packages from debian etch repos and install them. You will need libxpm-dev for sure, probably libpng-dev, libjpg-dev and i'd also grab most of the x11 dev packages. Actually the more header files that you install the less of a headache you'll have in the long run. If configure complains that it cant find something, search out the .deb, install it and try ./configure again. Once everything thats required to build the app is satisfied, it will build. :)

If you installed my gcc-devtools.xap i've at least included binutils and binutils-dev and a few other items needed, but again, no dev headers for anything else. Hope that helps a bit.

Cheers.

g3wyw

  • Newbie
  • *
  • Posts: 29
Re: How to compile on LLL's
« Reply #5 on: July 04, 2010, 07:13:31 AM »
My eureka moment came recently when I got the JanRinze script to run for installing the gcc compiler and libs

you need the !/bin/sh to make the LLL recognise the script as a command.

so if you want to install the gcc compiler and basic lib and tools then you can do the following:

Copy these files from the debian website on to a USB stick

binutils_2.17-3.mipsel.deb
cpp-4.1.11-21_mipsel.deb
gcc-4.1-base_4.11-21_mipsel.deb
gcc-4.1_4.1.1-21_mipsel.deb
libc6-dev_2.3.ds1-13etch7_mipsel.deb

then create the following file called install on the same stick you can use notepad in Windows or vi on the LLL

#!/bin/sh
# install the compiler
for package in $(ls *.deb);
  do
  echo $package;
  ar -x $package data.tar.gz;
  tar xzf ./data.tar.gz -C / ;
  done
rm .data.targz
ln -s //user/bin/gcc-4.1 /user/bin/gcc

plug the stick into the LLL and open Xterm
navigate to the stick

$ cd ..
$ cd USB/USB_1
$ ls   < check that the files are there
$ chmod install 777 < to make it executable
$ .\install < it should run and type out the names of the .debs as it processes them in turn

You may need to do the bit ld.config.so bit from the JanRinze page to point to the right libs, but my helloworld.c now runs

Paul