mirror of https://github.com/ARMmbed/mbed-os.git
Fix the makefile template
- Corrects a python barf when something in features is None - Corrects makefile to prevent barf when using make -fpull/2106/head
parent
1794463a06
commit
4b7f591d33
|
|
@ -13,7 +13,8 @@ endif
|
||||||
ifeq (,$(filter .build,$(notdir $(CURDIR))))
|
ifeq (,$(filter .build,$(notdir $(CURDIR))))
|
||||||
.SUFFIXES:
|
.SUFFIXES:
|
||||||
OBJDIR := .build
|
OBJDIR := .build
|
||||||
MAKETARGET = $(MAKE) --no-print-directory -C $(OBJDIR) -f $(CURDIR)/Makefile \
|
mkfile_path := $(abspath $(lastword $(MAKEFILE_LIST)))
|
||||||
|
MAKETARGET = $(MAKE) --no-print-directory -C $(OBJDIR) -f $(mkfile_path) \
|
||||||
SRCDIR=$(CURDIR) $(MAKECMDGOALS)
|
SRCDIR=$(CURDIR) $(MAKECMDGOALS)
|
||||||
.PHONY: $(OBJDIR) clean
|
.PHONY: $(OBJDIR) clean
|
||||||
all:
|
all:
|
||||||
|
|
|
||||||
|
|
@ -147,7 +147,7 @@ class Resources:
|
||||||
v = [rel_path(f, base, dot) for f in getattr(self, field)]
|
v = [rel_path(f, base, dot) for f in getattr(self, field)]
|
||||||
setattr(self, field, v)
|
setattr(self, field, v)
|
||||||
|
|
||||||
self.features = {k: f.relative_to(base, dot) for k, f in self.features.iteritems()}
|
self.features = {k: f.relative_to(base, dot) for k, f in self.features.iteritems() if f}
|
||||||
|
|
||||||
if self.linker_script is not None:
|
if self.linker_script is not None:
|
||||||
self.linker_script = rel_path(self.linker_script, base, dot)
|
self.linker_script = rel_path(self.linker_script, base, dot)
|
||||||
|
|
@ -160,7 +160,7 @@ class Resources:
|
||||||
v = [f.replace('\\', '/') for f in getattr(self, field)]
|
v = [f.replace('\\', '/') for f in getattr(self, field)]
|
||||||
setattr(self, field, v)
|
setattr(self, field, v)
|
||||||
|
|
||||||
self.features = {k: f.win_to_unix() for k, f in self.features.iteritems()}
|
self.features = {k: f.win_to_unix() for k, f in self.features.iteritems() if f}
|
||||||
|
|
||||||
if self.linker_script is not None:
|
if self.linker_script is not None:
|
||||||
self.linker_script = self.linker_script.replace('\\', '/')
|
self.linker_script = self.linker_script.replace('\\', '/')
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue