maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Development (https://talk.maemo.org/forumdisplay.php?f=13)
-   -   Gentoo x86_64 SDK (https://talk.maemo.org/showthread.php?t=33073)

FettsVett 2009-10-18 22:30

Gentoo x86_64 SDK
 
Hi, I'm new here, I've been lurking around and recently decided that I'm going to get an n900 - so I want to learn how to develop for it. I'm currently running a gentoo x86_64 install on my computer, there isn't really that much literature that isn't ancient on the web about how to successfully install all of the packages required on gentoo.

I was wondering if anyone could point me to a guide that was less than a year old or that detailed all requirements for a fremantle SDK install on 64-bit Gentoo install? Or you could just tell me :)

Thanks in advance for your help!

-Court

allnameswereout 2009-10-18 22:48

Re: Gentoo x86_64 SDK
 
If you install apt-get, dpkg, and follow Maemo 5 Final SDK Manual Installation instructions you should get a working Scratchbox and SDK environment.

Feel free to update the documentation on wiki to include Gentoo specific workarounds, or perhaps better please update the Gentoo documentation and link to it from Maemo wiki.

ewan 2009-10-18 23:05

Re: Gentoo x86_64 SDK
 
The other option, and what I've gone for on top of a Fedora system, is to install Ubuntu in a VM and use the provided scripts to install onto that. If you then SSH into the VM you can have it forward the X traffic back to a copy of Xephyr running on the host.

Aside from giving the SDK an Ubuntu/Debian style environment it neatly contains it and avoids having to run the installer scripts as root on your actual system.

allnameswereout 2009-10-18 23:34

Re: Gentoo x86_64 SDK
 
Quote:

Originally Posted by ewan (Post 350712)
The other option, and what I've gone for on top of a Fedora system, is to install Ubuntu in a VM and use the provided scripts to install onto that. If you then SSH into the VM you can have it forward the X traffic back to a copy of Xephyr running on the host.

Aside from giving the SDK an Ubuntu/Debian style environment it neatly contains it and avoids having to run the installer scripts as root on your actual system.

Ah yes, good point. Then the user can also run a 32-bit environment as host OS instead of 64-bit with 32-bit libraries.

In your case (RPM-based distribution) there is also Alien and this concerts .deb to .rpm, and vice versa.

I vaguely remember there is a way to get a full Debian chroot in Gentoo using Portage, and FreeBSD Ports Collection.

After SDK is installed the user could just move /path/to/chroot/debian/scratchbox out of the chroot into host /scratchbox. Although some stuff then must be copied (and probably ported) over as well such as /etc/init.d/scratchbox-core

pinsh 2009-10-18 23:46

Re: Gentoo x86_64 SDK
 
UPDATE (Oct 19, 2009): DON'T use these instructions, they contain some errors and omissions, I'm currently working on updated instructions.

Hi,

I recently installed the maemo 5 SDK on Gentoo amd64, let me try to reconstruct what I did to get it done. Maybe we can add it to the wiki after some editing.

1. Re-emerge x11-base/xorg-server with the "kdrive" USE flag enabled, this will give you Xephyr.

2. Instead of using the scratchbox installer from maemo, install the following using portage (you may have to unmask some packages):
Code:

dev-embedded/scratchbox
dev-embedded/scratchbox-devkit-apt-https
dev-embedded/scratchbox-devkit-debian
dev-embedded/scratchbox-devkit-doctools
dev-embedded/scratchbox-devkit-git
dev-embedded/scratchbox-devkit-perl
dev-embedded/scratchbox-devkit-qemu
dev-embedded/scratchbox-devkit-svn
dev-embedded/scratchbox-toolchain-cs2007q3-glibc2_5

3. Read the instructions "4. Installing on 64bit Debian based distrubution" at http://maemo.org/development/sdks/ma...0_installation (the stuff about vdso and where to download the installer). Install the SDK as follows:

Code:

./maemo-scratchbox-install_5.0beta.sh –u USER -F -s /opt/scratchbox
4. Start scratchbox:
Code:

/etc/init.d/scratchbox start
5. Follow the instructions "2. Starting/shutting down the SDK UI", but use
Code:

/opt/scratchbox login
to login.

I hope this helps.

allnameswereout 2009-10-19 00:08

Re: Gentoo x86_64 SDK
 
Quote:

Originally Posted by pinsh (Post 350730)
3. Read the instructions "4. Installing on 64bit Debian based distrubution" at http://maemo.org/development/sdks/ma...0_installation (the stuff about vdso and where to download the installer).

Since you're using Scratchbox on x86-64 and are into compiling business so to say :) please try this patch which works around VDSO32 issue with Scratchbox by fixing it in Scratchbox instead of requiring workaround. If works stable, could add it as official patch in Gentoo.

Thanks for the howto btw. After feedback in this thread I'll merge it into Maemo wiki. Gentoo documentation folks could link then from Gentoo Scratchbox or Maemo forums threads or wiki to the Maemo wiki entry.

It is important to keep one central place of info and let others link to it, else we get out of sync, so if it is in the Maemo wiki please help keeping it up to date as most folks here, as well as Nokia internally, run SDK on Debian-based Linux, either native or by using VM.

FettsVett 2009-10-19 09:12

Re: Gentoo x86_64 SDK
 
Thanks for the responses everyone!

Quote:

Originally Posted by pinsh (Post 350730)
Hi,

I recently installed the maemo 5 SDK on Gentoo amd64, let me try to reconstruct what I did to get it done. Maybe we can add it to the wiki after some editing.

1. Re-emerge x11-base/xorg-server with the "kdrive" USE flag enabled, this will give you Xephyr.

2. Instead of using the scratchbox installer from maemo, install the following using portage (you may have to unmask some packages):
Code:

dev-embedded/scratchbox
dev-embedded/scratchbox-devkit-apt-https
dev-embedded/scratchbox-devkit-debian
dev-embedded/scratchbox-devkit-doctools
dev-embedded/scratchbox-devkit-git
dev-embedded/scratchbox-devkit-perl
dev-embedded/scratchbox-devkit-qemu
dev-embedded/scratchbox-devkit-svn
dev-embedded/scratchbox-toolchain-cs2007q3-glibc2_5

3. Read the instructions "4. Installing on 64bit Debian based distrubution" at http://maemo.org/development/sdks/ma...0_installation (the stuff about vdso and where to download the installer). Install the SDK as follows:

Code:

./maemo-scratchbox-install_5.0beta.sh –u USER -F -s /opt/scratchbox
4. Start scratchbox:
Code:

/etc/init.d/scratchbox start
5. Follow the instructions "2. Starting/shutting down the SDK UI", but use
Code:

/opt/scratchbox login
to login.

I hope this helps.

I think that I'll do this. It seems like the most elegant solution - no messing around with foriegn package managers or SSH xorg voodoo.

Thanks again everyone!

pinsh 2009-10-19 23:29

Re: Gentoo x86_64 SDK
 
FettsVett,

Hold on with installing it as described above, I think there may be some things missing. I will install the SDK on a second Gentoo amd64 system tonight and then update the instructions.

allnameswereout,

You are welcome, I will test if the patch works after I updated the instructions.

pinsh 2009-10-20 02:01

Re: Gentoo x86_64 SDK
 
Or it may take a bit longer, I ran into some weird problems..

allnameswereout 2009-10-20 02:26

Re: Gentoo x86_64 SDK
 
Quote:

Originally Posted by pinsh (Post 352140)
Or it may take a bit longer, I ran into some weird problems..

You're using beta sh scripts. The final SDK has been released. Please use this one as reference instead

http://wiki.maemo.org/Documentation/...K_Installation


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

vBulletin® Version 3.8.8