2 # Copyright (C) 2007-2015 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
14 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.xz
15 PKG_SOURCE_URL
:=@KERNEL
/linux
/utils
/$(PKG_NAME
)/v2.29
16 PKG_HASH
:=accea4d678209f97f634f40a93b7e9fcad5915d1f4749f6c47bee6bf110fe8e3
19 PKG_LICENSE_FILES
:= COPYING \
23 Documentation
/licenses
/COPYING.GPLv2 \
24 Documentation
/licenses
/COPYING.LGPLv2.1 \
26 Documentation
/licenses
/COPYING.BSD-3
33 include $(INCLUDE_DIR
)/package.mk
35 define Package
/util-linux
/Default
39 URL
:=http
://www.kernel.org
/pub
/linux
/utils
/util-linux
/
42 define Package
/libblkid
43 $(call Package
/util-linux
/Default
)
45 TITLE
:=block device id library
50 define Package
/libblkid
/description
51 The libblkid library is used to identify block devices
(disks
) as to their
52 content
(e.g. filesystem type
, partitions
) as well
as extracting additional
53 information such
as filesystem labels
/volume names
, partitions
, unique
54 identifiers
/serial numbers...
57 define Package
/libfdisk
58 $(call Package
/util-linux
/Default
)
59 DEPENDS
:=+libuuid
+libblkid
60 TITLE
:=partition manipulating library
65 define Package
/libfdisk
/description
66 The libfdisk library is used for manipulating with partition tables.
69 define Package
/libmount
70 $(call Package
/util-linux
/Default
)
77 define Package
/libmount
/description
78 The libmount library is used to parse
/etc
/fstab
, /etc
/mtab and
79 /proc
/self
/mountinfo files
, manage the mtab file
, evaluate mount options...
82 define Package
/libuuid
83 $(call Package
/util-linux
/Default
)
84 TITLE
:=DCE compatible Universally Unique Identifier library
89 define Package
/libuuid
/description
90 The UUID library is used to generate unique identifiers for objects
91 that may be accessible beyond the local system. This library
92 generates UUIDs compatible with those created by the Open Software
93 Foundation
(OSF
) Distributed Computing Environment
(DCE
) utility.
96 define Package
/libsmartcols
97 $(call Package
/util-linux
/Default
)
98 TITLE
:=table or tree library
103 define Package
/libsmartcols
/description
104 The smartcols library is used to
print tables and trees in a pretty way.
107 define Package
/agetty
108 $(call Package
/util-linux
/Default
)
109 TITLE
:=alternative Linux getty
113 define Package
/agetty
/description
114 agetty opens a tty port
, prompts for a login name and invokes the
118 define Package
/blkdiscard
119 $(call Package
/util-linux
/Default
)
120 TITLE
:=discard sectors on a device
124 define Package
/blkdiscard
/description
125 The blkdiscard is used to discard device sectors. This is useful for
126 solid-state drivers
(SSDs
) and thinly-provisioned storage. Unlike fstrim
,
127 this command is used directly on the block device.
131 $(call Package
/util-linux
/Default
)
132 TITLE
:=locate and
print block device attributes
133 DEPENDS
:= +libblkid
+libuuid
137 define Package
/blkid
/description
138 The blkid program is the command-line interface to working with the libblkid
143 $(call Package
/util-linux
/Default
)
144 TITLE
:=display a calendar
145 DEPENDS
:= +libncurses
148 define Package
/cal
/description
149 cal displays a simple calendar
152 define Package
/cfdisk
153 $(call Package
/util-linux
/Default
)
154 TITLE
:=display or manipulate disk partition table
155 DEPENDS
:= +libblkid
+libncurses
+libsmartcols
+libfdisk
+libmount
159 define Package
/cfdisk
/description
160 cfdisk is a curses-based program for partitioning any hard disk drive
164 $(call Package
/util-linux
/Default
)
165 TITLE
:=print or control the kernel ring buffer
168 define Package
/dmesg
/description
169 dmesg is used to examine or control the kernel ring buffer
173 $(call Package
/util-linux
/Default
)
174 TITLE
:=manipulate disk partition table
175 DEPENDS
:= +libblkid
+libsmartcols
+libfdisk
179 define Package
/fdisk
/description
180 a menu-driven program for creation and manipulation of partition tables
183 define Package
/findfs
184 $(call Package
/util-linux
/Default
)
185 TITLE
:=find a filesystem by label or UUID
190 define Package
/findfs
/description
191 findfs will search the disks in the system looking for a filesystem which has
192 a label matching label or a UUID equal to uuid
196 $(call Package
/util-linux
/Default
)
197 TITLE
:=manage locks from
shell scripts
200 define Package
/flock
/description
201 manages flock locks from within
shell scripts or the command line
204 define Package
/getopt
205 $(call Package
/util-linux
/Default
)
206 TITLE
:=parse command options
(enhanced
)
209 define Package
/getopt
/description
210 getopt is used to break up
(parse
) options in command lines for easy parsing
211 by
shell procedures
, and to
check for legal options
214 define Package
/hwclock
215 $(call Package
/util-linux
/Default
)
216 TITLE
:=query or set the hardware clock
219 define Package
/hwclock
/description
220 hwclock is a tool for accessing the Hardware Clock
223 define Package
/logger
224 $(call Package
/util-linux
/Default
)
225 TITLE
:=a
shell command interface to the syslog system log module
228 define Package
/logger
/description
229 logger makes entries in the system log
, it provides a
shell command interface
230 to the syslog system log module
234 $(call Package
/util-linux
/Default
)
235 TITLE
:=display lines beginning with a given string
238 define Package
/look
/description
239 look utility displays any lines in file which contain string
242 define Package
/losetup
243 $(call Package
/util-linux
/Default
)
244 TITLE
:=set up and control loop devices
245 DEPENDS
:= +libsmartcols
248 define Package
/losetup
/description
249 losetup is used to associate loop devices with regular files or block devices
,
250 to detach loop devices and to query the status of a loop device
254 $(call Package
/util-linux
/Default
)
255 TITLE
:=list block devices
256 DEPENDS
:= +libblkid
+libmount
+libsmartcols
260 define Package
/lsblk
/description
261 lsblk lists information about
all or the specified block devices
264 define Package
/mcookie
265 $(call Package
/util-linux
/Default
)
266 TITLE
:=generate magic cookies for xauth
269 define Package
/mcookie
/description
270 mcookie generates a
128-bit random hexadecimal number for use with the X
274 define Package
/mount-utils
275 $(call Package
/util-linux
/Default
)
276 TITLE
:=related
(u
)mount utilities
277 DEPENDS
+= +libmount
+libsmartcols
280 define Package
/mount-utils
/description
281 contains
: mount
, umount
, findmnt
285 $(call Package
/util-linux
/Default
)
286 TITLE
:=follow a pathname until a terminal point is found
289 define Package
/namei
/description
290 namei uses its arguments
as pathnames to any type of Unix file
(symlinks
,
291 files
, directories
, and so forth
)
294 define Package
/prlimit
295 $(call Package
/util-linux
/Default
)
296 TITLE
:=get and set process resource limits
297 DEPENDS
:= +libsmartcols
300 define Package
/prlimit
/description
301 Given a process id and one or more resources
, prlimit tries to retrieve
302 and
/or modify the limits.
305 define Package
/rename
306 $(call Package
/util-linux
/Default
)
310 define Package
/rename
/description
311 rename will rename the specified files by replacing the first occurrence of
312 expression in their name by replacement
315 define Package
/partx-utils
316 $(call Package
/util-linux
/Default
)
317 TITLE
:=inform kernel about the presence and numbering of on-disk partitions
318 DEPENDS
:= +libblkid
+libsmartcols
322 define Package
/partx-utils
/description
323 contains partx
, addpart
, delpart
326 define Package
/script-utils
327 $(call Package
/util-linux
/Default
)
328 TITLE
:=make and replay typescript of terminal session
332 define Package
/script-utils
/description
333 contains
: script
, scriptreplay
336 define Package
/setterm
337 $(call Package
/util-linux
/Default
)
338 TITLE
:=set terminal attributes
339 DEPENDS
:= +libncurses
343 define Package
/setterm
/description
344 setterm writes to standard output a character string that will invoke the
345 specified terminal capabilities
348 define Package
/sfdisk
349 $(call Package
/util-linux
/Default
)
350 TITLE
:=partition table manipulator for Linux
352 DEPENDS
:= +libblkid
+libfdisk
+libsmartcols
355 define Package
/sfdisk
/description
356 list the size of a partition
, list the partitions on a device
, check the
357 partitions on a device and repartition a device
360 define Package
/swap-utils
361 $(call Package
/util-linux
/Default
)
362 TITLE
:=swap space management utilities
367 define Package
/swap-utils
/description
368 contains
: mkswap
, swaplabel
372 $(call Package
/util-linux
/Default
)
373 TITLE
:=UUID generation daemon
377 define Package
/uuidd
/description
378 The uuidd daemon is used by the UUID library to generate universally unique
379 identifiers
(UUIDs
), especially time-based UUIDs
, in a secure and
380 guaranteed-unique fashion
, even in the face of large numbers of threads
381 running on different CPUs trying to grab UUIDs.
384 define Package
/uuidgen
385 $(call Package
/util-linux
/Default
)
386 TITLE
:=create a new UUID value
390 define Package
/uuidgen
/description
391 The uuidgen program creates
(and prints
) a new universally unique identifier
392 (UUID
) using the libuuid library. The new UUID can reasonably be considered
393 unique among
all UUIDs created on the local system
, and among UUIDs created on
394 other systems in the past and in the future.
398 $(call Package
/util-linux
/Default
)
399 TITLE
:=send a message to everybody
's terminal
403 define Package/wall/description
404 wall sends a message to everybody logged in with their mesg permission
408 define Package/whereis
409 $(call Package/util-linux/Default)
410 TITLE:=locate the binary, source, and manual page files for a command
413 define Package/whereis/description
414 whereis locates source/binary and manuals sections for specified files
417 define Package/wipefs
418 $(call Package/util-linux/Default)
419 TITLE:=wipe a signature from a device
424 define Package/wipefs/description
425 wipefs can erase filesystem, raid or partition table signatures (magic
426 strings) from the specified device to make the signature invisible for
431 --disable-use-tty-group \
441 TARGET_CFLAGS += $(FPIC) -std=gnu99
443 define Build/InstallDev
444 $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
445 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/blkid.pc $(1)/usr/lib/pkgconfig
446 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/fdisk.pc $(1)/usr/lib/pkgconfig
447 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/mount.pc $(1)/usr/lib/pkgconfig
448 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/smartcols.pc $(1)/usr/lib/pkgconfig
449 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/uuid.pc $(1)/usr/lib/pkgconfig
451 $(INSTALL_DIR) $(1)/usr/include/blkid
452 $(CP) $(PKG_INSTALL_DIR)/usr/include/blkid/blkid.h $(1)/usr/include/blkid
453 $(INSTALL_DIR) $(1)/usr/include/libfdisk
454 $(CP) $(PKG_INSTALL_DIR)/usr/include/libfdisk/libfdisk.h $(1)/usr/include/libfdisk
455 $(INSTALL_DIR) $(1)/usr/include/libmount
456 $(CP) $(PKG_INSTALL_DIR)/usr/include/libmount/libmount.h $(1)/usr/include/libmount
457 $(INSTALL_DIR) $(1)/usr/include/uuid
458 $(CP) $(PKG_INSTALL_DIR)/usr/include/uuid/uuid.h $(1)/usr/include/uuid
459 $(INSTALL_DIR) $(1)/usr/include/libsmartcols
460 $(CP) $(PKG_INSTALL_DIR)/usr/include/libsmartcols/libsmartcols.h $(1)/usr/include/libsmartcols
462 $(INSTALL_DIR) $(1)/usr/lib
463 $(CP) $(PKG_INSTALL_DIR)/lib/libblkid.so* $(1)/usr/lib
464 $(CP) $(PKG_INSTALL_DIR)/lib/libfdisk.so* $(1)/usr/lib
465 $(CP) $(PKG_INSTALL_DIR)/lib/libmount.so* $(1)/usr/lib
466 $(CP) $(PKG_INSTALL_DIR)/lib/libuuid.so* $(1)/usr/lib
467 $(CP) $(PKG_INSTALL_DIR)/lib/libsmartcols.so* $(1)/usr/lib
469 $(LN) libblkid.so.1 $(1)/usr/lib/libblkid.so
470 $(LN) libfdisk.so.1 $(1)/usr/lib/libfdisk.so
471 $(LN) libmount.so.1 $(1)/usr/lib/libmount.so
472 $(LN) libuuid.so.1 $(1)/usr/lib/libuuid.so
473 $(LN) libsmartcols.so.1 $(1)/usr/lib/libsmartcols.so
477 define Package/libfdisk/install
478 $(INSTALL_DIR) $(1)/usr/lib
479 $(CP) $(PKG_INSTALL_DIR)/lib/libfdisk.so* $(1)/usr/lib/
480 $(LN) libfdisk.so.1 $(1)/usr/lib/libfdisk.so
483 define Package/libblkid/install
484 $(INSTALL_DIR) $(1)/usr/lib
485 $(CP) $(PKG_INSTALL_DIR)/lib/libblkid.so* $(1)/usr/lib/
486 $(LN) libblkid.so.1 $(1)/usr/lib/libblkid.so
489 define Package/libmount/install
490 $(INSTALL_DIR) $(1)/usr/lib
491 $(CP) $(PKG_INSTALL_DIR)/lib/libmount.so* $(1)/usr/lib/
492 $(LN) libmount.so.1 $(1)/usr/lib/libmount.so
495 define Package/libsmartcols/install
496 $(INSTALL_DIR) $(1)/usr/lib
497 $(CP) $(PKG_INSTALL_DIR)/lib/libsmartcols.so* $(1)/usr/lib/
498 $(LN) libsmartcols.so.1 $(1)/usr/lib/libsmartcols.so
501 define Package/libuuid/install
502 $(INSTALL_DIR) $(1)/usr/lib
503 $(CP) $(PKG_INSTALL_DIR)/lib/libuuid.so* $(1)/usr/lib/
504 $(LN) libuuid.so.1 $(1)/usr/lib/libuuid.so
507 define Package/agetty/install
508 $(INSTALL_DIR) $(1)/usr/sbin
509 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/agetty $(1)/usr/sbin/
512 define Package/blkdiscard/install
513 $(INSTALL_DIR) $(1)/usr/sbin
514 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/blkdiscard $(1)/usr/sbin/
517 define Package/blkid/install
518 $(INSTALL_DIR) $(1)/usr/sbin
519 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/blkid $(1)/usr/sbin/
522 define Package/cal/install
523 $(INSTALL_DIR) $(1)/usr/bin
524 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/cal $(1)/usr/bin/
527 define Package/cfdisk/install
528 $(INSTALL_DIR) $(1)/usr/sbin
529 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/cfdisk $(1)/usr/sbin/
532 define Package/dmesg/install
533 $(INSTALL_DIR) $(1)/usr/bin
534 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/dmesg $(1)/usr/bin/
537 define Package/fdisk/install
538 $(INSTALL_DIR) $(1)/usr/sbin
539 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/fdisk $(1)/usr/sbin/
542 define Package/findfs/install
543 $(INSTALL_DIR) $(1)/usr/sbin
544 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/findfs $(1)/usr/sbin/
547 define Package/flock/install
548 $(INSTALL_DIR) $(1)/usr/bin
549 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/flock $(1)/usr/bin/
552 define Package/getopt/install
553 $(INSTALL_DIR) $(1)/usr/bin
554 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/getopt $(1)/usr/bin/
557 define Package/hwclock/install
558 $(INSTALL_DIR) $(1)/usr/sbin
559 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/hwclock $(1)/usr/sbin/
562 define Package/logger/install
563 $(INSTALL_DIR) $(1)/usr/bin
564 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/logger $(1)/usr/bin/
567 define Package/look/install
568 $(INSTALL_DIR) $(1)/usr/bin
569 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/look $(1)/usr/bin/
572 define Package/losetup/install
573 $(INSTALL_DIR) $(1)/usr/sbin
574 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/losetup $(1)/usr/sbin/
577 define Package/lsblk/install
578 $(INSTALL_DIR) $(1)/usr/bin
579 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/lsblk $(1)/usr/bin/
582 define Package/mcookie/install
583 $(INSTALL_DIR) $(1)/usr/bin
584 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/mcookie $(1)/usr/bin/
587 define Package/mount-utils/install
588 $(INSTALL_DIR) $(1)/usr/bin
589 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/{u,}mount $(1)/usr/bin/
590 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/mountpoint $(1)/usr/bin/
591 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/findmnt $(1)/usr/bin/
594 define Package/namei/install
595 $(INSTALL_DIR) $(1)/usr/bin
596 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/namei $(1)/usr/bin/
599 define Package/prlimit/install
600 $(INSTALL_DIR) $(1)/usr/bin
601 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/prlimit $(1)/usr/bin/
604 define Package/rename/install
605 $(INSTALL_DIR) $(1)/usr/bin
606 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/rename $(1)/usr/bin/
609 define Package/partx-utils/install
610 $(INSTALL_DIR) $(1)/usr/sbin
611 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/partx $(1)/usr/sbin/
612 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/addpart $(1)/usr/sbin/
613 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/delpart $(1)/usr/sbin/
616 define Package/script-utils/install
617 $(INSTALL_DIR) $(1)/usr/bin
618 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/script $(1)/usr/bin/
619 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/scriptreplay $(1)/usr/bin/
622 define Package/setterm/install
623 $(INSTALL_DIR) $(1)/usr/bin
624 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/setterm $(1)/usr/bin/
627 define Package/sfdisk/install
628 $(INSTALL_DIR) $(1)/usr/sbin
629 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/sfdisk $(1)/usr/sbin/
632 define Package/swap-utils/install
633 $(INSTALL_DIR) $(1)/usr/sbin
634 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/mkswap $(1)/usr/sbin/
635 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/swaplabel $(1)/usr/sbin/
638 define Package/uuidd/install
639 $(INSTALL_DIR) $(1)/usr/sbin
640 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin//uuidd $(1)/usr/sbin/
643 define Package/uuidgen/install
644 $(INSTALL_DIR) $(1)/usr/bin
645 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin//uuidgen $(1)/usr/bin/
648 define Package/wall/install
649 $(INSTALL_DIR) $(1)/usr/bin
650 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/wall $(1)/usr/bin/
653 define Package/whereis/install
654 $(INSTALL_DIR) $(1)/usr/bin
655 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/whereis $(1)/usr/bin/
658 define Package/wipefs/install
659 $(INSTALL_DIR) $(1)/usr/sbin
660 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/wipefs $(1)/usr/sbin/
663 $(eval $(call BuildPackage,libblkid))
664 $(eval $(call BuildPackage,libfdisk))
665 $(eval $(call BuildPackage,libmount))
666 $(eval $(call BuildPackage,libsmartcols))
667 $(eval $(call BuildPackage,libuuid))
668 $(eval $(call BuildPackage,agetty))
669 $(eval $(call BuildPackage,blkdiscard))
670 $(eval $(call BuildPackage,blkid))
671 $(eval $(call BuildPackage,cal))
672 $(eval $(call BuildPackage,cfdisk))
673 $(eval $(call BuildPackage,dmesg))
674 $(eval $(call BuildPackage,fdisk))
675 $(eval $(call BuildPackage,findfs))
676 $(eval $(call BuildPackage,flock))
677 $(eval $(call BuildPackage,getopt))
678 $(eval $(call BuildPackage,hwclock))
679 $(eval $(call BuildPackage,logger))
680 $(eval $(call BuildPackage,look))
681 $(eval $(call BuildPackage,losetup))
682 $(eval $(call BuildPackage,lsblk))
683 $(eval $(call BuildPackage,mcookie))
684 $(eval $(call BuildPackage,mount-utils))
685 $(eval $(call BuildPackage,namei))
686 $(eval $(call BuildPackage,prlimit))
687 $(eval $(call BuildPackage,rename))
688 $(eval $(call BuildPackage,partx-utils))
689 $(eval $(call BuildPackage,script-utils))
690 $(eval $(call BuildPackage,setterm))
691 $(eval $(call BuildPackage,sfdisk))
692 $(eval $(call BuildPackage,swap-utils))
693 $(eval $(call BuildPackage,uuidd))
694 $(eval $(call BuildPackage,uuidgen))
695 $(eval $(call BuildPackage,wall))
696 $(eval $(call BuildPackage,whereis))
697 $(eval $(call BuildPackage,wipefs))