1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-01-18 12:52:44 +01:00

fixup for #710: use subfolder in bin dirs (native)

Update native Makefiles to provide changed object target paths
Fixes #989
This commit is contained in:
Ludwig Ortmann 2014-04-09 15:23:12 +02:00
parent f3024916ef
commit b9ffc1a99e
5 changed files with 20 additions and 15 deletions

View File

@ -7,10 +7,11 @@ all: $(BINDIR)$(MODULE).a
include $(RIOTBASE)/Makefile.base
$(BINDIR)%.o: %.c
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -c $*.c -o $(BINDIR)$*.o
$(BINDIR)$(MODULE)/%.o: %.c
@mkdir -p $(BINDIR)$(MODULE)
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -c $*.c -o $(BINDIR)$(MODULE)/$*.o
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -MM $*.c |\
sed -e "1s|^|$(BINDIR)|" > $(BINDIR)$*.d
sed -e "1s|^|$(BINDIR)$(MODULE)/|" > $(BINDIR)$(MODULE)/$*.d
clean::
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;

View File

@ -5,7 +5,8 @@ all: $(BINDIR)$(MODULE).a
include $(RIOTBASE)/Makefile.base
$(BINDIR)%.o: %.c
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -c $*.c -o $(BINDIR)$*.o
$(BINDIR)$(MODULE)/%.o: %.c
@mkdir -p $(BINDIR)$(MODULE)
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -c $*.c -o $(BINDIR)$(MODULE)/$*.o
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -MM $*.c |\
sed -e "1s|^|$(BINDIR)|" > $(BINDIR)$*.d
sed -e "1s|^|$(BINDIR)$(MODULE)/|" > $(BINDIR)$(MODULE)/$*.d

View File

@ -13,10 +13,11 @@ all: $(BINDIR)$(MODULE).a
include $(RIOTBASE)/Makefile.base
$(BINDIR)%.o: %.c
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -c $*.c -o $(BINDIR)$*.o
$(BINDIR)$(MODULE)/%.o: %.c
@mkdir -p $(BINDIR)$(MODULE)
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -c $*.c -o $(BINDIR)$(MODULE)/$*.o
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -MM $*.c |\
sed -e "1s|^|$(BINDIR)|" > $(BINDIR)$*.d
sed -e "1s|^|$(BINDIR)$(MODULE)/|" > $(BINDIR)$(MODULE)/$*.d
clean::
@for i in $(DIRS) ; do "$(MAKE)" -C $$i clean || exit 1; done ;

View File

@ -2,7 +2,8 @@ MODULE = nativenet
include $(RIOTBASE)/Makefile.base
$(BINDIR)%.o: %.c
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -c $*.c -o $(BINDIR)$*.o
$(BINDIR)$(MODULE)/%.o: %.c
@mkdir -p $(BINDIR)$(MODULE)
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -c $*.c -o $(BINDIR)$(MODULE)/$*.o
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -MM $*.c |\
sed -e "1s|^|$(BINDIR)|" > $(BINDIR)$*.d
sed -e "1s|^|$(BINDIR)$(MODULE)/|" > $(BINDIR)$(MODULE)/$*.d

View File

@ -2,7 +2,8 @@ MODULE =rtc
include $(RIOTBASE)/Makefile.base
$(BINDIR)%.o: %.c
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -c $*.c -o $(BINDIR)$*.o
$(BINDIR)$(MODULE)/%.o: %.c
@mkdir -p $(BINDIR)$(MODULE)
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -c $*.c -o $(BINDIR)$(MODULE)/$*.o
$(AD)$(CC) $(CFLAGS) $(NATIVEINCLUDES) -MM $*.c |\
sed -e "1s|^|$(BINDIR)|" > $(BINDIR)$*.d
sed -e "1s|^|$(BINDIR)$(MODULE)/|" > $(BINDIR)$(MODULE)/$*.d