summaryrefslogtreecommitdiffstats
path: root/bitbake/doc/bitbake-user-manual/bitbake-user-manual-hello.xml
blob: 95a6804a196984c6a2567653b7923d16b860d337 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
"http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">

<appendix id='hello-world-example'>
    <title>Hello World Example</title>

    <section id='bitbake-hello-world'>
        <title>BitBake Hello World</title>

        <para>
            The simplest example commonly used to demonstrate any new
            programming language or tool is the
            "<ulink url="http://en.wikipedia.org/wiki/Hello_world_program">Hello World</ulink>"
            example.
            This appendix demonstrates, in tutorial form, Hello
            World within the context of BitBake.
            The tutorial describes how to create a new Project
            and the applicable metadata files necessary to allow
            BitBake to build it.
        </para>
    </section>

    <section id='example-obtaining-bitbake'>
        <title>Obtaining BitBake</title>

        <para>
            See the
            "<link linkend='obtaining-bitbake'>Obtaining BitBake</link>"
            section for information on how to obtain BitBake.
            Once you have the source code on your machine, the BitBake directory
            appears as follows:
            <literallayout class='monospaced'>
     $ ls -al
     total 100
     drwxrwxr-x. 9 wmat wmat  4096 Jan 31 13:44 .
     drwxrwxr-x. 3 wmat wmat  4096 Feb  4 10:45 ..
     -rw-rw-r--. 1 wmat wmat   365 Nov 26 04:55 AUTHORS
     drwxrwxr-x. 2 wmat wmat  4096 Nov 26 04:55 bin
     drwxrwxr-x. 4 wmat wmat  4096 Jan 31 13:44 build
     -rw-rw-r--. 1 wmat wmat 16501 Nov 26 04:55 ChangeLog
     drwxrwxr-x. 2 wmat wmat  4096 Nov 26 04:55 classes
     drwxrwxr-x. 2 wmat wmat  4096 Nov 26 04:55 conf
     drwxrwxr-x. 3 wmat wmat  4096 Nov 26 04:55 contrib
     -rw-rw-r--. 1 wmat wmat 17987 Nov 26 04:55 COPYING
     drwxrwxr-x. 3 wmat wmat  4096 Nov 26 04:55 doc
     -rw-rw-r--. 1 wmat wmat    69 Nov 26 04:55 .gitignore
     -rw-rw-r--. 1 wmat wmat   849 Nov 26 04:55 HEADER
     drwxrwxr-x. 5 wmat wmat  4096 Jan 31 13:44 lib
     -rw-rw-r--. 1 wmat wmat   195 Nov 26 04:55 MANIFEST.in
     -rwxrwxr-x. 1 wmat wmat  3195 Jan 31 11:57 setup.py
     -rw-rw-r--. 1 wmat wmat  2887 Nov 26 04:55 TODO
            </literallayout>
        </para>

        <para>
            At this point, you should have BitBake cloned to
            a directory that matches the previous listing except for
            dates and user names.
        </para>
    </section>

    <section id='setting-up-the-bitbake-environment'>
        <title>Setting Up the BitBake Environment</title>

        <para>
            First, you need to be sure that you can run BitBake.
            Set your working directory to where your local BitBake
            files are and run the following command:
            <literallayout class='monospaced'>
     $ ./bin/bitbake --version
     BitBake Build Tool Core version 1.23.0, bitbake version 1.23.0
            </literallayout>
            The console output tells you what version you are running.
        </para>

        <para>
            The recommended method to run BitBake is from a directory of your
            choice.
            To be able to run BitBake from any directory, you need to add the
            executable binary to your binary to your shell's environment
            <filename>PATH</filename> variable.
            First, look at your current <filename>PATH</filename> variable
            by entering the following:
            <literallayout class='monospaced'>
     $ echo $PATH
            </literallayout>
            Next, add the directory location for the BitBake binary to the
            <filename>PATH</filename>.
            Here is an example that adds the
            <filename>/home/scott-lenovo/bitbake/bin</filename> directory
            to the front of the <filename>PATH</filename> variable:
            <literallayout class='monospaced'>
     $ export PATH=/home/scott-lenovo/bitbake/bin:$PATH
            </literallayout>
            You should now be able to enter the <filename>bitbake</filename>
            command from the command line while working from any directory.
        </para>

        <para>
            For a more permanent solution, assuming you are running the BASH
            shell, edit <filename>~/.bashrc</filename> and add the following to the end
            of that file:
            <literallayout class='monospaced'>
     PATH=&lt;path-to-bitbake-executable&gt;:$PATH
            </literallayout>
        </para>

        <para>
            If you're a Vim user, you will find useful
            Vim configuration contributions in the
            <filename>contrib/vim</filename> directory.
            Copy the files from that directory to your
            <filename>/home/yourusername/.vim</filename>
            directory.
            If that directory does not exist, create it, and then
            restart Vim.
        </para>
    </section>

    <section id='the-hello-world-example'>
        <title>The Hello World Example</title>

        <para>
            The following example leaps directly into how BitBake
            works.
            While every attempt is made to explain what is happening,
            not everything can be covered.
            You can find further information in the
            "<link linkend='bitbake-user-manual-metadata'>Syntax and Operators</link>"
            chapter.
        </para>

        <para>
            The overall goal of this exercise is to build a
            complete "Hello World" example utilizing task and layer
            concepts.
            Because this is how modern projects such as OpenEmbedded and
            the Yocto Project utilize BitBake, the example
            provides an excellent starting point for understanding
            BitBake.
        </para>

        <para>
            It should be noted that this chapter was inspired by
            and draws heavily from several sources:
            <itemizedlist>
                <listitem><para>
                    <ulink url="http://www.mail-archive.com/yocto@yoctoproject.org/msg09379.html">Mailing List post - The BitBake equivalent of "Hello, World!"</ulink>
                    </para></listitem>
                <listitem><para>
                    <ulink url="http://hambedded.org/blog/2012/11/24/from-bitbake-hello-world-to-an-image/">Hambedded Linux blog post - From Bitbake Hello World to an Image</ulink>
                    </para></listitem>
            </itemizedlist>
        </para>

        <section id='a-reverse-walk-through'>
            <title>A Reverse Walk-Through</title>

            <para>
                A good way to understand anything is to walk through the steps
                that take you to where you want to be and observe first
                principles.
                BitBake allows us to do this through the
                <filename>-D</filename> or <filename>Debug</filename>
                command-line parameter.
            </para>

            <para>
                The goal is to eventually compile a "Hello World" example.
                However, it is unknown what is needed to achieve that goal.
                Recall that BitBake utilizes three types of metadata files:
                <link linkend='configuration-files'>Configuration Files</link>,
                <link linkend='classes'>Classes</link>, and
                <link linkend='recipes'>Recipes</link>.
                But where do they go?
                How does BitBake find them?
                BitBake's error messaging helps you answer these types of questions
                and helps you better understand exactly what is going on.
            </para>

            <para>
                First, set up a directory for the "Hello World" project.
                Here is how you can do so in your home directory:
                <literallayout class='monospaced'>
     $ mkdir ~/hello
     $ cd ~/hello
                </literallayout>
                Within this new, empty directory, run BitBake with
                debugging output and see what happens:
                <literallayout class='monospaced'>
     $ bitbake -DDD
     The BBPATH variable is not set and bitbake did not find
     a conf/bblayers.conf file in the expected location.
     Maybe you accidentally invoked bitbake from the wrong
     directory?
     DEBUG: Removed the following variables from the environment:
     GNOME_DESKTOP_SESSION_ID, XDG_CURRENT_DESKTOP,
     GNOME_KEYRING_CONTROL, DISPLAY, SSH_AGENT_PID, LANG,
     no_proxy, XDG_SESSION_PATH, XAUTHORITY, SESSION_MANAGER,
     SHLVL, MANDATORY_PATH, COMPIZ_CONFIG_PROFILE, WINDOWID,
     EDITOR, GPG_AGENT_INFO, SSH_AUTH_SOCK, GDMSESSION,
     DEFAULTS_PATH, XDG_SEAT_PATH, XDG_CONFIG_DIRS, LESSOPEN,
     DBUS_SESSION_BUS_ADDRESS, _, XDG_SESSION_COOKIE,
     DESKTOP_SESSION, LESSCLOSE, GNOME_KEYRING_PID,
     UBUNTU_MENUPROXY, OLDPWD, XDG_DATA_DIRS, COLORTERM,
     LS_COLORS
                </literallayout>
                The majority of this output is specific to environment variables
                that are not directly relevant to BitBake.
                However, the very first message regarding the
                <filename>BBPATH</filename> variable and the
                <filename>conf/bblayers.conf</filename> file
                is relevant.
            </para>

            <para>
                <literallayout class='monospaced'>
