From 99233b650bf6c58614e1ee9bd077ff7a02d3a6c428759ae24679584c1bf6947e Mon Sep 17 00:00:00 2001 From: Kyrill Detinov Date: Wed, 21 Aug 2013 16:54:40 +0000 Subject: [PATCH] Accepting request 195776 from home:Andreas_Schwab:Factory - fsarchiver-types.patch: Remove conflicting uses of reserved identifiers OBS-URL: https://build.opensuse.org/request/show/195776 OBS-URL: https://build.opensuse.org/package/show/Archiving:Backup/fsarchiver?expand=0&rev=16 --- fsarchiver-types.patch | 131 +++++++++++++++++++++++++++++++++++++++++ fsarchiver.changes | 5 ++ fsarchiver.spec | 3 + 3 files changed, 139 insertions(+) create mode 100644 fsarchiver-types.patch diff --git a/fsarchiver-types.patch b/fsarchiver-types.patch new file mode 100644 index 0000000..389f7b3 --- /dev/null +++ b/fsarchiver-types.patch @@ -0,0 +1,131 @@ +Index: fsarchiver-0.6.17/src/fs_btrfs.h +=================================================================== +--- fsarchiver-0.6.17.orig/src/fs_btrfs.h ++++ fsarchiver-0.6.17/src/fs_btrfs.h +@@ -79,37 +79,37 @@ static inline u64 btrfs_sb_offset(int mi + struct btrfs_dev_item + { + /* the internal btrfs device id */ +- __le64 devid; ++ uint64_t devid; + + /* size of the device */ +- __le64 total_bytes; ++ uint64_t total_bytes; + + /* bytes used */ +- __le64 bytes_used; ++ uint64_t bytes_used; + + /* optimal io alignment for this device */ +- __le32 io_align; ++ uint32_t io_align; + + /* optimal io width for this device */ +- __le32 io_width; ++ uint32_t io_width; + + /* minimal io size for this device */ +- __le32 sector_size; ++ uint32_t sector_size; + + /* type and info about this device */ +- __le64 type; ++ uint64_t type; + + /* expected generation for this device */ +- __le64 generation; ++ uint64_t generation; + + /* + * starting byte of this partition on the device, + * to allowr for stripe alignment in the future + */ +- __le64 start_offset; ++ uint64_t start_offset; + + /* grouping information for allocation decisions */ +- __le32 dev_group; ++ uint32_t dev_group; + + /* seek speed 0-100 where 100 is fastest */ + u8 seek_speed; +@@ -133,32 +133,32 @@ struct btrfs_super_block + u8 csum[BTRFS_CSUM_SIZE]; + /* the first 4 fields must match struct btrfs_header */ + u8 fsid[BTRFS_FSID_SIZE]; /* FS specific uuid */ +- __le64 bytenr; /* this block number */ +- __le64 flags; ++ uint64_t bytenr; /* this block number */ ++ uint64_t flags; + + /* allowed to be different from the btrfs_header from here own down */ +- __le64 magic; +- __le64 generation; +- __le64 root; +- __le64 chunk_root; +- __le64 log_root; ++ uint64_t magic; ++ uint64_t generation; ++ uint64_t root; ++ uint64_t chunk_root; ++ uint64_t log_root; + + /* this will help find the new super based on the log root */ +- __le64 log_root_transid; +- __le64 total_bytes; +- __le64 bytes_used; +- __le64 root_dir_objectid; +- __le64 num_devices; +- __le32 sectorsize; +- __le32 nodesize; +- __le32 leafsize; +- __le32 stripesize; +- __le32 sys_chunk_array_size; +- __le64 chunk_root_generation; +- __le64 compat_flags; +- __le64 compat_ro_flags; +- __le64 incompat_flags; +- __le16 csum_type; ++ uint64_t log_root_transid; ++ uint64_t total_bytes; ++ uint64_t bytes_used; ++ uint64_t root_dir_objectid; ++ uint64_t num_devices; ++ uint32_t sectorsize; ++ uint32_t nodesize; ++ uint32_t leafsize; ++ uint32_t stripesize; ++ uint32_t sys_chunk_array_size; ++ uint64_t chunk_root_generation; ++ uint64_t compat_flags; ++ uint64_t compat_ro_flags; ++ uint64_t incompat_flags; ++ uint16_t csum_type; + u8 root_level; + u8 chunk_root_level; + u8 log_root_level; +@@ -167,7 +167,7 @@ struct btrfs_super_block + char label[BTRFS_LABEL_SIZE]; + + /* future expansion */ +- __le64 reserved[32]; ++ uint64_t reserved[32]; + u8 sys_chunk_array[BTRFS_SYSTEM_CHUNK_ARRAY_SIZE]; + } __attribute__ ((__packed__)); + +Index: fsarchiver-0.6.17/src/types.h +=================================================================== +--- fsarchiver-0.6.17.orig/src/types.h ++++ fsarchiver-0.6.17/src/types.h +@@ -32,10 +32,6 @@ typedef int32_t s32; + typedef uint64_t u64; + typedef int64_t s64; + +-typedef uint16_t __le16; +-typedef uint32_t __le32; +-typedef uint64_t __le64; +- + #define le8_to_cpu(v) (v) + #define cpu_to_le8(v) (v) + diff --git a/fsarchiver.changes b/fsarchiver.changes index 12db45e..bfb1164 100644 --- a/fsarchiver.changes +++ b/fsarchiver.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Tue Aug 20 16:06:42 UTC 2013 - schwab@suse.de + +- fsarchiver-types.patch: Remove conflicting uses of reserved identifiers + ------------------------------------------------------------------- Thu Feb 28 14:29:33 UTC 2013 - lazy.kent@opensuse.org diff --git a/fsarchiver.spec b/fsarchiver.spec index 2c2c2a0..5ea0c4a 100644 --- a/fsarchiver.spec +++ b/fsarchiver.spec @@ -25,6 +25,8 @@ Group: Productivity/Archiving/Backup Url: http://www.fsarchiver.org Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz Source1: HOWTO +# PATCH-FIX-UPSTREAM Remove conflicting uses of reserved identifiers +Patch0: fsarchiver-types.patch BuildRequires: e2fsprogs-devel BuildRequires: libattr-devel BuildRequires: libgcrypt-devel @@ -47,6 +49,7 @@ the whole archive. %prep %setup -q +%patch0 -p1 cp %{SOURCE1} . %build