mirror of
https://review.haiku-os.org/userguide
synced 2024-11-23 15:18:25 +01:00
* Added Philippe ("Socapex_2K") Groarke's work on an installation topic.
It's based on the blog articles of several people that will be credited in each page's header comment soon. * Did a little additional formatting and restructuring. * This is still a work in progress as we continue to restructure and remove redundancies. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28925 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
7c580c1214
commit
596ca54365
@ -28,6 +28,8 @@
|
||||
<p>
|
||||
<a href="contents.html">Contents</a>
|
||||
   
|
||||
Previous: <a href="installation.html">Installing Haiku</a>
|
||||
   
|
||||
Next: <a href="filesystem-layout.html">Filesystem layout</a>
|
||||
</p>
|
||||
</div>
|
||||
@ -77,6 +79,8 @@ The different symbols roughly correspond to these boot stages:</p>
|
||||
<p>
|
||||
<a href="contents.html">Contents</a>
|
||||
   
|
||||
Previous: <a href="installation.html">Installing Haiku</a>
|
||||
   
|
||||
Next: <a href="filesystem-layout.html">Filesystem layout</a>
|
||||
</p>
|
||||
</div>
|
||||
|
@ -35,6 +35,14 @@
|
||||
<h2><a name="welcome">Welcome to Haiku's User Guide</a></h2>
|
||||
<p>Below, you'll find the documentation of the most important aspects of Haiku. Naturally, completing and extending the documentation is a continuing process. If you find errors or would like to suggest topics or maybe even contribute yourself, please file a <a href="../../welcome/en/bugreports.html">bugreport</a> or get in touch on the <a href="http://www.freelists.org/list/haiku-doc">documentation mailing list</a>.</p>
|
||||
<table summary="contents" border="0" cellpadding="10" cellspacing="0">
|
||||
<tr><td valign="top"><a href="installation.html">Installation</a><ul>
|
||||
<li><a href="installation.html#boot-process">The basic boot process</a></li>
|
||||
<li><a href="installation.html#virtual-machine">Haiku in a virtual machine</a></li>
|
||||
<li><a href="installation.html#raw">Installing from a RAW image</a></li>
|
||||
<li><a href="installation.html#source">Compiling/Installing from source code</a></li>
|
||||
<li><a href="installation.html#grub">Adding Haiku to your boot manager (GRUB)</a></li>
|
||||
<li><a href="installation.html#transfer-data">Transfering data to/from a Haiku installation</a></li></ul></td>
|
||||
<td valign="top">Step by step guides covering Haiku installation during the (pre-) alpha release phase.</td></tr>
|
||||
<tr><td valign="top"><a href="bootloader.html">Boot Loader</a></td>
|
||||
<td valign="top">Set safe boot options to solve configuration problems.</td></tr>
|
||||
<tr><td valign="top"><a href="filesystem-layout.html">Filesystem layout</a><ul>
|
||||
|
85
userguide/en/installation.html
Normal file
85
userguide/en/installation.html
Normal file
@ -0,0 +1,85 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
||||
"../html-dtd/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xml:lang="en-US">
|
||||
<head>
|
||||
<!--
|
||||
*
|
||||
* Copyright 2009, Haiku. All rights reserved.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*
|
||||
* Authors:
|
||||
* Socapex_2K <philippe_groarke@yahoo.ca>
|
||||
* Humdinger <humdingerb@gmail.com>
|
||||
*
|
||||
-->
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||
<meta http-equiv="Content-Style-Type" content="text/css" />
|
||||
<meta name="robots" content="all" />
|
||||
<title>Installing Haiku</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../Haiku-doc.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="logo">
|
||||
<img src="../images/logo.png" alt="logo" width="372" height="86" />
|
||||
<div class="title">Installing Haiku</div>
|
||||
</div>
|
||||
<div class="topnav">
|
||||
<p>
|
||||
<a href="contents.html">Contents</a>
|
||||
   
|
||||
Next: <a href="bootloader.html">Boot Loader</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
|
||||
<p>Installation of Haiku during (pre-) alpha releases can be somewhat tricky, considering it's current development state. With this installation guide, you will learn many of the most common methods to get Haiku installed, whether it be on a USB stick, a partition or running it in a virtual machine. More advanced topics like building Haiku from source will also be explained in detail, so also beginners are be able to follow.<br />
|
||||
All these somewhat complicated installation methods won't be necessary once Haiku R1 is released. Probably even before that when Haiku enters the beta phase.</p>
|
||||
|
||||
<h1><a id="boot-process" name="boot-process">The basic boot process</a></h1>
|
||||
<p>Before explaining the many ways of getting Haiku installed, a little introduction to booting methods could be helpful. This information isn't Haiku specific, it describes the general booting process found in many OSes.<br />
|
||||
It's not essential to know these details, so feel free to skip this part if you're not interested in the technical background.</p>
|
||||
<p><a href="installation/install-boot-process.html">The basic boot process</a></p>
|
||||
|
||||
<h1><a id="virtual-machine" name="virtual-machine">Haiku in a virtual machine</a></h1>
|
||||
<p>You can try out Haiku without having to make room for it for a separate partition. A virtual machine simulates a specific hardware configuration within your familiar operating system and allows you to run Haiku in a window without having to reboot. It's also a good way to deal with incompatible hardware until Haiku gains the needed driver support.</p>
|
||||
<p><a href="installation/install-vm.html">Running Haiku in a virtual machine</a></p>
|
||||
|
||||
<h1><a id="raw" name="raw">Installing from a downloaded RAW image</a></h1>
|
||||
<p>text text text text text text</p>
|
||||
<p><a href="installation/install-raw.html">Installing from a downloaded RAW image</a></p>
|
||||
|
||||
<h1><a id="source" name="source">Compiling/Installing from source code</a></h1>
|
||||
<p>text text text text text text</p>
|
||||
<p><a href="installation/install-source-beos.html">Compiling/Installing on BeOS</a><br />
|
||||
<p><a href="installation/install-source-linux.html">Compiling/Installing on Linux</a><br />
|
||||
<p><a href="installation/install-source-mac.html">Compiling/Installing on Mac OS X</a><br />
|
||||
<!-- TODO
|
||||
<p><a href="installation/install-source-windows.html">Compiling/Installing on Windows</a></p>
|
||||
-->
|
||||
|
||||
<!-- TODO: Extract these two topics from install-source-linux.html and install-vm.html
|
||||
|
||||
<h1><a id="grub" name="grub">Adding Haiku to your boot manager (GRUB)</a></h1>
|
||||
<p>text text text text text text</p>
|
||||
<p><a href="installation/install-grub.html">Adding Haiku to GRUB</a></p>
|
||||
|
||||
<h1><a id="transfer-data" name="transfer-data">Transfering data to/from a Haiku installation</a></h1>
|
||||
<p>text text text text text text</p>
|
||||
<p><a href="installation/install-transfer-data.html">Transfering data to/from a Haiku installation</a></p>
|
||||
|
||||
-->
|
||||
</div>
|
||||
|
||||
<div class="bottomnav">
|
||||
<p>
|
||||
<a href="contents.html">Contents</a>
|
||||
   
|
||||
Next: <a href="bootloader.html">Boot Loader</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
71
userguide/en/installation/install-boot-process.html
Normal file
71
userguide/en/installation/install-boot-process.html
Normal file
@ -0,0 +1,71 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
||||
"../html-dtd/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xml:lang="en-US">
|
||||
<head>
|
||||
<!--
|
||||
*
|
||||
* Copyright 2009, Haiku. All rights reserved.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*
|
||||
* Authors:
|
||||
* Socapex_2K <philippe_groarke@yahoo.ca>
|
||||
*
|
||||
-->
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||
<meta http-equiv="Content-Style-Type" content="text/css" />
|
||||
<meta name="robots" content="all" />
|
||||
<title>The basic boot process</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../../Haiku-doc.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="logo">
|
||||
<img src="../../images/logo.png" alt="logo" width="372" height="86" />
|
||||
<div class="title">The basic boot process</div>
|
||||
</div>
|
||||
<div class="topnav">
|
||||
<p>
|
||||
<a href="../contents.html">Contents</a>
|
||||
   
|
||||
Back to <a href="../installation.html">Installing Haiku</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
|
||||
<h1>The BIOS</h1>
|
||||
<p>When you turn on a <acronym title="Basic Input Output System">BIOS</acronym> based (as opposed to firmware based) system, which is still the most common today, the first thing loaded will be the BIOS. It is like a small operating system of its own and has the purpose of configuring the system hardware and provide an environment that a more high level operating system can work with. For example it configures PCI devices, harddrive controllers, USB, the processor itself and sets up ACPI tables in main memory.<br />
|
||||
Current BIOSes are quite a bit more advanced than they were in the past, commonly having support for USB keyboards and USB mass storage to allow operating in so called legacy free configurations (i.e. without the old PS/2 input and maybe without some of the more traditional PC architecture components).<br />
|
||||
OK, not going into more detail as that's not essential here.</p>
|
||||
<p>So when the BIOS has done its job, it will try to find a <acronym title="Master Boot Record">MBR</acronym> on any of the harddisk-like medias or other boot method specific block on other media (El-Torito on CDs/DVDs for example). Something like a USB memory stick is regarded as being harddisk-like, because it really is emulating a SCSI harddisk to the system. When it finds a boot record, it then loads that into memory and instructs the CPU to start execution of the instructions present.</p>
|
||||
|
||||
<h1>The Master Boot Record</h1>
|
||||
<p>Generally this is just the first block of any harddisk-like medium, usually 512 bytes in length. It contains boot code in the first part and the partition table at the end of the block. What you have there as boot code depends on what boot manager you have installed. You have either installed a boot manager explicitly, for example GRUB or BeOS' bootman, or it was implicitly installed for you when partitioning the device (during Windows setup for example).<br />
|
||||
Boot managers range from totally simple ones that are just enough to find the partition marked active and jump to the partition boot code of said partition, to almost complete operating systems with editing capabilities and other fancy features.</p>
|
||||
|
||||
<h1>The Partition Boot Record</h1>
|
||||
<p>Additionally to the Master Boot Record, there can also be a partition boot record. It's located at the start of a partition and contains further boot code. Depending on the boot manager you are using and how you configured it, this boot code will be executed or not. In the case of Haiku the partition boot code does locate the <tt>/boot/beos/system/zbeos</tt>" file which then starts the operating system boot process.<br /> Additionally it contains the partition offset needed to access this partition during boot. A wrong value for that offset is probably one of the most common reason why a Haiku installation doesn't start to boot.</p>
|
||||
<p>As mentioned, whether or not the partition boot code is used depends on the boot manager and boot manager configuration. If you take GRUB installed as boot manager in the MBR and booting Linux. GRUB knows how to handle most Linux filesystems and it does know how to load and start a Linux kernel off of it. Therefore it can directly load Linux without the need for any additional boot code.<br />
|
||||
However GRUB does neither know how to handle BFS and find the zbeos boot loader, nor would it really know how to execute it. Therefore you cannot use GRUB to directly boot Haiku.<br />
|
||||
Instead you need to chainload the partition boot code of the BFS partition, as it knows how to handle both the BFS and zbeos.</p>
|
||||
|
||||
<h1>The Boot Loader</h1>
|
||||
<p>After the boot loader (zbeos in case of BeOS/Haiku) has been found and loaded into memory, it is executed. The boot loader is the one providing you with the Haiku boot menu when pressing the space bar in early boot and is the one detecting basic system configuration. It also contains the logic to find and load the kernel (kernel_intel on BeOS and kernel_x86 on Haiku) as well as some boot modules required. Boot modules include the bus managers, bus and device drivers required by the kernel to successfully access the boot volume to load the rest of the modules and execute anything it needs to fully boot the system.<br />
|
||||
If you boot to an ATA harddisk it would require for example the IDE or ATA bus manager, the harddisk controller driver and the helper modules used by them. Booting from USB would require the USB bus manager, the host controller drivers and the usb_disk driver for example. The boot loader also provides the kernel with configuration information and info about initial memory layout for example. This data passing between the boot loader and the kernel is specific to Haiku and the Haiku revision, it is possible that the information passed changes from one revision to another. This also makes it obvious that a zbeos from a BeOS installation cannot work with a Haiku kernel. Likewise using a BeOS bootfloppy that provides such a zbeos is not going to boot Haiku.</p>
|
||||
|
||||
<h1>The Kernel</h1>
|
||||
<p>Once the kernel is loaded and starts executing it sets up a working environment. Memory management, bootstrapping and configuring non-boot CPUs, timers, interrupts, filesystems, module infrastructure, drivers... Everything that is needed for a fully working system and has not yet been loaded. Once this environment is set up, the kernel will start the bootscript, that then launches the different servers to provide a usable userland.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="bottomnav">
|
||||
<p>
|
||||
<a href="../contents.html">Contents</a>
|
||||
   
