tree: 9ea296ec04c0fe8297e1a1420970a0013831c5a0 [path history] [tgz]
  1. README.md
  2. bin/
  3. bootstrap.mk
  4. commands/
  5. consts.mk
  6. docker/
  7. etc/
  8. gerrit/
  9. git-submodules.mk
  10. git/
  11. golang/
  12. help/
  13. include.mk
  14. jjb/
  15. library-makefiles.mk
  16. lint/
  17. main/
  18. python/
  19. release/
  20. targets/
  21. todo.mk
  22. utils/
  23. virtualenv/
makefiles/README.md

makefiles

Two distinct makefile directories are in use:

  • Common library makefiles (onf-make/)
  • Project specific makefile logic (local/)

Makefile logic is loaded/accessed through make macros: ONF_MAKEDIR= Common makefile targets and logic MAKEDIR= Repository/project specific targets

Common library targets are defined/augmented as double colon rules: build clean help sterile test :: # dup targets OK

% make sterile test

All other targets are defined and accessed as single colon rules: repo-rule : # fail on duplicate targets

All makefiles/ logic can be access from the top level Makefile

TOP ?= $(strip $(dir $(abspath $(lastword $(MAKEFILE_LIST))) ) )
include $(TOP)/config.mk include $(TOP)/makefiles/include.mk

Which in turn will load onf-make/ and local/

include $(ONF_MAKE)/makefiles/include.mk include $(MAKEDIR)/makefiles/include.mk

% make sterile build

[EOF]