Difference between revisions of "Build Environment Effort/Zen of gbuild"
From Apache OpenOffice Wiki
B michaelsen (Talk | contribs) (→Zen of gbuild) |
B michaelsen (Talk | contribs) (→Zen of gbuild) |
||
Line 2: | Line 2: | ||
== Zen of gbuild == | == Zen of gbuild == | ||
* One use make process, [http://miller.emu.id.au/pmiller/books/rmch/ do not recurse]. | * One use make process, [http://miller.emu.id.au/pmiller/books/rmch/ do not recurse]. | ||
− | * Always have good dependencies and clean targets. | + | * Always have good dependencies and good clean targets. |
− | * Have exactly one target per declaration file. | + | * Have exactly one $(OUTDIR) target per declaration file. |
* Use only tools as defined by [http://en.wikipedia.org/wiki/POSIX POSIX:2008]. Exception: GNU extensions are allowed for tar, cp and touch. | * Use only tools as defined by [http://en.wikipedia.org/wiki/POSIX POSIX:2008]. Exception: GNU extensions are allowed for tar, cp and touch. | ||
* Dont use Perl or Python for tooling, use POSIX sh, POSIX awk and GNU make instead. | * Dont use Perl or Python for tooling, use POSIX sh, POSIX awk and GNU make instead. |
Revision as of 14:39, 15 November 2010
Zen of gbuild
- One use make process, do not recurse.
- Always have good dependencies and good clean targets.
- Have exactly one $(OUTDIR) target per declaration file.
- Use only tools as defined by POSIX:2008. Exception: GNU extensions are allowed for tar, cp and touch.
- Dont use Perl or Python for tooling, use POSIX sh, POSIX awk and GNU make instead.
- If those dont cut it, use C/C++ (Or ask yourself if you are doing something wrong).
- Use the gb_Output_* functions for notifications.
- Keep all platform specific stuff confined in the platform subdirectory of gbuild.
- Never use relative paths. Only absolute paths starting with $(OUTDIR), $(WORKDIR) and the repository roots (for example $(SRCDIR)).
- Adhere to the Zen of Python, for it is valid in any language.