parted: update to parted-3.3

This commit is contained in:
MilhouseVH 2020-02-16 03:46:57 +00:00
parent 68d464e0fc
commit 5159fe1d35
3 changed files with 11 additions and 76 deletions

View File

@ -1,9 +1,10 @@
# SPDX-License-Identifier: GPL-2.0-or-later
# Copyright (C) 2009-2016 Stephan Raue (stephan@openelec.tv)
# Copyright (C) 2020-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="parted"
PKG_VERSION="3.2"
PKG_SHA256="858b589c22297cacdf437f3baff6f04b333087521ab274f7ab677cb8c6bb78e4"
PKG_VERSION="3.3"
PKG_SHA256="57e2b4bd87018625c515421d4524f6e3b55175b472302056391c5f7eccb83d44"
PKG_LICENSE="GPL"
PKG_SITE="http://www.gnu.org/software/parted/"
PKG_URL="http://ftpmirror.gnu.org/parted/$PKG_NAME-$PKG_VERSION.tar.xz"
@ -20,6 +21,10 @@ PKG_CONFIGURE_OPTS_TARGET="--disable-device-mapper \
PKG_CONFIGURE_OPTS_HOST="$PKG_CONFIGURE_OPTS_TARGET"
pre_configure_init() {
: # reuse pre_configure_target()
}
configure_init() {
: # reuse configure_target()
}
@ -33,3 +38,7 @@ makeinstall_init() {
cp ../.$TARGET_NAME/parted/parted $INSTALL/sbin
cp ../.$TARGET_NAME/partprobe/partprobe $INSTALL/sbin
}
pre_configure_target() {
export CFLAGS+=" -I$PKG_BUILD/lib"
}

View File

@ -1,45 +0,0 @@
diff -Naur parted-3.2/libparted/arch/linux.c parted-3.2.patch/libparted/arch/linux.c
--- parted-3.2/libparted/arch/linux.c 2014-06-15 21:15:54.000000000 +0200
+++ parted-3.2.patch/libparted/arch/linux.c 2014-08-04 01:57:47.626611437 +0200
@@ -2307,6 +2307,7 @@
static char *
dm_canonical_path (PedDevice const *dev)
{
+#ifdef ENABLE_DEVICE_MAPPER
LinuxSpecific const *arch_specific = LINUX_SPECIFIC (dev);
/* Get map name from devicemapper */
@@ -2324,6 +2325,7 @@
dm_task_destroy (task);
return dev_name;
err:
+#endif
return NULL;
}
@@ -2944,13 +2946,14 @@
unsigned long long *start,
unsigned long long *length);
-
+#ifdef ENABLE_DEVICE_MAPPER
if (disk->dev->type == PED_DEVICE_DM) {
add_partition = _dm_add_partition;
remove_partition = _dm_remove_partition;
resize_partition = _dm_resize_partition;
get_partition_start_and_length = _dm_get_partition_start_and_length;
} else {
+#endif
add_partition = _blkpg_add_partition;
remove_partition = _blkpg_remove_partition;
#ifdef BLKPG_RESIZE_PARTITION
@@ -2959,7 +2962,9 @@
resize_partition = NULL;
#endif
get_partition_start_and_length = _kernel_get_partition_start_and_length;
+#ifdef ENABLE_DEVICE_MAPPER
}
+#endif
/* lpn = largest partition number.
* for remove pass, use greater of device or label limit */

View File

@ -1,29 +0,0 @@
From b79bdebf285575ec2c3e8944d951655ef8c97a23 Mon Sep 17 00:00:00 2001
From: Mike Frysinger <vapier at gentoo.org>
Date: Tue, 21 Jun 2016 15:01:08 -0400
Subject: [PATCH] include sysmacros.h for major/minor/makedev
Linux C libs are moving away from including this header implicitly via
sys/types.h, so include it explicitly.
Upstream-Status: Pending
Signed-off-by: Martin Jansa <Martin.Jansa at gmail.com>
---
libparted/arch/linux.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c
index 0f18904..b302d63 100644
--- a/libparted/arch/linux.c
+++ b/libparted/arch/linux.c
@@ -37,6 +37,7 @@
#include <dirent.h>
#include <sys/ioctl.h>
#include <sys/stat.h>
+#include <sys/sysmacros.h>
#include <sys/types.h>
#include <sys/utsname.h> /* for uname() */
#include <scsi/scsi.h>
--
2.14.1