|
||||
Back to <a href="../installation.html">Installing Haiku</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
116
userguide/en/installation/install-raw.html
Normal file
116
userguide/en/installation/install-raw.html
Normal file
@ -0,0 +1,116 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
||||
"../html-dtd/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xml:lang="en-US">
|
||||
<head>
|
||||
<!--
|
||||
*
|
||||
* Copyright 2009, Haiku. All rights reserved.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*
|
||||
* Authors:
|
||||
* Socapex_2K <philippe_groarke@yahoo.ca>
|
||||
*
|
||||
-->
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||
<meta http-equiv="Content-Style-Type" content="text/css" />
|
||||
<meta name="robots" content="all" />
|
||||
<title>Installing from a Raw Image</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../../Haiku-doc.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="logo">
|
||||
<img src="../../images/logo.png" alt="logo" width="372" height="86" />
|
||||
<div class="title">Installing from a Raw Image</div>
|
||||
</div>
|
||||
<div class="topnav">
|
||||
<p>
|
||||
<a href="../contents.html">Contents</a>
|
||||
   
|
||||
Back to <a href="../installation.html">Installing Haiku</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
|
||||
|
||||
<p>If you can't or don't want to go through building from source, you can also install an already built image. You'll have to <a href="http://www.haiku-files.org/raw">download a raw image</a> for that, not a VMWare image. Note that these are test images, they are not complete distributions that include a lot of software, both to keep the size and complexity of building them down.</p>
|
||||
|
||||
<h1>Installing on a partition</h1>
|
||||
<p>After you have downloaded the raw image, you need to get this image to the partition or medium you intend to install it to. Under BeOS, Linux or basically everything except Windows you can use <tt>dd</tt> to just copy it over, using the partition or drive as a target.</p>
|
||||
|
||||
<p>Under BeOS to partition X on the master on the first channel:</p>
|
||||
<pre class="terminal">dd if=/path/to/image of=/dev/disk/ide/ata/0/master/X</pre>
|
||||
|
||||
<p>Under BeOS to the raw slave on the first channel (overwriting the MBR):</p>
|
||||
<pre class="terminal">dd if=/path/to/image of=/dev/disk/ide/ata/0/master/raw</pre>
|
||||
|
||||
<p>Under Linux to partition X on the first hard disk:</p>
|
||||
<pre class="terminal">dd if=/path/to/image of=/dev/hdaX</pre>
|
||||
|
||||
<p>Make extra sure that you have the right partition picked there, as these commands are destructive. Recheck with a partitioning tool to verify for example. Note that you'll probably need administrative rights under Linux, so use <tt>sudo</tt> or <tt>su</tt> to execute these commands.</p>
|
||||
|
||||
<p>If you want to put the image at the absolute start of the drive (so that you don't need an additional boot manager), make sure that you write to the whole raw drive and not to a partition. You do that by specifying a raw device instead of a partition. Under Linux you would for example omit the partition number resulting in <tt>sdb</tt> instead of <tt>sdb1</tt>. Under BeOS you would pick the <tt>.../raw</tt> path instead of one with a number. If you use such a command, you overwrite the MBR containing the partition table. This means, that all the partitions on that drive will become inaccessible (not only the first part of the drive). So be sure that you want to do such a destructive operation!</p>
|
||||
|
||||
<p>Under Windows things are sadly a bit more complicated. You can try <tt>dd</tt> for Windows or use a tool like <a href="http://shounen.ru/soft/flashnul">Flashnul</a> to get the image to a partition or USB drive. You should find the tools on the Internet, go back to the <a href="installation-usb.html">USB section</a> to learn how to use <i>Flashnul</i> to copy a Haiku image.</p>
|
||||
|
||||
<p>Note that when you just copy over an image to a partition or drive, you won't be able to use the full size of the target partition/drive. The image was built with a certain size (256MB currently) which is the size of the filesystem inside the image. So there's no real point in making a 10GB partition available for it, it won't be usable.</p>
|
||||
|
||||
<h1>Copying the contents of a pre-built image</h1>
|
||||
<p>Instead of copying the image itself you can also make a separate BFS partition yourself and then copy over the contents of the image to that partition. You will need a platform supporting BFS to do that obviously, which leaves you with two possible options. Either you use a version of BeOS to do the setup with <i>DriveSetup</i> or <tt>mkbfs</tt> or you use Haiku itself with <i>Installer</i> or <i>DriveSetup</i>.<br />
|
||||
Once you've created and initialized the target partition you can mount the image (using tools like <i>Mount Image</i> or through the Terminal) and copy over all the files. If you are under Haiku, you can just as well use <i>Installer</i> to make a duplicate of your currently booted installation.</p>
|
||||
|
||||
<h1>Making it bootable</h1>
|
||||
<p>When you just create a plain partition and initialize it to a BFS filesystem or if you copy over a complete Haiku image, this doesn't necessarily make the partition bootable. The partition boot record may be missing, or the partition offset could be misconfigured. The prebuilt images for example contain a partition offset of 0 for example, since they are not actually partitioned. They only consist of a direct BFS filesystem, so the offset to that is 0. This will work in exactly one case, where you don't actually put it into a partition. If you for example copy such an image directly to a USB drive starting from 0, overwriting the MBR (destroying all partitions already there), then this will boot. If you however copy an image to the first partition on your hard disk, this will not work out of the box, as the boot code in the partition boot record won't find the desired filesystem at offset 0 (that's where the MBR still is).</p>
|
||||
|
||||
<p>To make sure a partition boot record is there and it contains the right partition offset, you can use the tool <tt>makebootable</tt>. It will do both, write the partition boot code to the beginning of the partition and detect and write the partition offset to where it is needed. You can use the <tt>makebootable</tt> from BeOS if you have a BeOS installation that has access to the partition in question. To do that, mount the volume you have Haiku installed to and use:</p>
|
||||
|
||||
<pre class="terminal">makebootable /HaikuMountpoint</pre>
|
||||
|
||||
<p>Where <tt>/HaikuMountpoint</tt> is where you have mounted your Haiku volume to. Note that the BeOS' <tt>makebootable</tt> can be used, because the partition boot record does only load the zbeos boot loader. As Haiku does provide a zbeos as well and there is no information passed from the partition boot code to the boot loader, this is compatible between BeOS and Haiku and you can use a BeOS' <tt>makebootable</tt> with a Haiku boot loader and the other way around.</p>
|
||||
|
||||
<p>If you already have some Haiku medium capable of booting Haiku (like a USB drive) you could also boot into Haiku and run <tt>makebootable</tt> from there. Note that there is currently a bug that will require you to run it from the location it resides in like so:</p>
|
||||
|
||||
<pre class="terminal">cd /bin
|
||||
makebootable /MountpointOfNewHaikuInstallation</pre>
|
||||
|
||||
<p>If you are on Linux or another build platform that has support for <tt>makebootable</tt> and have the sources available you can run:</p>
|
||||
|
||||
<pre class="terminal">jam run ":<build>makebootable" /dev/sdaX</pre>
|
||||
|
||||
<p>Where the <tt>/dev/sdaX</tt> is the partition that is supposed to be made bootable. Under Windows this is currently not possible.</p>
|
||||
|
||||
<h1>Configuring the boot manager</h1>
|
||||
<p>When the partition itself is bootable, i.e. contains a partition boot record and the correct partition offset, there needs to be a way to get it executed. If you use a boot manager like GRUB, you need to instruct it to load from that partition. You do that for GRUB by adding an entry to its <tt>menu.lst</tt> usually located at <tt>/boot/grub/menu.lst</tt>. The following would instruct it to switch to the partition and then just chainload the partition boot record:</p>
|
||||
|
||||
<pre>title Haiku
|
||||
rootnoverify (hd0,3)
|
||||
chainloader +1</pre>
|
||||
|
||||
<p>That would work if you installed to disk "0" and partition "3". Note that the GRUB naming is one-off the Linux one, so if you have it installed to <tt>/dev/sda4</tt> that would translate to disk "0" (sda == 0, sdb == 1, ...) and partition "3" (4 - 1).</p>
|
||||
|
||||
<p>In case you are using the BeOS boot manager, just re-run the <tt>bootman</tt> command and add the new Haiku partition to the boot menu.</p>
|
||||
|
||||
<p>If you have another boot manager consult its documentation on how to chainload partitions, most should support such a thing, possibly named a bit different. In doubt just add an entry for the partition, probably this will cause it to chainload, even if not explicitly named so.</p>
|
||||
|
||||
<!--
|
||||
This is destructive and you can't use anything after the image size of that drive, but if you get some cheap small USB memory stick just for that purpose it's certainly one of the easiest ways to boot Haiku. Once you've booted Haiku you can also do an installation from there, initializing partitions with BFS using DriveSetup and using the Installer to do a proper installation. Note that you cannot currently create partitions under Haiku. Use your preferred partition tool to create a dedicated partition before booting Haiku. Note also that the Installer doesn't have a link in the Haiku menu, therefore just run it from the Terminal. If you additionally execute it from "/bin" this works around the makebootable problem, giving you the commands:
|
||||
|
||||
cd /bin
|
||||
Installer
|
||||
|
||||
That should work and be pretty usable to boot devices that you have no other means to put Haiku onto otherwise. This works for example out of the box on the Asus EEE, but really should work for every USB bootable x86 machine. If it doesn't, please make sure that your issue is documented in a bug report at our bug tracker. We cannot fix it if we don't know that it's broken.
|
||||
-->
|
||||
</div>
|
||||
|
||||
<div class="bottomnav">
|
||||
<p>
|
||||
<a href="../contents.html">Contents</a>
|
||||
   
