Accepting request 437311 from home:jeff_mahoney:branches:filesystems
- Add ability to provide site specific defaults for mkfs (FATE#320615). * Only used for SLES11 defaults. - Added patch mkfs-default-features.patch OBS-URL: https://build.opensuse.org/request/show/437311 OBS-URL: https://build.opensuse.org/package/show/filesystems/btrfsprogs?expand=0&rev=256
This commit is contained in:
parent
bc9b48237d
commit
960b0f8574
@ -1,3 +1,10 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Oct 25 15:58:46 UTC 2016 - jeffm@suse.com
|
||||||
|
|
||||||
|
- Add ability to provide site specific defaults for mkfs (FATE#320615).
|
||||||
|
* Only used for SLES11 defaults.
|
||||||
|
- Added patch mkfs-default-features.patch
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Oct 18 00:00:00 CEST 2016 - dsterba@suse.cz
|
Tue Oct 18 00:00:00 CEST 2016 - dsterba@suse.cz
|
||||||
|
|
||||||
|
@ -40,12 +40,14 @@ Source: https://www.kernel.org/pub/linux/kernel/people/kdave/btrfs-progs
|
|||||||
# support for mkinitrd in < 13.1
|
# support for mkinitrd in < 13.1
|
||||||
Source1: boot-btrfs.sh
|
Source1: boot-btrfs.sh
|
||||||
Source4: setup-btrfs.sh
|
Source4: setup-btrfs.sh
|
||||||
|
Source5: sles11-defaults.h
|
||||||
|
|
||||||
Patch163: 0163-btrfs-progs-fsck-fix-segfault.patch
|
Patch163: 0163-btrfs-progs-fsck-fix-segfault.patch
|
||||||
Patch167: 0167-Btrfs-progs-make-find_and_setup_root-return-an-error.patch
|
Patch167: 0167-Btrfs-progs-make-find_and_setup_root-return-an-error.patch
|
||||||
Patch168: 0168-Btrfs-progs-don-t-bug-out-if-we-can-t-find-the-last-.patch
|
Patch168: 0168-Btrfs-progs-don-t-bug-out-if-we-can-t-find-the-last-.patch
|
||||||
|
|
||||||
Patch1000: local-version-override.patch
|
Patch1000: local-version-override.patch
|
||||||
|
Patch1001: mkfs-default-features.patch
|
||||||
|
|
||||||
BuildRequires: asciidoc
|
BuildRequires: asciidoc
|
||||||
BuildRequires: autoconf
|
BuildRequires: autoconf
|
||||||
@ -141,9 +143,15 @@ thing.
|
|||||||
%patch167 -p1
|
%patch167 -p1
|
||||||
%patch168 -p1
|
%patch168 -p1
|
||||||
%patch1000 -p1
|
%patch1000 -p1
|
||||||
|
%patch1001 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
./autogen.sh
|
./autogen.sh
|
||||||
|
%if 0%{?suse_version} == 1110
|
||||||
|
cp %{SOURCE5} .
|
||||||
|
export CFLAGS="%optflags -include sles11-defaults.h"
|
||||||
|
%endif
|
||||||
|
|
||||||
%configure
|
%configure
|
||||||
make V=1 %{?_smp_mflags} all \
|
make V=1 %{?_smp_mflags} all \
|
||||||
%if %build_static
|
%if %build_static
|
||||||
|
30
mkfs-default-features.patch
Normal file
30
mkfs-default-features.patch
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
From: Jeff Mahoney <jeffm@suse.com>
|
||||||
|
Subject: mkfs: allow site to override defaults
|
||||||
|
Patch-mainline: Never, a real solution with a config file is required
|
||||||
|
References: FATE#320615
|
||||||
|
|
||||||
|
This is a simple method to allow us to set site defaults for mkfs by
|
||||||
|
adding -include <includefile> to cflags.
|
||||||
|
|
||||||
|
Signed-off-by: Jeff Mahoney <jeffm@suse.com>
|
||||||
|
---
|
||||||
|
utils.h | 4 ++++
|
||||||
|
1 file changed, 4 insertions(+)
|
||||||
|
|
||||||
|
--- a/utils.h
|
||||||
|
+++ b/utils.h
|
||||||
|
@@ -28,10 +28,14 @@
|
||||||
|
|
||||||
|
#define BTRFS_MKFS_SYSTEM_GROUP_SIZE (4 * 1024 * 1024)
|
||||||
|
#define BTRFS_MKFS_SMALL_VOLUME_SIZE (1024 * 1024 * 1024)
|
||||||
|
+#ifndef BTRFS_MKFS_DEFAULT_NODE_SIZE
|
||||||
|
#define BTRFS_MKFS_DEFAULT_NODE_SIZE 16384
|
||||||
|
+#endif
|
||||||
|
+#ifndef BTRFS_MKFS_DEFAULT_FEATURES
|
||||||
|
#define BTRFS_MKFS_DEFAULT_FEATURES \
|
||||||
|
(BTRFS_FEATURE_INCOMPAT_EXTENDED_IREF \
|
||||||
|
| BTRFS_FEATURE_INCOMPAT_SKINNY_METADATA)
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Avoid multi-device features (RAID56) and mixed block groups
|
5
sles11-defaults.h
Normal file
5
sles11-defaults.h
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
#ifndef _SLES11_DEFAULTS_H
|
||||||
|
#define _SLES11_DEFAULTS_H
|
||||||
|
#define BTRFS_MKFS_DEFAULT_NODE_SIZE sysconf(_SC_PAGESIZE)
|
||||||
|
#define BTRFS_MKFS_DEFAULT_FEATURES BTRFS_FEATURE_INCOMPAT_EXTENDED_IREF
|
||||||
|
#endif
|
Loading…
Reference in New Issue
Block a user