diff options
Diffstat (limited to 'meta/recipes-devtools/btrfs-tools/btrfs-tools/upstream-tmp/0010-Deprecate-btrfsctl-btrfs-show-btrfs-vol.patch')
-rw-r--r-- | meta/recipes-devtools/btrfs-tools/btrfs-tools/upstream-tmp/0010-Deprecate-btrfsctl-btrfs-show-btrfs-vol.patch | 152 |
1 files changed, 152 insertions, 0 deletions
diff --git a/meta/recipes-devtools/btrfs-tools/btrfs-tools/upstream-tmp/0010-Deprecate-btrfsctl-btrfs-show-btrfs-vol.patch b/meta/recipes-devtools/btrfs-tools/btrfs-tools/upstream-tmp/0010-Deprecate-btrfsctl-btrfs-show-btrfs-vol.patch new file mode 100644 index 0000000000..17e515d262 --- /dev/null +++ b/meta/recipes-devtools/btrfs-tools/btrfs-tools/upstream-tmp/0010-Deprecate-btrfsctl-btrfs-show-btrfs-vol.patch | |||
@@ -0,0 +1,152 @@ | |||
1 | Upstream-Status: Inappropriate [Backport] | ||
2 | From 36d8ab7002c5707538849a61eaa97cbac262bbc3 Mon Sep 17 00:00:00 2001 | ||
3 | From: Goffredo Baroncelli <kreijack@libero.it> | ||
4 | Date: Sun, 5 Dec 2010 17:47:36 +0000 | ||
5 | Subject: [PATCH 10/15] Deprecate btrfsctl, btrfs-show, btrfs-vol | ||
6 | |||
7 | Hi all, | ||
8 | |||
9 | the patch below deprecates the following programs | ||
10 | |||
11 | * btrfsctl | ||
12 | * btrfs-vol | ||
13 | * btrfs-show | ||
14 | |||
15 | the reason is simple, these programs are superseded by the btrfs utility, | ||
16 | both in terms of documentation, usability and bug. The goal is to avoid | ||
17 | to duplicate codes and avoid update two programs. | ||
18 | |||
19 | The patch adds a warning in the man pages, in the INSTALL file and in the | ||
20 | programs. | ||
21 | |||
22 | $ ./btrfsctl | ||
23 | ** | ||
24 | ** WARNING: this program is considered deprecated | ||
25 | ** Please consider to switch to the btrfs utility | ||
26 | ** | ||
27 | no valid commands given | ||
28 | usage: btrfsctl [ -d file|dir] [ -s snap_name subvol|tree ] | ||
29 | [-r size] [-A device] [-a] [-c] [-D dir .] | ||
30 | -d filename: defragments one file | ||
31 | -d directory: defragments the entire Btree | ||
32 | -s snap_name dir: creates a new snapshot of dir | ||
33 | -S subvol_name dir: creates a new subvolume | ||
34 | -r [+-]size[gkm]: resize the FS by size amount | ||
35 | -A device: scans the device file for a Btrfs filesystem | ||
36 | -a: scans all devices for Btrfs filesystems | ||
37 | -c: forces a single FS sync | ||
38 | -D: delete snapshot | ||
39 | -m [tree id] directory: set the default mounted subvolume to the [tree | ||
40 | id] or the | ||
41 | directory | ||
42 | |||
43 | Below the patch, but it is possible to pull the changes from: | ||
44 | |||
45 | http://cassiopea.homelinux.net/git/btrfs-progs-unstable.git | ||
46 | |||
47 | branch | ||
48 | |||
49 | btrfs-deprecated | ||
50 | |||
51 | Comments are welcome. | ||
52 | |||
53 | G.Baroncelli | ||
54 | |||
55 | INSTALL | 5 +++++ | ||
56 | btrfs-show.c | 5 +++++ | ||
57 | btrfs-vol.c | 5 +++++ | ||
58 | btrfsctl.c | 5 +++++ | ||
59 | man/btrfs-show.8.in | 3 +++ | ||
60 | man/btrfsctl.8.in | 3 +++ | ||
61 | 6 files changed, 26 insertions(+), 0 deletions(-) | ||
62 | |||
63 | the tool to create a new snapshot for the filesystem. | ||
64 | |||
65 | Signed-off-by: Chris Mason <chris.mason@oracle.com> | ||
66 | --- | ||
67 | btrfs-show.c | 5 +++++ | ||
68 | btrfs-vol.c | 5 +++++ | ||
69 | btrfsctl.c | 5 +++++ | ||
70 | man/btrfs-show.8.in | 3 +++ | ||
71 | man/btrfsctl.8.in | 3 +++ | ||
72 | 5 files changed, 21 insertions(+), 0 deletions(-) | ||
73 | |||
74 | diff --git a/btrfs-show.c b/btrfs-show.c | ||
75 | index c49626c..8210fd2 100644 | ||
76 | --- a/btrfs-show.c | ||
77 | +++ b/btrfs-show.c | ||
78 | @@ -117,6 +117,11 @@ int main(int ac, char **av) | ||
79 | int ret; | ||
80 | int option_index = 0; | ||
81 | |||
82 | + printf( "**\n" | ||
83 | + "** WARNING: this program is considered deprecated\n" | ||
84 | + "** Please consider to switch to the btrfs utility\n" | ||
85 | + "**\n"); | ||
86 | + | ||
87 | while(1) { | ||
88 | int c; | ||
89 | c = getopt_long(ac, av, "", long_options, | ||
90 | diff --git a/btrfs-vol.c b/btrfs-vol.c | ||
91 | index f573023..0efdbc1 100644 | ||
92 | --- a/btrfs-vol.c | ||
93 | +++ b/btrfs-vol.c | ||
94 | @@ -78,6 +78,11 @@ int main(int ac, char **av) | ||
95 | struct btrfs_ioctl_vol_args args; | ||
96 | u64 dev_block_count = 0; | ||
97 | |||
98 | + printf( "**\n" | ||
99 | + "** WARNING: this program is considered deprecated\n" | ||
100 | + "** Please consider to switch to the btrfs utility\n" | ||
101 | + "**\n"); | ||
102 | + | ||
103 | while(1) { | ||
104 | int c; | ||
105 | c = getopt_long(ac, av, "a:br:", long_options, | ||
106 | diff --git a/btrfsctl.c b/btrfsctl.c | ||
107 | index adfa519..73e20ec 100644 | ||
108 | --- a/btrfsctl.c | ||
109 | +++ b/btrfsctl.c | ||
110 | @@ -107,6 +107,11 @@ int main(int ac, char **av) | ||
111 | char *fullpath; | ||
112 | u64 objectid = 0; | ||
113 | |||
114 | + printf( "**\n" | ||
115 | + "** WARNING: this program is considered deprecated\n" | ||
116 | + "** Please consider to switch to the btrfs utility\n" | ||
117 | + "**\n"); | ||
118 | + | ||
119 | if (ac == 2 && strcmp(av[1], "-a") == 0) { | ||
120 | fprintf(stderr, "Scanning for Btrfs filesystems\n"); | ||
121 | btrfs_scan_one_dir("/dev", 1); | ||
122 | diff --git a/man/btrfs-show.8.in b/man/btrfs-show.8.in | ||
123 | index dd0b147..cb98b68 100644 | ||
124 | --- a/man/btrfs-show.8.in | ||
125 | +++ b/man/btrfs-show.8.in | ||
126 | @@ -3,6 +3,9 @@ | ||
127 | btrfs-show \- scan the /dev directory for btrfs partitions and print results. | ||
128 | .SH SYNOPSIS | ||
129 | .B btrfs-show | ||
130 | +.SH NOTE | ||
131 | +.B btrfs-show | ||
132 | +is deprecated. Please consider to switch to the btrfs utility. | ||
133 | .SH DESCRIPTION | ||
134 | .B btrfs-show | ||
135 | is used to scan the /dev directory for btrfs partitions and display brief | ||
136 | diff --git a/man/btrfsctl.8.in b/man/btrfsctl.8.in | ||
137 | index c2d4488..8705fa6 100644 | ||
138 | --- a/man/btrfsctl.8.in | ||
139 | +++ b/man/btrfsctl.8.in | ||
140 | @@ -10,6 +10,9 @@ btrfsctl \- control a btrfs filesystem | ||
141 | [ \fB \-A\fP\fI device\fP ] | ||
142 | [ \fB \-a\fP ] | ||
143 | [ \fB \-c\fP ] | ||
144 | +.SH NOTE | ||
145 | +B btrfsctl | ||
146 | +is deprecated. Please consider to switch to the btrfs utility. | ||
147 | .SH DESCRIPTION | ||
148 | .B btrfsctl | ||
149 | is used to control the filesystem and the files and directories stored. It is the tool to create a new snapshot for the filesystem. | ||
150 | -- | ||
151 | 1.7.2.3 | ||
152 | |||