|
||||
Back to <a href="../installation.html">Installing Haiku</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
92
userguide/en/installation/install-source-beos.html
Normal file
92
userguide/en/installation/install-source-beos.html
Normal file
@ -0,0 +1,92 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
||||
"../html-dtd/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xml:lang="en-US">
|
||||
<head>
|
||||
<!--
|
||||
*
|
||||
* Copyright 2009, Haiku. All rights reserved.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*
|
||||
* Authors:
|
||||
* Socapex_2K <philippe_groarke@yahoo.ca>
|
||||
*
|
||||
-->
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||
<meta http-equiv="Content-Style-Type" content="text/css" />
|
||||
<meta name="robots" content="all" />
|
||||
<title>Building Haiku on BeOS</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../../Haiku-doc.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="logo">
|
||||
<img src="../../images/logo.png" alt="logo" width="372" height="86" />
|
||||
<div class="title">Building Haiku on BeOS</div>
|
||||
</div>
|
||||
<div class="topnav">
|
||||
<p>
|
||||
<a href="../contents.html">Contents</a>
|
||||
   
|
||||
Back to <a href="../installation.html">Installing Haiku</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
|
||||
<h1>Getting the source</h1>
|
||||
<p><b>Note:</b> <i>All commands must be executed in the Terminal.</i></p>
|
||||
|
||||
<p>Go to the parent directory for Haiku's repository (ex. <tt>/home/develop</tt>) and enter:</p>
|
||||
|
||||
<pre class="terminal">svn checkout svn://svn.berlios.de/haiku/haiku/trunk haiku</pre>
|
||||
|
||||
<p>This will checkout the source into a new subdirectory called "haiku". <b>Members</b> of Haiku should login with their BerliOS account to get commit access:</p>
|
||||
<pre class="terminal">svn checkout svn+ssh://developername@svn.berlios.de/svnroot/repos/haiku/haiku/trunk haiku</pre>
|
||||
|
||||
<p>After the <b>initial checkout</b> (also in case not the entire tree was checked out successfully) you can fetch source code updates with the following command in your repository's root folder:</p>
|
||||
<pre class="terminal">svn update</pre>
|
||||
|
||||
|
||||
<h1>Installing the cross-compiler</h1>
|
||||
<p>Download the <a href="http://haiku.mlotz.ch/haiku_cross_compiler_bone_2.95.3-haiku-080323.zip">Haiku cross-compiler</a> and extract it to <tt>/boot</tt> (for example by setting the <i>Destination</i> in Expander to just <tt>/boot</tt>). Then you need to configure your tree to use this cross compiler. Go to the root folder of your checked out Haiku repository and invoke the configure script with the <tt>--cross-tools-prefix</tt> option like this:</p>
|
||||
|
||||
<pre class="terminal">configure --cross-tools-prefix /boot/apps/haiku/cross-tools/bin/i586-pc-haiku-</pre>
|
||||
|
||||
<p>Be careful to include all of the string up to and including the last dash, as all the cross compiler tools have this prefix (they are for example called <tt>i586-pc-haiku-ar</tt>). You need to specify this prefix everytime you run configure.</p>
|
||||
|
||||
<h1>Building the source</h1>
|
||||
|
||||
<p>You can now start the build process with:</p>
|
||||
|
||||
<pre class="terminal">jam</pre>
|
||||
|
||||
<p style="text-indent: 15pt"><b>Note:</b> <i>this will just build any target that is found in the tree. This is usually not that useful, as many parts might not build and are not required. So optionally, a target can be specified by adding a target name. For example, </i><tt>jam app_server</tt><i> will only build the </i><tt>app_server</tt><i> target. Normally though you will want to build an image or installation using the commands below. Add the </i><tt>-a</tt><i> option to rebuild the whole source or only the specified target in case </i><tt>Jam</tt><i> didn't notice source changes.</i></p>
|
||||
|
||||
<h1>Building an image</h1>
|
||||
|
||||
<p>You can build a Haiku image with:</p>
|
||||
<pre class="terminal">jam haiku-image</pre>
|
||||
|
||||
<p>This will place a file named <tt>haiku.image</tt> into the <tt>generated/</tt> folder.</p>
|
||||
|
||||
<p>To build an image for testing in VMWare:</p>
|
||||
<pre class="terminal">jam haiku-vmware-image</pre>
|
||||
|
||||
<p>This will place a file named <tt>haiku.vmdk</tt> into the <tt>generated/</tt> folder.</p>
|
||||
|
||||
<p>Instead of building an image, you may install Haiku on a mounted partition using:</p>
|
||||
<pre class="terminal">HAIKU_INSTALL_DIR=/target_folder jam install-haiku</pre>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="bottomnav">
|
||||
<p>
|
||||
<a href="../contents.html">Contents</a>
|
||||
   
|
||||
Back to <a href="../installation.html">Installing Haiku</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
310
userguide/en/installation/install-source-linux.html
Normal file
310
userguide/en/installation/install-source-linux.html
Normal file
@ -0,0 +1,310 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
||||
"../html-dtd/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xml:lang="en-US">
|
||||
<head>
|
||||
<!--
|
||||
*
|
||||
* Copyright 2009, Haiku. All rights reserved.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*
|
||||
* Authors:
|
||||
* Socapex_2K <philippe_groarke@yahoo.ca>
|
||||
*
|
||||
-->
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||
<meta http-equiv="Content-Style-Type" content="text/css" />
|
||||
<meta name="robots" content="all" />
|
||||
<title>Building Haiku on linux</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../../Haiku-doc.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="logo">
|
||||
<img src="../../images/logo.png" alt="logo" width="372" height="86" />
|
||||
<div class="title">Building Haiku on Linux</div>
|
||||
</div>
|
||||
<div class="topnav">
|
||||
<p>
|
||||
<a href="../contents.html">Contents</a>
|
||||
   
