autoconf
Commits on Jan 16, 2015
-
btrfs-progs: add --disable-documentation
Signed-off-by: Karel Zak <kzak@redhat.com>
karelzak committedJan 16, 2015 -
btrfs-progs: add --disable-backtrace
It's better to use ./configure than manually edit Makefile. Signed-off-by: Karel Zak <kzak@redhat.com>
karelzak committedJan 16, 2015 -
btrfs-progs: clean generated files, make version.h stuff more robust
- add rule to generated version.h when any relevant stuff changed - add rule to clean generated files on "make clean-all" Signed-off-by: Karel Zak <kzak@redhat.com>
karelzak committedJan 16, 2015 -
btrfs-progs: cleanup compilation flags usage
- define basic default CFLAGS in configure.ac, because: * autoconf default is -g -O2, but btrfs uses -g -O1 * it's better to follow autoconf; standard way to modify CFLAGS is to call: CFLAGS="foo bar" ./configure - move all flags to one place in Makefile.in - don't use AM_CFLAGS, the CFLAGS and STATIC_CFLAGS are enough - don't mix objects and flags in $LIBS, it's more readable to add $(libs) to make rules Signed-off-by: Karel Zak <kzak@redhat.com>karelzak committedJan 16, 2015 -
btrfs-progs: use paths and $*_LIBS from ./configure
Signed-off-by: Karel Zak <kzak@redhat.com>
karelzak committedJan 16, 2015 -
btrfs-progs: check for build programs in ./configure
Signed-off-by: Karel Zak <kzak@redhat.com>
karelzak committedJan 16, 2015 -
btrfs-progs: use ./configure to generate version.h
The original homemade solution is unnecessary, autotools provides better infrastructure to generate files. Signed-off-by: Karel Zak <kzak@redhat.com>
karelzak committedJan 16, 2015 -
btrfs-progs: use standard PACKAGE_* macros
- use standard PACKAGE_{NAME,VERSION,STRING,URL,...} autoconf macros rather than homemade BTRFS_BUILD_VERSION - don't #include version.h, now the file is necessary for library API only Note that "btrfs version" returns "btrfs-progs <version>" instead of the original confusing "btrfs <version>". Signed-off-by: Karel Zak <kzak@redhat.com>karelzak committedJan 16, 2015 -
- the header file is generated by ./configure, the standard autotools way is to use -include config.h on compiler command line rather than include the file directly from code - remove _GNU_SOURCE from code, the macros is already defined in config.h by AC_USE_SYSTEM_EXTENSIONS autoconf macro Signed-off-by: Karel Zak <kzak@redhat.com>
karelzak committedJan 16, 2015 -
btrfs-progs: add ./configure script
- add ./autogen.sh script (necessary after git clean/clone) - add ./configure.ac - copy autotool helper scripts from automake - modify version.sh to be usable from the configure script - rename Makefile to Makefile.in and use basic variables from configure.ac Signed-off-by: Karel Zak <kzak@redhat.com>
karelzak committedJan 16, 2015
Commits on Jan 9, 2015
-
Verified
This commit was signed with a verified signature.GPG key ID: C565D5F9D76D583B Learn about signing commits -
btrfs-progs: Don't increase error count if the inode can be repaired.
The original check_inode_recs() will return -1 if found any error in a inode_record. This is OK for original design since there is almost nothing can repair at that time. However more and more error from nlink mismatch to missing inode item can be repaired in try_repair_inode(), check_inode_recs() should not increase the error count if the inode can be repair. With this patch, repair function for leaf-corruption will not return error if all corruption inode can be recovered. Signed-off-by: Qu Wenruo <quwenruo@cn.fujitsu.com> Reviewed-by: Satoru Takeuchi <takeuchi_satoru@jp.fujitsu.com> Signed-off-by: David Sterba <dsterba@suse.cz>
-
btrfs-progs: fix some format errors in doc
Signed-off-by: Fan Chengniang <fancn.fnst@cn.fujitsu.com> Signed-off-by: David Sterba <dsterba@suse.cz>
-
btrfs-progs: doc: fix format of btrfs-replace
Current 'man btrfs-replace' is as follows: ======================================================================== ... ... -f force using and overwriting <targetdev> even if it looks like containing a valid btrfs filesystem. A valid filesystem is assumed if a btrfs superblock is found which contains a correct checksum. Devices which are currently mounted are never allowed to be used as the <targetdev>. -B:::: no background replace. ... ... ======================================================================== The format of 'B' option is wrong. So, fix it. Signed-off-by: Tsutomu Itoh <t-itoh@jp.fujitsu.com> Signed-off-by: David Sterba <dsterba@suse.cz> -
btrfs-progs: Fix a copy-n-paste bug in btrfs_read_fs_root().
Introduced in commit 96ec888 ("btrfs-progs: add quota group verify code"). Signed-off-by: Qu Wenruo <quwenruo@cn.fujitsu.com> Reviewed-by: Satoru Takeuchi <takeuchi_satoru@jp.fujitsu.com> Signed-off-by: David Sterba <dsterba@suse.cz>
-
btrfs-progs: Fix a buffer overflow causing segfault in fstests/btrfs/069
The newly introduced search_chunk_tree_for_fs_info() won't count devid 0 in fi_arg->num_devices, which will cause buffer overflow since later get_device_info() will fill di_args with devid. This can be trigger by fstests/btrfs/069 and any operations needs to iterate over all the devices like 'fi show' or 'dev stat' while replacing. The fix is do an extra probe specifically for devid 0 after search_chunk_tree_for_fs_info() and change num_devices if needed. Reported-by: Tsutomu Itoh <t-itoh@jp.fujitsu.com> Signed-off-by: Qu Wenruo <quwenruo@cn.fujitsu.com> Signed-off-by: Gui Hecheng <guihc.fnst@cn.fujitsu.com> Signed-off-by: David Sterba <dsterba@suse.cz>
-
btrfs-progs: Documentation: fix broken conversion
Fixes various formatting issues: Fixes quoting issues in various manpages. Before/After excerpts for mkfs.btrfs(8), btrfs-qgroup(8): mkfs.btrfs [-A|--alloc-start '<alloc-start>'] mkfs.btrfs [-A|--alloc-start <alloc-start>] id 0/<subvolume id>'' id 0/<subvolume id> If multiple '<attr>'s is given, use comma to separate. If multiple <attr>s is given, use comma to separate. The one that is most apparent is the removal of text in btrfs-subvolume(8) and others. Before/After: list [options] [-G <value>] [-C <value>] [--sort=rootid,gen,ogen,path] <path> list [options] [-G [+|-]<value>] [-C [+|-]<value>] [--sort=rootid,gen,ogen,path] <path> create [-i <qgroupid>] <name> create [-i <qgroupid>] [<dest>]<name> This happens because `<foo>` was replaced by `'<foo>'` in the sed expression, which is then treated as a constrained quote. As a result, the `[...]` before the string gets interpreted as "quoted text attributes". In this patch, the sed expression is dropped and asciidoc is configured to recognize `<...>` as a unconstrained quoted string (such that `<attr>s` is correctly emphasized) and to avoid adding quotes in contexts where it is not needed. A remaining problem is that some texts (the one between brackets) do not add the emphasis for `<...>`. While this could be solved by replacing `[` and `]` with `[` and `]` using sed, it introduces formatting problems in btrfs-zero-log(8) because the context is ignored. Signed-off-by: Peter Wu <peter@lekensteyn.nl> Signed-off-by: David Sterba <dsterba@suse.cz> -
btrfs-progs: Fix a extent buffer leak in count_csum_range().
The commit f495a2a ("btrfs-progs: fsck: remove unfriendly BUG_ON() for searching tree failure") is causing tons of extent buffer leak if some csum mismatches in btrfsck. This is caused by a misplaced btrfs_release_path(), fix it. Signed-off-by: Qu Wenruo <quwenruo@cn.fujitsu.com> Reviewed-by: Satoru Takeuchi <takeuchi_satoru@jp.fujitsu.com> Signed-off-by: David Sterba <dsterba@suse.cz>
-
btrfs-progs: Allow debug-tree to be executed on regular file.
The commit 1bad43f ("btrfs-progs: refine btrfs-debug-tree error prompt when a mount point given") add judgement on btrfs-debug-tree to restrict only block device to be executed on, but the command can also be used on regular file, so add regular file support for the judgement. Signed-off-by: Qu Wenruo <quwenruo@cn.fujitsu.com> Signed-off-by: David Sterba <dsterba@suse.cz>
Commits on Jan 6, 2015
-
btrfs-progs: convert, handle pwrite error in do_rollback
Resolves-coverity-id: 1242984 Signed-off-by: David Sterba <dsterba@suse.cz>
kdave committedJan 6, 2015 -
btrfs-progs: handle orphan creation error in btrfs_unlink
The error handling is simple and just returns an error upward, no cleanup. Resolves-coverity-id: 1260251 Signed-off-by: David Sterba <dsterba@suse.cz>
kdave committedJan 6, 2015
Commits on Jan 3, 2015
-
btrfs-progs: fix leak of path in reset_balance
A path may leak after an unlikely error condition. Resolves-coverity-id: 1199474 Signed-off-by: David Sterba <dsterba@suse.cz>
kdave committedJan 3, 2015 -
btrfs-progs: safely copy path in btrfs_scan_lblkid
We should terminate the string, let's use the wrapper. Resolves-coverity-id: 1127097 Signed-off-by: David Sterba <dsterba@suse.cz>
kdave committedJan 3, 2015 -
btrfs-progs: cleanup whitespace in is_same_blk_file
Signed-off-by: David Sterba <dsterba@suse.cz>
kdave committedJan 3, 2015 -
btrfs-progs: use strncpy in is_same_blk_file
Although we're getting strings from the caller, let's be safe. Resolves-coverity-id: 1199475 Signed-off-by: David Sterba <dsterba@suse.cz>
kdave committedJan 3, 2015 -
btrfs-progs: check, handle error in fix_key_order
In case the buffer is corrupted and the for loop does not happen, we'd return garbage. The caller retunrs -EIO in case of any corruption, use that value in fix_key_order. Resolves-coverity-id: 1246944 Signed-off-by: David Sterba <dsterba@suse.cz>
kdave committedJan 3, 2015 -
btrfs-progs: doc subvolume, sort subcommands alphabetically
Signed-off-by: David Sterba <dsterba@suse.cz>
kdave committedJan 3, 2015 -
btrfs-progs: doc scrub, sort subcommands alphabetically
Signed-off-by: David Sterba <dsterba@suse.cz>
kdave committedJan 3, 2015 -
btrfs-progs: doc replace, sort subcommands alphabetically
Signed-off-by: David Sterba <dsterba@suse.cz>
kdave committedJan 3, 2015 -
btrfs-progs: doc quota, sort subcommands alphabetically
Signed-off-by: David Sterba <dsterba@suse.cz>
kdave committedJan 3, 2015 -
btrfs-progs: doc qgroup, sort subcommands alphabetically
Signed-off-by: David Sterba <dsterba@suse.cz>
kdave committedJan 3, 2015 -
btrfs-progs: doc property, sort subcommands alphabetically
Signed-off-by: David Sterba <dsterba@suse.cz>
kdave committedJan 3, 2015 -
btrfs-progs: doc inspect-internal, sort subcommands alphabetically
Signed-off-by: David Sterba <dsterba@suse.cz>
kdave committedJan 3, 2015 -
btrfs-progs: doc device, sort subcommands alphabetically
Signed-off-by: David Sterba <dsterba@suse.cz>
kdave committedJan 3, 2015 -
btrfs-progs: doc, undocument old balance syntax
Standalone balance subcommand has been around since 3.3. Signed-off-by: David Sterba <dsterba@suse.cz>
kdave committedJan 3, 2015