300f9c9c9d
Thanks to the pkgparentdir and pkgname functions, we can rewrite the AUTOTARGETS macro in a way that avoids the need for each package to repeat its name and the directory in which it is present. [Peter: pkgdir->pkgparentdir] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
27 lines
682 B
Makefile
27 lines
682 B
Makefile
#############################################################
|
|
#
|
|
# nbd
|
|
#
|
|
#############################################################
|
|
|
|
NBD_VERSION = 2.9.15
|
|
NBD_SOURCE = nbd-$(NBD_VERSION).tar.bz2
|
|
NBD_SITE=http://$(BR2_SOURCEFORGE_MIRROR).dl.sourceforge.net/sourceforge/nbd/
|
|
NBD_CONF_OPT = $(if $(BR2_LARGEFILE),--enable-lfs,--disable-lfs)
|
|
NBD_DEPENDENCIES = libglib2
|
|
|
|
ifneq ($(BR2_NBD_CLIENT),y)
|
|
NBD_TOREMOVE += nbd-client
|
|
endif
|
|
ifneq ($(BR2_NBD_SERVER),y)
|
|
NBD_TOREMOVE += nbd-server
|
|
endif
|
|
|
|
define NBD_CLEANUP_AFTER_INSTALL
|
|
rm -f $(addprefix $(TARGET_DIR)/usr/sbin/, $(NBD_TOREMOVE))
|
|
endef
|
|
|
|
NBD_POST_INSTALL_TARGET_HOOKS += NBD_CLEANUP_AFTER_INSTALL
|
|
|
|
$(eval $(call AUTOTARGETS))
|