|
||||
Back to <a href="../installation.html">Installing Haiku</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
|
||||
<p>The following will show you step by step how to get Haiku's source code and build tools, how to compile it all and how to generate either a VMWare image or directly install onto a partition or USB drive. You'll also learn how to exchange data with an image or an installation on it's partition.</p>
|
||||
<p><b>Note:</b> <i>This guide is based on Ubuntu 8.10, but should generally work the same way on all other Linux distributions. Some changes may apply.</i></p>
|
||||
|
||||
<h1>Downloading the tools and the Haiku source</h1>
|
||||
<ol>
|
||||
<li><p>Install all needed packages:</p>
|
||||
<pre class="terminal">sudo apt-get install subversion autoconf automake texinfo flex bison gawk build-essential</pre></li>
|
||||
|
||||
<li><p>Create the Haiku development directories and get the Haiku build tools source:</p>
|
||||
<pre class="terminal">mkdir develop
|
||||
cd develop
|
||||
mkdir haiku
|
||||
cd haiku
|
||||
svn checkout svn://svn.berlios.de/haiku/buildtools/trunk buildtools</pre></li>
|
||||
|
||||
<li><p>Build and install the Haiku Jam:</p>
|
||||
<pre class="terminal">cd buildtools/jam
|
||||
make
|
||||
sudo ./jam0 install
|
||||
cd ../..</pre></li>
|
||||
|
||||
<li><p>Get the Haiku source (this will take a while).<br />
|
||||
For anonymous check-out:</p>
|
||||
<pre class="terminal">svn checkout http://svn.berlios.de/svnroot/repos/haiku/haiku/trunk trunk</pre>
|
||||
<p>If you have a valid Haiku developer account at Berlios:</p>
|
||||
<pre class="terminal">svn checkout https://developername@svn.berlios.de/svnroot/repos/haiku/haiku/trunk trunk</pre>
|
||||
|
||||
<p>If there are any errors while checking out the source, just cd into the trunk directory and type <tt>svn update</tt> to get any missed files.<br />
|
||||
This is also how you update the code in the future.</p></li>
|
||||
|
||||
<li><p>Build the cross compiler tools (GCC 2.95):</p>
|
||||
<pre class="terminal">cd ~/develop/haiku/trunk
|
||||
./configure --build-cross-tools ../buildtools/</pre>
|
||||
<p>To build with GCC 4.x the configure line changes to:</p>
|
||||
<pre class="terminal">./configure --build-cross-tools-gcc4 x86 ../buildtools/</pre>
|
||||
<p>But keep in mind this will produce binaries which are not compatible with BeOS.</p></li>
|
||||
</ol>
|
||||
|
||||
<p><br /></p>
|
||||
<p>To download all code changes from now on, simply enter the <tt>haiku/trunk/</tt> folder and type:</p>
|
||||
<pre class="terminal">svn update</pre>
|
||||
|
||||
<h1>Customizing UserBuildConfig</h1>
|
||||
|
||||
<p>Now you could already start to build RAW or VMWare images. Before we come to that, however, let's have a look at the <tt>UserBuildConfig</tt> that can be used to customize and automate some things.</p>
|
||||
|
||||
<p>In <tt>trunk/haiku/build/jam/</tt> there's a <tt>UserBuildConfig.ReadMe</tt> that explains various options. <b>Don't</b> simply rename it and use it as <tt>UserBuildConfig</tt>!</p>
|
||||
<p>You start by duplicating the <tt>UserBuildConfig.sample</tt> and the remove the<tt>.sample</tt> suffix to get your <tt>UserBuildConfig</tt>. From the <tt>.ReadMe</tt> you can copy interesting parts into your config and customize them there.</p>
|
||||
|
||||
<ol>
|
||||
<li><p>First, the line needed for the optional "OpenSSH" package:</p>
|
||||
<pre>HAIKU_IMAGE_HOST_NAME = "TEST" ;</pre>
|
||||
</li>
|
||||
<li><p>Now the block that sets the defaults for timezone and keymap:</p>
|
||||
<pre># Add symlink/file (timezone and keymap settings) to the image.
|
||||
AddSymlinkToHaikuImage home config settings
|
||||
: /boot/beos/etc/timezones/Europe/Paris : timezone ;
|
||||
AddFilesToHaikuImage home config settings : German
|
||||
: Key_map ;</pre></li>
|
||||
<li><p>The build process can be fine tuned until it fits your needs. You could create your own folder <tt>haiku/trunk/user_data/</tt>
|
||||
and put files there that are then copied or unzipped into the image.
|
||||
Zipping is important when dealing with Haiku files with their
|
||||
attributes, because zipping them up will preserve them on non-BFS
|
||||
partitions.<br />
|
||||
For example:</p>
|
||||
|
||||
<pre># Zip up your emails between each system update and place the archive into the
|
||||
# user_data folder to be automatically put back when building the new image.
|
||||
UnzipArchiveToHaikuImage home
|
||||
: $(HAIKU_TOP)/user_data/mail.zip ;</pre>
|
||||
<p>The first line defines the location in the image where the archive will be unzipped (here: <tt>/boot/home/</tt>). Deeper hierarchies are separated with a blank instead of the usual "<tt>/</tt>" (see the setting of the timezone above).<br />
|
||||
The second line is the location of the zip file. <tt>$(HAIKU_TOP)</tt> is the lowest level of the checked out source tree, normally <tt>haiku/trunk/</tt>.</p>
|
||||
<p>In the same way, you use <tt>CopyDirectoryToHaikuImage</tt> and <tt>AddFilesToHaikuImage</tt> to copy whole directories or single files into the image.</p></li>
|
||||
|
||||
<li><p>The above commands are executed when building any kind of image.
|
||||
"Build Profiles" provide the means to set commands specifically for
|
||||
different configurations.<br />
|
||||
These are two profiles, one for building and installing an image
|
||||
directly onto a partition and the other to generate a VMWare image:</p>
|
||||
<pre>DefineBuildProfile disk : disk : "/dev/sda7" ;
|
||||
DefineBuildProfile vmware : vmware-image ;
|
||||
|
||||
switch $(HAIKU_BUILD_PROFILE) {
|
||||
case "disk" : {
|
||||
HAIKU_ADD_ALL_OPTIONAL_PACKAGES = 1 ;
|
||||
}
|
||||
|
||||
|
||||
case "vmware" : {
|
||||
HAIKU_IMAGE_SIZE = 900 ;
|
||||
HAIKU_DONT_CLEAR_IMAGE = 1 ;
|
||||
HAIKU_ADD_ALL_OPTIONAL_PACKAGES = 1
|
||||
}
|
||||
|
||||
}</pre>
|
||||
<p>The first line is especially important and <b>dangerous</b>: "<tt>/dev/sda7</tt>"<br />
|
||||
<span style="font-size: 1.2em; font-weight: bold;">The so defined partition will be irretrievably overwritten!
|
||||
</span></p>
|
||||
<p>Before you use this profile, you should make sure that it's really
|
||||
the correct partition on the right harddisk or USB-stick, for example
|
||||
by using Ubuntu's partition editor <i>GParted</i>.</p></li>
|
||||
|
||||
</ol>
|
||||
<p><br /></p>
|
||||
<p>Here's the complete <tt>UserBuildConfig</tt> once more:</p>
|
||||
<pre># Quick start file for UserBuildConfig. Copy it and uncomment and edit the
|
||||
# lines you want. See UserBuildConfig.ReadMe for details.
|
||||
|
||||
# Optional package OpenSSH needs this variable set
|
||||
HAIKU_IMAGE_HOST_NAME = "TEST" ;
|
||||
|
||||
# Add symlink/file (timezone and keymap settings) to the image.
|
||||
AddSymlinkToHaikuImage home config settings
|
||||
: /boot/beos/etc/timezones/Europe/Paris : timezone ;
|
||||
AddFilesToHaikuImage home config settings : German
|
||||
: Key_map ;
|
||||
|
||||
DefineBuildProfile disk : disk : "/dev/sda7" ;
|
||||
DefineBuildProfile vmware : vmware-image ;
|
||||
|
||||
switch $(HAIKU_BUILD_PROFILE) {
|
||||
case "disk" : {
|
||||
HAIKU_ADD_ALL_OPTIONAL_PACKAGES = 1 ;
|
||||
}
|
||||
|
||||
|
||||
case "vmware" : {
|
||||
HAIKU_IMAGE_SIZE = 900 ;
|
||||
HAIKU_DONT_CLEAR_IMAGE = 1 ;
|
||||
HAIKU_ADD_ALL_OPTIONAL_PACKAGES = 1 ;
|
||||
}
|
||||
|
||||
}</pre>
|
||||
|
||||
<p style="text-indent: 15pt"><b>Note:</b> <i>when building an a USB memory stick, you wouldn't specify the partition number in the disk entry (ex. </i><tt>/dev/sdb</tt><i> instead of </i><tt>/dev/sdb1</tt><i>). This will erase your whole flash drive and it's partitions, so be cautious the drive name is exact.</i></p>
|
||||
|
||||
<p>Besides these user build profiles, there are also official release profiles, see <tt>ReleaseBuildProfiles</tt> in the same folder. The profiles <i>alpha-raw</i> and <i>alpha-vmware</i> will build all officially planned components for the alpha release. They are invoked just like the user profiles, see <a href="#build_vmimage">Building a VMWare Image</a> a bit further down.
|
||||
</p>
|
||||
|
||||
<h1>Building/installing Haiku Images</h1>
|
||||
|
||||
<p>Thanks to our <tt>UserBuildConfig</tt> it's all quite simple now.</p>
|
||||
|
||||
<h4>Installing on a partition/USB-stick</h4>
|
||||
|
||||
<p>To install Haiku directly onto a partition/USB-stick, you have to
|
||||
set the according read and write permissions. <br />
|
||||
When installing to a hard drive partition, replace the drive name and use:</p>
|
||||
|
||||
<pre class="terminal">
|
||||
sudo chmod o+r /dev/sda
|
||||
sudo chmod o+rw /dev/sda7
|
||||
</pre>
|
||||
|
||||
<p style="margin: 15pt">Note that the read permission is set for the whole disk (1st line)
|
||||
while the write permission is limited to one specific partition (2nd
|
||||
line).</p>
|
||||
|
||||
<p>When installing to a USB flashdrive, replace the drive name, and type:</p>
|
||||
<pre class="terminal">sudo chmod o+r /dev/sda</pre>
|
||||
<br />
|
||||
|
||||
<p>Now the Haiku image is built and installed on the partition:</p>
|
||||
|
||||
<pre class="terminal">sudo jam -q @disk</pre>
|
||||
|
||||
<p>Installing to its own partition offers some interesting possibilities:</p>
|
||||
<pre class="terminal">sudo jam -q @disk update-all</pre>
|
||||
|
||||
<p style="margin: 15pt">This updates all of the system, but leaves the home folder untouched, so all your data will still be there.</p>
|
||||
|
||||
<p>You can also decide to only update certain components:</p>
|
||||
<pre class="terminal">sudo jam -q @disk update {components}</pre>
|
||||
|
||||
<p style="margin: 15pt">Just replace the <tt>{components}</tt> with the program/component to be updated, e.g. <tt>kernel</tt>, <tt>StyledEdit</tt> or <tt>libmedia.so</tt> or more than one, separated with blanks. <tt>haiku/build/jam/HaikuImage</tt> lists all possible "targets".</p>
|
||||
|
||||
|
||||
<h4><a id="build_vmimage" name="build_vmimage">Building a VMWare Image</a></h4>
|
||||
|
||||
<p>Just enter:</p>
|
||||
<pre class="terminal">sudo jam -q @vmware</pre>
|
||||
|
||||
<p>You'll now have to rededicate the generated image to satisfy the VMPlayer, before you can run it with an associated <a href="http://haiku-files.org/files/haiku.vmx">.vmx</a> file (There's also a <tt>.vmx</tt> file in <tt>haiku/3rdparty/vmware/</tt>):</p>
|
||||
|
||||
<pre class="terminal">sudo chown [YourUsername] haiku.image</pre>
|
||||
|
||||
|
||||
<h1>Booting with GRUB</h1>
|
||||
|
||||
<p>If you installed Haiku directly onto a USB-stick, you just have to
|
||||
make sure the boot order in the BIOS looks first for USB devices to
|
||||
have Haiku boot right up from the stick.</p>
|
||||
|
||||
<p>If Haiku was installed on a partition on your hard drive, you have to
|
||||
adjust the boot loader accordingly. This is how it's done with GRUB:</p>
|
||||
|
||||
<pre class="terminal">sudo gedit /boot/grub/menu.lst</pre>
|
||||
|
||||
<p>You'll note that GRUB uses a different naming strategy for hard drives than Linux.</p>
|
||||
|
||||
<p>With GRUB it's: <tt>(hdN,n)</tt></p>
|
||||
<p>All harddisks start with "<i>hd</i>"<br />
|
||||
"<i>N</i>" is the hard disk number, starting with "0".<br />
|
||||
"<i>n</i> is the partition number, also starting with "0".<br />
|
||||
|
||||
The first logical partition always have the number 4, regardless of the number of primary partitions.</p>
|
||||
|
||||
<p>If you're still unsure, check out the <a href="http://www.gnu.org/software/grub/manual/grub.html#Naming-convention">GRUB manual</a>.</p>
|
||||
|
||||
<p>As an example:</p>
|
||||
|
||||
<p style="margin: 15pt"><tt>/dev/sda7</tt> would be <tt>(hd0,6)</tt> in GRUB.</p>
|
||||
|
||||
<p>Now using your own hard drive number, type this entry in <tt>/boot/grub/menu.lst</tt>:</p>
|
||||
|
||||
<pre># Haiku on /dev/sda7
|
||||
title Haiku
|
||||
rootnoverify (hd0,6)
|
||||
chainloader +1</pre>
|
||||
|
||||
<p>Save, reboot and choose "Haiku" in the GRUB menu at boot-up.</p>
|
||||
|
||||
|
||||
<h1>Accessing images/partitions</h1>
|
||||
|
||||
<p>Using build profiles has another advantage: You can mount a VMWare
|
||||
image or the partition of a Haiku installation to transfer data.
|
||||
Navigate to <tt>haiku/trunk/</tt> and simply enter:</p>
|
||||
<pre class="terminal">sudo jam @disk mount</pre>
|
||||
|
||||
<p>or</p>
|
||||
<pre class="terminal">sudo jam @vmware mount</pre>
|
||||
<p>You are now in the <tt>bfs_shell</tt>. Enter <tt>help</tt> to get a list of all supported commands:</p>
|
||||
<pre class="terminal">fssh:/> help
|
||||
supported commands:
|
||||
cd - change current directory
|
||||
chmod - change file permissions
|
||||
cp - copy files and directories
|
||||
exit - quit the shell
|
||||
help - list supported commands
|
||||
info - prints volume informations
|
||||
ln - create a hard or symbolic link
|
||||
ls - list files or directories
|
||||
mkdir - create directories
|
||||
mkindex - create an index
|
||||
query - query for files
|
||||
quit - quit the shell
|
||||
rm - remove files and directories
|
||||
sync - syncs the file system</pre>
|
||||
<p>It all works pretty much like in your normal bash shell (besides there's sadly no tab-completion).<br />
|
||||
|
||||
The one thing to remember: You have to prefix every local path (your Linux partition) with a "<tt>:</tt>".</p>
|
||||
<p>Here's an example to copy the file <tt>.bash_history</tt> from Haiku to your Linux partition:</p>
|
||||
<pre class="terminal">fssh:/> cd myfs/home
|
||||
fssh:/myfs/home> cp .bash_history :/home/humdinger/</pre>
|
||||
<p>The other way around works the same:</p>
|
||||
|
||||
<pre class="terminal">fssh:> cp :/home/humdinger/Bilder/gazette-final.png myfs/home/</pre>
|
||||
|
||||
<!--To Continue?
|
||||
|
||||
-->
|
||||
</div>
|
||||
|
||||
<div class="bottomnav">
|
||||
<p>
|
||||
<a href="../contents.html">Contents</a>
|
||||
   
|
||||
Back to <a href="../installation.html">Installing Haiku</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
251
userguide/en/installation/install-source-mac.html
Normal file
251
userguide/en/installation/install-source-mac.html
Normal file
@ -0,0 +1,251 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
||||
"../html-dtd/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xml:lang="en-US">
|
||||
<head>
|
||||
<!--
|
||||
*
|
||||
* Copyright 2009, Haiku. All rights reserved.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*
|
||||
* Authors:
|
||||
* Socapex_2K <philippe_groarke@yahoo.ca>
|
||||
*
|
||||
-->
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||
<meta http-equiv="Content-Style-Type" content="text/css" />
|
||||
<meta name="robots" content="all" />
|
||||
<title>Building Haiku on Mac OS X</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../../Haiku-doc.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="logo">
|
||||
<img src="../../images/logo.png" alt="logo" width="372" height="86" />
|
||||
<div class="title">Building Haiku on Mac OS X</div>
|
||||
</div>
|
||||
<div class="topnav">
|
||||
<p>
|
||||
<a href="../contents.html">Contents</a>
|
||||
   
|
||||
Back to <a href="../installation.html">Installing Haiku</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
|
||||
<!--
|
||||
|
||||
TODO:
|
||||
|
||||
|
||||
-->
|
||||
|
||||
<p>Even if Mac OS X is Unix based, building Haiku on it still requires some tweaks.
|
||||
These instructions were tested on Mac OS X 10.5.5 (Leopard). They may not work on older versions of Mac OS X (Tiger, Panther etc.)</p>
|
||||
|
||||
<h1>Requirements</h1>
|
||||
<ul>
|
||||
<li>You will need the Xcode Tools: use the installer on your Mac OS X Install DVD, or download the latest version from <a href="http://connect.apple.com/">Apple Developer Connection</a> (free registration required).</li>
|
||||
|
||||
<li>You must be logged in as <b>administrator</b> to install some tools.</li>
|
||||
<li><a href="http://www.macports.org/">MacPorts</a> will also be required (see Step 3 for installation tips)</li>
|
||||
</ul>
|
||||
|
||||
<h2>Step 1: Case-sensitive disk image</h2>
|
||||
|
||||
<p>The Mac OS file system, HFS+, is case-insensitive by default. This causes troubles during the build of some Haiku components, because of wrong headers inclusion ("String.h" (from Haiku) instead of "string.h" (from the system) for
|
||||
instance). If your Mac OS X partition is not in case-sensitive HFS+ (which is very
|
||||
likely), you need to create a case-sensitive disk image and put Haiku
|
||||
buildtools and source code on it.</p>
|
||||
|
||||
<p>1) Open Disk Utility (in /Application/Utilities)<br />
|
||||
2) Click "New Image", and enter the following parameters:</p>
|
||||
<ul>
|
||||
<li>Volume name: You should enter a short name without special character or spaces.</li>
|
||||
<li>Volume size: the minimum volume size is 2.68 Gb, the recommended size is the double. Do not worry about making the image bigger, since only the consumed space will be used on your hard drive.</li>
|
||||
<li>Volume format: Mac OS Extended (Case-sensitive, Journaled)</li>
|
||||
<li>Encryption: You should say "none", unless you really want to slow down Haiku building…</li>
|
||||
<li>Partitions: (Tiger users will not have this - just skip it): Choose No partition map.</li>
|
||||
<li>Image format: Choose “sparse disk image”.</li>
|
||||
</ul>
|
||||
|
||||
<p><img alt="macosx.png" src="../../images/installation-images/macosx.png" /></p>
|
||||
|
||||
<p>The image is automatically mounted on the Desktop. If you want to remount it later, just double-click on the image file.</p>
|
||||
|
||||
<h2>Step 2: Fetching the buildtools and the Haiku source code</h2>
|
||||
|
||||
<p>Open a Terminal (in /Application/Utilities), and enter:</p>
|
||||
<pre class="terminal">cd /Volumes/Haiku/</pre>
|
||||
|
||||
<p><tt>/Volumes/Haiku</tt> refers here (and in
|
||||
all this tutorial) to the mounted disk image name. I named it "Haiku",
|
||||
so if you chose another name, use it instead of "Haiku" after
|
||||
<tt>/Volumes/</tt>.</p>
|
||||
|
||||
<p>Checkout the buildtools:</p>
|
||||
<pre class="terminal">svn checkout svn://svn.berlios.de/haiku/buildtools/trunk buildtools</pre>
|
||||
|
||||
<p><b>Note:</b> <i>in Tiger, as I remember, Subversion is not available with Xcode 2.5. You have to install it manually.</i></p>
|
||||
|
||||
<p>And the source code:</p>
|
||||
<pre class="terminal">svn checkout svn://svn.berlios.de/haiku/haiku/trunk haiku</pre>
|
||||
|
||||
<p>You should now have two folders "haiku" and "buildtools" into the mounted disk image.</p>
|
||||
|
||||
<p>To update your code from now on, go to the <tt>haiku/trunk/</tt> folder and type:</p>
|
||||
<pre class="terminal">svn update</pre>
|
||||
|
||||
<h2>Step 3: Install required software</h2>
|
||||
|
||||
<p>First, install <a href="http://www.macports.org/">MacPorts</a> (A standard Installer package is provided)</p>
|
||||
|
||||
<p>Close your Terminal, and enter in a new one:</p>
|
||||
<pre class="terminal">sudo port install gnuregex gawk wget</pre>
|
||||
|
||||
<p>You will be prompted for the administrator password of the current account - Do not worry if nothing you type shows after the Password prompt, this is intended.</p>
|
||||
|
||||
<p>If you get an error "port: command not found", the MacPorts shell configuration is probably not taken into account. You probably have a <tt>~/.bash_profile</tt> or <tt>~/.bash_login</tt> file overwriting MacPorts config located in <tt>~/.profile</tt>. When a "login shell" starts up, it reads the file <tt>"/etc/profile"</tt> and then <tt>"~/.bash_profile"</tt> or <tt>"~/.bash_login"</tt> or <tt>"~/.profile"</tt> (whichever one exists - it only reads one of these, checking for them in the order mentioned). Check the file used by Bash (in the mentioned order) and add these lines to the used file:</p>
|
||||
|
||||
<pre class="terminal">nano ~/.bash_profile
|
||||
<b>or</b>
|
||||
nano ~/.bash_login
|
||||
<b>or</b>
|
||||
nano ~/.profile
|
||||
</pre>
|
||||
|
||||
<p>Add at the end of the chosen file :</p>
|
||||
<pre>export PATH=/opt/local/bin:$PATH
|
||||
export MANPATH=$MANPATH:/opt/local/share/man
|
||||
export INFOPATH=$INFOPATH:/opt/local/share/info</pre>
|
||||
|
||||
<p>To save the file and quit the editor, type <tt>CTRL-X</tt>, <tt>Y</tt> and <tt>RETURN</tt>. If you are using another shell, take a look a the shell documentation to see which file is parsed at login, and add the required commands.</p>
|
||||
|
||||
<p>You can now retry the command in a new Terminal:</p>
|
||||
<pre class="terminal">sudo port install gnuregex gaw wget</pre>
|
||||
|
||||
<p>After MacPorts finished installing the tools, install the modified Haiku jam:</p>
|
||||
<pre class="terminal">cd /Volumes/Haiku/buildtools/jam
|
||||
make
|
||||
sudo ./jam0 install
|
||||
[Enter your password]
|
||||
cd ..</pre>
|
||||
|
||||
<p>Reopen a new Terminal, and enter:</p>
|
||||
<pre class="terminal">jam -v</pre>.
|
||||
|
||||
<p>You should get:</p>
|
||||
<pre>Jam 2.5-haiku-20080327. OS=MACOSX. Copyright 1993-2002 Christopher Seiwald.</pre>
|
||||
|
||||
<h2>Step 4: Let's Patch</h2>
|
||||
|
||||
<p>With your favorite text editor, open the file:<br /> <tt>[Mounted Disk Image]/buildtools/legacy/gcc/config.guess</tt></p>
|
||||
|
||||
<p>Go to line 522, and add this:</p>
|
||||
<pre>*:Darwin:*:*)
|
||||
echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*//'`
|
||||
exit 0 ;;</pre>
|
||||
|
||||
<p>before:</p>
|
||||
<pre>*:FreeBSD:*:*)
|
||||
if test -x /usr/bin/objformat -a "elf" = "`/usr/bin/objformat`"; then
|
||||
echo ${UNAME_MACHINE}-unknown-freebsdelf
|
||||
else
|
||||
echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*//'`
|
||||
fi
|
||||
exit 0 ;;</pre>
|
||||
|
||||
<p><b>Warning!</b> When you copy-paste preformatted text from a web page, some versions of Safari replace every space with a no-break space. You can use the search/replace function of your text editor to replaces these "spaces" with real ones. (or copy the text by hand... or use another browser).</p>
|
||||
|
||||
<p>Save the file, and open:<br />
|
||||
<tt>[Mounted Disk Image]/buildtools/legacy/gcc/Makefile.in</tt></p>
|
||||
|
||||
<p>Replace (line 144):</p>
|
||||
|
||||
<pre>MAKEINFO = `if [ -f $$r/texinfo/makeinfo/Makefile ] ; \
|
||||
then echo $$r/texinfo/makeinfo/makeinfo ; \
|
||||
else echo makeinfo ; fi`</pre>
|
||||
<p>By:</p>
|
||||
<pre>MAKEINFO = `if which -s makeinfo ; \
|
||||
then echo makeinfo ; \
|
||||
else echo $$r/texinfo/makeinfo/makeinfo ; fi`</pre>
|
||||
|
||||
<p>These patches are from the <a href="http://www.freelists.org/archives/haiku-development/09-2008/msg00294.html">Haiku development mailing list</a>, thanks to their authors!</p>
|
||||
|
||||
<h2>Step 5: Building the buildtools</h2>
|
||||
|
||||
<p>Now, you can compile GCC2 with:</p>
|
||||
<pre class="terminal">cd /Volumes/Haiku/haiku
|
||||
./configure --build-cross-tools ../buildtools</pre>
|
||||
|
||||
<p>If you want to build Haiku with GCC4, use :</p>
|
||||
<pre class="terminal">./configure --build-cross-tools-gcc4 x86 ../buildtools/</pre>
|
||||
|
||||
<p>If you do not now which one you should use, choose gcc2 : Original BeOS R5 binaries (and many Haiku optional packages) will not run on a gcc4 build.</p>
|
||||
|
||||
<p><tt>./configure</tt> has some more options, use this command to list them:</p>
|
||||
<pre class="terminal">./configure --help</pre>
|
||||
|
||||
<p>After some time, you should get:</p>
|
||||
<pre>binutils and gcc for cross compilation have been built successfully!</pre>
|
||||
|
||||
<h2>Step 6: Customizing the UserBuildConfig</h2>
|
||||
|
||||
<p>Now you could already start to build RAW or VMWare images. Before we come to that, however, let's have a look at the UserBuildConfig that can be used to customize and automate some things.</p>
|
||||
|
||||
<p>In <tt>trunk/haiku/build/jam/</tt> there's a <tt>UserBuildConfig.ReadMe</tt> that explains various options. <b>Don't</b> simply rename it and use it as UserBuildConfig!</p>
|
||||
|
||||
You start by duplicating the <tt>UserBuildConfig.sample</tt> and the remove the .sample suffix to get your <tt>UserBuildConfig</tt>. From the .ReadMe you can copy interesting parts into your config and customize them there.
|
||||
|
||||
<h2>Step 7: Building Haiku</h2>
|
||||
|
||||
<p>Since on-disk install from Mac OS X does not seems possible at this time, you will need to use an emulation or virtualisation software.</p>
|
||||
|
||||
<h3>Instructions for VMWare Fusion:</h3>
|
||||
<p>The command:</p>
|
||||
<pre class="terminal">cd /Volumes/Haiku/haiku
|
||||
jam -q haiku-vmware-image</pre>
|
||||
|
||||
<p>will build a VMWare disk image:<br />
|
||||
<tt>[Mounted Disk Image]/haiku/generated/haiku.vmdk</tt>.</p>
|
||||
|
||||
<p>To use it, follow these steps:</p>
|
||||
|
||||
<ol>
|
||||
<li>Create a folder at the root of the disk image.</li>
|
||||
<li>Copy <tt>[Mounted Disk Image]/3rdparty/vmware/haiku.vmx</tt> inside this folder, and edit the copy.</li>
|
||||
<li>Change <tt>ide0:0.fileName = "haiku.vmdk"</tt> to <tt>ide0:0.fileName = "../haiku/generated/haiku.vmdk"</tt>. Save the file.</li>
|
||||
<li>Double-clicking on the file should start VMWare Fusion and launch Haiku.</li>
|
||||
</ol>
|
||||
|
||||
<p>VMWare will create some files in the folder you put haiku.vmx. If you want easy access to the virtual machine file, make an alias of the haiku.vmx file (or put it into the Dock). Launching this alias will mount the disk image and start the VM, automatically.</p>
|
||||
|
||||
<p>Haiku should run in:<br />
|
||||
<a href="http://www.kju-app.org/">Q</a> (free),<br />
|
||||
<a href="http://www.parallels.com/desktop/">Parallels Desktop</a> (commercial) and,<br />
|
||||
<a href="http://www.virtualbox.org/">VirtualBox</a> (free).</p>
|
||||
|
||||
<p><b>Note:</b> <i>For more information refer to the topic <a href="install-vm.html">Running Haiku in a virtual machine</a>.</i></p>
|
||||
|
||||
<p>Some of them (like Parallels and Virtual box, maybe others) can use the VMWare disk image (see above). For the others you can create a raw disk image.</p>
|
||||
|
||||
<h3>Create a raw disk image</h3>
|
||||
|
||||
<pre class="terminal">cd /Volumes/Haiku/haiku
|
||||
jam haiku-image</pre>
|
||||
|
||||
<p>The image will be created in <tt>[Mounted Disk Image]/haiku/generated/haiku.image</tt>.</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="bottomnav">
|
||||
<p>
|
||||
<a href="../contents.html">Contents</a>
|
||||
   
