From 52f8d5bdce1bce9fc1119c1674fd5be24453a22c Mon Sep 17 00:00:00 2001 From: Nicolas Thill Date: Sun, 18 Jun 2006 18:05:20 +0000 Subject: [PATCH] move source files to src/. SVN-Revision: 3993 --- openwrt/package/robocfg/Makefile | 11 ++++++++--- openwrt/package/robocfg/src/Makefile | 12 ++++++++++++ openwrt/package/robocfg/{ => src}/etc53xx.h | 0 openwrt/package/robocfg/{ => src}/robocfg.c | 0 4 files changed, 20 insertions(+), 3 deletions(-) create mode 100644 openwrt/package/robocfg/src/Makefile rename openwrt/package/robocfg/{ => src}/etc53xx.h (100%) rename openwrt/package/robocfg/{ => src}/robocfg.c (100%) diff --git a/openwrt/package/robocfg/Makefile b/openwrt/package/robocfg/Makefile index 81cf99ac23..49f6005699 100644 --- a/openwrt/package/robocfg/Makefile +++ b/openwrt/package/robocfg/Makefile @@ -16,15 +16,20 @@ TITLE:=BCM5325E/536x switch configuration utility DESCRIPTION:=Broadcom BCM5325E/536x switch configuration utility endef +define Build/Prepare + mkdir -p $(PKG_BUILD_DIR) + $(CP) ./src/* $(PKG_BUILD_DIR)/ +endef + define Build/Compile - $(TARGET_CC) $(TARGET_CFLAGS) -o $(PKG_BUILD_DIR)/robocfg robocfg.c + $(MAKE) -C $(PKG_BUILD_DIR) \ + CC="$(TARGET_CC)" CFLAGS="$(TARGET_CFLAGS)" \ + all endef define Package/robocfg/install install -d -m0755 $(1)/sbin install -m0755 $(PKG_BUILD_DIR)/robocfg $(1)/sbin/ - $(RSTRIP) $(1) - $(IPKG_BUILD) $(1) $(PACKAGE_DIR) endef $(eval $(call BuildPackage,robocfg)) diff --git a/openwrt/package/robocfg/src/Makefile b/openwrt/package/robocfg/src/Makefile new file mode 100644 index 0000000000..fa763edbc8 --- /dev/null +++ b/openwrt/package/robocfg/src/Makefile @@ -0,0 +1,12 @@ +# $Id$ + +all: robocfg + +%.o: %.c + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -c -o $@ $^ + +robocfg: robocfg.o + $(CC) -o $@ $^ + +clean: + rm -f *.o robocfg diff --git a/openwrt/package/robocfg/etc53xx.h b/openwrt/package/robocfg/src/etc53xx.h similarity index 100% rename from openwrt/package/robocfg/etc53xx.h rename to openwrt/package/robocfg/src/etc53xx.h diff --git a/openwrt/package/robocfg/robocfg.c b/openwrt/package/robocfg/src/robocfg.c similarity index 100% rename from openwrt/package/robocfg/robocfg.c rename to openwrt/package/robocfg/src/robocfg.c