From 32986b80d4aeca7c0295b134743e81f79e913486 Mon Sep 17 00:00:00 2001 From: Peter Korsgaard Date: Tue, 24 Jun 2008 09:55:37 +0000 Subject: [PATCH] package/i2c-tools: I2C tools package This package contains a heterogeneous set of I2C tools for Linux: a bus probing tool, a chip dumper, register-level access helpers, EEPROM decoding scripts, and more. Based on patch by Michel (BusError). --- package/Config.in | 1 + package/i2c-tools/Config.in | 11 +++++++ package/i2c-tools/i2c-tools.mk | 53 ++++++++++++++++++++++++++++++++++ 3 files changed, 65 insertions(+) create mode 100644 package/i2c-tools/Config.in create mode 100644 package/i2c-tools/i2c-tools.mk diff --git a/package/Config.in b/package/Config.in index 34c0681623..ce4a6fbbb7 100644 --- a/package/Config.in +++ b/package/Config.in @@ -258,6 +258,7 @@ source "package/hdparm/Config.in" source "package/hotplug/Config.in" endif source "package/hwdata/Config.in" +source "package/i2c-tools/Config.in" source "package/input-tools/Config.in" source "package/iostat/Config.in" source "package/libaio/Config.in" diff --git a/package/i2c-tools/Config.in b/package/i2c-tools/Config.in new file mode 100644 index 0000000000..a8df197d00 --- /dev/null +++ b/package/i2c-tools/Config.in @@ -0,0 +1,11 @@ +config BR2_PACKAGE_I2C_TOOLS + bool "i2c-tools" + default n + help + Heterogeneous set of I2C tools for Linux + + This package contains a heterogeneous set of I2C tools for Linux: + a bus probing tool, a chip dumper, register-level access helpers, + EEPROM decoding scripts, and more. + + http://www.lm-sensors.org diff --git a/package/i2c-tools/i2c-tools.mk b/package/i2c-tools/i2c-tools.mk new file mode 100644 index 0000000000..76c2d7a50d --- /dev/null +++ b/package/i2c-tools/i2c-tools.mk @@ -0,0 +1,53 @@ +############################################################# +# +# i2c-tools +# +############################################################# +I2C_TOOLS_VERSION:=3.0.1 +I2C_TOOLS_SOURCE:=i2c-tools-$(I2C_TOOLS_VERSION).tar.bz2 +I2C_TOOLS_SITE:=http://dl.lm-sensors.org/i2c-tools/releases/ +I2C_TOOLS_DIR:=$(BUILD_DIR)/i2c-tools-$(I2C_TOOLS_VERSION) +I2C_TOOLS_BINARY:=tools/i2cdetect +I2C_TOOLS_TARGET_BINARY:=usr/bin/i2cdetect + +$(DL_DIR)/$(I2C_TOOLS_SOURCE): + $(WGET) -P $(DL_DIR) $(I2C_TOOLS_SITE)/$(I2C_TOOLS_SOURCE) + +$(I2C_TOOLS_DIR)/.unpacked: $(DL_DIR)/$(I2C_TOOLS_SOURCE) + $(BZCAT) $(DL_DIR)/$(I2C_TOOLS_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) - + toolchain/patch-kernel.sh $(I2C_TOOLS_DIR) package/i2c-tools/ i2c-tools-$(I2C_TOOLS_VERSION)\*.patch + touch $@ + +$(I2C_TOOLS_DIR)/$(I2C_TOOLS_BINARY): $(I2C_TOOLS_DIR)/.unpacked + $(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(I2C_TOOLS_DIR) + +$(TARGET_DIR)/$(I2C_TOOLS_TARGET_BINARY): $(I2C_TOOLS_DIR)/$(I2C_TOOLS_BINARY) + $(INSTALL) -m 755 -d $(@D) + for i in i2cdump i2cget i2cset i2cdetect; \ + do \ + $(INSTALL) -m 755 $(