Search:  
Gentoo Wiki

HOWTO_Gentoo_on_WINDOWS

This article is part of the HOWTO series.
Installation Kernel & Hardware Networks Portage Software System X Server Gaming Non-x86 Emulators Misc

People that use ReactOS are needed to test this on Cygwin/UWin

Contents

Overview

There are several ways that use sometimes very different approaches to have a working Gentoo Linux inside a Windows OS.

Interix (by Microsoft) is a Unix subsystem implementation directly on the Windows NT native subsystem. Cygwin and UWIN are Unix library implementions on Win32 (the main subsystem in Windows NT but also available on DOS-based Windows). coLinux is the Linux kernel running as a Win32 process.

Comparison

Interix

Presentations

Interix at Wikipedia

Services for Unix at Wikipedia

Microsoft Windows Services for UNIX (SFU), is a package which provides a Unix compliant environment on Windows. It provides both a subsystem, named Interix and a set of tools. Microsoft does not intend to produce any further versions of the product and plans to discontinue support for it because it is being integrated as part of the regular OS distribution (now called Subsystem for UNIX-based Applications or SUA in Windows Server 2003 R2 and Windows Vista Enterprise and Ultimate).

First impressions

Interix comes with some basic utilities and a lot of them are lacking... but we will install them in this HOWTO.

The annoying bit is that the console display is the same one used by Windows for 32-bit Windows programs that are in text mode, or MS-DOS programs in text mode.

Interix also comes with a almost complete X11R5 and X11R6 distrib, only lacking a window server. You can run either X11R5 or X11R6 xterm if you need a new terminal type.

Installation

You need to follow the forum post at http://forums.gentoo.org/viewtopic-t-319691-postdays-0-postorder-asc-start-0.html after reading ALL of this wiki. At the beginning, the author uses the wrong methods in order to build portage. The author was thinking of './configure ; make ; make install' but there is no make so he has done this by hand...and later Gentoo developers have told us that there are tools in order to make all this work.

Interix doesn't come with many utilities, for example, a Stage3 Gentoo install comes with a lot more utilities... so some that are needed for installing or for portage are lacking... so the original wiki entry author made a script (please test it and update it if possible)

X11

Installing X11 on Interix (SfU) is pretty straightforward. This involves installing X-Deep/32 or Xming.

the freeware version of x-deep is no longer available!

When you install it, install it to the default location (C:\xdeep40); It's easier that way.

Now, in Interix, run the following command:

ln -s /dev/fs/C/xdeep40/bin/xdeep32.exe /usr/X11R6/bin/X

Commands that depend on a X server will now run. Be sure to set your X-Deep/32 bind address to ANY, unless you have reasons not to (your Windows system is the network DMZ or you don't portblock port 6000).

Now type in 'startx'. You will be presented with several Xterms and twm.

Script

#!/bin/sh
#####################################################################
#Little script for sfu...
#the first purpose of this script was installing portage with a script on sfu
#but it can also be used for installing or doing any things...
#####################################################################
#Faq
#what it does?
#->it provide usefull utilities necessary to install or compile packages,such as wget,bunzip2,gunzip that are not provided by default and it also provide the needed uttilities for portage 
#####################################################################
#Status
#-------
#directories					[update for ftp]	[not tested]
#wget						[install by ftp]	[not tested]
#gzip						[ok]			[not tested]
#bzip2						[ok]			[not tested]
#rsync						[ok]			[not tested]
#python						[ok]			[not tested]
#portage					
#directories between instalation (cd ..)	[ok]			[not tested]
#Implement md5sum check
#remplace python binary by bsd source
#####################################################################
#Settings
#--------
#cd /wget/portage-install-files/ can be a default value remplaced by a windows or unix directory under the script parameters (find how to cope with $1 values in order to make the script behave as any coreutils (--help))
#
#
#
#####################################################################
#------------------------------------------------------------------------------------------------------------------------
#sfu(installed by hand)							->[provide ftp,wget]
#------------------------------------------------------------------------------------------------------------------------
#directories creations
cd /
mkdir wget
cd wget
mkdir portage-install-files
#------------------------------------------------------------------------------------------------------------------------
#first install gzip in order to be able to install all others sources	>-[need ftp/wget,tar]		[ok]
cd /wget/portage-install-files/
mkdir tar-gz
cd tar-gz
ftp ftp://mirrors.kernel.org/gnu/gzip/gzip-1.2.4a.tar
tar -xvpf gzip-1.2.4a.tar
cd gzip-1.2.4a
./configure
make
make install
#now gunzip is avaliable under gunxip for tar.gz			->[provide gzip]
#------------------------------------------------------------------------------------------------------------------------
#download wget with ftp							>-[need gzip,ftp/wget,tar]	[ok]
cd /wget/portage-install-files/
mkdir wget
cd wget
ftp ftp://mirrors.kernel.org/gnu/wget/wget-1.9.1.tar.gz
gunzip wget-1.9.1.tar.gz
tar -xvpf wget-1.9.1.tar
cd wget-1.9.1
./configure
make
make install
#------------------------------------------------------------------------------------------------------------------------
#then bzip2,python,rsync that are needed for portage:
#------------------------------------------------------------------------------------------------------------------------
#then bzip2								>-[need wget(http),gzip,tar]	[ok]	
cd /wget/portage-install-files/
mkdir bzip2
cd bzip2
wget http://www.bzip.org/1.0.3/bzip2-1.0.3.tar.gz
gunzip bzip2-1.0.3.tar.gz
tar -xvpf bzip2-1.0.3.tar
cd bzip2-1.0.3
make install
#bzip2 is now avaliable under bunzip2 for tar.bz2			->[provide bz2]			[ok]	[portage]
#------------------------------------------------------------------------------------------------------------------------
#rsync									>-[need ftp-wget,gzip,tar]	[ok]
cd /wget/portage-install-files/
mkdir rsync
cd rsync
wget ftp://ftp.samba.org/pub/rsync/*
gunzip rsync-2.6.6.tar.gz
tar -xvpf rsync-2.6.6.tar
cd rsync-2.6.6
./configure
make
make install								
#rsync is now avaliable							->[provide rsync]		[ok]	[portage]
#------------------------------------------------------------------------------------------------------------------------
#python binary								>-[need wget(http),gunzip,tar]	[ok]	[portage]
cd /wget/portage-install-files/
mkdir python
cd python
wget http://dev.gentoo.org/~redhatter/nt-sfu/sfu-pkgs/python-current-bin.tgz
gunzip python-current-bin.tgz
tar -xvpf python-current-bin.tar
cp -r * /usr/
#									->[provide python binary]
#------------------------------------------------------------------------------------------------------------------------

Cygwin

This is a notably involved process, but quite rewarding. See HOWTO Gentoo on Cygwin. --Jalonso 08:12, 1 March 2006 (GMT)

UWIN

Colinux

See HOWTO CoLinux

See Also

Windows Gentoo bootstraping

GeNToo mentioned here in links was 1st April joke, but it can be implemented using Internix or Cygwin unix-compatibility layer.

ReactOS

Moreover one can provide freeware install cd/livecd based on ReactOS. At the time of writing ReactOS is still pre-alpha (which means only working inside virtualization software, due to lack of drivers for real hardware).

Windows

Another solution is to create utility that can convert user-supplied licensed version of windows to such LiveCD. Usage of this tool can be legal in some countries, but not sure about Europe/USA.'

External Links

Retrieved from "http://www.gentoo-wiki.info/HOWTO_Gentoo_on_WINDOWS"

Last modified: Thu, 27 Sep 2007 06:36:00 +0000 Hits: 19,477