Difference between revisions of "EBC Exercise 25 Configuring U-boot"

From eLinux.org
Jump to: navigation, search
m (Compiling U-boot: Updated for 2011)
m (Updated for Winter 2011-2012)
Line 2: Line 2:
 
[[Category:BeagleBoard]]
 
[[Category:BeagleBoard]]
  
This follows the approach taken in [[ECE597 Configuring the Kernel]].  We'll use '''bitbake''' to get the source files for U-boot and then we'll edit them.
+
This follows the approach taken in [[EBC Exercise 13 Configuring the Kernel]].  We'll use '''bitbake''' to get the source files for U-boot and then we'll edit them.
  
 
== bitbake ==
 
== bitbake ==
  
When you did [[ECE497 Lab02 Installing The Angstrom Distribution]] u-boot was downloaded and compiled.  If you used the default configure, the source code was removed once it was done.  Check and see:
+
When you did [[EBC Exercise 12 Cross-Compiling and Finding the Right Kernel]] u-boot was downloaded and compiled.  If you used the default configure, the source code was removed once it was done.  Check and see:
<pre>
+
 
$ cd ~/BeagleBoard/oe/build/tmp-angstrom_2008_1/work/beagleboard-angstrom-linux-gnueabi/
+
host$ '''cd ~/BeagleBoard/oe/build/tmp-angstrom_2010_x-eglibc/work/beagleboard-angstrom-linux-gnueabi'''
$ ls
+
host$ '''ls'''
</pre>
+
 
 
You should see a directory starting with <code>u-boot-</code>.  The rest of the name tells what version you have.  Change to that directory and see what's there:
 
You should see a directory starting with <code>u-boot-</code>.  The rest of the name tells what version you have.  Change to that directory and see what's there:
<pre>
+
 
$ cd u-boot-*
+
host$ '''cd u-boot-*'''
$ ls
+
host$ '''ls'''
</pre>
+
 
If you see a '''git''' directory, you are in luck. If you see just a '''temp''' directory you need to go back to [[ECE497 Lab02 Installing The Angstrom Distribution]] and get it installed.
+
If you see a '''git''' directory, you are in luck. If you see just a '''temp''' directory you need to go back to [[EBC Exercise 12 Cross-Compiling and Finding the Right Kernel]] and get it installed.
  
 
Once you have the '''git''' directory, ''cd'' to it and look around.
 
Once you have the '''git''' directory, ''cd'' to it and look around.
Line 23: Line 23:
  
 
You can now compile U-boot.  
 
You can now compile U-boot.  
</pre>
 
Save the file and enter:
 
<pre>
 
$ cd ~/BeagleBoard/oe/build/tmp-angstrom_2008_1/work/beagleboard-angstrom-linux-gnueabi/u-boot-*/git
 
$ source ~/BeagleBoard/oe/crossCompileEnv.sh
 
$ make
 
</pre>
 
  
'''Assignment:'''  Modify u-boot to include your initials in the prompt.  
+
host$ '''source ~/.oe/crossCompileEnv.sh'''
 +
  host$ '''make'''
 +
 
 +
== Assignment==
 +
 
 +
Modify u-boot to include your initials in the prompt.  
  
 
Hint:  Look for the omap3_beagle.h file.
 
Hint:  Look for the omap3_beagle.h file.

Revision as of 16:50, 2 January 2012


This follows the approach taken in EBC Exercise 13 Configuring the Kernel. We'll use bitbake to get the source files for U-boot and then we'll edit them.

bitbake

When you did EBC Exercise 12 Cross-Compiling and Finding the Right Kernel u-boot was downloaded and compiled. If you used the default configure, the source code was removed once it was done. Check and see:

host$ cd ~/BeagleBoard/oe/build/tmp-angstrom_2010_x-eglibc/work/beagleboard-angstrom-linux-gnueabi
host$ ls

You should see a directory starting with u-boot-. The rest of the name tells what version you have. Change to that directory and see what's there:

host$ cd u-boot-*
host$ ls

If you see a git directory, you are in luck. If you see just a temp directory you need to go back to EBC Exercise 12 Cross-Compiling and Finding the Right Kernel and get it installed.

Once you have the git directory, cd to it and look around.

Compiling U-boot

You can now compile U-boot.

host$ source ~/.oe/crossCompileEnv.sh
host$ make

Assignment

Modify u-boot to include your initials in the prompt.

Hint: Look for the omap3_beagle.h file.