From 8593f662e9e613785c0d46ede1834215c8060f6d Mon Sep 17 00:00:00 2001 From: Andreas Dilger Date: Thu, 28 Apr 2011 02:07:58 -0600 Subject: [PATCH] LU-113: add .spec file for RHEL6 split packages Add .spec file from RHEL6 to handle multiple split RPM packages to avoid conflicts while installing the resulting e2fsprogs RPMs. Fix warnings that result from building on a RHEL6 system. Also resolve LU 44 build problem when --disable-lfsck is given. Signed-off-by: Andreas Dilger Change-Id: Ib6b7e6789aed75ab2afd12e216605552498613c7 --- patches/ChangeLog | 4 +- .../e2fsprogs-1.40.4-sb_feature_check_ignore.patch | 35 + patches/e2fsprogs-attr_cleanup.patch | 29 +- patches/e2fsprogs-data_in_dirent.patch | 12 - patches/e2fsprogs-e2scan.patch | 41 +- patches/e2fsprogs-fiemap-lustre.patch | 6 +- patches/e2fsprogs-large-ea.patch | 12 - patches/e2fsprogs-lfsck.patch | 44 +- patches/e2fsprogs-misc.patch | 94 ++- patches/e2fsprogs-mmp.patch | 12 +- patches/e2fsprogs-rpm_RHEL-6.patch | 900 +++++++++++++++++++++ ...m_support.patch => e2fsprogs-rpm_SLES-11.patch} | 92 +-- patches/e2fsprogs-specdotin.patch | 27 +- patches/series | 4 +- patches/sles/libcom_err-no-static-buffer.patch | 24 +- 15 files changed, 1171 insertions(+), 165 deletions(-) create mode 100644 patches/e2fsprogs-1.40.4-sb_feature_check_ignore.patch create mode 100644 patches/e2fsprogs-rpm_RHEL-6.patch rename patches/{e2fsprogs-rpm_support.patch => e2fsprogs-rpm_SLES-11.patch} (95%) diff --git a/patches/ChangeLog b/patches/ChangeLog index a9c67e5..541e9c8 100644 --- a/patches/ChangeLog +++ b/patches/ChangeLog @@ -1,5 +1,5 @@ -2011-01-20 Whamcloud, Inc. - * version 1.41.14.wc1 +tbd Whamcloud, Inc. + * version 1.42.0.wc1 Severity : enhancement Description: update to latest upstream e2fsprogs release diff --git a/patches/e2fsprogs-1.40.4-sb_feature_check_ignore.patch b/patches/e2fsprogs-1.40.4-sb_feature_check_ignore.patch new file mode 100644 index 0000000..0630a68 --- /dev/null +++ b/patches/e2fsprogs-1.40.4-sb_feature_check_ignore.patch @@ -0,0 +1,35 @@ +Index: e2fsprogs-1.41.5/e2fsck/super.c +=================================================================== +--- e2fsprogs-1.41.5.orig/e2fsck/super.c ++++ e2fsprogs-1.41.5/e2fsck/super.c +@@ -869,7 +869,11 @@ void check_super_block(e2fsck_t ctx) + * unfortunately, we shouldn't ignore it since if it's not set in the + * backup, the extended attributes in the filesystem will be stripped + * away. ++ * ++ * Well, I'm still going that route for now, 'til I do something ++ * better. Full-fsck after a fresh install is just no good. -ERS + */ ++#define FEATURE_COMPAT_IGNORE (EXT2_FEATURE_COMPAT_EXT_ATTR) + #define FEATURE_RO_COMPAT_IGNORE (EXT2_FEATURE_RO_COMPAT_LARGE_FILE| \ + EXT4_FEATURE_RO_COMPAT_DIR_NLINK) + #define FEATURE_INCOMPAT_IGNORE (EXT3_FEATURE_INCOMPAT_EXTENTS| \ +@@ -921,6 +925,9 @@ int check_backup_super_block(e2fsck_t ct + (EXT2_INODE_SIZE(backup_sb) < EXT2_GOOD_OLD_INODE_SIZE)) + continue; + ++#define SUPER_COMPAT_DIFFERENT(x) \ ++ ((fs->super->x & ~FEATURE_COMPAT_IGNORE) != \ ++ (backup_sb->x & ~FEATURE_COMPAT_IGNORE)) + #define SUPER_INCOMPAT_DIFFERENT(x) \ + ((fs->super->x & ~FEATURE_INCOMPAT_IGNORE) != \ + (backup_sb->x & ~FEATURE_INCOMPAT_IGNORE)) +@@ -930,7 +937,7 @@ int check_backup_super_block(e2fsck_t ct + #define SUPER_DIFFERENT(x) \ + (fs->super->x != backup_sb->x) + +- if (SUPER_DIFFERENT(s_feature_compat) || ++ if (SUPER_COMPAT_DIFFERENT(s_feature_compat) || + SUPER_INCOMPAT_DIFFERENT(s_feature_incompat) || + SUPER_RO_COMPAT_DIFFERENT(s_feature_ro_compat) || + SUPER_DIFFERENT(s_blocks_count) || diff --git a/patches/e2fsprogs-attr_cleanup.patch b/patches/e2fsprogs-attr_cleanup.patch index b216a79..d24aad8 100644 --- a/patches/e2fsprogs-attr_cleanup.patch +++ b/patches/e2fsprogs-attr_cleanup.patch @@ -314,7 +314,7 @@ Index: e2fsprogs/lib/ext2fs/tst_read_ea.c =================================================================== --- /dev/null +++ e2fsprogs/lib/ext2fs/tst_read_ea.c -@@ -0,0 +1,219 @@ +@@ -0,0 +1,233 @@ +/* + * tst_getsize.c --- this function tests the getsize function + * @@ -324,6 +324,9 @@ Index: e2fsprogs/lib/ext2fs/tst_read_ea.c + * %End-Header% + */ + ++#ifndef _GNU_SOURCE ++#define _GNU_SOURCE /* for asprintf */ ++#endif +#include +#include +#if HAVE_UNISTD_H @@ -333,6 +336,17 @@ Index: e2fsprogs/lib/ext2fs/tst_read_ea.c +#include +#include +#include ++#ifdef HAVE_ATTR_XATTR_H ++#include ++#elif HAVE_SYS_XATTR_H ++#include ++#else ++/* This is just a test program, let's try to work around the lack of header */ ++extern ssize_t fgetxattr (int __filedes, const char *__name, ++ void *__value, size_t __size); ++extern int fsetxattr (int __filedes, const char *__name, ++ const void *__value, size_t __size, int __flags); ++#endif +#include +#include +#if HAVE_ERRNO_H @@ -534,3 +548,16 @@ Index: e2fsprogs/lib/ext2fs/tst_read_ea.c + "\thope it is ok\n"); + return 0; +} +Index: e2fsprogs/configure.in +=================================================================== +--- e2fsprogs.orig/configure.in ++++ e2fsprogs/configure.in +@@ -747,7 +747,7 @@ if test $cross_compiling = no; then + else + AC_CHECK_PROGS(BUILD_CC, gcc cc) + fi +-AC_CHECK_HEADERS(dirent.h errno.h getopt.h malloc.h mntent.h paths.h semaphore.h setjmp.h signal.h stdarg.h stdint.h stdlib.h termios.h termio.h unistd.h utime.h linux/fd.h linux/major.h net/if_dl.h netinet/in.h sys/disklabel.h sys/file.h sys/ioctl.h sys/mkdev.h sys/mman.h sys/prctl.h sys/queue.h sys/resource.h sys/select.h sys/socket.h sys/sockio.h sys/stat.h sys/syscall.h sys/sysmacros.h sys/time.h sys/types.h sys/un.h sys/wait.h) ++AC_CHECK_HEADERS(attr/xattr.h dirent.h errno.h getopt.h malloc.h mntent.h paths.h semaphore.h setjmp.h signal.h stdarg.h stdint.h stdlib.h termios.h termio.h unistd.h utime.h linux/fd.h linux/major.h net/if_dl.h netinet/in.h sys/disklabel.h sys/file.h sys/ioctl.h sys/mkdev.h sys/mman.h sys/prctl.h sys/queue.h sys/resource.h sys/select.h sys/socket.h sys/sockio.h sys/stat.h sys/syscall.h sys/sysmacros.h sys/time.h sys/types.h sys/un.h sys/wait.h sys/xattr.h) + AC_CHECK_HEADERS(sys/disk.h sys/mount.h,,, + [[ + #if HAVE_SYS_QUEUE_H diff --git a/patches/e2fsprogs-data_in_dirent.patch b/patches/e2fsprogs-data_in_dirent.patch index bb2db8b..af89e65 100644 --- a/patches/e2fsprogs-data_in_dirent.patch +++ b/patches/e2fsprogs-data_in_dirent.patch @@ -1,15 +1,3 @@ -Index: e2fsprogs/lib/blkid/probe.h -=================================================================== ---- e2fsprogs.orig/lib/blkid/probe.h -+++ e2fsprogs/lib/blkid/probe.h -@@ -120,6 +120,7 @@ struct ext2_super_block { - #define EXT4_FEATURE_INCOMPAT_MMP 0x0100 - #define EXT4_FEATURE_INCOMPAT_FLEX_BG 0x0200 - #define EXT4_FEATURE_INCOMPAT_EA_INODE 0x0400 -+#define EXT4_FEATURE_INCOMPAT_DIRDATA 0x1000 - - #define EXT2_FEATURE_RO_COMPAT_SUPP (EXT2_FEATURE_RO_COMPAT_SPARSE_SUPER| \ - EXT2_FEATURE_RO_COMPAT_LARGE_FILE| \ Index: e2fsprogs/lib/e2p/feature.c =================================================================== --- e2fsprogs.orig/lib/e2p/feature.c diff --git a/patches/e2fsprogs-e2scan.patch b/patches/e2fsprogs-e2scan.patch index 311c373..49d22c6 100644 --- a/patches/e2fsprogs-e2scan.patch +++ b/patches/e2fsprogs-e2scan.patch @@ -42,7 +42,7 @@ Index: e2fsprogs/configure.in AC_FUNC_VPRINTF dnl Check to see if dirent has member d_reclen. On cygwin those d_reclen dnl is not decleared. -@@ -954,6 +980,51 @@ AC_CHECK_LIB(db-4.8, db_env_create, +@@ -954,6 +980,52 @@ AC_CHECK_LIB(db-4.8, db_env_create, AC_DEFINE(HAVE_DB4)]) AC_SUBST(DB4VERSION) dnl @@ -50,8 +50,9 @@ Index: e2fsprogs/configure.in +dnl +AC_ARG_WITH( + [sqlite3], -+ [ --with-sqlite3=DIR location of sqlite3 library (default /usr/lib)],, -+ [with_sqlite3=/usr/lib]) ++ [ --with-sqlite3=DIR location of sqlite3 library (default /usr/lib)], ++ [SQLITE3_LIBS="-L$with_sqlite3"],, ++ [SQLITE3_LIBS="-L/usr/lib64 -L/usr/lib"]) + +dnl do not check sqlite3 library if e2scan is disabled +if test x"$E2SCAN_CMT" == x; then @@ -61,10 +62,10 @@ Index: e2fsprogs/configure.in +dnl +dnl check static sqlite3 first +dnl -+CFLAGS="$CFLAGS_OLD -L$with_sqlite3 -static -pthread" ++CFLAGS="$CFLAGS_OLD $SQLITE3_LIBS -static -pthread" +AC_CHECK_LIB(sqlite3, sqlite3_open, + [ -+ SQLITE3_LIB="-L$with_sqlite3 -static -pthread -lsqlite3" ++ SQLITE3_LIB="$SQLITE3_LIBS -static -pthread -lsqlite3" + AC_DEFINE(HAVE_SQLITE3) + ]) + @@ -73,10 +74,10 @@ Index: e2fsprogs/configure.in +dnl static sqlite3 is not found, check dynamic sqlite3 +dnl + AC_MSG_WARN(no static sqlite3 - looking for dynamic one) -+ CFLAGS="$CFLAGS_OLD -L$with_sqlite3 -pthread" ++ CFLAGS="$CFLAGS_OLD $SQLITE3_LIBS -pthread" + AC_CHECK_LIB(sqlite3, sqlite3_close, + [ -+ SQLITE3_LIB="-L$with_sqlite3 -pthread -lsqlite3" ++ SQLITE3_LIB="$SQLITE3_LIBS -pthread -lsqlite3" + AC_DEFINE(HAVE_SQLITE3) + ]) +fi @@ -107,14 +108,14 @@ Index: e2fsprogs/e2fsprogs.spec.in =================================================================== --- e2fsprogs.orig/e2fsprogs.spec.in +++ e2fsprogs/e2fsprogs.spec.in -@@ -150,6 +150,7 @@ exit 0 - %{_sbindir}/e2freefrag - %{_sbindir}/e4defrag - @LFSCK_CMT@%{_sbindir}/lfsck +@@ -146,6 +146,7 @@ exit 0 + %{_root_sbindir}/mkfs.ext4dev + %{_root_sbindir}/resize2fs + %{_root_sbindir}/tune2fs +@E2SCAN_CMT@%{_sbindir}/e2scan - - %{_root_libdir}/libblkid.so.* - %{_root_libdir}/libcom_err.so.* + %{_sbindir}/filefrag + %{_sbindir}/mklost+found + %{_sbindir}/e2freefrag @@ -183,6 +184,7 @@ exit 0 %{_mandir}/man8/fsck.ext4dev.8* %{_mandir}/man8/e2image.8* @@ -518,7 +519,7 @@ Index: e2fsprogs/e2scan/e2scan.c =================================================================== --- /dev/null +++ e2fsprogs/e2scan/e2scan.c -@@ -0,0 +1,640 @@ +@@ -0,0 +1,639 @@ +#define _GNU_SOURCE +#define _FILE_OFFSET_BITS 64 +#define _XOPEN_SOURCE /* for getdate */ @@ -830,8 +831,8 @@ Index: e2fsprogs/e2scan/e2scan.c + ext2_ino_t ino; + dgrp_t nr; + time_t t; ++ pid_t pid = 0; + int c; -+ pid_t pid; + + /* + * by default find for files which are modified less than one @@ -910,7 +911,6 @@ Index: e2fsprogs/e2scan/e2scan.c + NULL, + }; + const char **fmt; -+ char *ret; + struct tm tmptm, *tm = NULL; + time_t now = time(0); + @@ -1309,7 +1309,7 @@ Index: e2fsprogs/e2scan/filelist.c =================================================================== --- /dev/null +++ e2fsprogs/e2scan/filelist.c -@@ -0,0 +1,455 @@ +@@ -0,0 +1,456 @@ +#define _GNU_SOURCE +#define _FILE_OFFSET_BITS 64 + @@ -1476,7 +1476,8 @@ Index: e2fsprogs/e2scan/filelist.c + dentry->name, namelen, name); + exit(1); + } -+ asprintf(&dentry->name, "%.*s", namelen, name); ++ if (asprintf(&dentry->name, "%.*s", namelen, name) == -1) ++ dentry->name = "unable to allocate filename"; /* XXX: handle */ +} + +/* @@ -1700,7 +1701,7 @@ Index: e2fsprogs/e2scan/filelist.c + struct ext2_dir_entry *dirent, + int namelen) +{ -+ struct e2scan_dentry *dir, *subdir; ++ struct e2scan_dentry *dir, *subdir = NULL; + int created; + int ret; + struct ext2_dir_entry_2 *dirent2; diff --git a/patches/e2fsprogs-fiemap-lustre.patch b/patches/e2fsprogs-fiemap-lustre.patch index 0f8ee40..9d2e542 100644 --- a/patches/e2fsprogs-fiemap-lustre.patch +++ b/patches/e2fsprogs-fiemap-lustre.patch @@ -386,8 +386,8 @@ Index: e2fsprogs/misc/filefrag.c + } + count++; + if (force_extent && -+ (last_block && (block != last_block + 1) || -+ fm_ext.fe_logical + fm_ext.fe_length != logical)) { ++ (last_block && ((block != last_block + 1) || ++ fm_ext.fe_logical + fm_ext.fe_length != logical))) { + print_extent_info(&fm_ext, *num_extents - 1, + blk_shift, fileinfo); + fm_ext.fe_logical = logical; @@ -428,7 +428,7 @@ Index: e2fsprogs/misc/filefrag.c - int num_extents = 0, expected; + unsigned long numblocks; + int data_blocks_per_cyl = 1; -+ int num_extents = 1, expected; ++ int num_extents = 1, expected = ~0; int is_ext2 = 0; - static int once = 1; + static int last_device; diff --git a/patches/e2fsprogs-large-ea.patch b/patches/e2fsprogs-large-ea.patch index e3ad594..8bf9e24 100644 --- a/patches/e2fsprogs-large-ea.patch +++ b/patches/e2fsprogs-large-ea.patch @@ -361,18 +361,6 @@ Index: e2fsprogs/e2fsck/problem.h /* * Pass 1b errors */ -Index: e2fsprogs/lib/blkid/probe.h -=================================================================== ---- e2fsprogs.orig/lib/blkid/probe.h -+++ e2fsprogs/lib/blkid/probe.h -@@ -119,6 +119,7 @@ struct ext2_super_block { - #define EXT4_FEATURE_INCOMPAT_64BIT 0x0080 - #define EXT4_FEATURE_INCOMPAT_MMP 0x0100 - #define EXT4_FEATURE_INCOMPAT_FLEX_BG 0x0200 -+#define EXT4_FEATURE_INCOMPAT_EA_INODE 0x0400 - - #define EXT2_FEATURE_RO_COMPAT_SUPP (EXT2_FEATURE_RO_COMPAT_SPARSE_SUPER| \ - EXT2_FEATURE_RO_COMPAT_LARGE_FILE| \ Index: e2fsprogs/lib/e2p/feature.c =================================================================== --- e2fsprogs.orig/lib/e2p/feature.c diff --git a/patches/e2fsprogs-lfsck.patch b/patches/e2fsprogs-lfsck.patch index 43743cd..79fbeab 100644 --- a/patches/e2fsprogs-lfsck.patch +++ b/patches/e2fsprogs-lfsck.patch @@ -726,25 +726,24 @@ Index: e2fsprogs/e2fsprogs.spec.in Provides: e2fsprogs-libs = %{version} ldiskfsprogs = %{version} Obsoletes: e4fsprogs e2fsprogs-libs < %{version} %endif -@@ -71,8 +75,8 @@ SMP systems. - %setup +@@ -72,7 +76,8 @@ SMP systems. %build --%configure --enable-elf-shlibs --enable-nls \ + %configure --enable-elf-shlibs --enable-nls --disable-defrag \ - %{?extra_config_flags:%extra_config_flags} -+%configure --enable-elf-shlibs --enable-nls --with-lustre=@LUSTRE@ \ -+ %{?extra_config_flags:%extra_config_flags} @LFSCK_CMT@ --enable-lfsck ++ %{?extra_config_flags:%extra_config_flags} \ ++ --with-lustre=@LUSTRE@ @LFSCK_CMT@ --enable-lfsck make make check -@@ -145,6 +149,7 @@ exit 0 +@@ -142,6 +146,7 @@ exit 0 + %{_root_sbindir}/resize2fs + %{_root_sbindir}/tune2fs + %{_sbindir}/filefrag ++@LFSCK_CMT@%{_sbindir}/lfsck %{_sbindir}/mklost+found %{_sbindir}/e2freefrag - %{_sbindir}/e4defrag -+@LFSCK_CMT@%{_sbindir}/lfsck - %{_root_libdir}/libblkid.so.* - %{_root_libdir}/libcom_err.so.* @@ -170,6 +175,7 @@ exit 0 %{_mandir}/man8/debugfs.8* %{_mandir}/man8/dumpe2fs.8* @@ -840,7 +839,7 @@ Index: e2fsprogs/e2fsck/lfsck.c =================================================================== --- /dev/null +++ e2fsprogs/e2fsck/lfsck.c -@@ -0,0 +1,2088 @@ +@@ -0,0 +1,2096 @@ +/* -*- mode: c; c-basic-offset: 8; -*- + * vim:shiftwidth=8:tabstop=8: + * @@ -2358,8 +2357,8 @@ Index: e2fsprogs/e2fsck/lfsck.c + progname, path, strerror(errno)); + continue; + } -+ VERBOSE(3, "clearning locks in %s\n", path); -+ write(fd, "clear", 6); ++ VERBOSE(3, "clearing locks in %s\n", path); ++ rc = write(fd, "clear", 6); + close(fd); + } + @@ -2371,9 +2370,16 @@ Index: e2fsprogs/e2fsck/lfsck.c + * the client if it tries to attach two inodes to the same object */ +static void lfsck_drop_caches(void) +{ ++ int fd, rc; ++ + sync(); + llapi_cancel_osc_locks(mnt_path); -+ system("echo 3 > /proc/sys/vm/drop_caches"); ++ fd = open("/proc/sys/vm/drop_caches", O_WRONLY); ++ if (fd < 0) ++ return; ++ VERBOSE(3, "flushing vm cache\n"); ++ rc = write(fd, "3", 2); ++ close(fd); +} + +/* Duplicate an object that is referenced by multiple files and point one @@ -2535,7 +2541,8 @@ Index: e2fsprogs/e2fsck/lfsck.c + + snprintf(tmp, sizeof(tmp) - 1, "rm -rvf '%s'", dupedir); + VERBOSE(1, "%s\n", tmp); -+ system(tmp); ++ if (system(tmp) == -1) ++ VERBOSE(1, "%s failed", tmp); + + log_write("lfsck: pass4 finished\n"); + @@ -2933,7 +2940,7 @@ Index: e2fsprogs/lib/ext2fs/lfsck.h =================================================================== --- /dev/null +++ e2fsprogs/lib/ext2fs/lfsck.h -@@ -0,0 +1,322 @@ +@@ -0,0 +1,323 @@ +#undef PACKAGE +#undef VERSION +#ifndef LFSCK_H @@ -3226,7 +3233,7 @@ Index: e2fsprogs/lib/ext2fs/lfsck.h +int lfsck_get_fid(ext2_filsys fs, ino_t ino, struct lu_fid *fid); +int lfsck_is_dirfid_root(const struct lu_fid *dirfid); +int lfsck_fidcmp(const struct lu_fid *fid1, const struct lu_fid *fid2); -+#endif /* FSCK_ON */ ++#endif /* FSCK_OK */ + +#define MDS_START_DIRENT_TABLE sizeof(struct lfsck_mds_hdr) + @@ -3249,7 +3256,8 @@ Index: e2fsprogs/lib/ext2fs/lfsck.h +#define OST_START_OFFSET sizeof(struct lfsck_ost_hdr) + +#else /* !ENABLE_LFSCK */ -+#define e2fsck_lfsck_found_ea(ctx, ino, inode, entry, value) (0) ++#define e2fsck_lfsck_find_ea(ctx, inode, entry, value, lmm, lma) (0) ++#define e2fsck_lfsck_save_ea(ctx, ino, generation, lmm, lma) do {} while(0) +#define e2fsck_lfsck_flush_ea(ctx) (0) +#define e2fsck_lfsck_cleanupdb(ctx) (0) +#define e2fsck_lfsck_remove_pending(ctx, block_buf) (0) diff --git a/patches/e2fsprogs-misc.patch b/patches/e2fsprogs-misc.patch index 4e21c65..84a0bd6 100644 --- a/patches/e2fsprogs-misc.patch +++ b/patches/e2fsprogs-misc.patch @@ -6,20 +6,6 @@ but 0 seems reasonable, and is better than random garbage. Signed-off-by: Andreas Dilger -Index: e2fsprogs/lib/blkid/probe.c -=================================================================== ---- e2fsprogs.orig/lib/blkid/probe.c -+++ e2fsprogs/lib/blkid/probe.c -@@ -1296,7 +1296,8 @@ static int probe_hfsplus(struct blkid_pr - return 0; - - label_len = blkid_be16(key->unicode_len) * 2; -- unicode_16be_to_utf8(label, sizeof(label), key->unicode, label_len); -+ unicode_16be_to_utf8((unsigned char *)label, sizeof(label), -+ key->unicode, label_len); - blkid_set_tag(probe->dev, "LABEL", label, 0); - return 0; - } Index: e2fsprogs/debugfs/debugfs.c =================================================================== --- e2fsprogs.orig/debugfs/debugfs.c @@ -175,23 +161,7 @@ Index: e2fsprogs/e2fsprogs.spec.in =================================================================== --- e2fsprogs.orig/e2fsprogs.spec.in +++ e2fsprogs/e2fsprogs.spec.in -@@ -135,6 +135,7 @@ exit 0 - %{_sbindir}/filefrag - %{_sbindir}/mklost+found - %{_sbindir}/e2freefrag -+%{_sbindir}/e4defrag - - %{_root_libdir}/libblkid.so.* - %{_root_libdir}/libcom_err.so.* -@@ -180,6 +181,7 @@ exit 0 - %{_mandir}/man8/tune2fs.8* - %{_mandir}/man8/filefrag.8* - %{_mandir}/man8/e2freefrag.8* -+%{_mandir}/man8/e4defrag.8* - - %files devel - %defattr(-,root,root) -@@ -212,6 +214,7 @@ exit 0 +@@ -212,6 +212,7 @@ exit 0 %{_includedir}/blkid %{_includedir}/e2p %{_includedir}/et @@ -199,6 +169,42 @@ Index: e2fsprogs/e2fsprogs.spec.in %{_includedir}/ext2fs %{_includedir}/ss %{_includedir}/uuid +Index: e2fsprogs/lib/e2p/ls.c +=================================================================== +--- e2fsprogs.orig/lib/e2p/ls.c ++++ e2fsprogs/lib/e2p/ls.c +@@ -370,7 +370,7 @@ void list_super2(struct ext2_super_block + tm = sb->s_first_error_time; + fprintf(f, "First error time: %s", ctime(&tm)); + memset(buf, 0, sizeof(buf)); +- strncpy(buf, sb->s_first_error_func, ++ strncpy(buf, (char *)sb->s_first_error_func, + sizeof(sb->s_first_error_func)); + fprintf(f, "First error function: %s\n", buf); + fprintf(f, "First error line #: %u\n", +@@ -384,7 +384,7 @@ void list_super2(struct ext2_super_block + tm = sb->s_last_error_time; + fprintf(f, "Last error time: %s", ctime(&tm)); + memset(buf, 0, sizeof(buf)); +- strncpy(buf, sb->s_last_error_func, ++ strncpy(buf, (char *)sb->s_last_error_func, + sizeof(sb->s_last_error_func)); + fprintf(f, "Last error function: %s\n", buf); + fprintf(f, "Last error line #: %u\n", +Index: e2fsprogs/lib/ext2fs/ext2_io.h +=================================================================== +--- e2fsprogs.orig/lib/ext2fs/ext2_io.h ++++ e2fsprogs/lib/ext2fs/ext2_io.h +@@ -117,6 +117,9 @@ extern errcode_t io_channel_read_blk64(i + extern errcode_t io_channel_write_blk64(io_channel channel, + unsigned long long block, + int count, const void *data); ++extern errcode_t io_channel_discard(io_channel channel, ++ unsigned long long block, ++ unsigned long long count); + + /* unix_io.c */ + extern io_manager unix_io_manager; Index: e2fsprogs/lib/ext2fs/ext2fs.h =================================================================== --- e2fsprogs.orig/lib/ext2fs/ext2fs.h @@ -287,6 +293,19 @@ Index: e2fsprogs/lib/ext2fs/progress.c if (!(fs->flags & EXT2_FLAG_PRINT_PROGRESS)) return; fprintf(stdout, "%.*s", (2*progress->log_max)+1, spaces); +Index: e2fsprogs/lib/ext2fs/res_gdt.c +=================================================================== +--- e2fsprogs.orig/lib/ext2fs/res_gdt.c ++++ e2fsprogs/lib/ext2fs/res_gdt.c +@@ -75,7 +75,7 @@ errcode_t ext2fs_create_resize_inode(ext + + retval = ext2fs_get_array(2, fs->blocksize, &dindir_buf); + if (retval) +- goto out_free; ++ return retval; + gdt_buf = (__u32 *)((char *)dindir_buf + fs->blocksize); + + retval = ext2fs_read_inode(fs, EXT2_RESIZE_INO, &inode); Index: e2fsprogs/lib/ext2fs/unix_io.c =================================================================== --- e2fsprogs.orig/lib/ext2fs/unix_io.c @@ -349,6 +368,19 @@ Index: e2fsprogs/misc/e2undo.c tdb_file = argv[optind]; device_name = argv[optind+1]; +Index: e2fsprogs/misc/mke2fs.c +=================================================================== +--- e2fsprogs.orig/misc/mke2fs.c ++++ e2fsprogs/misc/mke2fs.c +@@ -2014,7 +2014,7 @@ static int mke2fs_discard_device(ext2_fi + if (cur + count > blocks) + count = blocks - cur; + +- retval = io_channel_discard(fs->io, cur, count, fs->blocksize); ++ retval = io_channel_discard(fs->io, cur, count); + if (cur == 0) { + /* If discard is unimplemented skip the progress bar */ + if (retval == EXT2_ET_UNIMPLEMENTED) Index: e2fsprogs/misc/tune2fs.8.in =================================================================== --- e2fsprogs.orig/misc/tune2fs.8.in diff --git a/patches/e2fsprogs-mmp.patch b/patches/e2fsprogs-mmp.patch index d29ab5f..0fa380b 100644 --- a/patches/e2fsprogs-mmp.patch +++ b/patches/e2fsprogs-mmp.patch @@ -51,7 +51,7 @@ Index: e2fsprogs/lib/ext2fs/ext2_fs.h #define EXT2_FEATURE_RO_COMPAT_SUPP (EXT2_FEATURE_RO_COMPAT_SPARSE_SUPER| \ EXT2_FEATURE_RO_COMPAT_LARGE_FILE| \ EXT4_FEATURE_RO_COMPAT_DIR_NLINK| \ -@@ -780,26 +781,34 @@ struct ext2_dir_entry_2 { +@@ -780,26 +781,39 @@ struct ext2_dir_entry_2 { /* * This structure will be used for multiple mount protection. It will be * written into the block number saved in the s_mmp_block field in the @@ -63,6 +63,11 @@ Index: e2fsprogs/lib/ext2fs/ext2_fs.h + * superblock. Programs that check MMP should assume that if SEQ_FSCK + * (or any unknown code above SEQ_MAX) is present then it is NOT safe + * to use the filesystem, regardless of how old the timestamp is. ++ * ++ * Note: Only the mmp_seq value is used to determine whether the MMP block ++ * is being updated. The mmp_time, mmp_nodename, and mmp_bdevname ++ * fields can only be for informational purposes for the administrator, ++ * due to clock skew between nodes and hostname HA service takeover. + */ +#define EXT2_MMP_MAGIC 0x004D4D50U /* ASCII for MMP */ +#define EXT2_MMP_SEQ_CLEAN 0xFF4D4D50U /* mmp_seq value for clean unmount */ @@ -1208,7 +1213,7 @@ Index: e2fsprogs/lib/ext2fs/mmp.c =================================================================== --- /dev/null +++ e2fsprogs/lib/ext2fs/mmp.c -@@ -0,0 +1,420 @@ +@@ -0,0 +1,417 @@ +/* + * Helper functions for multiple mount protection(MMP). + * @@ -1408,7 +1413,6 @@ Index: e2fsprogs/lib/ext2fs/mmp.c + +errcode_t ext2fs_mmp_clear(ext2_filsys fs) +{ -+ struct mmp_struct *mmp_s = NULL; + errcode_t retval = 0; + + if (!(fs->super->s_feature_incompat & EXT4_FEATURE_INCOMPAT_MMP) || @@ -1423,7 +1427,6 @@ Index: e2fsprogs/lib/ext2fs/mmp.c +errcode_t ext2fs_mmp_init(ext2_filsys fs) +{ + struct ext2_super_block *sb = fs->super; -+ struct mmp_struct *mmp_s = NULL; + blk_t mmp_block; + errcode_t retval; + @@ -1571,7 +1574,6 @@ Index: e2fsprogs/lib/ext2fs/mmp.c + goto mmp_error; + } + -+check_skipped: + mmp_cmp->mmp_seq = EXT2_MMP_SEQ_CLEAN; + retval = ext2fs_mmp_write(fs, fs->super->s_mmp_block, fs->mmp_cmp); + diff --git a/patches/e2fsprogs-rpm_RHEL-6.patch b/patches/e2fsprogs-rpm_RHEL-6.patch new file mode 100644 index 0000000..eeba2c8 --- /dev/null +++ b/patches/e2fsprogs-rpm_RHEL-6.patch @@ -0,0 +1,900 @@ +Index: e2fsprogs/e2fsprogs-RHEL-6.spec.in +=================================================================== +--- /dev/null ++++ e2fsprogs/e2fsprogs-RHEL-6.spec.in +@@ -0,0 +1,785 @@ ++%define _root_sbindir /sbin ++%define _root_libdir /%{_lib} ++ ++Summary: Utilities for managing ext2, ext3, and ext4 filesystems ++Name: e2fsprogs ++Version: @E2FSPROGS_PKGVER@ ++Release: 7%{?dist} ++ ++# License tags based on COPYING file distinctions for various components ++License: GPLv2 ++Group: System Environment/Base ++Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz ++#[AED] Source1: ext2_types-wrapper.h ++ ++#[AED] Patch1: e2fsprogs-1.40.4-sb_feature_check_ignore.patch ++#[AED] Patch2: e2fsprogs-1.41.12-e4defrag.patch ++ ++Url: http://downloads.whamcloud.com/public/ ++Provides: ldiskfsprogs = %{version} ++@LFSCK_CMT@Requires: db4 >= @DB4VERSION@ ++@LFSCK_CMT@BuildRequires: db4-devel >= 4.1 texinfo ++BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) ++Requires: e2fsprogs-libs = %{version}-%{release} ++ ++# e4fsprogs was a parallel ext4-capable package in RHEL5.x ++%if 0%{?rhel} > 0 ++Obsoletes: e4fsprogs < %{version}-%{release} ++Provides: e4fsprogs = %{version}-%{release} ++%endif ++ ++BuildRequires: pkgconfig, texinfo, libselinux-devel ++BuildRequires: libsepol-devel ++BuildRequires: libblkid-devel ++BuildRequires: libuuid-devel ++ ++%description ++The e2fsprogs package contains a number of utilities for creating, ++checking, modifying, and correcting any inconsistencies in second, ++third and fourth extended (ext2/ext3/ext4) filesystems. E2fsprogs ++contains e2fsck (used to repair filesystem inconsistencies after an ++unclean shutdown), mke2fs (used to initialize a partition to contain ++an empty ext2 filesystem), debugfs (used to examine the internal ++structure of a filesystem, to manually repair a corrupted ++filesystem, or to create test cases for e2fsck), tune2fs (used to ++modify filesystem parameters), and most of the other core ext2fs ++filesystem utilities. ++ ++You should install the e2fsprogs package if you need to manage the ++performance of an ext2, ext3, or ext4 filesystem. ++ ++%package libs ++Summary: Ext2/3/4 filesystem-specific shared libraries ++Group: Development/Libraries ++License: GPLv2 and LGPLv2 ++ ++%description libs ++E2fsprogs-libs contains libe2p and libext2fs, the libraries of the ++e2fsprogs package. ++ ++These libraries are used to directly acccess ext2/3/4 filesystems ++from userspace. ++ ++%package static ++Summary: Ext2/3/4 filesystem-specific static libraries ++Group: Development/Libraries ++License: GPLv2 and LGPLv2 ++ ++%description static ++E2fsprogs-static contains all static libraries built from e2fsprogs, ++including libext2fs, libcom_err, libe2p, and libss. ++ ++These libraries are used to directly acccess ext2/3/4 filesystems ++from userspace, and perform other useful functions. ++ ++%package devel ++Summary: Ext2/3/4 filesystem-specific libraries and headers ++Group: Development/Libraries ++License: GPLv2 and LGPLv2 ++Requires: e2fsprogs-libs = %{version}-%{release} ++Requires: gawk ++Requires: libcom_err-devel ++Requires: pkgconfig ++Requires(post): info ++Requires(preun): info ++ ++%description devel ++E2fsprogs-devel contains the libraries and header files needed to ++develop second, third and fourth extended (ext2/ext3/ext4) ++filesystem-specific programs. ++ ++You should install e2fsprogs-devel if you want to develop ext2/3/4 ++filesystem-specific programs. If you install e2fsprogs-devel, you'll ++also want to install e2fsprogs. ++ ++%package -n libcom_err ++Summary: Common error description library ++Group: Development/Libraries ++License: MIT ++ ++%description -n libcom_err ++This is the common error description library, part of e2fsprogs. ++ ++libcom_err is an attempt to present a common error-handling mechanism. ++ ++%package -n libcom_err-devel ++Summary: Common error description library ++Group: Development/Libraries ++License: MIT ++Requires: libcom_err = %{version}-%{release} ++Requires: pkgconfig ++ ++%description -n libcom_err-devel ++This is the common error description development library and headers, ++part of e2fsprogs. It contains the compile_et commmand, used ++to convert a table listing error-code names and associated messages ++messages into a C source file suitable for use with the library. ++ ++libcom_err is an attempt to present a common error-handling mechanism. ++ ++%package -n libss ++Summary: Command line interface parsing library ++Group: Development/Libraries ++License: MIT ++ ++%description -n libss ++This is libss, a command line interface parsing library, part of e2fsprogs. ++ ++This package includes a tool that parses a command table to generate ++a simple command-line interface parser, the include files needed to ++compile and use it. ++ ++It was originally inspired by the Multics SubSystem library. ++ ++%package -n libss-devel ++Summary: Command line interface parsing library ++Group: Development/Libraries ++License: MIT ++Requires: libss = %{version}-%{release} ++Requires: pkgconfig ++ ++%description -n libss-devel ++This is the command line interface parsing (libss) development library ++and headers, part of e2fsprogs. It contains the mk_cmds command, which ++parses a command table to generate a simple command-line interface parser. ++ ++It was originally inspired by the Multics SubSystem library. ++ ++%prep ++%setup -q ++# ignore some flag differences on primary/backup sb feature checks ++# mildly unsafe but 'til I get something better, avoid full fsck ++# after an selinux install... ++#[AED] %patch1 -p1 -b .featurecheck ++# Enable e4defrag for testing ++#[AED] %patch2 -p1 -b .e4defrag ++ ++%build ++%configure --enable-elf-shlibs --enable-nls --disable-uuidd --disable-fsck \ ++ --disable-e2initrd-helper --disable-libblkid --disable-libuuid \ ++ --disable-defrag --with-lustre=@LUSTRE@ @LFSCK_CMT@ --enable-lfsck ++make %{?_smp_mflags} ++ ++%install ++rm -rf %{buildroot} ++export PATH=/sbin:$PATH ++make install install-libs DESTDIR=%{buildroot} INSTALL="%{__install} -p" \ ++ root_sbindir=%{_root_sbindir} root_libdir=%{_root_libdir} ++ ++# ugly hack to allow parallel install of 32-bit and 64-bit -devel packages: ++%define multilib_arches %{ix86} x86_64 ppc ppc64 s390 s390x sparcv9 sparc64 ++ ++%ifarch %{multilib_arches} ++mv -f %{buildroot}%{_includedir}/ext2fs/ext2_types.h \ ++ %{buildroot}%{_includedir}/ext2fs/ext2_types-%{_arch}.h ++mv -f %{buildroot}%{_includedir}/ext2fs/ext2_types-wrapper.h \ ++ %{buildroot}%{_includedir}/ext2fs/ext2_types.h ++%endif ++ ++# Hack for now, otherwise strip fails. ++chmod +w %{buildroot}%{_libdir}/*.a ++ ++%find_lang %{name} ++ ++%check ++make check ++ ++%clean ++rm -rf %{buildroot} ++ ++%post libs -p /sbin/ldconfig ++%postun libs -p /sbin/ldconfig ++ ++%post devel ++# Test for file; if installed with --excludedocs it may not be there ++if [ -f %{_infodir}/libext2fs.info.gz ]; then ++ /sbin/install-info %{_infodir}/libext2fs.info.gz %{_infodir}/dir || : ++fi ++ ++%preun devel ++if [ $1 = 0 -a -f %{_infodir}/libext2fs.info.gz ]; then ++ /sbin/install-info --delete %{_infodir}/libext2fs.info.gz %{_infodir}/dir || : ++fi ++exit 0 ++ ++%post -n libcom_err -p /sbin/ldconfig ++%postun -n libcom_err -p /sbin/ldconfig ++ ++%post -n libss -p /sbin/ldconfig ++%postun -n libss -p /sbin/ldconfig ++ ++%files -f %{name}.lang ++%defattr(-,root,root) ++%doc COPYING README RELEASE-NOTES ++ ++%config(noreplace) /etc/mke2fs.conf ++%{_root_sbindir}/badblocks ++%{_root_sbindir}/debugfs ++%{_root_sbindir}/dumpe2fs ++%{_root_sbindir}/e2fsck ++%{_root_sbindir}/e2image ++%{_root_sbindir}/e2label ++%{_root_sbindir}/e2undo ++%{_root_sbindir}/fsck.ext2 ++%{_root_sbindir}/fsck.ext3 ++%{_root_sbindir}/fsck.ext4 ++%{_root_sbindir}/fsck.ext4dev ++%{_root_sbindir}/logsave ++%{_root_sbindir}/mke2fs ++%{_root_sbindir}/mkfs.ext2 ++%{_root_sbindir}/mkfs.ext3 ++%{_root_sbindir}/mkfs.ext4 ++%{_root_sbindir}/mkfs.ext4dev ++%{_root_sbindir}/resize2fs ++%{_root_sbindir}/tune2fs ++%{_sbindir}/filefrag ++%{_sbindir}/e2freefrag ++@E2SCAN_CMT@%{_sbindir}/e2scan ++@LFSCK_CMT@%{_sbindir}/lfsck ++%{_sbindir}/mklost+found ++ ++%{_bindir}/chattr ++%{_bindir}/lsattr ++%{_mandir}/man1/chattr.1* ++%{_mandir}/man1/lsattr.1* ++ ++%{_mandir}/man5/e2fsck.conf.5* ++%{_mandir}/man5/mke2fs.conf.5* ++ ++%{_mandir}/man8/badblocks.8* ++%{_mandir}/man8/debugfs.8* ++%{_mandir}/man8/dumpe2fs.8* ++%{_mandir}/man8/e2fsck.8* ++%{_mandir}/man8/filefrag.8* ++%{_mandir}/man8/e2freefrag.8* ++%{_mandir}/man8/fsck.ext2.8* ++%{_mandir}/man8/fsck.ext3.8* ++%{_mandir}/man8/fsck.ext4.8* ++%{_mandir}/man8/fsck.ext4dev.8* ++%{_mandir}/man8/e2image.8* ++%{_mandir}/man8/e2label.8* ++@E2SCAN_CMT@%{_mandir}/man8/e2scan.8* ++%{_mandir}/man8/e2undo.8* ++@LFSCK_CMT@%{_mandir}/man8/lfsck.8* ++%{_mandir}/man8/logsave.8* ++%{_mandir}/man8/mke2fs.8* ++%{_mandir}/man8/mkfs.ext2.8* ++%{_mandir}/man8/mkfs.ext3.8* ++%{_mandir}/man8/mkfs.ext4.8* ++%{_mandir}/man8/mkfs.ext4dev.8* ++%{_mandir}/man8/mklost+found.8* ++%{_mandir}/man8/resize2fs.8* ++%{_mandir}/man8/tune2fs.8* ++ ++%files libs ++%defattr(-,root,root) ++%doc COPYING ++%{_root_libdir}/libe2p.so.* ++%{_root_libdir}/libext2fs.so.* ++ ++%files static ++%defattr(-,root,root) ++%doc COPYING ++%{_libdir}/*.a ++ ++%files devel ++%defattr(-,root,root) ++%{_infodir}/libext2fs.info* ++%{_libdir}/libe2p.so ++%{_libdir}/libext2fs.so ++%{_libdir}/pkgconfig/e2p.pc ++%{_libdir}/pkgconfig/ext2fs.pc ++ ++%{_includedir}/e2p ++%{_includedir}/ext2fs ++ ++%files -n libcom_err ++%defattr(-,root,root) ++%doc COPYING ++%{_root_libdir}/libcom_err.so.* ++ ++%files -n libcom_err-devel ++%defattr(-,root,root) ++%{_bindir}/compile_et ++%{_libdir}/libcom_err.so ++%{_datadir}/et ++%{_includedir}/et ++%{_includedir}/com_err.h ++%{_mandir}/man1/compile_et.1* ++%{_mandir}/man3/com_err.3* ++%{_libdir}/pkgconfig/com_err.pc ++ ++%files -n libss ++%defattr(-,root,root) ++%doc COPYING ++%{_root_libdir}/libss.so.* ++ ++%files -n libss-devel ++%defattr(-,root,root) ++%{_bindir}/mk_cmds ++%{_libdir}/libss.so ++%{_datadir}/ss ++%{_includedir}/ss ++%{_mandir}/man1/mk_cmds.1* ++%{_libdir}/pkgconfig/ss.pc ++ ++%changelog ++* Tue Feb 08 2011 Fedora Release Engineering 1.41.14-2 ++- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild ++ ++* Thu Dec 23 2010 Eric Sandeen 1.41.14-1 ++- New upstream release ++ ++* Wed Dec 22 2010 Dan Horák 1.41.13-2 ++- Add upstream fix for big-endian machines ++ ++* Mon Dec 20 2010 Eric Sandeen 1.41.13-1 ++- New upstream release ++ ++* Tue Dec 07 2010 Eric Sandeen 1.41.12-7 ++- Fix up UTF-8 formatting in e2fsck output (#655227) ++ ++* Wed Oct 06 2010 Eric Sandeen 1.41.12-6 ++- Install e4defrag for testing ++ ++* Mon Jul 13 2010 Eric Sandeen 1.41.12-5 ++- Relax fsck requirements for resize2fs -P ++ ++* Mon Jul 12 2010 Eric Sandeen 1.41.12-4 ++- Add COPYING file to the static subpackage ++ ++* Wed Jun 02 2010 Eric Sandeen 1.41.12-3 ++- Reinstate static libs in dedicated package (#596377) ++ ++* Wed May 19 2010 Eric Sandeen 1.41.12-2 ++- Fix fsck thinko in 1.41.12 release ++ ++* Mon May 17 2010 Eric Sandeen 1.41.12-1 ++- New upstream version ++ ++* Mon Mar 15 2010 Eric Sandeen 1.41.11-1 ++- New upstream version ++ ++* Mon Mar 01 2010 Eric Sandeen 1.41.10-5 ++- Don't ask for confirmation of misaligned mkfs with -F (#569021) ++ ++* Tue Feb 23 2010 Eric Sandeen 1.41.10-4 ++- Fix for e2fsck -fD corruption ++ ++* Fri Feb 12 2010 Eric Sandeen 1.41.10-3 ++- And drop virtual provides for static libs ++ ++* Fri Feb 12 2010 Eric Sandeen 1.41.10-2 ++- Drop static libs (#545144) ++ ++* Wed Feb 10 2010 Eric Sandeen 1.41.10-1 ++- New upstream version ++ ++* Sun Feb 07 2010 Eric Sandeen 1.41.9-10 ++- Upstream version of resize2fs array fix, original was wrong ++ ++* Sat Jan 23 2010 Eric Sandeen 1.41.9-9 ++- Fix up stray output & re-enable make check ++- Fix dlopen issues for newer libreadline ++- Fix access beyond end of array in resize2fs ++ ++* Tue Nov 10 2009 Eric Sandeen 1.41.9-8 ++- Fix up topology patch to build w/ new util-linux-ng ++- Fix endian swapping of backup journal blocks in sb ++ ++* Tue Nov 10 2009 Eric Sandeen 1.41.9-7 ++- Re-enable "make check" during build ++ ++* Wed Oct 28 2009 Eric Sandeen 1.41.9-6 ++- Add support for block discard (TRIM) at mkfs time ++- Add support for new blkid topology awareness ++ ++* Mon Oct 19 2009 Eric Sandeen 1.41.9-5 ++- Allow superblock timestamp differences up to 24h (#522969) ++ ++* Tue Oct 06 2009 Eric Sandeen 1.41.9-4 ++- Fix install with --excludedocs (#515987) ++ ++* Thu Sep 14 2009 Eric Sandeen 1.41.9-3 ++- Drop defrag bits for now, not ready yet. ++ ++* Thu Sep 10 2009 Josef Bacik 1.41.9-2 ++- Fix resize -m bug with flexbg (#519131) ++ ++* Sun Aug 23 2009 Eric Sandeen 1.41.9-1 ++- New upstream release ++ ++* Fri Aug 05 2009 Eric Sandeen 1.41.8-6 ++- Fix filefrag in fallback case ++- Add e2freefrag & e4defrag (experimental) ++ ++* Sun Jul 26 2009 Karel Zak 1.41.8-5 ++- disable fsck (replaced by util-linux-ng) ++ ++* Sat Jul 25 2009 Karel Zak 1.41.8-4 ++- disable libuuid and uuidd (replaced by util-linux-ng) ++ ++* Fri Jul 24 2009 Fedora Release Engineering - 1.41.8-3 ++- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild ++ ++* Fri Jul 17 2009 Eric Sandeen 1.41.8-2 ++- Address some package review concerns (#225714) ++ ++* Sun Jul 12 2009 Eric Sandeen 1.41.8-1 ++- New upstream version, several resize fixes. ++ ++* Tue Jun 30 2009 Eric Sandeen 1.41.7-1 ++- New upstream version ++ ++* Fri Jun 26 2009 Eric Sandeen 1.41.6-6 ++- Split out sub-libraries (#225406) ++- Don't start uuidd by default ++ ++* Thu Jun 18 2009 Eric Sandeen 1.41.6-5 ++- Update journal backup blocks in sb after resize (#505339) ++- Fix memory leak in extent handling functions ++- Fix bug in inode writing in extent code, clobbered i_extra_isize etc ++ ++* Mon Jun 8 2009 Karel Zak 1.41.6-4 ++- set BuildRequires: libblkid-devel (from util-linux-ng) ++ ++* Mon Jun 8 2009 Karel Zak 1.41.6-3 ++- temporary use BuildRequires: e2fsprogs-devel (we cannot install ++ new util-linux-ng with libblkid to buildroots without new e2fsprogs ++ without libblkid). ++ ++* Thu Jun 4 2009 Karel Zak 1.41.6-2 ++- disable libblkid (replaced by libblkid from util-linux-ng) ++ ++* Sat May 30 2009 Eric Sandeen 1.41.6-1 ++- New upstream version ++ ++* Fri Apr 24 2009 Eric Sandeen 1.41.5-1 ++- New upstream version ++ ++* Wed Apr 22 2009 Eric Sandeen 1.41.4-8 ++- Fix support for external journals ++ ++* Wed Apr 22 2009 Eric Sandeen 1.41.4-7 ++- Fix ext4 resize issues (#496982) ++ ++* Sat Apr 11 2009 Eric Sandeen 1.41.4-6 ++- ignore differing NEEDS_RECOVERY flag on fsck post-resize (#471925) ++ ++* Thu Feb 26 2009 Eric Sandeen 1.41.4-5 ++- fix a couple missed descriptions; obsolete e4fsprogs ++ ++* Thu Feb 26 2009 Eric Sandeen 1.41.4-4 ++- Edit summary & description to include ext4 (#487469) ++- Fix blkid null ptr deref in initrd (#486997) ++ ++* Tue Feb 24 2009 Fedora Release Engineering - 1.41.4-3 ++- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild ++ ++* Thu Jan 29 2009 Eric Sandeen 1.41.4-2 ++- Fix debugfs "stat" segfault if no open fs (#482894) ++- Fix name of libext2fs info page (#481620) ++ ++* Thu Jan 29 2009 Eric Sandeen 1.41.4-1 ++- New upstream release ++- Dropped btrfs & resize fixes, upstream now ++ ++* Tue Jan 20 2009 Eric Sandeen 1.41.3-4 ++- resize2fs fixes, esp. for ext4 ++ ++* Sat Jan 10 2009 Eric Sandeen 1.41.3-3 ++- Remove conservative "don't change journal location" patch for F11 ++- Add btrfs recognition to blkid ++ ++* Mon Oct 03 2008 Eric Sandeen 1.41.3-2 ++- Bump to revision 2, f10 was behind f9, oops. ++ ++* Mon Oct 03 2008 Eric Sandeen 1.41.3-1 ++- New upstream version (very minor fixes, ext4-related) ++ ++* Thu Oct 02 2008 Eric Sandeen 1.41.2-2 ++- Fix blkid to recognize ext4dev filesystems as ext4-mountable ++ ++* Thu Oct 02 2008 Eric Sandeen 1.41.2-1 ++- New upstream version ++- Updated default dir hash (half_md4) for better perf & fewer collisions ++- Fixed ext4 online resizing with flex_bg ++- ext4 journal now in extents format and in middle of filesystem ++- fix unreadable e2image files ++- fix file descriptor leak in libcom_err (#464689) ++ ++* Sat Aug 23 2008 Eric Sandeen 1.41.0-2 ++- Don't check the group checksum when !GDT_CSUM (#459875) ++ ++* Thu Jul 10 2008 Eric Sandeen 1.41.0-1 ++- New upstream version ++- ext4 capable ++ ++* Mon Jul 07 2008 Eric Sandeen 1.41-0.2.WIP.0707 ++- Fix release macro snafu ++ ++* Mon Jul 07 2008 Eric Sandeen 1.41-0.1.WIP.0707 ++- New upstream snapshot release ++ ++* Fri Jun 20 2008 Eric Sandeen 1.41-0.WIP.0617.1 ++- Fix blkid -g segfault when clearing entries (#452333) ++ ++* Wed Jun 18 2008 Eric Sandeen 1.41-0.WIP.0617 ++- New upstream snapshot release for ext4 capability ++ ++* Wed Jun 04 2008 Eric Sandeen 1.40.10-3 ++- Tidy up multilib hack for non-multilib arches (#446016) ++- Fix up postun script (#449868) ++ ++* Wed Jun 04 2008 Dennis Gilmore 1.40.10-2 ++- setup header support for sparc ++ ++* Fri May 23 2008 Eric Sandeen 1.40.10-1 ++- New upstream version ++- Fixes unprivileged blkid use problem (#448591) ++ ++* Mon May 12 2008 Eric Sandeen 1.40.9-2 ++- Fix blkid swap recognition on big-endian boxes (#445786) ++ ++* Sun Apr 27 2008 Eric Sandeen 1.40.9-1 ++- New upstream version ++ ++* Fri Mar 14 2008 Eric Sandeen 1.40.8-2 ++- Update ext2fs_swap_inode_full() fix to match upstream ++- Check more of swapv1 header in blkid detection (#442937) ++ ++* Fri Mar 14 2008 Eric Sandeen 1.40.8-1 ++- New upstream version ++ ++* Mon Mar 03 2008 Eric Sandeen 1.40.7-2 ++- second try at fixing resize2fs vs. large inodes... (#434893) ++ ++* Fri Feb 29 2008 Eric Sandeen 1.40.7-1 ++- New upstream version, special leap-day edition ++- Fix resize2fs losing inline xattrs when shrinking (#434893) ++ and add patch to fix swap_inode_full in this case ++- Allow mke2fs & tune2fs to manipulate large_file feature (#258381) ++- Handle lvm error conditions in libblkid (#433857) ++- Allow tune2fs to clear the resize_inode feature (#167816) ++- Teach blkid to detect LVM2 physical volumes (#409321) ++- Show "mostly printable" xattrs as text in debugfs (#430621) ++- Trimmed pre-1.38 rpm changelog entries ++ ++* Sun Feb 10 2008 Eric Sandeen 1.40.6-1 ++- New upstream version ++ ++* Fri Feb 08 2008 Eric Sandeen 1.40.5-2 ++- gcc-4.3 rebuild ++ ++* Mon Jan 28 2008 Eric Sandeen 1.40.5-1 ++- New upstream version, drop several now-upstream patches. ++ ++* Thu Jan 24 2008 Eric Sandeen 1.40.4-7 ++- Fix sb flag comparisons properly this time (#428893) ++- Make 256-byte inodes for the [default] mkfs case. ++ This will facilitate upgrades to ext4 later, and help xattr perf. ++ ++* Wed Jan 23 2008 Eric Sandeen 1.40.4-6 ++- Completely clobber e2fsck.static build. ++ ++* Wed Jan 23 2008 Eric Sandeen 1.40.4-5 ++- Ignore some primary/backup superblock flag differences (#428893) ++- Teach libblkid about ext4dev. ++ ++* Mon Jan 10 2008 Eric Sandeen 1.40.4-4 ++- Build e2fsck as a dynamically linked binary. ++- Re-fix uidd manpage default paths. ++ ++* Tue Jan 09 2008 Eric Sandeen 1.40.4-3 ++- New uuidd subpackage, and properly set up uuidd at install. ++ ++* Tue Jan 01 2008 Eric Sandeen 1.40.4-2 ++- Add new uidd files to specfile ++ ++* Tue Jan 01 2008 Eric Sandeen 1.40.4-1 ++- New upstream version, drop several now-upstream patches. ++ ++* Tue Jan 01 2008 Eric Sandeen 1.40.2-15 ++- Drop resize_inode removal patch from tune2fs; ostensibly was ++ for old kernels which could not mount, but seems to be fine. ++- Drop pottcdate removal patch, and don't rebuild .po files, ++ causes multilib problems and we generally shouldn't rebuild. ++- Drop multilib patch; wrapper header should take care of this now. ++- Drop ->open rename, Fedora seems ok with this now. ++ ++* Tue Dec 11 2007 Eric Sandeen 1.40.2-14 ++- Fix integer overflows (#414591 / CVE-2007-5497) ++ ++* Tue Dec 4 2007 Stepan Kasal 1.40.2-13 ++- The -devel package now requires device-mapper-devel, to match ++ the dependency in blkid.pc (#410791) ++ ++* Tue Nov 27 2007 Eric Sandeen 1.40.2-12 ++- Use upstream patch for blkid fat detection, avoids div-by-zero ++ when encountering some BSD partitions (#398281) ++ ++* Tue Oct 23 2007 Eric Sandeen 1.40.2-11 ++- Add arm to multilib header wrapper ++ ++* Sat Oct 20 2007 Eric Sandeen 1.40.2-10 ++- Make (more) file timestamps match those in tarball for multilib tidiness ++- Fix e2fsprogs-libs summary (shared libs not static) ++ ++* Tue Oct 15 2007 Eric Sandeen 1.40.2-9 ++- Detect big-endian squashfs filesystems in libblkid (#305151) ++ ++* Tue Oct 02 2007 Eric Sandeen 1.40.2-8 ++- Detect squashfs filesystems in libblkid (#305151) ++ ++* Tue Sep 18 2007 Eric Sandeen 1.40.2-7 ++- Fix blkid fat probe when there is a real MBR (#290951) ++ ++* Tue Sep 18 2007 Oliver Falk 1.40.2-6 ++- Add alpha to the header wrappers ++ ++* Fri Sep 07 2007 Eric Sandeen 1.40.2-5 ++- wrap a couple headers to fix multilib issues (#270441) ++ ++* Wed Aug 29 2007 Eric Sandeen 1.40.2-4 ++- add gawk to e2fsprogs-devel Requires, compile_et needs it (#265961) ++ ++* Thu Aug 23 2007 Eric Sandeen 1.40.2-3 ++- Update license tags ++- Fix one open-create caller with no mode ++- Protect ->open ops from glibc open-create-mode-checker ++- Fix source URL ++- Add gawk to BuildRequires ++ ++* Wed Jul 18 2007 Eric Sandeen 1.40.2-2 ++- Fix bug in ext2fs_swap_inode_full() on big-endian boxes ++ ++* Tue Jul 17 2007 Eric Sandeen 1.40.2-1 ++- New version 1.40.2 ++- Fix up warning in badblocks ++ ++* Mon Jun 25 2007 Eric Sandeen 1.39-15 ++- Fix up .po files to remove timestamps; multilib issues (#245653) ++ ++* Fri Jun 22 2007 Eric Sandeen 1.39-14 ++- Many coverity-found potential leaks, segfaults, etc (#239354) ++- Fix debugfs segfaults when no fs open (#208416, #209330) ++- Avoid recursive loops in logdump due to symlinks in /dev (#210371) ++- Don't write changes to the backup superblocks by default (#229561) ++- Correct byteswapping for fast symlinks with xattrs (#232663) ++- e2fsck: added sanity check for xattr validation (#230193) ++ ++* Wed Jun 20 2007 Eric Sandeen 1.39-13 ++- add dist tag to release field ++ ++* Wed Jun 20 2007 Eric Sandeen 1.39-12 ++- add LUKS support to libblkid (#242421) ++ ++* Fri Feb 23 2007 Karsten Hopp 1.39-11 ++- fix post/preun requirements ++- use smp flags ++ ++* Mon Feb 05 2007 Alasdair Kergon - 1.39-10 ++- Add build dependency on new device-mapper-devel package. ++ ++* Mon Dec 25 2006 Thomas Woerner - 1.39-9 ++- build fixes for new automake 1.10 (#220715) ++ ++* Mon Dec 18 2006 Thomas Woerner - 1.39-8 ++- make uuid_generate_time generate unique uuids (#218606) ++ ++* Wed Sep 20 2006 Jarod Wilson - 1.39-7 ++- 32-bit 16T fixups from esandeen (#202807) ++- Update summaries and descriptions ++ ++* Sun Sep 17 2006 Karel Zak - 1.39-6 ++- Fix problem with empty FAT label (#206656) ++ ++* Tue Sep 5 2006 Peter Jones - 1.39-5 ++- Fix memory leak in device probing. ++ ++* Mon Jul 24 2006 Thomas Woerner - 1.39-4 ++- fixed multilib devel conflicts (#192665) ++ ++* Thu Jul 20 2006 Bill Nottingham - 1.39-3 ++- prevent libblkid returning /dev/dm-X ++ ++* Wed Jul 12 2006 Jesse Keating - 1.39-2.1 ++- rebuild ++ ++* Mon Jul 10 2006 Karel Zak - 1.39-2 ++- add GFS abd GFS2 support to libblkid ++ ++* Thu Jul 6 2006 Thomas Woerner - 1.39-1 ++- new version 1.39 ++- dropped ext2online, because resize2fs is now able to do online resize ++- spec file cleanup ++- enabled checks for build ++ ++* Tue Jun 13 2006 Bill Nottingham - 1.38-15 ++- prevent libblkid returning /dev/dm-X ++- fix build ++ ++* Tue Mar 21 2006 Karel Zak - 1.38-14 ++- prevent error messages to stderr caused by libblkid calling libdevmapper ++ ++* Mon Mar 13 2006 Karel Zak - 1.38-13 ++- used upstream version of the blkid-epoch patch (by Theodore Tso, #182188) ++ ++* Wed Mar 8 2006 Peter Jones - 1.38-12 ++- Move /etc/blkid.tab to /etc/blkid/blkid.tab ++ ++* Tue Mar 7 2006 David Cantrell - 1.38-11 ++- BuildRequires pkgconfig ++ ++* Tue Mar 7 2006 David Cantrell - 1.38-10 ++- Disable /etc/blkid.tab caching if time is set before epoch (#182188) ++ ++* Fri Feb 24 2006 Peter Jones - 1.38-9 ++- _don't_ handle selinux context on blkid.tab, dwalsh says this is a no-no. ++ ++* Wed Feb 22 2006 Peter Jones - 1.38-8 ++- handle selinux context on blkid.tab ++ ++* Mon Feb 20 2006 Karsten Hopp 1.38-7 ++- BuildRequires: gettext-devel ++ ++* Fri Feb 10 2006 Jesse Keating - 1.38-6.2 ++- bump again for double-long bug on ppc(64) ++ ++* Tue Feb 7 2006 Jesse Keating - 1.38-6.1 ++- rebuilt for new gcc4.1 snapshot and glibc changes ++ ++* Wed Jan 11 2006 Karel Zak 1.38-6 ++- cleanup device-mapper patch ++- use pkg-config for device-mapper ++ ++* Mon Jan 9 2006 Peter Jones 1.38-5 ++- fix some more minor logic errors in dm probing ++ ++* Wed Jan 4 2006 Peter Jones 1.38-4 ++- fix a logic error in dm probing ++- add priority group for dm devices, so they'll be preferred ++ ++* Tue Jan 3 2006 Peter Jones 1.38-3 ++- added support for device-mapper devices ++ ++* Fri Dec 9 2005 Jesse Keating ++- rebuilt ++ ++* Thu Nov 10 2005 Thomas Woerner 1.38-2.1 ++- fixed file conflicts between 32bit and 64bit packages (#168815) ++- fixed mklost+found crashes with buffer overflow (#157773) ++ Thanks to Arjan van de Ven for the patch ++ ++* Wed Nov 9 2005 Thomas Woerner 1.38-2 ++- splitted up libs from main package, into a new e2fsprogs-libs package ++- fixed requires and prereqs ++ ++* Thu Sep 8 2005 Thomas Woerner 1.38-1 ++- new version 1.38 ++- Close File descriptor for unregognized devices (#159878) ++ Thanks to David Milburn for the patch. ++ Merged from RHEL-4 ++- enable tune2fs to set and clear feature resize_inode (#167816) ++- removed outdated information from ext2online man page (#164383) ++ +Index: e2fsprogs/configure.in +=================================================================== +--- e2fsprogs.orig/configure.in ++++ e2fsprogs/configure.in +@@ -1233,6 +1233,7 @@ test -d lib || mkdir lib + test -d include/linux || mkdir include/linux + test -d include/asm || mkdir include/asm + for i in MCONFIG Makefile e2fsprogs.spec \ ++ e2fsprogs-RHEL-6.spec \ + util/Makefile util/subst.conf util/gen-tarball \ + lib/et/Makefile lib/ss/Makefile lib/e2p/Makefile \ + lib/ext2fs/Makefile lib/ext2fs/ext2_types.h \ +Index: e2fsprogs/contrib/build-rpm +=================================================================== +--- e2fsprogs.orig/contrib/build-rpm ++++ e2fsprogs/contrib/build-rpm +@@ -34,11 +34,46 @@ EXCLUDE="--exclude .hg* --exclude .pc*" + + [ "`rpmbuild --version 2> /dev/null`" ] && RPM=rpmbuild || RPM=rpm + ++# which distro and release ++DISTRO=$(lsb_release -is) ++RELEASE=$(lsb_release -rs) ++# now the hacks in case either is empty ++if [ -z "$DISTRO" ]; then ++ echo "You really ought to install the lsb_release binary for this distro" ++ if grep "Fedora " /etc/issue; then ++ DISTRO="Fedora" ++ fi ++fi ++if [ -z "$DISTRO" ]; then ++ echo "Could not determine the distribution. Please install the lsb_release binary" ++ exit 1 ++fi ++if [ -z "$RELEASE" ]; then ++ echo "You really ought to install the lsb_release binary for this distro" ++ case "$DISTRO" in ++ Fedora) ++ RELEASE=$(grep Fedora /etc/issue | sed -e 's/Fedora release //' -e 's/ .*//') ++ ;; ++ esac ++fi ++if [ -z "$RELEASE" ]; then ++ echo "Could not determine the release. Please install the lsb_release binary" ++ exit 1 ++fi ++case "$DISTRO-$RELEASE" in ++ RedHatEnterpriseServer-6*) DISTRO=RHEL; RELEASE=6;; ++ Fedora-1[234]) DISTRO=RHEL; RELEASE=6;; # use the same .spec for now ++esac ++ ++SPECFILE="$currdir/e2fsprogs-${DISTRO// /_}-$RELEASE.spec" ++if [ ! -f "$SPECFILE" ]; then ++ SPECFILE="$currdir/e2fsprogs.spec" ++fi + $RPM --define "_sourcedir $tmpdir" \ + --define "_topdir ${RPM_TOPDIR:-$(rpm -E %_topdir)}" \ + --define "_tmpdir ${RPM_TMPDIR:-$TMP}" \ + --define "extra_config_flags ${EXTRA_CONFIG_FLAGS:-''}" \ +- -ba $currdir/e2fsprogs.spec ++ -ba $SPECFILE + + rpm_exit=$? + rm -rf $tmpdir +Index: e2fsprogs/lib/ext2fs/ext2_types-wrapper.h +=================================================================== +--- /dev/null ++++ e2fsprogs/lib/ext2fs/ext2_types-wrapper.h +@@ -0,0 +1,28 @@ EXCLUDE="--exclude .hg* --exclude .pc*" ++/* This file is here to prevent a file conflict on multiarch systems. A ++ * conflict will occur because ext2_types.h has arch-specific definitions. ++ * ++ * DO NOT INCLUDE THE NEW FILE DIRECTLY -- ALWAYS INCLUDE THIS ONE INSTEAD. */ ++ ++#if defined(__i386__) ++#include "ext2_types-i386.h" ++#elif defined(__powerpc64__) ++#include "ext2_types-ppc64.h" ++#elif defined(__powerpc__) ++#include "ext2_types-ppc.h" ++#elif defined(__s390x__) ++#include "ext2_types-s390x.h" ++#elif defined(__s390__) ++#include "ext2_types-s390.h" ++#elif defined(__x86_64__) ++#include "ext2_types-x86_64.h" ++#elif defined(__alpha__) ++#include "ext2_types-alpha.h" ++#elif defined(__arm__) ++#include "ext2_types-arm.h" ++#elif defined(__sparc__) && defined(__arch64__) ++#include "ext2_types-sparc64.h" ++#elif defined(__sparc__) ++#include "ext2_types-sparc.h" ++#else ++#error "This e2fsprogs-devel package does not work your architecture?" ++#endif +Index: e2fsprogs/lib/ext2fs/Makefile.in +=================================================================== +--- /dev/null ++++ e2fsprogs/lib/ext2fs/Makefile.in +@@ -159,7 +159,7 @@ + + HFILES= bitops.h ext2fs.h ext2_io.h ext2_fs.h ext2_ext_attr.h ext3_extents.h \ + tdb.h +-HFILES_IN= ext2_err.h ext2_types.h ++HFILES_IN= ext2_err.h ext2_types.h ext2_types-wrapper.h + + LIBRARY= libext2fs + LIBDIR= ext2fs diff --git a/patches/e2fsprogs-rpm_support.patch b/patches/e2fsprogs-rpm_SLES-11.patch similarity index 95% rename from patches/e2fsprogs-rpm_support.patch rename to patches/e2fsprogs-rpm_SLES-11.patch index d54563e..4a3f5fa 100644 --- a/patches/e2fsprogs-rpm_support.patch +++ b/patches/e2fsprogs-rpm_SLES-11.patch @@ -2,7 +2,7 @@ Index: e2fsprogs/e2fsprogs-SUSE_LINUX-11.spec.in =================================================================== --- /dev/null +++ e2fsprogs/e2fsprogs-SUSE_LINUX-11.spec.in -@@ -0,0 +1,1106 @@ +@@ -0,0 +1,1113 @@ +# +# spec file for package e2fsprogs (Version 1.41.9) +# @@ -24,7 +24,7 @@ Index: e2fsprogs/e2fsprogs-SUSE_LINUX-11.spec.in + + +Name: e2fsprogs -+License: GPL v2 or later ++License: GPLv2 +Group: System/Filesystems +Supplements: filesystem(ext2) filesystem(ext3) filesystem(ext4) +BuildRequires: libblkid-devel libuuid-devel pkg-config libdb-4_5-devel @@ -38,7 +38,10 @@ Index: e2fsprogs/e2fsprogs-SUSE_LINUX-11.spec.in +Version: @E2FSPROGS_PKGVER@ +Release: 0%{_vendor} +Summary: Utilities for the Second Extended File System -+Url: http://e2fsprogs.sourceforge.net ++Url: http://downloads.whamcloud.com/public/ ++Provides: ldiskfsprogs = %{version} ++@LFSCK_CMT@Requires: db4 >= @DB4VERSION@ ++@LFSCK_CMT@BuildRequires: db4-devel >= 4.1 texinfo +Source: %{name}-%{version}.tar.gz +BuildRoot: %{_tmppath}/%{name}-%{version}-build + @@ -55,7 +58,7 @@ Index: e2fsprogs/e2fsprogs-SUSE_LINUX-11.spec.in + Theodore Ts'o + +%package devel -+License: GPL v2 or later ++License: GPLv2 and LGPLv2 +Summary: Dummy development package +Group: Development/Libraries/C and C++ +AutoReqProv: on @@ -77,7 +80,7 @@ Index: e2fsprogs/e2fsprogs-SUSE_LINUX-11.spec.in + Theodore Ts'o + +%package -n libext2fs2 -+License: GPL v2 or later ++License: GPLv2 +Summary: Ext2fs libray +Group: System/Filesystems +AutoReqProv: on @@ -93,7 +96,7 @@ Index: e2fsprogs/e2fsprogs-SUSE_LINUX-11.spec.in + Theodore Ts'o + +%package -n libext2fs-devel -+License: GPL v2 or later ++License: GPLv2 +Summary: Development files for libext2fs +Group: Development/Libraries/C and C++ +AutoReqProv: on @@ -110,7 +113,7 @@ Index: e2fsprogs/e2fsprogs-SUSE_LINUX-11.spec.in + Theodore Ts'o + +%package -n libcom_err2 -+License: GPL v2 or later ++License: MIT +Summary: E2fsprogs error reporting library +Group: System/Filesystems +# bug437293 @@ -134,7 +137,7 @@ Index: e2fsprogs/e2fsprogs-SUSE_LINUX-11.spec.in + Theodore Ts'o + +%package -n libcom_err-devel -+License: GPL v2 or later ++License: MIT +Summary: Development files for libcom_err +Group: Development/Libraries/C and C++ +AutoReqProv: on @@ -177,7 +180,10 @@ Index: e2fsprogs/e2fsprogs-SUSE_LINUX-11.spec.in + --disable-libuuid \ + --disable-uuidd \ + --disable-fsck \ -+ %{?extra_config_flags:%extra_config_flags} CFLAGS="$RPM_OPT_FLAGS" ++ %{?extra_config_flags:%extra_config_flags} CFLAGS="$RPM_OPT_FLAGS" \ ++ --disable-defrag \ ++ --with-lustre=@LUSTRE@ \ ++ @LFSCK_CMT@ --enable-lfsck +make V=1 + +%install @@ -283,6 +289,7 @@ Index: e2fsprogs/e2fsprogs-SUSE_LINUX-11.spec.in +%_libdir/pkgconfig/com_err.pc +%_libdir/pkgconfig/ss.pc +%_includedir/et ++%_includedir/com_err.h +%_includedir/ss +%_datadir/et +%_datadir/ss @@ -1113,12 +1120,11 @@ Index: e2fsprogs/configure.in =================================================================== --- e2fsprogs.orig/configure.in +++ e2fsprogs/configure.in -@@ -1232,7 +1232,7 @@ test -d lib || mkdir lib - test -d include || mkdir include - test -d include/linux || mkdir include/linux +@@ -1234,6 +1234,7 @@ test -d lib || mkdir lib test -d include/asm || mkdir include/asm --for i in MCONFIG Makefile e2fsprogs.spec \ -+for i in MCONFIG Makefile e2fsprogs.spec e2fsprogs-SUSE_LINUX-11.spec \ + for i in MCONFIG Makefile e2fsprogs.spec \ + e2fsprogs-RHEL-6.spec \ ++ e2fsprogs-SUSE_LINUX-11.spec \ util/Makefile util/subst.conf util/gen-tarball \ lib/et/Makefile lib/ss/Makefile lib/e2p/Makefile \ lib/ext2fs/Makefile lib/ext2fs/ext2_types.h \ @@ -1126,51 +1132,23 @@ Index: e2fsprogs/contrib/build-rpm =================================================================== --- e2fsprogs.orig/contrib/build-rpm +++ e2fsprogs/contrib/build-rpm -@@ -34,11 +34,46 @@ EXCLUDE="--exclude .hg* --exclude .pc*" - - [ "`rpmbuild --version 2> /dev/null`" ] && RPM=rpmbuild || RPM=rpm - -+# which distro and release -+DISTRO=$(lsb_release -is) -+RELEASE=$(lsb_release -rs) -+# now the hacks in case either is empty -+if [ -z "$DISTRO" ]; then -+ echo "You really ought to install the lsb_release binary for this distro" +@@ -43,6 +43,9 @@ EXCLUDE="--exclude .hg* --exclude .pc*" + if grep "Fedora " /etc/issue; then + DISTRO="Fedora" + fi + if grep "SUSE Linux Enterprise Server " /etc/issue; then + DISTRO="SUSE LINUX" + fi -+fi -+if [ -z "$DISTRO" ]; then -+ echo "Could not determine the distribution. Please install the lsb_release binary" -+ exit 1 -+fi -+if [ -z "$RELEASE" ]; then -+ echo "You really ought to install the lsb_release binary for this distro" -+ case "$DISTRO" in + fi + if [ -z "$DISTRO" ]; then + echo "Could not determine the distribution. Please install the lsb_release binary" +@@ -54,6 +59,9 @@ EXCLUDE="--exclude .hg* --exclude .pc*" + Fedora) + RELEASE=$(grep Fedora /etc/issue | sed -e 's/Fedora release //' -e 's/ .*//') + ;; + SUSE\ LINUX) -+ if grep "SUSE Linux Enterprise Server 11 " /etc/issue; then -+ RELEASE=11 -+ elif grep "SUSE Linux Enterprise Server 10 " /etc/issue; then -+ RELEASE=10 -+ fi ++ RELEASE=$(grep SUSE /etc/issue | sed -e 's/SUSE Linux Enterprise Server //' -e 's/ .*//') + ;; -+ esac -+fi -+if [ -z "$RELEASE" ]; then -+ echo "Could not determine the release. Please install the lsb_release binary" -+ exit 1 -+fi -+ -+SPECFILE="$currdir/e2fsprogs-${DISTRO// /_}-$RELEASE.spec" -+if [ ! -f "$SPECFILE" ]; then -+ SPECFILE="$currdir/e2fsprogs.spec" -+fi - $RPM --define "_sourcedir $tmpdir" \ - --define "_topdir ${RPM_TOPDIR:-$(rpm -E %_topdir)}" \ - --define "_tmpdir ${RPM_TMPDIR:-$TMP}" \ - --define "extra_config_flags ${EXTRA_CONFIG_FLAGS:-''}" \ -- -ba $currdir/e2fsprogs.spec -+ -ba $SPECFILE - - rpm_exit=$? - rm -rf $tmpdir + esac + fi + if [ -z "$RELEASE" ]; then diff --git a/patches/e2fsprogs-specdotin.patch b/patches/e2fsprogs-specdotin.patch index 9a0041a..4644d0b 100644 --- a/patches/e2fsprogs-specdotin.patch +++ b/patches/e2fsprogs-specdotin.patch @@ -18,12 +18,13 @@ Index: e2fsprogs/e2fsprogs.spec.in Name: e2fsprogs Version: @E2FSPROGS_PKGVER@ -Release: 0 +-License: GPLv2 +Release: 0%{_vendor} - License: GPLv2 ++License: GPLv2 and LGPLv2 Group: System Environment/Base Source: ftp://download.sourceforge.net/pub/sourceforge/e2fsprogs/e2fsprogs-%{version}.tar.gz -Url: http://e2fsprogs.sourceforge.net/ -+Url: http://build.whamcloud.com/job/e2fsprogs/ ++Url: http://downloads.whamcloud.com/public/ Prereq: /sbin/ldconfig BuildRoot: %{_tmppath}/%{name}-root +%if %{_vendor} == "suse" @@ -38,3 +39,25 @@ Index: e2fsprogs/e2fsprogs.spec.in %description The e2fsprogs package contains a number of utilities for creating, +@@ -72,7 +81,7 @@ + %setup + + %build +-%configure --enable-elf-shlibs --enable-nls \ ++%configure --enable-elf-shlibs --enable-nls --disable-defrag \ + %{?extra_config_flags:%extra_config_flags} + make + make check +Index: e2fsprogs/contrib/build-rpm +=================================================================== +--- e2fsprogs.orig/contrib/build-rpm ++++ e2fsprogs/contrib/build-rpm +@@ -29,7 +29,7 @@ cp -sR `pwd`/$currdir $tmpdir/$builddir + # Remove any build files from the temporary tarball directory + [ -f $tmpdir/$builddir/Makefile ] && make -C $tmpdir/$builddir distclean + +-EXCLUDE="--exclude .hg* --exclude .pc*" ++EXCLUDE="--exclude .hg* --exclude .pc* --exclude .git*" + (cd $tmpdir && tar czfh ${builddir}.tar.gz $EXCLUDE $builddir) + + [ "`rpmbuild --version 2> /dev/null`" ] && RPM=rpmbuild || RPM=rpm diff --git a/patches/series b/patches/series index ffe5002..d92d6df 100644 --- a/patches/series +++ b/patches/series @@ -74,4 +74,6 @@ e2fsprogs-e2scan.patch e2fsprogs-tests-s_basic_scan.patch e2fsprogs-data_in_dirent.patch e2fsprogs-tests-f_data_in_dirent.patch -e2fsprogs-rpm_support.patch +e2fsprogs-rpm_RHEL-6.patch +e2fsprogs-1.40.4-sb_feature_check_ignore.patch +e2fsprogs-rpm_SLES-11.patch diff --git a/patches/sles/libcom_err-no-static-buffer.patch b/patches/sles/libcom_err-no-static-buffer.patch index 7b1f1ae..3655d63 100644 --- a/patches/sles/libcom_err-no-static-buffer.patch +++ b/patches/sles/libcom_err-no-static-buffer.patch @@ -4,7 +4,29 @@ Index: e2fsprogs/lib/et/error_message.c =================================================================== --- e2fsprogs.orig/lib/et/error_message.c +++ e2fsprogs/lib/et/error_message.c -@@ -148,25 +148,7 @@ const char * error_message (errcode_t co +@@ -102,13 +102,6 @@ + #include "error_table.h" + #include "internal.h" + +-#ifdef TLS +-#define THREAD_LOCAL static TLS +-#else +-#define THREAD_LOCAL static +-#endif +- +-THREAD_LOCAL char buffer[25]; + + struct et_list * _et_list = (struct et_list *) NULL; + struct et_list * _et_dynamic_list = (struct et_list *) NULL; +@@ -102,7 +95,6 @@ const char * error_message (errcode_t co + int offset; + struct et_list *et; + errcode_t table_num; +- int started = 0; + char *cp; + + offset = (int) (code & ((1<