dosfstools.mk 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. ################################################################################
  2. #
  3. # dosfstools
  4. #
  5. ################################################################################
  6. DOSFSTOOLS_VERSION = 4.1
  7. DOSFSTOOLS_SOURCE = dosfstools-$(DOSFSTOOLS_VERSION).tar.xz
  8. DOSFSTOOLS_SITE = https://github.com/dosfstools/dosfstools/releases/download/v$(DOSFSTOOLS_VERSION)
  9. DOSFSTOOLS_LICENSE = GPL-3.0+
  10. DOSFSTOOLS_LICENSE_FILES = COPYING
  11. DOSFSTOOLS_CONF_OPTS = --enable-compat-symlinks --exec-prefix=/
  12. HOST_DOSFSTOOLS_CONF_OPTS = --enable-compat-symlinks
  13. ifeq ($(BR2_PACKAGE_HAS_UDEV),y)
  14. DOSFSTOOLS_CONF_OPTS += --with-udev
  15. DOSFSTOOLS_DEPENDENCIES += udev
  16. else
  17. DOSFSTOOLS_CONF_OPTS += --without-udev
  18. endif
  19. ifneq ($(BR2_ENABLE_LOCALE),y)
  20. DOSFSTOOLS_CONF_OPTS += LIBS="-liconv"
  21. DOSFSTOOLS_DEPENDENCIES += libiconv
  22. endif
  23. ifeq ($(BR2_PACKAGE_DOSFSTOOLS_FATLABEL),y)
  24. define DOSFSTOOLS_INSTALL_FATLABEL
  25. $(INSTALL) -D -m 0755 $(@D)/src/fatlabel $(TARGET_DIR)/sbin/fatlabel
  26. ln -sf fatlabel $(TARGET_DIR)/sbin/dosfslabel
  27. endef
  28. endif
  29. ifeq ($(BR2_PACKAGE_DOSFSTOOLS_FSCK_FAT),y)
  30. define DOSFSTOOLS_INSTALL_FSCK_FAT
  31. $(INSTALL) -D -m 0755 $(@D)/src/fsck.fat $(TARGET_DIR)/sbin/fsck.fat
  32. ln -sf fsck.fat $(TARGET_DIR)/sbin/fsck.vfat
  33. ln -sf fsck.fat $(TARGET_DIR)/sbin/fsck.msdos
  34. ln -sf fsck.fat $(TARGET_DIR)/sbin/dosfsck
  35. endef
  36. endif
  37. ifeq ($(BR2_PACKAGE_DOSFSTOOLS_MKFS_FAT),y)
  38. define DOSFSTOOLS_INSTALL_MKFS_FAT
  39. $(INSTALL) -D -m 0755 $(@D)/src/mkfs.fat $(TARGET_DIR)/sbin/mkfs.fat
  40. ln -sf mkfs.fat $(TARGET_DIR)/sbin/mkdosfs
  41. ln -sf mkfs.fat $(TARGET_DIR)/sbin/mkfs.msdos
  42. ln -sf mkfs.fat $(TARGET_DIR)/sbin/mkfs.vfat
  43. endef
  44. endif
  45. define DOSFSTOOLS_INSTALL_TARGET_CMDS
  46. $(call DOSFSTOOLS_INSTALL_FATLABEL)
  47. $(call DOSFSTOOLS_INSTALL_FSCK_FAT)
  48. $(call DOSFSTOOLS_INSTALL_MKFS_FAT)
  49. endef
  50. $(eval $(autotools-package))
  51. $(eval $(host-autotools-package))