|
||||
Back to <a href="../installation.html">Installing Haiku</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
50
userguide/en/installation/install-source-windows.html
Normal file
50
userguide/en/installation/install-source-windows.html
Normal file
@ -0,0 +1,50 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
||||
"../html-dtd/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xml:lang="en-US">
|
||||
<head>
|
||||
<!--
|
||||
*
|
||||
* Copyright 2009, Haiku. All rights reserved.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*
|
||||
* Authors:
|
||||
* Socapex_2K <philippe_groarke@yahoo.ca>
|
||||
*
|
||||
-->
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||
<meta http-equiv="Content-Style-Type" content="text/css" />
|
||||
<meta name="robots" content="all" />
|
||||
<title>Building Haiku on Windows</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../../Haiku-doc.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="logo">
|
||||
<img src="../../images/logo.png" alt="logo" width="372" height="86" />
|
||||
<div class="title">Building Haiku on Windows</div>
|
||||
</div>
|
||||
<div class="topnav">
|
||||
<p>
|
||||
<a href="../contents.html">Contents</a>
|
||||
   
|
||||
Back to <a href="../installation.html">Installing Haiku</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<div class="bottomnav">
|
||||
<p>
|
||||
<a href="../contents.html">Contents</a>
|
||||
   
|
||||
Back to <a href="../installation.html">Installing Haiku</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
193
userguide/en/installation/install-usb.html
Normal file
193
userguide/en/installation/install-usb.html
Normal file
@ -0,0 +1,193 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
||||
"../html-dtd/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xml:lang="en-US">
|
||||
<head>
|
||||
<!--
|
||||
*
|
||||
* Copyright 2009, Haiku. All rights reserved.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*
|
||||
* Authors:
|
||||
* Socapex_2K <philippe_groarke@yahoo.ca>
|
||||
*
|
||||
-->
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||
<meta http-equiv="Content-Style-Type" content="text/css" />
|
||||
<meta name="robots" content="all" />
|
||||
<title>Installing on a USB flash drive</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../../Haiku-doc.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="logo">
|
||||
<img src="../../images/logo.png" alt="logo" width="372" height="86" />
|
||||
<div class="title">Installing on a USB flash drive</div>
|
||||
</div>
|
||||
<div class="topnav">
|
||||
<p>
|
||||
<a href="contents.html">Contents</a>
|
||||
   
