diff options
author | Peter Korsgaard <jacmet@sunsite.dk> | 2008-04-18 13:54:50 +0000 |
---|---|---|
committer | Peter Korsgaard <jacmet@sunsite.dk> | 2008-04-18 13:54:50 +0000 |
commit | ab954a6ce65db14ab677c7442d2ecfb89a2f0650 (patch) | |
tree | 9ed5d886fb71191848ae5481afc02d4134bfdfd0 /package | |
parent | c326efd9872c7516af58d6721ad34d52970b1a37 (diff) |
buildroot: devmem2 package
Diffstat (limited to 'package')
-rw-r--r-- | package/Config.in | 1 | ||||
-rw-r--r-- | package/devmem2/Config.in | 7 | ||||
-rw-r--r-- | package/devmem2/devmem2.mk | 42 |
3 files changed, 50 insertions, 0 deletions
diff --git a/package/Config.in b/package/Config.in index dd27e7dc1..c3f9e86dd 100644 --- a/package/Config.in +++ b/package/Config.in @@ -235,6 +235,7 @@ menuconfig BR2_BLOCKDEV_SUPPORT if BR2_BLOCKDEV_SUPPORT source "package/acpid/Config.in" +source "package/devmem2/Config.in" source "package/dbus/Config.in" source "package/dbus-glib/Config.in" source "package/dm/Config.in" diff --git a/package/devmem2/Config.in b/package/devmem2/Config.in new file mode 100644 index 000000000..30bf73f63 --- /dev/null +++ b/package/devmem2/Config.in @@ -0,0 +1,7 @@ +config BR2_PACKAGE_DEVMEM2 + bool "devmem2" + default n + help + Simple program to read/write from/to any location in memory. + + http://free-electrons.com/pub/mirror/devmem2.c diff --git a/package/devmem2/devmem2.mk b/package/devmem2/devmem2.mk new file mode 100644 index 000000000..cce6ad538 --- /dev/null +++ b/package/devmem2/devmem2.mk @@ -0,0 +1,42 @@ +############################################################# +# +# devmem2 +# +############################################################# + +DEVMEM2_SOURCE:=devmem2.c +DEVMEM2_SITE:=http://free-electrons.com/pub/mirror +DEVMEM2_BINARY:=devmem2 +DEVMEM2_DIR:=$(BUILD_DIR)/devmem2 + +$(DL_DIR)/$(DEVMEM2_SOURCE): + $(WGET) -P $(DL_DIR) $(DEVMEM2_SITE)/$(DEVMEM2_SOURCE) + +$(DEVMEM2_DIR)/$(DEVMEM2_SOURCE): $(DL_DIR)/$(DEVMEM2_SOURCE) + mkdir -p $(@D) + cp $^ $@ + +$(DEVMEM2_DIR)/$(DEVMEM2_BINARY): $(DEVMEM2_DIR)/$(DEVMEM2_SOURCE) + $(TARGET_CC) $(TARGET_CFLAGS) -o $@ $^ + +$(TARGET_DIR)/sbin/$(DEVMEM2_BINARY): $(DEVMEM2_DIR)/$(DEVMEM2_BINARY) + cp $^ $@ + $(STRIPCMD) $(STRIP_STRIP_UNNEEDED) $@ + +devmem2: uclibc $(TARGET_DIR)/sbin/$(DEVMEM2_BINARY) + +devmem2-source: $(DL_DIR)/$(DEVMEM2_SOURCE) + +devmem2-clean: + rm -f $(TARGET_DIR/sbin/$(DEVMEM2_BINARY) + +devmem2-dirclean: + rm -rf $(DEVMEM2_DIR) +############################################################# +# +# Toplevel Makefile options +# +############################################################# +ifeq ($(strip $(BR2_PACKAGE_DEVMEM2)),y) +TARGETS+=devmem2 +endif |