-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
57 lines (36 loc) · 1.59 KB
/
Makefile
File metadata and controls
57 lines (36 loc) · 1.59 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
## ========================================================================================================
## IMPORTANT NOTE: This Makefile setup is designed to work both standalone and integrated with brickOS-bibo
## - Makefile: For building stand-alone, effectively providing what would provided by Makefle
## or Makefile.common from brickOS-bibo
## - Makefile.sub: Facilitates building as part of brickOS-bibo
## ========================================================================================================
# Development Packages:
# * Required: h8300 binutils
# Using $(abspath x) here so that symlinks are NOT replaced
MAKEFILE_PATH := $(abspath $(lastword $(MAKEFILE_LIST)))
MAKEFILE_DIR := $(abspath $(dir $(MAKEFILE_PATH)))
MAKEFILE_NAME := $(notdir $(MAKEFILE_PATH))
TARGET_ARCH = h8300-lego-coff
CROSSTOOLPREFIX ?= h8300-hitachi-coff-
CROSSTOOLSUFFIX ?=
CROSSAS ?= $(CROSSTOOLPREFIX)as$(CROSSTOOLSUFFIX)
CROSSLD ?= $(CROSSTOOLPREFIX)ld$(CROSSTOOLSUFFIX)
CROSSOBJCOPY ?= $(CROSSTOOLPREFIX)objcopy$(CROSSTOOLSUFFIX)
ROM_BASESUBDIR = .
# Installation Path Configuration
DESTDIR ?=
prefix ?= /opt/stow/foss-rcx-rom
pkgtargetkerneldir ?= ${prefix}/${TARGET_ARCH}/boot
all: rom
clean: rom-clean
realclean: rom-realclean
install: rom-install
uninstall: rom-uninstall
include $(MAKEFILE_DIR)/Makefile.sub
$(ROM_FILES_BASE).bin: $(ROM_FILES_BASE).coff
$(CROSSOBJCOPY) -I coff-h8300 -O binary $< $@
$(ROM_FILES_BASE).srec: $(ROM_FILES_BASE).coff
$(CROSSOBJCOPY) -I coff-h8300 -O srec $< $@
# Cancel default rules
.SUFFIXES:
include $(MAKEFILE_DIR)/Makefile.utility