aboutsummaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/btrfs-tools/btrfs-tools/debian/02-ftbfs.patch
blob: 7b47190757fc7eaa22ab23bd081fd45b21379c83 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
Upstream-Status: Inappropriate [distribution: debian]

Authors:
 Luca Bruno <lucab@debian.org>
 Alexander Kurtz <kurtz.alex@googlemail.com>
 Daniel Baumann <daniel@debian.org>
Description:
 Patch to properly cast and avoiding compiler warnings. Fixes FTBFS on alpha
 and ia64 (Closes: #539433, #583768).

diff -Naurp btrfs-tools.orig/btrfsctl.c btrfs-tools/btrfsctl.c
--- btrfs-tools.orig/btrfsctl.c	2010-06-01 07:22:33.000000000 +0200
+++ btrfs-tools/btrfsctl.c	2010-06-05 08:44:05.000000000 +0200
@@ -234,7 +234,7 @@ int main(int ac, char **av)
 		args.fd = fd;
 		ret = ioctl(snap_fd, command, &args);
 	} else if (command == BTRFS_IOC_DEFAULT_SUBVOL) {
-		printf("objectid is %llu\n", objectid);
+		printf("objectid is %llu\n", (long long unsigned int) objectid);
 		ret = ioctl(fd, command, &objectid);
 	} else
 		ret = ioctl(fd, command, &args);
diff -Naurp btrfs-tools.orig/btrfs-list.c btrfs-tools/btrfs-list.c
--- btrfs-tools.orig/btrfs-list.c	2010-06-01 07:22:33.000000000 +0200
+++ btrfs-tools/btrfs-list.c	2010-06-05 08:47:27.000000000 +0200
@@ -248,8 +248,9 @@ static int resolve_root(struct root_look
 			break;
 		}
 	}
-	printf("ID %llu top level %llu path %s\n", ri->root_id, top_id,
-	       full_path);
+	printf("ID %llu top level %llu path %s\n",
+		(long long unsigned int) ri->root_id,
+		(long long unsigned int) top_id, full_path);
 	free(full_path);
 	return 0;
 }
diff -Naurp btrfs-tools.orig/btrfs-map-logical.c btrfs-tools/btrfs-map-logical.c
--- btrfs-tools.orig/btrfs-map-logical.c	2010-06-01 07:22:33.000000000 +0200
+++ btrfs-tools/btrfs-map-logical.c	2010-06-05 08:48:10.000000000 +0200
@@ -65,8 +65,9 @@ struct extent_buffer *debug_read_block(s
 		eb->dev_bytenr = multi->stripes[0].physical;
 
 		fprintf(info_file, "mirror %d logical %Lu physical %Lu "
-			"device %s\n", mirror_num, bytenr, eb->dev_bytenr,
-			device->name);
+			"device %s\n", mirror_num,
+			(long long unsigned int) bytenr,
+			(long long unsigned int) eb->dev_bytenr, device->name);
 		kfree(multi);
 
 		if (!copy || mirror_num == copy)
diff -Naurp btrfs-tools.orig/convert.c btrfs-tools/convert.c
--- btrfs-tools.orig/convert.c	2010-06-01 07:22:33.000000000 +0200
+++ btrfs-tools/convert.c	2010-06-05 08:43:29.000000000 +0200
@@ -2572,7 +2572,7 @@ int do_rollback(const char *devname, int
 	ext2_root = btrfs_read_fs_root(root->fs_info, &key);
 	if (!ext2_root || IS_ERR(ext2_root)) {
 		fprintf(stderr, "unable to open subvol %llu\n",
-			key.objectid);
+			(unsigned long long) key.objectid);
 		goto fail;
 	}
 
diff -Naurp btrfs-tools.orig/debug-tree.c btrfs-tools/debug-tree.c
--- btrfs-tools.orig/debug-tree.c	2010-06-01 07:22:33.000000000 +0200
+++ btrfs-tools/debug-tree.c	2010-06-05 08:46:17.000000000 +0200
@@ -162,7 +162,8 @@ int main(int ac, char **av)
 					      root->nodesize, 0);
 		}
 		if (!leaf) {
-			fprintf(stderr, "failed to read %llu\n", block_only);
+			fprintf(stderr, "failed to read %llu\n",
+			(long long unsigned int) block_only);
 			return 0;
 		}
 		btrfs_print_tree(root, leaf, 0);
diff -Naurp btrfs-tools.orig/disk-io.c btrfs-tools/disk-io.c
--- btrfs-tools.orig/disk-io.c	2010-06-01 07:18:01.000000000 +0200
+++ btrfs-tools/disk-io.c	2010-06-05 08:43:29.000000000 +0200
@@ -678,7 +678,8 @@ struct btrfs_root *open_ctree_fd(int fp,
 		   ~BTRFS_FEATURE_INCOMPAT_SUPP;
 	if (features) {
 		printk("couldn't open because of unsupported "
-		       "option features (%Lx).\n", features);
+		       "option features (%Lx).\n",
+			(unsigned long long)features);
 		BUG_ON(1);
 	}
 
@@ -692,7 +693,8 @@ struct btrfs_root *open_ctree_fd(int fp,
 		~BTRFS_FEATURE_COMPAT_RO_SUPP;
 	if (writes && features) {
 		printk("couldn't open RDWR because of unsupported "
-		       "option features (%Lx).\n", features);
+		       "option features (%Lx).\n",
+			(unsigned long long) features);
 		BUG_ON(1);
 	}
 
diff -Naurp btrfs-tools.orig/extent-tree.c btrfs-tools/extent-tree.c
--- btrfs-tools.orig/extent-tree.c	2010-06-01 07:18:01.000000000 +0200
+++ btrfs-tools/extent-tree.c	2010-06-05 08:43:29.000000000 +0200
@@ -1448,7 +1448,8 @@ int btrfs_lookup_extent_info(struct btrf
 		goto out;
 	if (ret != 0) {
 		btrfs_print_leaf(root, path->nodes[0]);
-		printk("failed to find block number %Lu\n", bytenr);
+		printk("failed to find block number %Lu\n",
+		(unsigned long long) bytenr);
 		BUG();
 	}
 
diff -Naurp btrfs-tools.orig/print-tree.c btrfs-tools/print-tree.c
--- btrfs-tools.orig/print-tree.c	2010-06-01 07:22:33.000000000 +0200
+++ btrfs-tools/print-tree.c	2010-06-05 08:43:29.000000000 +0200
@@ -494,7 +494,7 @@ void btrfs_print_leaf(struct btrfs_root
 		case BTRFS_DIR_LOG_ITEM_KEY:
 			dlog = btrfs_item_ptr(l, i, struct btrfs_dir_log_item);
 			printf("\t\tdir log end %Lu\n",
-			       btrfs_dir_log_end(l, dlog));
+			       (unsigned long long) btrfs_dir_log_end(l, dlog));
 		       break;
 		case BTRFS_ORPHAN_ITEM_KEY:
 			printf("\t\torphan item\n");