Merge "Fix all warnings and enable -Werror for gptfdisk."

am: 2c054ab90e

Change-Id: I39b4221ab89b9bc352b0f139353cfb17e3235cf1
This commit is contained in:
Aurimas Liutikas
2016-10-27 23:38:51 +00:00
committed by android-build-merger
15 changed files with 28 additions and 2 deletions

View File

@@ -24,6 +24,7 @@ LOCAL_CPP_EXTENSION := .cc
LOCAL_C_INCLUDES := $(LOCAL_PATH) external/e2fsprogs/lib
LOCAL_SRC_FILES := $(sgdisk_src_files)
LOCAL_CFLAGS += -Wno-unused-parameter -Werror
LOCAL_SHARED_LIBRARIES := libext2_uuid
@@ -41,6 +42,7 @@ endif
LOCAL_C_INCLUDES := $(LOCAL_PATH) external/e2fsprogs/lib
LOCAL_SRC_FILES := $(sgdisk_src_files)
LOCAL_CFLAGS += -Wno-unused-parameter -Werror
LOCAL_SHARED_LIBRARIES := libext2_uuid-host

View File

@@ -7,7 +7,9 @@
under the terms of the GNU GPL version 2, as detailed in the COPYING file. */
#define __STDC_LIMIT_MACROS
#ifndef __STDC_CONSTANT_MACROS
#define __STDC_CONSTANT_MACROS
#endif
#include <stdint.h>
#include <stdio.h>

View File

@@ -7,7 +7,9 @@
under the terms of the GNU GPL version 2, as detailed in the COPYING file. */
#define __STDC_LIMIT_MACROS
#ifndef __STDC_CONSTANT_MACROS
#define __STDC_CONSTANT_MACROS
#endif
#include <stdio.h>
#include <stdlib.h>

2
bsd.cc
View File

@@ -7,7 +7,9 @@
under the terms of the GNU GPL version 2, as detailed in the COPYING file. */
#define __STDC_LIMIT_MACROS
#ifndef __STDC_CONSTANT_MACROS
#define __STDC_CONSTANT_MACROS
#endif
#include <stdio.h>
//#include <unistd.h>

View File

@@ -31,7 +31,7 @@ uint32_t crc_tab[256];
*/
uint32_t chksum_crc32 (unsigned char *block, unsigned int length)
{
register unsigned long crc;
unsigned long crc;
unsigned long i;
crc = 0xFFFFFFFF;

View File

@@ -13,7 +13,9 @@
// under the terms of the GNU GPL version 2, as detailed in the COPYING file.
#define __STDC_LIMIT_MACROS
#ifndef __STDC_CONSTANT_MACROS
#define __STDC_CONSTANT_MACROS
#endif
#include <sys/ioctl.h>
#include <string.h>

View File

@@ -13,7 +13,9 @@
// under the terms of the GNU GPL version 2, as detailed in the COPYING file.
#define __STDC_LIMIT_MACROS
#ifndef __STDC_CONSTANT_MACROS
#define __STDC_CONSTANT_MACROS
#endif
#ifdef _WIN32
#include <windows.h>

2
gpt.cc
View File

@@ -7,7 +7,9 @@
under the terms of the GNU GPL version 2, as detailed in the COPYING file. */
#define __STDC_LIMIT_MACROS
#ifndef __STDC_CONSTANT_MACROS
#define __STDC_CONSTANT_MACROS
#endif
#include <stdio.h>
#include <stdlib.h>

View File

@@ -109,7 +109,7 @@ int GPTDataCL::DoOptions(int argc, char* argv[]) {
{"version", 'V', POPT_ARG_NONE, NULL, 'V', "display version information", ""},
{"zap", 'z', POPT_ARG_NONE, NULL, 'z', "zap (destroy) GPT (but not MBR) data structures", ""},
{"zap-all", 'Z', POPT_ARG_NONE, NULL, 'Z', "zap (destroy) GPT and MBR data structures", ""},
POPT_AUTOHELP { NULL, 0, 0, NULL, 0 }
POPT_AUTOHELP { NULL, 0, 0, NULL, 0, NULL, NULL }
};
// Create popt context...

View File

@@ -13,7 +13,9 @@
// under the terms of the GNU GPL version 2, as detailed in the COPYING file.
#define __STDC_LIMIT_MACROS
#ifndef __STDC_CONSTANT_MACROS
#define __STDC_CONSTANT_MACROS
#endif
#ifdef USE_UTF16
#include <unicode/ustdio.h>

View File

@@ -12,7 +12,9 @@
//
#define __STDC_LIMIT_MACROS
#ifndef __STDC_CONSTANT_MACROS
#define __STDC_CONSTANT_MACROS
#endif
#include <stdio.h>
#include <time.h>

2
mbr.cc
View File

@@ -7,7 +7,9 @@
under the terms of the GNU GPL version 2, as detailed in the COPYING file. */
#define __STDC_LIMIT_MACROS
#ifndef __STDC_CONSTANT_MACROS
#define __STDC_CONSTANT_MACROS
#endif
#include <stdio.h>
#include <stdlib.h>

View File

@@ -18,7 +18,9 @@
*/
#define __STDC_LIMIT_MACROS
#ifndef __STDC_CONSTANT_MACROS
#define __STDC_CONSTANT_MACROS
#endif
#include <stddef.h>
#include <stdint.h>

View File

@@ -6,7 +6,9 @@
under the terms of the GNU GPL version 2, as detailed in the COPYING file. */
#define __STDC_LIMIT_MACROS
#ifndef __STDC_CONSTANT_MACROS
#define __STDC_CONSTANT_MACROS
#endif
#include <string.h>
#include <stdint.h>

View File

@@ -7,7 +7,9 @@
under the terms of the GNU GPL version 2, as detailed in the COPYING file. */
#define __STDC_LIMIT_MACROS
#ifndef __STDC_CONSTANT_MACROS
#define __STDC_CONSTANT_MACROS
#endif
#include <stdio.h>
#include <stdint.h>