1. Once you have PATH set up to actually run BB, and then you run it
   using:

   bitbake -DDD

   You get these complaints:

The BBPATH variable is not set and bitbake did not find a conf/bblayers.conf file in the expected location.
Maybe you accidentally invoked bitbake from the wrong directory?

2. If you export BBPATH to point to your build directory and do nothing
   else, BB will look for the &lt;buildir&gt;/conf/bitbake.conf file. It will
   throw and error with a bunch of traceback stuff and say:

scott-lenovo@scott-lenovo:~ [master #]
$ mkdir junk
scott-lenovo@scott-lenovo:~ [master #]
$ BBPATH="/home/scott-lenovo/junk"
scott-lenovo@scott-lenovo:~ [master #]
$ export BBPATH
scott-lenovo@scott-lenovo:~ [master #]
$ bitbake -DDD
ERROR: Traceback (most recent call last):
  File "/home/scott-lenovo/bitbake/lib/bb/cookerdata.py", line 163, in wrapped
    return func(fn, *args)
  File "/home/scott-lenovo/bitbake/lib/bb/cookerdata.py", line 173, in parse_config_file
    return bb.parse.handle(fn, data, include)
  File "/home/scott-lenovo/bitbake/lib/bb/parse/__init__.py", line 99, in handle
    return h['handle'](fn, data, include)
  File "/home/scott-lenovo/bitbake/lib/bb/parse/parse_py/ConfHandler.py", line 120, in handle
    abs_fn = resolve_file(fn, data)
  File "/home/scott-lenovo/bitbake/lib/bb/parse/__init__.py", line 117, in resolve_file
    raise IOError("file %s not found in %s" % (fn, bbpath))
IOError: file conf/bitbake.conf not found in /home/scott-lenovo/junk

ERROR: Unable to parse conf/bitbake.conf: file conf/bitbake.conf not found in /home/scott-lenovo/junk
scott-lenovo@scott-lenovo:~ [master #]

3. Now I am going to create the conf/bitbake.conf file I need for the hello
   world example.  Then run it again.  Time it complains about not finding
   classes/base.bbclass.

scott-lenovo@scott-lenovo:~/junk [master #]
$ bitbake -DDD
ERROR: Traceback (most recent call last):
  File "/home/scott-lenovo/bitbake/lib/bb/cookerdata.py", line 163, in wrapped
    return func(fn, *args)
  File "/home/scott-lenovo/bitbake/lib/bb/cookerdata.py", line 177, in _inherit
    bb.parse.BBHandler.inherit(bbclass, "configuration INHERITs", 0, data)
  File "/home/scott-lenovo/bitbake/lib/bb/parse/parse_py/BBHandler.py", line 92, in inherit
    include(fn, file, lineno, d, "inherit")
  File "/home/scott-lenovo/bitbake/lib/bb/parse/parse_py/ConfHandler.py", line 100, in include
    raise ParseError("Could not %(error_out)s file %(fn)s" % vars(), oldfn, lineno)
ParseError: ParseError in configuration INHERITs: Could not inherit file classes/base.bbclass

ERROR: Unable to parse base: ParseError in configuration INHERITs: Could not inherit file classes/base.bbclass
scott-lenovo@scott-lenovo:~/junk [master #]

4. So now we add that classes/base.bbclass file and put in one line that says
   "addtask build", which is the minimum task you need.  We run it again and
   things work but there is nothing to do.  That stands to reason since I gave it
   no target.

scott-lenovo@scott-lenovo:~/junk [master #]
$ bitbake -DDD
Nothing to do.  Use 'bitbake world' to build everything, or run 'bitbake --help' for usage information.
DEBUG: Removed the following variables from the environment: GNOME_DESKTOP_SESSION_ID, XDG_CURRENT_DESKTOP, GNOME_KEYRING_CONTROL, DISPLAY, SSH_AGENT_PID, LANG, no_proxy, XDG_SESSION_PATH, XAUTHORITY, SESSION_MANAGER, SHLVL, MANDATORY_PATH, COMPIZ_CONFIG_PROFILE, WINDOWID, EDITOR, GPG_AGENT_INFO, SSH_AUTH_SOCK, GDMSESSION, GNOME_KEYRING_PID, XDG_SEAT_PATH, XDG_CONFIG_DIRS, LESSOPEN, DBUS_SESSION_BUS_ADDRESS, _, XDG_SESSION_COOKIE, DESKTOP_SESSION, LESSCLOSE, DEFAULTS_PATH, UBUNTU_MENUPROXY, OLDPWD, XDG_DATA_DIRS, COLORTERM, LS_COLORS
DEBUG: LOAD /home/scott-lenovo/junk/conf/bitbake.conf
DEBUG: BB configuration INHERITs:0: inheriting /home/scott-lenovo/junk/classes/base.bbclass
DEBUG: BB /home/scott-lenovo/junk/classes/base.bbclass: handle(data, include)
DEBUG: LOAD /home/scott-lenovo/junk/classes/base.bbclass
DEBUG: Clearing SRCREV cache due to cache policy of: clear
DEBUG: Using cache in '/home/scott-lenovo/junk/tmp/cache/local_file_checksum_cache.dat'
DEBUG: Using cache in '/home/scott-lenovo/junk/tmp/cache/bb_codeparser.dat'
DEBUG: Features set [3] (was [3])
scott-lenovo@scott-lenovo:~/junk [master #]

5. Here is what happens when you do provide a target but the target doesn't
   exist yet.

scott-lenovo@scott-lenovo:~/junk [master #]
$ bitbake a
ERROR: no recipe files to build, check your BBPATH and BBFILES?

Summary: There was 1 ERROR message shown, returning a non-zero exit code.
scott-lenovo@scott-lenovo:~/junk [master #]

6. Create a layer that has your metadata in it.  You need your recipe file
   and your layer.conf file.  That is all good but you still need to
   tell BB where your layers are.  You do that through a bblayers.conf file.
   We will use this one:

   BBLAYERS ?=" \
     /home/scott-lenovo/LayerA \
     "

   Now when you run it, you get this:

$ bitbake -DDD a
DEBUG: Removed the following variables from the environment: GNOME_DESKTOP_SESSION_ID, XDG_CURRENT_DESKTOP, GNOME_KEYRING_CONTROL, DISPLAY, SSH_AGENT_PID, LANG, no_proxy, XDG_SESSION_PATH, XAUTHORITY, SESSION_MANAGER, SHLVL, MANDATORY_PATH, COMPIZ_CONFIG_PROFILE, WINDOWID, EDITOR, GPG_AGENT_INFO, SSH_AUTH_SOCK, GDMSESSION, GNOME_KEYRING_PID, XDG_SEAT_PATH, XDG_CONFIG_DIRS, LESSOPEN, DBUS_SESSION_BUS_ADDRESS, _, XDG_SESSION_COOKIE, DESKTOP_SESSION, LESSCLOSE, DEFAULTS_PATH, UBUNTU_MENUPROXY, OLDPWD, XDG_DATA_DIRS, COLORTERM, LS_COLORS
DEBUG: Found bblayers.conf (/home/scott-lenovo/junk/conf/bblayers.conf)
DEBUG: LOAD /home/scott-lenovo/junk/conf/bblayers.conf
DEBUG: Adding layer /home/scott-lenovo/LayerA
DEBUG: LOAD /home/scott-lenovo/LayerA/conf/layer.conf
DEBUG: LOAD /home/scott-lenovo/junk/conf/bitbake.conf
DEBUG: BB configuration INHERITs:0: inheriting /home/scott-lenovo/junk/classes/base.bbclass
DEBUG: BB /home/scott-lenovo/junk/classes/base.bbclass: handle(data, include)
DEBUG: LOAD /home/scott-lenovo/junk/classes/base.bbclass
DEBUG: Clearing SRCREV cache due to cache policy of: clear
DEBUG: Using cache in '/home/scott-lenovo/junk/tmp/cache/local_file_checksum_cache.dat'
DEBUG: Using cache in '/home/scott-lenovo/junk/tmp/cache/bb_codeparser.dat'
DEBUG: Features set [3] (was [3])
DEBUG: Calculated priority of layer A as 1
DEBUG: collecting .bb files
DEBUG: Using cache in '/home/scott-lenovo/junk/tmp/cache'
DEBUG: Cache: /home/scott-lenovo/LayerA/a.bb is not cached
DEBUG: BB /home/scott-lenovo/LayerA/a.bb: handle(data)                                                           | ETA:  --:--:--
DEBUG: LOAD /home/scott-lenovo/LayerA/a.bb
Parsing recipes: 100% |##########################################################################################| Time: 00:00:00
Parsing of 1 .bb files complete (0 cached, 1 parsed). 1 targets, 0 skipped, 0 masked, 0 errors.
DEBUG: parsing complete
DEBUG: providers for a are: ['a']
DEBUG: sorted providers for a are: ['/home/scott-lenovo/LayerA/a.bb']
DEBUG: adding /home/scott-lenovo/LayerA/a.bb to satisfy a
DEBUG: Added dependencies [] for /home/scott-lenovo/LayerA/a.bb
NOTE: Resolving any missing task queue dependencies
DEBUG: Resolved 0 extra dependencies
NOTE: Preparing runqueue
NOTE: Marking Active Tasks
NOTE: Pruned 0 inactive tasks, 1 left
NOTE: Assign Weightings
NOTE: Compute totals (have 1 endpoint(s))
DEBUG: Starting bitbake-worker
NOTE: Executing RunQueue Tasks
DEBUG: Considering 0 (/home/scott-lenovo/LayerA/a.bb, do_build): set([])
DEBUG: Skip list (pre setsceneverify) []
DEBUG: Full skip list set([])
DEBUG: Using runqueue scheduler 'speed'
DEBUG: Stampfile /home/scott-lenovo/junk/tmp/stamps.do_build not available
DEBUG: Found bblayers.conf (/home/scott-lenovo/junk/conf/bblayers.conf)
DEBUG: LOAD /home/scott-lenovo/junk/conf/bblayers.conf
DEBUG: Adding layer /home/scott-lenovo/LayerA
DEBUG: LOAD /home/scott-lenovo/LayerA/conf/layer.conf
DEBUG: LOAD /home/scott-lenovo/junk/conf/bitbake.conf
DEBUG: BB configuration INHERITs:0: inheriting /home/scott-lenovo/junk/classes/base.bbclass
DEBUG: BB /home/scott-lenovo/junk/classes/base.bbclass: handle(data, include)
DEBUG: LOAD /home/scott-lenovo/junk/classes/base.bbclass
DEBUG: Using cache in '/home/scott-lenovo/junk/tmp/cache/bb_codeparser.dat'
************************
*                      *
*     Hello, World!    *
*                      *
************************
DEBUG: Teardown for bitbake-worker
NOTE: Tasks Summary: Attempted 1 tasks of which 0 didn't need to be rerun and all succeeded.
scott-lenovo@scott-lenovo:~/junk/conf [master #]

7. If you run it without the "-DDD" option, the output is cleaner.

scott-lenovo@scott-lenovo:~/junk [master #]
$ bitbake a
Parsing recipes: 100% |##########################################################################################| Time: 00:00:00
Parsing of 1 .bb files complete (0 cached, 1 parsed). 1 targets, 0 skipped, 0 masked, 0 errors.
NOTE: Resolving any missing task queue dependencies
NOTE: Preparing runqueue
NOTE: Executing RunQueue Tasks
************************
*                      *
*     Hello, World!    *
*                      *
************************
NOTE: Tasks Summary: Attempted 1 tasks of which 0 didn't need to be rerun and all succeeded.
scott-lenovo@scott-lenovo:~/junk [master #]
                </literallayout>
            </para>

            <para>
                You need to set
                <link linkend='var-BBPATH'><filename>BBPATH</filename></link>.
            </para>

            <para>
                When you run BitBake, it begins looking for metadata files.
                The <filename>BBPATH</filename> variable is what tells
                BitBake where to look.
                You could set <filename>BBPATH</filename> in the same manner
                that you set <filename>PATH</filename> as shown earlier.
                However, it is much more flexible to set the
                <link linkend='var-BBPATH'><filename>BBPATH</filename></link>
                variable for each project.
            </para>

            <para>
                Without <filename>BBPATH</filename>, Bitbake cannot
                find any configuration files (<filename>.conf</filename>)
                or recipe files (<filename>.bb</filename>) at all.
                BitBake also cannot find the <filename>bitbake.conf</filename>
                file.
            </para>

            <para>
                It is standard practice to organize the project's directory tree
                to include both a <filename>conf/</filename> and
                <filename>classes/</filename> directory.
                You need to add those directories to your project:
                <literallayout class='monospaced'>
     $ mkdir conf classes
                </literallayout>
                Once those directories are in place, you can copy the
                sample configuration files provided in the
                BitBake source tree to their appropriate directories.
                First, change to the BitBake source tree directory and
                then copy the directories:
                <literallayout class='monospaced'>
     cp conf/bitbake.conf ~/dev/hello/conf/
     cp classes/base.bbclass ~/dev/hello/classes/
                </literallayout>
                At this point your project directory structure should look like
                the following:
               <literallayout class='monospaced'>
     ~/dev/hello$ tree
     .
     |-- classes
     |   +-- base.bbclass
     +-- conf
         +-- bitbake.conf
                </literallayout>
            </para>

            <para>
                Once you have copied these files into your project, you
                can now get back to resolving the <filename>BBPATH</filename>
                issue.
            </para>

            <para>
                The first configuration file that BitBake looks for is always
                <filename>bblayers.conf</filename>.
                With this knowledge, you know that to resolve your
                <filename>BBPATH</filename> error you can add a
                <filename>conf/bblayers.conf</filename> file to the
                project source tree and populate it with the
                <filename>BBPATH</filename> variable declaration.
            </para>

            <para>
                From your project source tree:
                <literallayout class='monospaced'>
     $ vim conf/bblayers.conf
                </literallayout>
                Now add the following to the empty
                <filename>bblayers.conf</filename> file:
                <literallayout class='monospaced'>
     BBPATH := "${TOPDIR}"
                </literallayout>
            </para>

            <para>
                Now, from the root of your project directory, run BitBake
                again and see what happens:
                <literallayout class='monospaced'>
     $ bitbake -DDD
     Nothing to do.  Use 'bitbake world' to build everything, or
     run 'bitbake --help' for usage information.
     DEBUG: Removed the following variables from the environment:
     GNOME_DESKTOP_SESSION_ID, XDG_CURRENT_DESKTOP,
     GNOME_KEYRING_CONTROL, DISPLAY, SSH_AGENT_PID, LANG, no_proxy,
     XDG_SESSION_PATH, XAUTHORITY, SESSION_MANAGER, SHLVL,
     MANDATORY_PATH, COMPIZ_CONFIG_PROFILE, WINDOWID, EDITOR,
     GPG_AGENT_INFO, SSH_AUTH_SOCK, GDMSESSION, DEFAULTS_PATH,
     XDG_SEAT_PATH, XDG_CONFIG_DIRS, LESSOPEN,
     DBUS_SESSION_BUS_ADDRESS, _, XDG_SESSION_COOKIE,
     DESKTOP_SESSION, LESSCLOSE, GNOME_KEYRING_PID, UBUNTU_MENUPROXY,
     OLDPWD, XDG_DATA_DIRS, COLORTERM, LS_COLORS
     DEBUG: Found bblayers.conf (/home/scott-lenovo/dev/hello/conf/bblayers.conf)
     DEBUG: LOAD /home/scott-lenovo/dev/hello/conf/bblayers.conf
     DEBUG: LOAD /home/scott-lenovo/dev/hello/conf/bitbake.conf
     DEBUG: BB configuration INHERITs:0: inheriting /home/scott-lenovo/dev/hello/classes/base.bbclass
     DEBUG: BB /home/scott-lenovo/dev/hello/classes/base.bbclass: handle(data, include)
     DEBUG: LOAD /home/scott-lenovo/dev/hello/classes/base.bbclass
     DEBUG: Clearing SRCREV cache due to cache policy of: clear
     DEBUG: Using cache in '/home/scott-lenovo/dev/hello/tmp/cache/local_file_checksum_cache.dat'
     DEBUG: Using cache in '/home/scott-lenovo/dev/hello/tmp/cache/bb_codeparser.dat'
     DEBUG: Features set [3] (was [3])
                </literallayout>
                <note>
                    From this point forward in the example, the environment
                    variable removal messages are ignored and omitted.
                    Examine the relevant DEBUG messages:
                </note>
            </para>
        </section>
    </section>
</appendix>