|
||||
Previous: <a href="installation.html">Installation Basics</a>
|
||||
   
|
||||
Next: <a href="installation-vm.html">Emulating Haiku</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
|
||||
<!-- This whole topic should be combined with install-raw.html -->
|
||||
|
||||
<!--
|
||||
TODO
|
||||
|
||||
- Test out dd to usb stick on mac. Confirm it writes on byte 0 of the drive.
|
||||
|
||||
- Does BeOS, Freebsd and others (which?) use fdisk -l (For USB KEY install).
|
||||
|
||||
- Reformat my steps to remove the 15pt margin between terminal style text
|
||||
|
||||
-->
|
||||
|
||||
<h1><a id="usb" name="usb">Installing on a USB flash drive</a></h1>
|
||||
<ul>
|
||||
<li><a href="#unix">From a Unix system</a></li>
|
||||
<li><a href="#windows">From Windows</a></li>
|
||||
</ul><br />
|
||||
|
||||
<p>Booting Haiku from a USB memory stick is currently one of the best ways to test out the operating system. No changes will be made to your computer, so you can test a pre-Alpha OS without any worries. It is also the easiest method to install Haiku, so it is recommended for beginners. The installation process differs from a Unix system (This includes many operating systems like Linux, Mac OS X, FreeBSD and such) to that of Windows.</p>
|
||||
|
||||
<p> You will need a small USB memory stick (512MB should be more than enough) that you are ready to erase and a recent <a href="http://haiku-files.org/raw/index.php">HDD raw image</a>. Note that these are test images, they are not complete distributions that include a lot of software. Future releases will include a more complete set of software, obviously. Your motherboard should also support booting from USB Drives (most recent computers do).</p>
|
||||
|
||||
<h2><a id="unix" name="unix">Using a Unix system (Linux, Mac OS X, FreeBSD etc.)</a></h2>
|
||||
<p>Now that you've downloaded the raw image, you will need to expand this image on your USB Drive you intend to install it to. You will first need to know the name of your drive (something like <tt>/dev/sdb</tt>, <tt>/dev/disk1</tt> or a variant).</p>
|
||||
|
||||
<p>First connect your flash drive.</p>
|
||||
<p>Under Linux, open your shell and type:</p>
|
||||
<pre class="terminal">fdisk -l</pre>
|
||||
|
||||
<p>On Mac OS X, open the terminal (<i>Utilities > Terminal</i>) and type:</p>
|
||||
<pre class="terminal">df -hl</pre>
|
||||
|
||||
<p>The output should resemble something like,</p>
|
||||
|
||||
<pre>Disk /dev/sda: 4034 MB, 4034838528 bytes
|
||||
255 heads, 63 sectors/track, 490 cylinders
|
||||
Units = cylinders of 16065 * 512 = 8225280 bytes
|
||||
Disk identifier: 0x000740f4
|
||||
|
||||
Device Boot Start End Blocks Id System
|
||||
/dev/sda1 * 1 462 3710983+ 83 Linux
|
||||
/dev/sda2 463 490 224910 5 Extended
|
||||
/dev/sda5 463 490 224878+ 82 Linux swap / Solaris
|
||||
|
||||
<b>Disk /dev/sdb: 16.1 GB, 16139354112 bytes</b>
|
||||
255 heads, 63 sectors/track, 1962 cylinders
|
||||
Units = cylinders of 16065 * 512 = 8225280 bytes
|
||||
Disk identifier: 0xf26d47c4</pre>
|
||||
|
||||
or
|
||||
|
||||
<pre>Filesystem Size Used Avail Capacity Mounted on
|
||||
/dev/disk0s2 186Gi 112Gi 74Gi 61% /
|
||||
<b>/dev/disk1s1 1.9Gi 265Mi 1.6Gi 14% /Volumes/KINGSTON</b></pre>
|
||||
|
||||
<p>Now you need to use the <tt>dd</tt> tool to extract the raw image to your USB Key. Make sure you have the right drive selected here, since this will erase all data on the specified location. Recheck with a partition tool to verify for example. You might need administrative rights, so add the <tt>sudo</tt> or <tt>su</tt> command before the next step to run the process as administrator (a password will be required).</p>
|
||||
|
||||
<p><b>Note:</b> <i>You will want to put the image at the absolute start of the drive, make sure that you write to the whole raw drive and not to a partition. You do that by specifying a raw device instead of a partition. Under Linux you would for example omit the partition number resulting in</i> <tt>sdb</tt> <i>instead of</i> <tt>sdb1</tt><i>. Under BeOS you would pick the</i> <tt>.../raw</tt> <i>path instead of one with a number. If you use such a command, you overwrite the MBR containing the partition table of your USB memory stick. This means, that all the partitions on that drive will become inaccessible (not only the first part of the drive). So be sure that you want to do such a destructive operation!</i></p>
|
||||
|
||||
<p>Still in the terminal, enter:</p>
|
||||
<pre class="terminal">dd if=/path/to/image of=/dev/sdb</pre>
|
||||
|
||||
<p>Where <tt>/dev/sdb</tt> stands for your USB memory stick's name found earlier.</p>
|
||||
|
||||
<p>Congratualtions! You have just installed Haiku to a USB memory stick. You can now restart your computer to boot from Haiku. Note that you will probably have to enable USB drive booting in your BIOS and change the hard drive boot priority order. If Haiku's splash screen stops in the middle of the icons, and then sends you to <i>Kernel Debug Land</i>, you might have to disable the <i>Plug and Play OS</i> option in your BIOS.</p>
|
||||
|
||||
<h2><a id="windows" name="windows">Using Windows</a></h2>
|
||||
<p>You will need basic knowledge of your command prompt to go through this step-by-step guide. You can type <tt>help</tt> inside your command prompt to get some information on the required navigation commands.</p>
|
||||
|
||||
<p>You have to download and install the latest <a href="http://shounen.ru/soft/flashnul">Flashnul</a> utility.</p>
|
||||
|
||||
<p><b>Note:</b><i>The <i>Flashnul</i> website isn't in English. You can simply click on the "Download" link and then select the upper-most entry (the latest version) to download.</i></p>
|
||||
|
||||
<p>Extract your raw image zip file and the <i>Flashnul</i> program in the same directory (ex. <tt>c:\haiku</tt>). Rename the raw image's extension to <tt>.img</tt> (ex. <tt>haiku.img</tt>).</p>
|
||||
|
||||
<p>Open your command prompt (go to <i>Start > Run</i>, then type <tt>cmd</tt> and press <tt>ENTER</tt>). You will see a black window with a blinking cursor, this is your command line editor (commonly named command prompt or shell).</p>
|
||||
|
||||
<p><b>Note:</b><i>If you are using Windows Vista, you will need administrator rights to see the available physical drives. To run the command prompt in administrator mode, go to </i>Start > All Programs > Accessories > Command prompt<i>, right click on the program and select </i>Run as Administrator.</p>
|
||||
|
||||
<p>Navigate to the directory containing your raw image and the <i>Flashnul</i> utility. For example,</p>
|
||||
<pre class="terminal">cd \haiku</pre>
|
||||
<p>if the directory is <tt>c:\haiku</tt></p>
|
||||
|
||||
<p>You need to find the number of your USB flash drive. This is very important, because if you do not select the right drive, your whole hard drive <b><i>will be erased</i></b>. To find out your flashdrive's name, in the command prompt, type:</p>
|
||||
<pre class="terminal">flashnul -p</pre>
|
||||
|
||||
<p>The output should resemble something like,</p>
|
||||
<pre>Available physical drives:
|
||||
0 size = 81961123328 (76 Gb)
|
||||
<b>1 size = 1000341504 (954 Mb)</b></pre>
|
||||
|
||||
<p>You are now ready to extract the raw image over the memory stick. Make sure the number you have noted <i>is the one of your flash drive</i>. X being your memory stick's number, type:</p>
|
||||
|
||||
<pre class="terminal">flashnul X -L haiku.img</pre>
|
||||
|
||||
<p>And your shell should output:</p>
|
||||
|
||||
<pre>Disk PhysicalDrive1 (UNC name: \\.\PhysicalDrive1)
|
||||
------------------------------------------------------------[Drive geometry]--
|
||||
Cylinders/heads/sectors = 121/255/63
|
||||
Bytes per sector = 512
|
||||
CHS size = 995258880 (949 Mb)
|
||||
---------------------------------------------------------------[Device size]--
|
||||
Device size = 1000341504 (954 Mb)
|
||||
delta to near power of 2 = 73400320 (70 Mb), 7%
|
||||
Surplus size = 5082624 (4963 kb)
|
||||
|
||||
-----------------------------------------------[Adapter & Device properties]--
|
||||
Bus type = (7) USB
|
||||
Removable device = Yes
|
||||
Command Queue = Unsupported
|
||||
Device vendor = Kingston
|
||||
Device name = DataTraveler 2.0
|
||||
Revision = PMAP
|
||||
--------------------------------------------------------------[Hotplug info]--
|
||||
|
||||
Device hotplug = Yes
|
||||
Media hotplug = No
|
||||
Selected operation: load file content
|
||||
Selected drive: PhysicalDrive1, 1000341504b (954 Mb)
|
||||
THIS OPERATION IS DESTRUCTIVE!!!
|
||||
Type 'yes' to confirm operation. All other text will stop it.
|
||||
Really destroy data on drive PhysicalDrive1? :<b>yes</b>
|
||||
|
||||
-----------------------------------------------------------------------[Log]--
|
||||
Running operation [load file content] for drive PhysicalDrive1
|
||||
Writing 0xf9f0000 (250 Mb), 899733 b/s
|
||||
image load finished
|
||||
----------------------------------------------------------[Operation result]--
|
||||
passes: 1
|
||||
errors: 0
|
||||
write bytes: 262144000 (250 Mb)
|
||||
avg. write speed: 899731 (878 kb/s)
|
||||
max/min write speed: 0 (0 b/s) / 0 (0 b/s)
|
||||
Press ENTER to exit.</pre><br />
|
||||
|
||||
<p>Congratualtions! You have just installed Haiku to a USB memory stick. You can now restart your computer to boot from Haiku. Note that you will probably have to enable USB drive booting in your BIOS and change the hard drive boot priority order. If Haiku's splash screen stops in the middle of the icons, and then sends you to <i>Kernel Debug Land</i>, you might have to disable the option <i>Plug and Play OS</i> in your BIOS.</p>
|
||||
<br />
|
||||
|
||||
</div>
|
||||
|
||||
<div class="bottomnav">
|
||||
<p>
|
||||
<a href="contents.html">Contents</a>
|
||||
   
