1SUMMARY = "Utility for modifying GPT disk partitioning"
2DESCRIPTION = "GPT fdisk is a disk partitioning tool loosely modeled on Linux fdisk, but used for modifying GUID Partition Table (GPT) disks. The related FixParts utility fixes some common problems on Master Boot Record (MBR) disks."
3HOMEPAGE = "https://sourceforge.net/projects/gptfdisk/"
4
5LICENSE = "GPL-2.0-only"
6LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552"
7
8DEPENDS = "util-linux"
9
10SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${PV}/${BP}.tar.gz \
11           file://0001-gptcurses-correctly-include-curses.h.patch \
12           "
13SRC_URI[sha256sum] = "2abed61bc6d2b9ec498973c0440b8b804b7a72d7144069b5a9209b2ad693a282"
14
15UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/gptfdisk/files/gptfdisk/"
16UPSTREAM_CHECK_REGEX = "/gptfdisk/(?P<pver>(\d+[\.\-_]*)+)/"
17
18EXTRA_OEMAKE = "'CC=${CC}' 'CXX=${CXX}' gdisk fixparts ${PACKAGECONFIG_CONFARGS}"
19
20PACKAGECONFIG ??= "ncurses popt"
21PACKAGECONFIG[ncurses] = "cgdisk,,ncurses"
22PACKAGECONFIG[popt] = "sgdisk,,popt"
23
24do_install() {
25    install -d ${D}${sbindir}
26    for f in cgdisk sgdisk; do
27        if [ -x $f ]; then
28            install -m 0755 $f ${D}${sbindir}
29        fi
30    done
31    install -m 0755 gdisk ${D}${sbindir}
32    install -m 0755 fixparts ${D}${sbindir}
33}
34
35BBCLASSEXTEND = "native nativesdk"
36