Changes

Jump to navigation Jump to search
2,026 bytes added ,  00:35, 17 May 2016
no edit summary
Line 1: Line 1:  
<noinclude>{{TeamHeader|Dextrose|home=Dextrose|xbgColor=ffe792|join_label=Get Involved}}</noinclude>
 
<noinclude>{{TeamHeader|Dextrose|home=Dextrose|xbgColor=ffe792|join_label=Get Involved}}</noinclude>
 +
 +
{{Obsolete|Moved and died at https://sugardextrose.org/projects/dextrose/wiki/Build_system_set-up}}
    
== Dextrose build system ==
 
== Dextrose build system ==
Line 7: Line 9:  
== Build host requirements ==
 
== Build host requirements ==
   −
The Dextrose build system is known to work on '''Fedora 14 x86_64'''. The OS on the host system ''shouldn't'' matter because the build runs in a chroot environment. olpc-os-builder does not yet run on Ubuntu due to a missing dependency (bitfrost).
+
The Dextrose build system is known to work on '''Fedora 14 x86_64''' and '''Fedora 16 x86_64'''. The OS on the host system ''shouldn't'' matter because the build runs in a chroot environment. olpc-os-builder does not yet run on Ubuntu due to a missing dependency (bitfrost).
    
The initial build requires about '''700MB''' of rpm packages and Sugar activity bundles. The packages and bundles are cached for futures builds.
 
The initial build requires about '''700MB''' of rpm packages and Sugar activity bundles. The packages and bundles are cached for futures builds.
    
== Initial setup ==
 
== Initial setup ==
 +
 +
* If sudo isn't configured to work with your account, add yourself to the '''wheel''' group. Alternatively, you can become root with <code>su -</code>.
    
* Install build dependencies (you need to be root to do this)
 
* Install build dependencies (you need to be root to do this)
    
   yum upgrade
 
   yum upgrade
   yum install libtomcrypt-devel bitfrost make gcc mtd-utils python-imgcreate zip unzip zlib-devel lzma
+
   yum install libtomcrypt-devel bitfrost crcimg make gcc mtd-utils python-imgcreate zip unzip zlib-devel lzma netpbm-progs git wget
   −
* Checkout the Dextrose build system
+
* Install the olpc-bootanim-tools package:
   −
   git clone git://git.sugarlabs.org/dextrose/mainline.git dextrose -b dextrose-3-20110919
+
   rpm -i http://download.sugarlabs.org/dextrose/testing/dx3/rpms/x86_64/os/olpc-bootanim-tools-2.14-1.bernie1.fc16.x86_64.rpm
 
  −
* Compile build helper programs
  −
 
  −
  cd dextrose
  −
  make
     −
* Install the olpc-bootanim-tools package:
+
If you have a 32bit machine:
   −
   rpm -i http://download.sugarlabs.org/dextrose/testing/dx3/rpms/x86_64/os/olpc-bootanim-tools-2.14-1.bernie1.fc16.x86_64.rpm
+
   rpm -i http://download.sugarlabs.org/dextrose/testing/dx3/rpms/i386/os/olpc-bootanim-tools-2.14-1.bernie1.fc16.i686.rpm
   −
* Alternatively, rebuild olpc-bootanim from source:
+
Alternatively, you could rebuild the olpc-bootanim package from source:
    +
  yum install rpm-build netpbm-progs
 
   wget http://download.sugarlabs.org/dextrose/testing/dx3/rpms/source/olpc-bootanim-2.14-1.bernie1.fc16.src.rpm
 
   wget http://download.sugarlabs.org/dextrose/testing/dx3/rpms/source/olpc-bootanim-2.14-1.bernie1.fc16.src.rpm
 
   rpmbuild --rebuild olpc-bootanim-2.14-1.bernie1.fc16.src.rpm
 
   rpmbuild --rebuild olpc-bootanim-2.14-1.bernie1.fc16.src.rpm
 
   rpm -U ~/rpmbuild/RPMS/*/olpc-bootanim-tools-*.rpm
 
   rpm -U ~/rpmbuild/RPMS/*/olpc-bootanim-tools-*.rpm
 +
 +
* Checkout the Dextrose build system
 +
 +
  git clone git://git.sugarlabs.org/dextrose/mainline.git dextrose
 +
 +
* Compile build helper programs
 +
 +
  cd dextrose
 +
  make
    
* Generate initial sequence number for the builds (42 is just an example)
 
* Generate initial sequence number for the builds (42 is just an example)
Line 45: Line 54:  
* Become root and run the build system:
 
* Become root and run the build system:
   −
   sudo -i
+
   time sudo ./osbuilder.py config/dextrose3-xo1-nognome.ini
  time ./osbuilder.py config/dextrose3-xo1-nognome.ini
+
 
 +
The initial build may take several hours, depending on available bandwidth.
 +
Subsequent builds will take about 15-20 minutes on average desktop machines.
 +
 
 +
Upon completion, the new image will be available in <tt>build/output</tt>.
 +
Now copy it on a USB stick and test it on your target.
 +
 
 +
=== Available variants ===
 +
 
 +
There's a set of configuration files for each variant of the images you can build. You only need to specify the top-level file (i.e. none of the <code>*-common.ini</code> files) to build an image:
   −
The initial build may take several hours, depending on available bandwith.
+
;dextrose3-xo1-gnome.ini:
Subsequent builds will take about 15-20 minutes on average machines.
+
:Works on [[olpc:XO-1|XO-1]], includes Gnome. Not recommended unless you're running from an external SD card as the free space available on the internal NAND is too limited with Gnome installed.
 +
;dextrose3-xo1-nognome.ini:
 +
:Works on [[olpc:XO-1|XO-1]], does not include Gnome. This is the recommended image for XO-1s.
 +
;dextrose3-xo1.5-gnome.ini:
 +
:Works on [[olpc:XO-1.5|XO-1.5]] (including XO-1.5 [[olpc:OLPC_English_Non-membrane_Keyboard|HS]]), includes Gnome. Some teachers and older students seem to like Gnome, so you can trade off some of the free space that could be used by the Journal for the additional desktop environment.
 +
;dextrose3-xo1.5-nognome.ini:
 +
:Works on [[olpc:XO-1.5|XO-1.5]] (including XO-1.5 [[olpc:OLPC_English_Non-membrane_Keyboard|HS]]), doesn't include Gnome. More space for the Journal, so use this one if your users don't ask for Gnome and you haven't paid for a larger (i.e. > 4GB) SD card.
 +
;dextrose3-xo1.75-gnome.ini:
 +
:Experimental [[olpc:XO-1.75|XO-1.75]] image with Gnome.
 +
;dextrose3-xo1.75-nognome.ini:
 +
:Experimental [[olpc:XO-1.75|XO-1.75]] image without Gnome.
   −
Upon completion the new image will be available in <tt>build/output</tt>.
+
== Debugging ==
    
Because several build tools (olpc-os-builder, imgcreate and yum) run chrooted
 
Because several build tools (olpc-os-builder, imgcreate and yum) run chrooted
and nested into each other, error output could be misleading or obscure.
+
and nested into each other, error output is often obscure or misleading.
Before digging into code, you can ask on IRC in case someone has already seen the same problem.
+
Before digging into the code, try asking on IRC in case someone has already seen
 +
the same problem.
    
== Publishing the images ==
 
== Publishing the images ==
Line 70: Line 99:  
=== Upstream Code ===
 
=== Upstream Code ===
   −
Dextrose is based on upstream olpc code located at dev.laptop.org.
+
Dextrose is based on [http://dev.laptop.org/git/projects/olpc-os-builder/ olpc-os-builder] by Daniel Drake. You can fetch the latest source code into your Dextrose repository:
    
  git remote add olpc git://dev.laptop.org/projects/olpc-os-builder
 
  git remote add olpc git://dev.laptop.org/projects/olpc-os-builder
Line 109: Line 138:  
== Resources ==
 
== Resources ==
   −
* [[Machine/treehouse/dextrose|Dextrose VM]] hosted by [[Machine/treehouse|treehouse]]
+
* [[Machine/dextrose|Dextrose VM]] hosted by [[Machine/treehouse|treehouse]]
    
* [[Development_Team/Jhbuild|Sugar-jhbuild]] - The Sugar build system
 
* [[Development_Team/Jhbuild|Sugar-jhbuild]] - The Sugar build system

Navigation menu