| 1 | ###############################################################################
|
|---|
| 2 | # air-boot.gmk :: Master GNU Makefile for AiR-BOOT #
|
|---|
| 3 | # --------------------------------------------------------------------------- #
|
|---|
| 4 | # This Makefile builds AiR-BOOT for all supported languages. #
|
|---|
| 5 | # AiR-BOOT consists of the following components: #
|
|---|
| 6 | # o The Loader #
|
|---|
| 7 | # This is the small ~31kB binary that resides in track0 #
|
|---|
| 8 | # o The Installer(s) #
|
|---|
| 9 | # This program installs the loader into track0. #
|
|---|
| 10 | # The following platforms are supported: DOS, OS/2 and Windows #
|
|---|
| 11 | # o The AiR-BOOT version of 'setboot' called 'setaboot' #
|
|---|
| 12 | # This is an OS/2 specific program. #
|
|---|
| 13 | ###############################################################################
|
|---|
| 14 |
|
|---|
| 15 | # UUID of this Makefile
|
|---|
| 16 | uuid:=95b9bf74-70d3-11e6-bae9-df2b17e2701d
|
|---|
| 17 |
|
|---|
| 18 | # Get the name of this Makefile
|
|---|
| 19 | self:=$(lastword $(MAKEFILE_LIST))
|
|---|
| 20 |
|
|---|
| 21 | # Delegate to target 'default' which can specify more than one dependency
|
|---|
| 22 | .DEFAULT_GOAL:=default
|
|---|
| 23 |
|
|---|
| 24 | # Inform the user on how to build AiR-BOOT
|
|---|
| 25 | default: info
|
|---|
| 26 |
|
|---|
| 27 | # Show information on how to use this Makefile
|
|---|
| 28 | info:
|
|---|
| 29 | $(info )
|
|---|
| 30 | $(info [$@])
|
|---|
| 31 | @less BUILD.NFO
|
|---|
| 32 | @echo
|
|---|
| 33 |
|
|---|
| 34 | # Redirect to 'build' target
|
|---|
| 35 | all: build
|
|---|
| 36 |
|
|---|
| 37 | # Build AiR-BOOT and its components
|
|---|
| 38 | build:
|
|---|
| 39 | $(info )
|
|---|
| 40 | $(info [$@])
|
|---|
| 41 | $(call owc.env)
|
|---|
| 42 | wmake -h
|
|---|
| 43 |
|
|---|
| 44 | # Create package
|
|---|
| 45 | package:
|
|---|
| 46 | $(info )
|
|---|
| 47 | $(info [$@])
|
|---|
| 48 | @echo
|
|---|
| 49 | @echo "*** Packaging is not implemented yet ***"
|
|---|
| 50 | @echo
|
|---|
| 51 |
|
|---|
| 52 | # Cleanup the generated files
|
|---|
| 53 | clean:
|
|---|
| 54 | $(info )
|
|---|
| 55 | $(info [$@])
|
|---|
| 56 | $(call owc.env)
|
|---|
| 57 | wmake -h clean
|
|---|
| 58 |
|
|---|
| 59 | # Show license information
|
|---|
| 60 | license:
|
|---|
| 61 | $(info )
|
|---|
| 62 | $(info [$@])
|
|---|
| 63 | @less COPYING
|
|---|
| 64 | @echo
|
|---|
| 65 |
|
|---|
| 66 | # Show release history
|
|---|
| 67 | history:
|
|---|
| 68 | $(info )
|
|---|
| 69 | $(info [$@])
|
|---|
| 70 | @less air-boot.his
|
|---|
| 71 | @echo
|
|---|
| 72 |
|
|---|
| 73 | #
|
|---|
| 74 | # Open Watcom Environment
|
|---|
| 75 | #
|
|---|
| 76 | define owc.env
|
|---|
| 77 | $(call owc19.env)
|
|---|
| 78 | endef
|
|---|
| 79 | define owc19.env
|
|---|
| 80 | $(eval export WATCOM:=/vol/devtools/owc19)
|
|---|
| 81 | $(eval export PATH:=$(WATCOM)/binl:$(PATH))
|
|---|
| 82 | $(eval export INCLUDE:=$(WATCOM)/lh:$(INCLUDE))
|
|---|
| 83 | $(eval export EDPATH:=$(WATCOM)/eddat)
|
|---|
| 84 | $(eval export WIPFC:=$(WATCOM)/wipfc)
|
|---|
| 85 | $(eval CC=owcc)
|
|---|
| 86 | endef
|
|---|