Skip to content

Commit

Permalink
apps/examples/udp and nettest: Back out parts of commit e806097 that …
Browse files Browse the repository at this point in the history
…broke the build of these examples.
  • Loading branch information
gregory-nutt committed Oct 18, 2019
1 parent 46612fe commit 2830892
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 4 deletions.
14 changes: 12 additions & 2 deletions examples/nettest/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -109,24 +109,34 @@ $(HOST_OBJS): %.$(HOSTOBJEXT): %.c
@echo "CC: $<"
$(Q) $(HOSTCC) -c $(HOSTCFLAGS) $< -o $@

endif
endif

config.h: $(TOPDIR)/include/nuttx/config.h
@echo "CP: $<"
$(Q) cp $< $@

ifneq ($(CONFIG_EXAMPLES_NETTEST_TARGET2),y)
ifneq ($(CONFIG_EXAMPLES_NETTEST_LOOPBACK),y)

$(HOST_BIN): config.h $(HOST_OBJS)
@echo "LD: $@"
$(Q) $(HOSTCC) $(HOSTLDFLAGS) $(HOST_OBJS) -o $@

endif
endif

context:: config.h $(HOST_BIN)

clean::
ifneq ($(CONFIG_EXAMPLES_NETTEST_TARGET2),y)
ifneq ($(CONFIG_EXAMPLES_NETTEST_LOOPBACK),y)
$(call DELFILE, *.$(HOSTOBJEXT))
$(call DELFILE, $(HOST_BIN))
$(call DELFILE, *.dSYM)
$(call DELFILE, config.h)

endif
endif
$(call DELFILE, config.h)

MODULE = $(CONFIG_EXAMPLES_NETTEST)

Expand Down
10 changes: 8 additions & 2 deletions examples/udp/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -96,22 +96,28 @@ $(HOST_OBJS): %.$(HOSTOBJSEXT): %.c
@echo "CC: $<"
$(Q) $(HOSTCC) -c $(HOSTCFLAGS) $< -o $@

endif

config.h: $(TOPDIR)/include/nuttx/config.h
@echo "CP: $<"
$(Q) cp $< $@

ifneq ($(CONFIG_EXAMPLES_UDP_TARGET2),y)

$(HOST_BIN): config.h $(HOST_OBJS)
$(Q) $(HOSTCC) $(HOSTLDFLAGS) $(HOST_OBJS) -o $@

endif

context:: config.h $(HOST_BIN)

clean::
ifneq ($(CONFIG_EXAMPLES_UDP_TARGET2),y)
$(call DELFILE, $(HOST_BIN))
$(call DELFILE, *.$(HOSTOBJSEXT))
$(call DELFILE, *.dSYM)
$(call DELFILE, config.h)

endif
$(call DELFILE, config.h)

MODULE = $(CONFIG_EXAMPLES_UDP)

Expand Down

0 comments on commit 2830892

Please sign in to comment.