README revision 533
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan FosterThis is documentation of the Makefile system used in this tree.
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan FosterGeneral Overview:
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Foster-----------------
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan FosterThis tree builds dozens of open source modules that are each released
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fosterseparately and delivered as source in seperate tarballs. These modules
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fosterare organized in subdirectories based on the X.Org module list, though
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fostermodules from other sources are included as appropriate. For instance,
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fosterthe application xterm is built in open-src/app/xterm, while the fontconfig
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan FosterIn this tree, the term "module" is used for a specific set of source built
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fostergenerally from a single tarball from upstream, such as xterm or fontconfig.
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan FosterThe directories grouping these together are referred to as "module type"
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fosterdirectories - app, lib, font, etc. Each module is thus found in a
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fostersubdirectory of the form open-src/<module type>/<module> . Various flags
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fostercan be set at either the individual module level or for all modules of a
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan FosterFor each module, at build time the tarball is unpacked, patches applied for
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fosterpost-release bug fixes or customizations, and then the build is run.
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan FosterTo allow building both 32-bit and 64-bit versions in the same build,
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fosterthis all happens in subdirectories named build_32 & build_64 in each
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fostermodules' directory. Since those subdirectories are competely recreatable
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fosterfrom the source tarball and patches, rebuilding the tree or running make clean
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fostersimply removes them entirely and recreates them.
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan FosterYou should be able to run make commands in any module directory or
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fostermodule-type directory, though since most of the intermodule dependencies
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fosterare not declared, many modules will break unless you've done a full-tree
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fosterbuild at some point to populate the proto area with the bits needed.
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Foster=============================================================================
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan FosterMake targets you can build in each module:
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Foster------------------------------------------
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan FosterFor most of these you can append _32 or _64 to do just the 32-bit or 64-bit
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fosterversions of the targets, while the version listed here repeats for all build
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fostertypes set in the BUILD_TYPES variable. These are defined in the
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fosteropen-src/common/Makefile.inc file, though open-src/<module type>/Makefile.inc
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fostermay add additional rules needed for modules of that type.
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Foster Completely removes build_* directories.
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Foster Creates build_* directories by unpacking sources from tarball
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Foster and applying patches.
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Fostermake configure
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Foster Runs GNU autoconf script or similar configuration steps if
a688bcbb4bcff5398fdd29b86f83450257dc0df4Allan Foster needed, including autoreconf or delibtoolize if variables are set.
If open-src/tarballs does not contain the tarball needed for this
from open-src/common/Makefile.subdirs to define these.
man page conventions to, via the open-src/common/suntouch-manpages.pl
- Additional flags to pass to open-src/common/suntouch-manpages.pl, such as
- Names of pkgconfig .pc or .pc.in files in the module, which will be
unnecessary Requires.privates lines from.
- Makefile targets/rules that the default_* rules list as dependencies
running configure, to regenerate autoconf/automake/libtool created
open-src/common/delibtoolize.pl to remove libtool calls from Makefiles
libtool/compiler etc. Used by default_build & default_install rules.
Makefile.inc is included to prevent the default from being set. For
SOURCE_URL=http://fontconfig.org/release/$(SOURCE_TARBALL_NAME)
Default: $(DEFAULT_COMPILER) setting in common/Makefile.init,
Default: $(X11_DIR) (aka /usr/X11).
- Name of tarball file under open-src/tarballs directory for this module.
Default: $(SOURCE_DIRNAME).tar.bz2
- For X.Org sources, what directory the source tarball & git repo is in
on freedesktop.org - usually the same as the module type directory in
the binaries built (32 and/or 64), but may be set to any string if other
- Makefile targets/rules to run for "make source", "make configure",
for use by include statements in package copyright.add files, where
Variables that can be set in the Makefile.inc for each module type:
open-src/<module_type>/Makefile.inc - they have the same meanings and uses
directory for the module type in X.Org's source trees.
open-src/common/Makefile.init defines $MACH to be either sparc or i386
on x86/x64, you can do:
Variables you may want to customize for your site/tree:
XORG_RELEASES_URL & SF_DOWNLOADS_URL (set in open-src/common/Makefile.init)
- urls for X.Org & sourceforge mirrors to download tarballs from
FDO_GIT_URL (set in open-src/common/Makefile.init)
- url for git repositories hosted on freedesktop.org, including
X.Org, Mesa, pixman, etc. - defaults to anonymous git over http, can
Some tools to ease development are available in the util/build-tools
find-build-errors - looks for a log/buildit-XW file (or another file you
a X.org release still in development, you can choose to to check out a
- Setting up proper parallel make rules so that multi-core/cpu
makefiles - you can't bringover the tree and just cd open-src/xserver/xorg
dependencies will probably take a while - getting them done for xserver/xorg
distribute, and/or sell copies of the Software, and to permit persons