aboutsummaryrefslogtreecommitdiffstats
path: root/package/bridge
diff options
context:
space:
mode:
Diffstat (limited to 'package/bridge')
-rw-r--r--package/bridge/Config.in2
-rw-r--r--package/bridge/Makefile69
-rw-r--r--package/bridge/bridge.control8
-rw-r--r--package/bridge/bridge.mk73
4 files changed, 78 insertions, 74 deletions
diff --git a/package/bridge/Config.in b/package/bridge/Config.in
index 5856e3f791..8e5cddbb36 100644
--- a/package/bridge/Config.in
+++ b/package/bridge/Config.in
@@ -1,5 +1,5 @@
config BR2_PACKAGE_BRIDGE
- bool "bridge"
+ tristate "Ethernet bridging support"
default y
help
Manage ethernet bridging; a way to connect networks together to
diff --git a/package/bridge/Makefile b/package/bridge/Makefile
new file mode 100644
index 0000000000..5340a9b58e
--- /dev/null
+++ b/package/bridge/Makefile
@@ -0,0 +1,69 @@
+#############################################################
+#
+# ebtables
+#
+#############################################################
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=bridge
+PKG_VERSION:=1.0.4
+PKG_RELEASE:=1
+PKG_SOURCE_URL:=http://umn.dl.sourceforge.net/sourceforge/bridge
+PKG_SOURCE:=bridge-utils-$(PKG_VERSION).tar.gz
+PKG_BUILD_DIR:=$(BUILD_DIR)/bridge-utils-$(PKG_VERSION)
+PKG_CAT:=zcat
+PKG_IPK:=$(PACKAGE_DIR)/$(PKG_NAME)_$(PKG_VERSION)-$(PKG_RELEASE)_$(ARCH).ipk
+PKG_IPK_DIR:=$(PKG_BUILD_DIR)/ipkg
+
+$(DL_DIR)/$(PKG_SOURCE):
+ $(WGET) -P $(DL_DIR) $(PKG_SOURCE_URL)/$(PKG_SOURCE)
+
+$(PKG_BUILD_DIR)/.unpacked: $(DL_DIR)/$(PKG_SOURCE)
+ $(PKG_CAT) $(DL_DIR)/$(PKG_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) -
+ touch $(PKG_BUILD_DIR)/.unpacked
+
+$(PKG_BUILD_DIR)/.patched: $(PKG_BUILD_DIR)/.unpacked
+ $(PATCH) $(PKG_BUILD_DIR) ./patches
+ touch $(PKG_BUILD_DIR)/.patched
+
+$(PKG_BUILD_DIR)/.configured: $(PKG_BUILD_DIR)/.patched
+ (cd $(PKG_BUILD_DIR); rm -rf config.cache; \
+ $(TARGET_CONFIGURE_OPTS) \
+ CFLAGS="$(TARGET_CFLAGS)" \
+ ./configure \
+ --target=$(GNU_TARGET_NAME) \
+ --host=$(GNU_TARGET_NAME) \
+ --build=$(GNU_HOST_NAME) \
+ --prefix=/usr \
+ --exec-prefix=/usr \
+ --bindir=/usr/bin \
+ --sbindir=/usr/sbin \
+ --libexecdir=/usr/lib \
+ --sysconfdir=/etc \
+ --datadir=/usr/share \
+ --localstatedir=/var \
+ --mandir=/usr/man \
+ --infodir=/usr/info \
+ $(DISABLE_NLS) \
+ --with-linux-headers=$(LINUX_DIR) \
+ );
+ touch $(PKG_BUILD_DIR)/.configured
+
+$(PKG_BUILD_DIR)/brctl/brctl: $(PKG_BUILD_DIR)/.configured
+ $(MAKE) -C $(PKG_BUILD_DIR)
+
+$(PKG_IPK): $(PKG_BUILD_DIR)/brctl/brctl
+ $(SCRIPT_DIR)/make-ipkg-dir.sh $(PKG_IPK_DIR) $(PKG_NAME).control $(PKG_VERSION)-$(PKG_RELEASE) $(ARCH)
+ mkdir -p $(PKG_IPK_DIR)/usr/sbin
+ cp $(PKG_BUILD_DIR)/brctl/brctl $(PKG_IPK_DIR)/usr/sbin/
+ $(STRIP) $(PKG_IPK_DIR)/usr/sbin/brctl
+ mkdir -p $(PACKAGE_DIR)
+ $(IPKG_BUILD) $(PKG_IPK_DIR) $(PACKAGE_DIR)
+
+source: $(DL_DIR)/$(PKG_SOURCE)
+prepare: $(PKG_BUILD_DIR)/.patched
+compile: $(PKG_IPK)
+install:
+ $(IPKG) install $(PKG_IPK)
+clean:
+ rm -rf $(PKG_BUILD_DIR)
diff --git a/package/bridge/bridge.control b/package/bridge/bridge.control
new file mode 100644
index 0000000000..9ba7b50274
--- /dev/null
+++ b/package/bridge/bridge.control
@@ -0,0 +1,8 @@
+Package: bridge
+Priority: essential
+Section: net
+Version: 1.0.4-1
+Architecture: mipsel
+Maintainer: Felix Fietkau <nbd@vd-s.ath.cx>
+Source: buildroot internal
+Description: Ethernet bridging tools
diff --git a/package/bridge/bridge.mk b/package/bridge/bridge.mk
deleted file mode 100644
index e831e26d06..0000000000
--- a/package/bridge/bridge.mk
+++ /dev/null
@@ -1,73 +0,0 @@
-#############################################################
-#
-# bridgeutils - User Space Program For Controling Bridging
-#
-#############################################################
-#
-BRIDGE_SOURCE_URL=http://umn.dl.sourceforge.net/sourceforge/bridge/
-BRIDGE_SOURCE=bridge-utils-1.0.4.tar.gz
-BRIDGE_BUILD_DIR=$(BUILD_DIR)/bridge-utils-1.0.4
-BRIDGE_PATCHES=$(PACKAGE_DIR)/bridge/patches
-BRIDGE_TARGET_BINARY:=usr/sbin/brctl
-
-$(DL_DIR)/$(BRIDGE_SOURCE):
- $(WGET) -P $(DL_DIR) $(BRIDGE_SOURCE_URL)/$(BRIDGE_SOURCE)
-
-$(BRIDGE_BUILD_DIR)/.unpacked: $(DL_DIR)/$(BRIDGE_SOURCE)
- zcat $(DL_DIR)/$(BRIDGE_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) -
- touch $(BRIDGE_BUILD_DIR)/.unpacked
-
-$(BRIDGE_BUILD_DIR)/.patched: $(BRIDGE_BUILD_DIR)/.unpacked
- $(PATCH) $(BRIDGE_BUILD_DIR) $(BRIDGE_PATCHES)
- touch $(BRIDGE_BUILD_DIR)/.patched
-
-$(BRIDGE_BUILD_DIR)/.configured: $(BRIDGE_BUILD_DIR)/.patched
- (cd $(BRIDGE_BUILD_DIR); rm -rf config.cache; \
- $(TARGET_CONFIGURE_OPTS) \
- CFLAGS="$(TARGET_CFLAGS)" \
- ./configure \
- --target=$(GNU_TARGET_NAME) \
- --host=$(GNU_TARGET_NAME) \
- --build=$(GNU_HOST_NAME) \
- --prefix=/usr \
- --exec-prefix=/usr \
- --bindir=/usr/bin \
- --sbindir=/usr/sbin \
- --libexecdir=/usr/lib \
- --sysconfdir=/etc \
- --datadir=/usr/share \
- --localstatedir=/var \
- --mandir=/usr/man \
- --infodir=/usr/info \
- $(DISABLE_NLS) \
- --with-linux-headers=$(LINUX_DIR) \
- );
- touch $(BRIDGE_BUILD_DIR)/.configured
-
-$(BRIDGE_BUILD_DIR)/brctl/brctl: $(BRIDGE_BUILD_DIR)/.configured
- $(MAKE) -C $(BRIDGE_BUILD_DIR)
-
-$(TARGET_DIR)/$(BRIDGE_TARGET_BINARY): $(BRIDGE_BUILD_DIR)/brctl/brctl
- mkdir -p $(TARGET_DIR)/usr/sbin
- cp -af $(BRIDGE_BUILD_DIR)/brctl/brctl $(TARGET_DIR)/$(BRIDGE_TARGET_BINARY)
- $(STRIP) $(TARGET_DIR)/$(BRIDGE_TARGET_BINARY)
-
-bridge: uclibc $(TARGET_DIR)/$(BRIDGE_TARGET_BINARY)
-
-bridge-source: $(DL_DIR)/$(BRIDGE_SOURCE)
-
-bridge-clean:
- #$(MAKE) DESTDIR=$(TARGET_DIR) CC=$(TARGET_CC) -C $(BRIDGE_BUILD_DIR) uninstall
- -$(MAKE) -C $(BRIDGE_BUILD_DIR) clean
-
-bridge-dirclean:
- rm -rf $(BRIDGE_BUILD_DIR)
-
-#############################################################
-#
-# Toplevel Makefile options
-#
-#############################################################
-ifeq ($(strip $(BR2_PACKAGE_BRIDGE)),y)
-TARGETS+=bridge
-endif