|
||||
Previous: <a href="installation.html">Installation Basics</a>
|
||||
   
|
||||
Next: <a href="installation-vm.html">Emulating Haiku</a>
|
||||
|
||||
</p>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
170
userguide/en/installation/install-vm.html
Normal file
170
userguide/en/installation/install-vm.html
Normal file
@ -0,0 +1,170 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
||||
"../html-dtd/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xml:lang="en-US">
|
||||
<head>
|
||||
<!--
|
||||
*
|
||||
* Copyright 2009, Haiku. All rights reserved.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*
|
||||
* Authors:
|
||||
* Socapex_2K <philippe_groarke@yahoo.ca>
|
||||
*
|
||||
-->
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||
<meta http-equiv="Content-Style-Type" content="text/css" />
|
||||
<meta name="robots" content="all" />
|
||||
<title>Haiku in a virtual machine</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../../Haiku-doc.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="logo">
|
||||
<img src="../../images/logo.png" alt="logo" width="372" height="86" />
|
||||
<div class="title">Haiku in a virtual machine</div>
|
||||
</div>
|
||||
<div class="topnav">
|
||||
<p>
|
||||
<a href="../contents.html">Contents</a>
|
||||
   
|
||||
Back to <a href="../installation.html">Installing Haiku</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
|
||||
<!--
|
||||
|
||||
TODO:
|
||||
|
||||
- Different sections for main vm software:
|
||||
|
||||
<ul><li><a href="#vmware">VMWare</a></li>
|
||||
<li><a href="#vbox">VirtualBox</a></li>
|
||||
<li><a href="#parallel">Parallel Desktops</a></li>
|
||||
<li><a href="#qemu">Qemu</a></li></ul>
|
||||
|
||||
- Complete the list of vm software (OSes and free, commercial info)
|
||||
-->
|
||||
|
||||
<p>Computer emulation is a very handy tool, not only for users, but also for developers. Obviously running Haiku under native hardware is preferred (due to better performance), but this is not always an option. Manufacturers are often reluctant to release hardware specifications towards developers, and they are therefore often left to the difficult task of writing hardware drivers from scratch - it is a plague and barrier for smaller operating systems. Since Haiku can not possibly support all the hardware available, the release of Haiku disk images that are compatible with leading industry emulators is a logical choice. Also, users may not be confident in natively installing pre-alpha software onto their computers, leaving emulators as a 'safe' and attractive option to test out Haiku.</p>
|
||||
|
||||
<p>Emulators attach to your hardware and usually emulate more common hardware on top. Because the hardware is now the same, and is fixed and consistent, development under emulation can also be consistent - bugs can be easily replicated as well, eliminating suspect hardware. A couple of Haiku developers develop under emulators occasionally and realize their importance towards the development of Haiku.</p>
|
||||
|
||||
<p>Haiku runs very well under several of the major emulators such as Vmware, Virtual Box, and Qemu (has also been shown to run under Parallels and Virtual PC). Most emulators are cross-platform, and can be downloaded from the following locations:</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="http://www.vmware.com/products/player/">Vmware Player</a> (Free but limited in function; Windows and Linux)</li>
|
||||
<li><a href="http://www.vmware.com/products/server/">Vmware Server</a> (Free with registration; Windows and Linux)</li>
|
||||
<li><a href="http://www.vmware.com/products/ws/">Vmware Personal Work Station</a> (Commercial; Windows and Linux)</li>
|
||||
<li><a href="http://www.vmware.com/products/fusion/">Vmware Fusion</a> (Commercial; Mac OS X)</li>
|
||||
<li><a href="http://www.davereyn.co.uk/download.htm">Qemu</a> (Free; Windows)</li>
|
||||
<li><a href="http://www.kju-app.org/">Q</a> (Free; OS X)</li>
|
||||
<li><a href="http://www.virtualbox.org/">Virtual Box</a> (Free; Windows, Mac OS X, Linux and Solaris)</li>
|
||||
<li><a href="http://www.parallels.com/">Parallels</a> (Commerical; Mac OS X)</li>
|
||||
<li><a href="http://www.microsoft.com/windows/products/winfamily/virtualpc/default.mspx">Virtual PC for Windows</a>, <a href="http://www.microsoft.com/mac/">Virtual PC for Mac</a> (Free)</li>
|
||||
</ul>
|
||||
|
||||
<p>Of all the emulation options, Vmware, Virtual Box, and Qemu are well supported without the need for format conversion or tinkering (should work 'out of the box'). Haiku under Vmware is the fastest emulation option (on a subjective basis), and has driver support for networking, audio, and video. Virtual Box has Vmware disk compatibility yet the audio isn't yet supported.</p>
|
||||
|
||||
|
||||
<table style="text-align: left; width: 750px;" border="0" cellpadding="2" cellspacing="2">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td align="left" valign="top"><a href="../../images/installation-images/haiku-vmware.jpg"><img style="border: 1px solid ; width: 250px; height: 219px;" alt="" src="../../images/installation-images/haiku-vmware.jpg" /></a><br />
|
||||
<br />
|
||||
<span style="font-style: italic;">Haiku under Vmware</span></td>
|
||||
<td align="left" valign="top"><a href="../../images/installation-images/haiku-virtualbox.jpg"><img style="border: 1px solid ; width: 250px; height: 219px;" alt="" src="../../images/installation-images/haiku-virtualbox.jpg" /></a><br />
|
||||
<br />
|
||||
<span style="font-style: italic;">Haiku under Virtual Box</span></td>
|
||||
<td align="left" valign="top"><a href="../../images/installation-images/haiku-qemu.jpg"><img style="border: 1px solid ; width: 250px; height: 219px;" alt="" src="../../images/installation-images/haiku-qemu.jpg" /></a><br />
|
||||
<br />
|
||||
<span style="font-style: italic;">Haiku und Q (Qemu)</span></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
|
||||
<br />
|
||||
<p>Haiku's disk images are usually built on a daily basis, and can be downloaded here:</p>
|
||||
<ul>
|
||||
<li><a href="http://haiku-files.org/raw">Raw</a> (Qemu compatible) </li>
|
||||
<li><a href="http://haiku-files.org/vm">Vmware</a> (Virtual Box compatible)</li>
|
||||
</ul>
|
||||
|
||||
<h1>Using disk images</h1>
|
||||
|
||||
<h2>VMWare:</h2>
|
||||
<p>To use Haiku under Vmware, simply unzip the archive and execute the included <tt>*.vmx</tt> file.</p>
|
||||
|
||||
<h2>VirtualBox:</h2>
|
||||
<p><b>Note:</b> <i>Use the latest version of VirtualBox for the best compatibility, but emulating Haiku in VirtualBox isn't totally supported. Some settings will require you have a specific processor to work. If it isn't the case, you will either have to wait for upgrades (from Haiku and/or VirtualBox) or get a free version of VMWare.</i></p>
|
||||
|
||||
<p>To use the VMWare disk image under Virtual Box, create a virtual machine (click <i>New</i>) and press next. First name your image (ex. Haiku r28888). Under the <i>Operating System</i> tab, select "other", and for the <i>Version</i> tab, select "other" again. Next, you will have to chose the amount of RAM you wish to allocate to Haiku (512 MB through 1 GB should be enough). Remember your host OS will be deprived from this amount of memory.<br />
|
||||
Now in the <i>Virtual Hard Disk</i> section, enable <i>Boot Hard Disk (Primary Master)</i>, then click <i>Existing...</i>, click <i>Add</i>, navigate to your VMWare (.vmdk) image and click <i>Open</i>. Select it in the list, and click <i>Select</i>. Now your done creating your Virtual Machine, but you will have to tweak some settings.</p>
|
||||
|
||||
<p>With your new virtual machine selected, click on <i>Settings</i>. Here you can tweak your VM to your likings. Haiku will not boot if the "VT-x/AMD-V" option isn't on. Go to <i>General > Advanced > Enable VT-x/AMD-V</i> and activate the option. Your processor might not support this option, if so, your out of luck for VirtualBox emulation.</p>
|
||||
|
||||
<p>In order to get networking running under Haiku in Virtual Box, under the <i>Network > Adapter 1</i> tab, change the adapter type to "Intel Pro/1000 MT (82540OEM)". You can use either "NAT" or "Host Interface" under the <i>attached to</i> option. If you choose "Host Interface", you'll then have to select your desired network card in the bottom window ("Host Interfaces")</p>
|
||||
|
||||
<p>Sound doesn't work when emulating Haiku in VirtualBox, so you might as well disable it. I haven't tested the USB ports, but it should work. For more information on the various options you have, refer to (the very complete) VirtualBox User Manual.</p>
|
||||
|
||||
<h2>Parallels Desktop:</h2>
|
||||
<p><b>Note:</b> <i>These instructions have been posted in the forums, they are not guaranteed to work, and some issues might arise (like networking). Visit the forums for more information.</i></p>
|
||||
<ul>
|
||||
<li><p>Download a nightly build from the Haiku Build Factory and extract the tar.bz2 file.</p></li>
|
||||
<li><p>Move the extracted <tt>haiku.image</tt> file to the desired directory. Open terminal and navigate to that directory. Type:</p>
|
||||
<pre class="terminal">dd if=/dev/zero of=haiku.image bs=1024 count=1 conv=notrunc seek=408600</pre></li>
|
||||
<li><p>Rename the <tt>haiku.image</tt> file to <tt>haiku.hdd</tt>.</p></li>
|
||||
<li><p>Use ImageTool to resize the haiku.hdd file to 120MB.</p></li>
|
||||
<li><p>Create a new virtual machine in Parallels, with <i>Guest OS Type</i> as Windows.</p></li>
|
||||
<li><p>Set the <i>Hard Drive</i> to the <tt>haiku.hdd</tt> file that you downloaded.</p></li>
|
||||
</ul>
|
||||
|
||||
<h2>Qemu:</h2>
|
||||
<p>For Qemu, rename the raw disk image to <tt>haiku.img</tt> and manually configure a virtual machine using that disk image.</p>
|
||||
|
||||
<h1>Increasing disk image space - Creating and formatting disks</h1>
|
||||
<p>The disk images provided come as 250MB fixed disk images. The disk image's size can't be increased, but one can easily create a new disk with an increased capacity. Under the emulators GUI and virtual machine's settings, you should find an option to add another hard disk.<br />
|
||||
Choose which type of disk you would like to create. There are two options:</p>
|
||||
<ul>
|
||||
<li><p>Fixed disk: This means the disk's space will be pre-allocated, i.e if you choose to create a 10GB fixed disk, the disk image will occupy 10GB of data on your hard drive.</p></li>
|
||||
<li><p>Expanding disk: If you choose to create a 10GB disk image, the disk will appear as it's 10GB under Haiku, but will only actually be as big as the space that's used within Haiku (it grows).</p></li>
|
||||
</ul>
|
||||
<p>Once you've created the disk image to a size of your choice, add the secondary disk to your virtual machine and boot Haiku. The disk won't show up until you have formatted it. Navigate to Haiku's <i>DiskSetup</i> application - the disk should be shown (see a 1GB disk added in the screenshot below).</p>
|
||||
<br />
|
||||
<a href="../../images/installation-images/haiku.jpg"><img style="border: 0px solid ; width: 200px; height: 175px;" alt="" src="../../images/installation-images/haiku.jpg" /></a><br />
|
||||
<br />
|
||||
<p>Select the disk, and then select <i>Partition | Initialize | Be File System</i>. Select the default variables, and accept the alert messages. Return to the menu and select <i>Partition Mount</i> - another Haiku disk should now be on your desktop (without the leaf logo). Now simply open a Tracker window on the boot disk, and a Tracker window on your newly created disk and copy the contents over (over-writing the <tt>home</tt> folder on the new disk).</p>
|
||||
|
||||
<p>One final step: Open a Terminal and type:</p>
|
||||
<pre class ="terminal">df</pre>
|
||||
<p>to see the disk space size & usage on each disk. After selecting the correct disk (probably <tt>/Haiku1</tt>) type:</p>
|
||||
<pre class="terminal">makebootable Haiku1</pre>
|
||||
<p>You can now shutdown the Haiku virtual machine, remove the primary disk image (the Haiku disk image you downloaded) in your virtual machine's preferences, and make sure that the new disk you created is your primary disk now.</p>
|
||||
|
||||
<p><b>Tip:</b> In order to skip a couple steps, you can download <a href="http://www.haikuware.com/view-details/development/app-installation/formatted-bootable-vmware-images">pre-built bootable disk images</a>.</p>
|
||||
|
||||
<h1>Transferring files between your host computer and a Haiku virtual machine</h1>
|
||||
<p>There are several ways you can transfer files between the host and guest machines on your computer. Since there is no 'Vmware tools installer' for Haiku, file-sharing between the host and guest isn't built-in, and there's no clipboard sharing. Here are a couple of ways you could share files.</p>
|
||||
<ul>
|
||||
<li><p><b><i>Transfer files using a disk image</i></b>: create a disk image with the files you'd like to transfer from your PC to Haiku. In Windows use a utility like <i>Burn At Once</i>, in OS X you could use the the hard drisk utility to make an ISO i.e create a folder called 'test' on your desktop, put the files you want into that folder and execute the command:</p>
|
||||
<pre class="terminal">hdiutil makehybrid -o /Users/myusername/Desktop/test.iso /Users/myusername/Desktop/test -iso -joliet'</pre>
|
||||
<p>(replacing "myusername" with your username). Attach the resultant ISO images in place of your optical disk in your virtual machine preferences.</p></li>
|
||||
<li><p><b><i>Transfer files over the internet</i></b>: upload files to an online server you have, and then download them internally through Haiku. Note, Haiku doesn't yet have a web browser included, however, you can use <tt>wget</tt>.</p></li>
|
||||
<li><p><b><i>Transfer files between the host and machine</i></b>: First you'll need to setup a FTP server on your host machine. OS X users can easily do this under their sharing preferences tab. As suggested, you can use <tt>wget</tt> to download files from your host machine. You could use <a href="http://www.haikuware.com/view-details/internet-&-network/ftp/wput">wput</a> to upload files to your host machine, alternatively, you could use a grahphical client like <a href="http://www.haikuware.com/view-details/internet-&-network/ftp/netpenguin">NetPenguin</a>.</p></li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="bottomnav">
|
||||
<p>
|
||||
<a href="../contents.html">Contents</a>
|
||||
   
|
||||
Back to <a href="../installation.html">Installing Haiku</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
BIN
userguide/images/installation-images/haiku-qemu.jpg
Normal file
BIN
userguide/images/installation-images/haiku-qemu.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 49 KiB |
BIN
userguide/images/installation-images/haiku-virtualbox.jpg
Normal file
BIN
userguide/images/installation-images/haiku-virtualbox.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 52 KiB |
BIN
userguide/images/installation-images/haiku-vmware.jpg
Normal file
BIN
userguide/images/installation-images/haiku-vmware.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 63 KiB |
BIN
userguide/images/installation-images/haiku.jpg
Normal file
BIN
userguide/images/installation-images/haiku.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 90 KiB |
BIN
userguide/images/installation-images/haiku_big.jpg
Normal file
BIN
userguide/images/installation-images/haiku_big.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 90 KiB |
BIN
userguide/images/installation-images/macosx.png
Normal file
BIN
userguide/images/installation-images/macosx.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 18 KiB |
Loading…
Reference in New Issue
Block a user