Commit Graph

60 Commits

Author SHA1 Message Date
Travis Geiselbrecht
eaa673169e [make] add feature to allow multiple parallel build dirs
Using environment variables LKROOT and LKINC you can specify multiple
parallel top level directories (outside of the lk root) that are overlayed
on top of the build system. This allows for a structure like

lk/
testproject/
someotherfirmware/

Where each of these subdirs has an entire overlayed tree of libraries, platforms,
targets, and projects.

To accomplish this, copy makefile into the root dir and build a lk_inc.mk that
sets LKROOT and LKINC.
2013-03-12 03:12:24 -07:00
Travis Geiselbrecht
34b56263d3 [make] fix compile.mk to properly use MODULE_INCLUDES 2013-02-16 15:06:24 -08:00
Travis Geiselbrecht
5f6b2a955d [make] fix a typo that was causing some build lines to echo 2012-11-11 14:00:34 -08:00
Travis Geiselbrecht
0e0c77c04f [make] also output .hex files in intel hex format 2012-11-02 11:48:17 -07:00
Travis Geiselbrecht
3635b5d314 [make] put all of the global and local build switches in config.h files
-now if you change any interesting build flags, the appropriate sources
will be rebuilt
2012-09-23 18:48:11 -07:00
Travis Geiselbrecht
6830dfe447 [make] add options to add extra .o files to the link line at the module and global scope 2012-09-23 18:29:34 -07:00
Travis Geiselbrecht
d82b0fbca0 [make] add mod.o files to the GENERATED list so they get cleaned up properly 2012-09-05 11:42:57 -07:00
Travis Geiselbrecht
734f32b143 [make] better modularize the build system
-Each module's rules.mk defines a seperate linkage unit. Each
module can have a private set of CFLAGS, DEFINES, INCLUDES, and so
forth.
-Files to be compiled are now added by source, not object.

Most rules.mk files can be converted easily by following these steps:

1) add 'MODULE := $(LOCAL_DIR)' near the top of the file
2) change OBJS += to MODULE_SRCS += and list source files instead of .os
3) add 'include make/module.mk' at the bottom of the file

See make/module.mk for directions.
2012-08-31 15:52:24 -07:00
Travis Geiselbrecht
9c0f307ce6 [make] rename module.mk to recurse.mk to make way for a real module.mk 2012-08-31 15:42:44 -07:00
Travis Geiselbrecht
5bcbd9d68e move the stray .mk files from the root dir into a make/ subdir 2009-01-24 20:15:32 -08:00