diff options
author | Eric Andersen <andersen@codepoet.org> | 2005-06-09 09:46:12 +0000 |
---|---|---|
committer | Eric Andersen <andersen@codepoet.org> | 2005-06-09 09:46:12 +0000 |
commit | d5b0e08e9dfec6bdffca4b909f8188a40c541d21 (patch) | |
tree | 0e15837a935e3762fdb02ce63001804d8fd5530f /package/modutils/modutils.mk | |
parent | 8d1ce2a787e196bac5a65b783f6202500eb2abef (diff) | |
download | buildroot-novena-d5b0e08e9dfec6bdffca4b909f8188a40c541d21.tar.gz buildroot-novena-d5b0e08e9dfec6bdffca4b909f8188a40c541d21.zip |
http://bugs.uclibc.org/view.php?id=178
This patch provides modutils and module-init-tools. I know busybox can load
modules, but modinfo may also be very useful for kernel/driver debugging
purposes.
I have managed binaries concurrency between modutils and module-init-tools, but
I'm not sure this is the best way to do it...
Thanks for your work.
Diffstat (limited to 'package/modutils/modutils.mk')
-rw-r--r-- | package/modutils/modutils.mk | 62 |
1 files changed, 62 insertions, 0 deletions
diff --git a/package/modutils/modutils.mk b/package/modutils/modutils.mk new file mode 100644 index 000000000..01a55530d --- /dev/null +++ b/package/modutils/modutils.mk @@ -0,0 +1,62 @@ +############################################################# +# +# modutils +# +############################################################# +MODUTILS_SOURCE=modutils-2.4.27.tar.bz2 +MODUTILS_SITE=ftp://ftp.kernel.org/pub/linux/utils/kernel/modutils/v2.4/ +MODUTILS_DIR=$(BUILD_DIR)/modutils-2.4.27 +MODUTILS_BINARY=insmod +MODUTILS_TARGET_BINARY=$(TARGET_DIR)/sbin/$(MODUTILS_BINARY) + +STRIPPROG=$(STRIP) + +$(DL_DIR)/$(MODUTILS_SOURCE): + $(WGET) -P $(DL_DIR) $(MODUTILS_SITE)/$(MODUTILS_SOURCE) + +$(MODUTILS_DIR)/.source: $(DL_DIR)/$(MODUTILS_SOURCE) + bzcat $(DL_DIR)/$(MODUTILS_SOURCE) | tar -C $(BUILD_DIR) -xvf - + toolchain/patch-kernel.sh $(MODUTILS_DIR) \ + package/modutils \*.patch + touch $(MODUTILS_DIR)/.source + +$(MODUTILS_DIR)/.configured: $(MODUTILS_DIR)/.source + (cd $(MODUTILS_DIR); \ + $(TARGET_CONFIGURE_OPTS) \ + INSTALL=$(MODUTILS_DIR)/install-sh \ + ./configure \ + --target=$(GNU_TARGET_NAME) \ + --host=$(GNU_TARGET_NAME) \ + --build=$(GNU_HOST_NAME) \ + --prefix=/ \ + --sysconfdir=/etc \ + ); + touch $(MODUTILS_DIR)/.configured; + +$(MODUTILS_DIR)/$(MODUTILS_BINARY): $(MODUTILS_DIR)/.configured + $(MAKE) CC=$(TARGET_CC) -C $(MODUTILS_DIR) + +$(TARGET_DIR)/$(MODUTILS_TARGET_BINARY): $(MODUTILS_DIR)/$(MODUTILS_BINARY) + STRIPPROG='$(STRIPPROG)' \ + $(MAKE) prefix=$(TARGET_DIR) -C $(MODUTILS_DIR) install-bin + rm -Rf $(TARGET_DIR)/usr/man + +modutils: uclibc $(TARGET_DIR)/$(MODUTILS_TARGET_BINARY) + +modutils-source: $(DL_DIR)/$(MODUTILS_SOURCE) + +modutils-clean: + $(MAKE) prefix=$(TARGET_DIR)/usr -C $(MODUTILS_DIR) uninstall + -$(MAKE) -C $(MODUTILS_DIR) clean + +modutils-dirclean: + rm -rf $(MODUTILS_DIR) + +############################################################# +# +## Toplevel Makefile options +# +############################################################## +ifeq ($(strip $(BR2_PACKAGE_MODUTILS)),y) +TARGETS+=modutils +endif |