Skip to content

Commit

Permalink
handbook/cutting-edge: Add more details about MAKEOBJDIRPREFIX
Browse files Browse the repository at this point in the history
Previously, the handbook suggested /tmp for MAKEOBJDIRPREFIX. This was
fine, but suggesting /tmp/obj instead is even better as build artifacts
will not mix with other files in /tmp.  Also note that MAKEOBJDIRPREFIX
must exist.

Sponsored by:	Klara, Inc.
  • Loading branch information
0mp committed Oct 4, 2023
1 parent 275d942 commit cd8ea66
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1179,10 +1179,11 @@ For example, the following `tools/build/make.py` invocation builds the world:

[source,shell]
....
MAKEOBJDIRPREFIX=/tmp tools/build/make.py -j 8 TARGET=arm64 TARGET_ARCH=aarch64 buildworld
MAKEOBJDIRPREFIX=/tmp/obj tools/build/make.py -j 8 TARGET=arm64 TARGET_ARCH=aarch64 buildworld
....

It builds the world for target `aarch64:arm64` on 8 CPUs and uses [.filename]#/tmp# for object files.
It builds the world for target `aarch64:arm64` on 8 CPUs and uses [.filename]#/tmp/obj# for object files.
Note that the variables `MAKEOBJDIRPREFIX`, `TARGET`, and `TARGET_ARCH` are mandatory when building on non-FreeBSD hosts.
Also, make sure to create the object directory pointed to by the `MAKEOBJDIRPREFIX` environment variable.

Refer to man:arch[7] and man:build[7] for more details.

0 comments on commit cd8ea66

Please sign in to comment.