Makefile 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132
  1. # This file is part of the OpenADK project. OpenADK is copyrighted
  2. # material, please see the LICENCE file in the top-level directory.
  3. include ${ADK_TOPDIR}/rules.mk
  4. PKG_NAME:= util-linux
  5. PKG_VERSION:= 2.25.2
  6. PKG_RELEASE:= 3
  7. PKG_HASH:= e0457f715b73f4a349e1acb08cb410bf0edc9a74a3f75c357070f31f70e33cd6
  8. PKG_DESCR:= basic utilities
  9. PKG_SECTION:= base/apps
  10. PKG_BUILDDEP:= ncurses pam
  11. PKG_SITES:= http://www.kernel.org/pub/linux/utils/util-linux/v2.25/
  12. PKG_OPTS:= dev
  13. PKG_SUBPKGS:= FDISK SFDISK SWAP_UTILS LOSETUP MCOOKIE MOUNT
  14. PKG_SUBPKGS+= LIBUUID LIBBLKID LIBMOUNT SU CFDISK MKFS
  15. PKGSD_LIBUUID:= uuid library
  16. PKGSC_LIBUUID:= libs/misc
  17. PKGSD_LIBBLKID:= blkid library
  18. PKGSC_LIBBLKID:= libs/misc
  19. PKGSD_LIBMOUNT:= mount library
  20. PKGSC_LIBMOUNT:= libs/misc
  21. PKGSD_FDISK:= partition table manipulation utility
  22. PKGSC_FDISK:= sys/fs
  23. PKGSD_SFDISK:= scriptable partition table manipulation utility
  24. PKGSC_SFDISK:= sys/fs
  25. PKGSD_CFDISK:= partition table manipulation utility
  26. PKGSC_CFDISK:= sys/fs
  27. PKGSD_SU:= switch user utility
  28. PKGSC_SU:= sys/misc
  29. PKGSD_SWAP_UTILS:= swap space management utilities
  30. PKGSS_SWAP_UTILS:= libblkid
  31. PKGSC_SWAP_UTILS:= sys/fs
  32. PKGSD_LOSETUP:= loop devices management utilities
  33. PKGSC_LOSETUP:= sys/fs
  34. PKGSD_MKFS:= filesystem creation frontend
  35. PKGSC_MKFS:= sys/fs
  36. PKGSD_MOUNT:= mount/umount utilities
  37. PKGSS_MOUNT:= libblkid libmount libuuid libncurses
  38. PKGSC_MOUNT:= sys/fs
  39. PKGSD_MCOOKIE:= generate magic cookies for xauth
  40. PKGSC_MCOOKIE:= x11/utils
  41. include ${ADK_TOPDIR}/mk/package.mk
  42. $(eval $(call PKG_template,FDISK,fdisk,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKGSD_FDISK},${PKGSC_FDISK}))
  43. $(eval $(call PKG_template,CFDISK,cfdisk,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKGSD_CFDISK},${PKGSC_CFDISK}))
  44. $(eval $(call PKG_template,SFDISK,sfdisk,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKGSD_SFDISK},${PKGSC_SFDISK}))
  45. $(eval $(call PKG_template,SU,su,${PKG_VERSION}-${PKG_RELEASE},${PKGSS_SU},${PKGSD_SU},${PKGSC_SU}))
  46. $(eval $(call PKG_template,SWAP_UTILS,swap-utils,${PKG_VERSION}-${PKG_RELEASE},${PKGSS_SWAP_UTILS},${PKGSD_SWAP_UTILS},${PKGSC_SWAP_UTILS}))
  47. $(eval $(call PKG_template,LOSETUP,losetup,${PKG_VERSION}-${PKG_RELEASE},${PKGSS_LOSETUP},${PKGSD_LOSETUP},${PKGSC_LOSETUP}))
  48. $(eval $(call PKG_template,MKFS,mkfs,${PKG_VERSION}-${PKG_RELEASE},${PKGSS_MKFS},${PKGSD_MKFS},${PKGSC_MKFS}))
  49. $(eval $(call PKG_template,MOUNT,mount,${PKG_VERSION}-${PKG_RELEASE},${PKGSS_MOUNT},${PKGSD_MOUNT},${PKGSC_MOUNT}))
  50. $(eval $(call PKG_template,MCOOKIE,mcookie,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKGSD_MCOOKIE},${PKGSC_MCOOKIE}))
  51. $(eval $(call PKG_template,LIBUUID,libuuid,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKGSD_LIBUUID},${PKGSC_LIBUUID},${PKG_OPTS}))
  52. $(eval $(call PKG_template,LIBBLKID,libblkid,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKGSD_LIBBLKID},${PKGSC_LIBBLKID},${PKG_OPTS}))
  53. $(eval $(call PKG_template,LIBMOUNT,libmount,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKGSD_LIBMOUNT},${PKGSC_LIBMOUNT},${PKG_OPTS}))
  54. TARGET_CFLAGS+= -DSWAPON_HAS_TWO_ARGS -DHAVE_LLSEEK
  55. TARGET_LDFLAGS+= -ltinfo
  56. AUTOTOOL_STYLE:= autoreconf
  57. CONFIGURE_ENV+= have_scanf_alloc_modifier=yes \
  58. scanf_cv_alloc_modifier=ms
  59. ifeq ($(ADK_TARGET_USE_STATIC_LIBS),y)
  60. CONFIGURE_ARGS+= --disable-su
  61. CONFIGURE_ARGS+= --disable-runuser
  62. else
  63. CONFIGURE_ARGS+= --enable-su
  64. endif
  65. CONFIGURE_ARGS+= --disable-use-tty-group \
  66. --disable-schedutils \
  67. --disable-cramfs \
  68. --disable-login \
  69. --disable-eject \
  70. --without-python \
  71. --without-systemd \
  72. --without-user \
  73. --enable-libuuid \
  74. --enable-libblkid \
  75. --enable-libmount \
  76. --enable-mount
  77. FAKE_FLAGS+= INSTALLSUID="install -m 4755"
  78. fdisk-install:
  79. ${INSTALL_DIR} ${IDIR_FDISK}/usr/sbin
  80. ${CP} ${WRKINST}/usr/sbin/fdisk ${IDIR_FDISK}/usr/sbin
  81. cfdisk-install:
  82. ${INSTALL_DIR} ${IDIR_CFDISK}/usr/sbin
  83. ${CP} ${WRKINST}/usr/sbin/cfdisk ${IDIR_FDISK}/usr/sbin
  84. sfdisk-install:
  85. ${INSTALL_DIR} ${IDIR_SFDISK}/usr/sbin
  86. ${CP} ${WRKINST}/usr/sbin/sfdisk ${IDIR_SFDISK}/usr/sbin
  87. losetup-install:
  88. ${INSTALL_DIR} ${IDIR_LOSETUP}/usr/sbin
  89. ${CP} ${WRKINST}/usr/sbin/losetup ${IDIR_LOSETUP}/usr/sbin
  90. swap-utils-install:
  91. ${INSTALL_DIR} ${IDIR_SWAP_UTILS}/usr/sbin
  92. ${CP} ${WRKINST}/usr/sbin/mkswap ${IDIR_SWAP_UTILS}/usr/sbin
  93. ${CP} ${WRKINST}/usr/sbin/swap{on,off} ${IDIR_SWAP_UTILS}/usr/sbin
  94. mkfs-install:
  95. ${INSTALL_DIR} ${IDIR_MKFS}/usr/sbin
  96. ${INSTALL_BIN} ${WRKINST}/usr/sbin/mkfs ${IDIR_MKFS}/usr/sbin
  97. mount-install:
  98. ${INSTALL_DIR} ${IDIR_MOUNT}/bin
  99. ${INSTALL_BIN} ${WRKINST}/usr/bin/{u,}mount ${IDIR_MOUNT}/bin
  100. mcookie-install:
  101. ${INSTALL_DIR} ${IDIR_MCOOKIE}/usr/bin
  102. ${INSTALL_BIN} ${WRKINST}/usr/bin/mcookie ${IDIR_MCOOKIE}/usr/bin
  103. libuuid-install:
  104. ${INSTALL_DIR} ${IDIR_LIBUUID}/usr/lib
  105. ${CP} ${WRKINST}/usr/lib/libuuid.so* ${IDIR_LIBUUID}/usr/lib
  106. libblkid-install:
  107. ${INSTALL_DIR} ${IDIR_LIBBLKID}/usr/lib
  108. ${CP} ${WRKINST}/usr/lib/libblkid.so* ${IDIR_LIBBLKID}/usr/lib
  109. libmount-install:
  110. ${INSTALL_DIR} ${IDIR_LIBMOUNT}/usr/lib
  111. ${CP} ${WRKINST}/usr/lib/libmount.so* ${IDIR_LIBMOUNT}/usr/lib
  112. include ${ADK_TOPDIR}/mk/pkg-bottom.mk