parted/0083-Fix-make-check.patch
Brian C. Lane d6652ea632 - Use python3 in buildroot
- Add make to BuildRequires
- Switch gpt-header-move and msdos-overlap to python3 (bcl)
- Modify gpt-header-move and msdos-overlap to work with py2 or py3 (bcl)
- Fix atari label false positives (psusi)
- Lift 512 byte restriction on fat resize (psusi)
- build: Remove unused traces of dynamic loading (cjwatson)
- Fix resizepart iec unit end sector (psusi)
- mkpart: Allow negative start value when FS-TYPE is not given (mail)
- Fix set and disk_set to not crash when no flags are supported (psusi)
- tests: fix t6100-mdraid-partitions (psusi)
- Fix make check (psusi)
- linux: Include <sys/sysmacros.h> for major() macro. (rjones)
2018-06-27 14:44:42 -07:00

64 lines
1.8 KiB
Diff

From d91acc645ad1204ded41cfecad337bf9c48952f6 Mon Sep 17 00:00:00 2001
From: Phillip Susi <psusi@ubuntu.com>
Date: Fri, 4 May 2018 10:12:05 -0400
Subject: [PATCH 83/92] Fix make check
Make check failed due to some warnings treated as errors. One was
caused by a warning that a function could have the noreturn attribute.
It seems that this had previously been disabled but gcc has changed
the flag from -Wmissing-noreturn to -Wsuggest-attribute=noreturn. The
recently added volser.c test also caused a few warnings when not
compiled on s390x because most of the functions were no used, so #if
those out as well.
---
configure.ac | 2 +-
libparted/tests/volser.c | 5 ++++-
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/configure.ac b/configure.ac
index 738c697..056478f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -226,7 +226,7 @@ if test "$gl_gcc_warnings" = yes; then
nw="$nw -Wpacked"
nw="$nw -Wmissing-prototypes"
nw="$nw -Wmissing-declarations"
- nw="$nw -Wmissing-noreturn"
+ nw="$nw -Wsuggest-attribute=noreturn"
# things I might fix soon:
nw="$nw -Wfloat-equal" # sort.c, seq.c
nw="$nw -Wmissing-format-attribute" # copy.c
diff --git a/libparted/tests/volser.c b/libparted/tests/volser.c
index 9063821..c6efa5f 100644
--- a/libparted/tests/volser.c
+++ b/libparted/tests/volser.c
@@ -14,6 +14,8 @@
#include "common.h"
#include "progname.h"
+#if defined __s390__ || defined __s390x__
+
/* set dasd first */
static char vol_devno[7] = {0};
static char *tmp_disk;
@@ -75,7 +77,6 @@ END_TEST
START_TEST (test_check_volser)
{
- char vol[7] = {0};
char vol_long[] = "abcdefg";
char vol_short[] = "ab_c ";
char vol_null[] = " ";
@@ -135,6 +136,8 @@ START_TEST (test_reuse_vtoc)
}
END_TEST
+#endif
+
int main (int argc, char **argv)
{
--
2.17.1