diff options
Diffstat (limited to 'repo/parted')
-rw-r--r-- | repo/parted/fix-includes.patch | 10 | ||||
-rw-r--r-- | repo/parted/fix-libintl-header-s390x.patch | 58 | ||||
-rw-r--r-- | repo/parted/make-tests.patch | 45 | ||||
-rw-r--r-- | repo/parted/parted-include-sysmacros.patch | 10 | ||||
-rw-r--r-- | repo/parted/parted.xibuild | 37 | ||||
-rw-r--r-- | repo/parted/skip-duplicate-bsd-test-on-s390x.patch | 16 |
6 files changed, 176 insertions, 0 deletions
diff --git a/repo/parted/fix-includes.patch b/repo/parted/fix-includes.patch new file mode 100644 index 0000000..c6eff0e --- /dev/null +++ b/repo/parted/fix-includes.patch @@ -0,0 +1,10 @@ +--- parted-3.1.orig/libparted/fs/xfs/platform_defs.h ++++ parted-3.1/libparted/fs/xfs/platform_defs.h +@@ -35,6 +35,7 @@ + #define __XFS_PLATFORM_DEFS_H__ + + #include <stdio.h> ++#include <fcntl.h> + #include <stdarg.h> + #include <assert.h> + #include <endian.h> diff --git a/repo/parted/fix-libintl-header-s390x.patch b/repo/parted/fix-libintl-header-s390x.patch new file mode 100644 index 0000000..68ae7d2 --- /dev/null +++ b/repo/parted/fix-libintl-header-s390x.patch @@ -0,0 +1,58 @@ +From 4b2a566a3e007184d3ee9ce5b399a63eebbdadc3 Mon Sep 17 00:00:00 2001 +From: "Tuan M. Hoang" <tmhoang@flatglobe.org> +Date: Thu, 23 Feb 2017 07:53:02 +0000 +Subject: [PATCH] main/parted: disable nls on s390x + +Because we build with --disable-nls by default, we need to remove libintl.h in +these files on s390x. This is specific for DASD devices only on s390x. +--- + libparted/labels/dasd.c | 2 +- + libparted/labels/fdasd.c | 2 +- + libparted/labels/vtoc.c | 2 +- + 3 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/libparted/labels/dasd.c b/libparted/labels/dasd.c +index fa9414f..5acf844 100644 +--- a/libparted/labels/dasd.c ++++ b/libparted/labels/dasd.c +@@ -40,8 +40,8 @@ + #include <parted/fdasd.h> + #include <arch/linux.h> + +-#include <libintl.h> + #if ENABLE_NLS ++# include <libintl.h> + # define _(String) dgettext (PACKAGE, String) + #else + # define _(String) (String) +diff --git a/libparted/labels/fdasd.c b/libparted/labels/fdasd.c +index 1f87937..e6a9086 100644 +--- a/libparted/labels/fdasd.c ++++ b/libparted/labels/fdasd.c +@@ -24,8 +24,8 @@ + + #include <parted/parted.h> + +-#include <libintl.h> + #if ENABLE_NLS ++# include <libintl.h> + # define _(String) dgettext (PACKAGE, String) + #else + # define _(String) (String) +diff --git a/libparted/labels/vtoc.c b/libparted/labels/vtoc.c +index fdfa94f..64ba149 100644 +--- a/libparted/labels/vtoc.c ++++ b/libparted/labels/vtoc.c +@@ -12,8 +12,8 @@ + + #include <parted/parted.h> + +-#include <libintl.h> + #if ENABLE_NLS ++# include <libintl.h> + # define _(String) dgettext (PACKAGE, String) + #else + # define _(String) (String) +-- +2.11.1 + diff --git a/repo/parted/make-tests.patch b/repo/parted/make-tests.patch new file mode 100644 index 0000000..edadee9 --- /dev/null +++ b/repo/parted/make-tests.patch @@ -0,0 +1,45 @@ +diff --git a/tests/Makefile.in b/tests/Makefile.in +index 11baba0..2288cc7 100644 +--- a/tests/Makefile.in ++++ b/tests/Makefile.in +@@ -1622,16 +1622,12 @@ TEST_EXTENSIONS = .sh + SH_LOG_COMPILER = $(SHELL) + TESTS = \ + help-version.sh \ +- t0000-basic.sh \ +- t0001-tiny.sh \ + t0010-script-no-ctrl-chars.sh \ + t0100-print.sh \ + t0101-print-empty.sh \ + t0200-gpt.sh \ + t0201-gpt.sh \ + t0202-gpt-pmbr.sh \ +- t0203-gpt-tiny-device-abort.sh \ +- t0203-gpt-shortened-device-primary-valid.sh \ + t0203-gpt-create-on-min-sized-device.sh \ + t0205-gpt-list-clobbers-pmbr.sh \ + t0206-gpt-print-with-corrupt-primary-clobbers-pmbr.sh \ +@@ -1644,14 +1640,9 @@ TESTS = \ + t0213-mkpart-start-negative.sh \ + t0220-gpt-msftres.sh \ + t0250-gpt.sh \ +- t0251-gpt-unicode.sh \ + t0280-gpt-corrupt.sh \ +- t0281-gpt-grow.sh \ +- t0282-gpt-move-backup.sh \ +- t0283-overlap-partitions.sh \ + t0300-dos-on-gpt.sh \ + t0301-overwrite-gpt-pmbr.sh \ +- t0350-mac-PT-increases-sector-size.sh \ + t0400-loop-clobber-infloop.sh \ + t0500-dup-clobber.sh \ + t0501-duplicate.sh \ +@@ -1673,8 +1664,6 @@ TESTS = \ + t3200-resize-partition.sh \ + t3200-type-change.sh \ + t3300-palo-prep.sh \ +- t3310-flags.sh \ +- t3400-whole-disk-FAT-partition.sh \ + t4000-sun-raid-type.sh \ + t4001-sun-vtoc.sh \ + t4100-msdos-partition-limits.sh \ diff --git a/repo/parted/parted-include-sysmacros.patch b/repo/parted/parted-include-sysmacros.patch new file mode 100644 index 0000000..52ec588 --- /dev/null +++ b/repo/parted/parted-include-sysmacros.patch @@ -0,0 +1,10 @@ +--- a/libparted/arch/linux.c ++++ b/libparted/arch/linux.c +@@ -38,6 +38,7 @@ + #include <sys/ioctl.h> + #include <sys/stat.h> + #include <sys/types.h> ++#include <sys/sysmacros.h> + #include <sys/utsname.h> /* for uname() */ + #include <scsi/scsi.h> + #include <assert.h> diff --git a/repo/parted/parted.xibuild b/repo/parted/parted.xibuild new file mode 100644 index 0000000..1fd2222 --- /dev/null +++ b/repo/parted/parted.xibuild @@ -0,0 +1,37 @@ +#!/bin/sh + +NAME="parted" +DESC="Utility to create, destroy, resize, check and copy partitions" + +MAKEDEPS="readline ncurses lvm2 bash util-linux" + +PKG_VER=3.4 +SOURCE="https://ftp.gnu.org/gnu/parted/parted-$PKG_VER.tar.xz" + +ADDITIONAL=" +fix-includes.patch +fix-libintl-header-s390x.patch +make-tests.patch +parted-include-sysmacros.patch +skip-duplicate-bsd-test-on-s390x.patch +" + +prepare () { + apply_patches +} + +build() { + ./configure \ + --prefix=/usr \ + --enable-debug \ + --disable-nls \ + --disable-static \ + --enable-shared + make +} + +package() { + make DESTDIR="$PKG_DEST" install + rm -rf "$PKG_DEST"/usr/lib/charset.alias + rmdir -p "$PKG_DEST"/usr/lib 2>/dev/null || true +} diff --git a/repo/parted/skip-duplicate-bsd-test-on-s390x.patch b/repo/parted/skip-duplicate-bsd-test-on-s390x.patch new file mode 100644 index 0000000..6920ee2 --- /dev/null +++ b/repo/parted/skip-duplicate-bsd-test-on-s390x.patch @@ -0,0 +1,16 @@ +diff --git a/tests/t0501-duplicate.sh b/tests/t0501-duplicate.sh +index 66d321a..0520131 100644 +--- a/tests/t0501-duplicate.sh ++++ b/tests/t0501-duplicate.sh +@@ -18,7 +18,11 @@ + + . "${srcdir=.}/init.sh"; path_prepend_ ../parted . + ++arch=$(uname -m) + for t in msdos gpt bsd; do ++ if [ "$t" = bsd ] && [ "$arch" = "s390x" ]; then ++ continue ++ fi + duplicate $t || fail=1 + done + |