[arch-commits] Commit in e2fsprogs/repos (4 files)
Christian Hesse
eworm at gemini.archlinux.org
Mon Aug 2 11:54:31 UTC 2021
Date: Monday, August 2, 2021 @ 11:54:31
Author: eworm
Revision: 421033
archrelease: copy trunk to testing-x86_64
Added:
e2fsprogs/repos/testing-x86_64/
e2fsprogs/repos/testing-x86_64/0001-mke2fs-do-not-warn-about-a-pre-existing-partition-table-when-using-a-non-zero-offset.patch
(from rev 421032, e2fsprogs/trunk/0001-mke2fs-do-not-warn-about-a-pre-existing-partition-table-when-using-a-non-zero-offset.patch)
e2fsprogs/repos/testing-x86_64/MIT-LICENSE
(from rev 421032, e2fsprogs/trunk/MIT-LICENSE)
e2fsprogs/repos/testing-x86_64/PKGBUILD
(from rev 421032, e2fsprogs/trunk/PKGBUILD)
-------------------------------------------------------------------------------------------------+
0001-mke2fs-do-not-warn-about-a-pre-existing-partition-table-when-using-a-non-zero-offset.patch | 79 ++++++++++
MIT-LICENSE | 25 +++
PKGBUILD | 78 +++++++++
3 files changed, 182 insertions(+)
Copied: e2fsprogs/repos/testing-x86_64/0001-mke2fs-do-not-warn-about-a-pre-existing-partition-table-when-using-a-non-zero-offset.patch (from rev 421032, e2fsprogs/trunk/0001-mke2fs-do-not-warn-about-a-pre-existing-partition-table-when-using-a-non-zero-offset.patch)
===================================================================
--- testing-x86_64/0001-mke2fs-do-not-warn-about-a-pre-existing-partition-table-when-using-a-non-zero-offset.patch (rev 0)
+++ testing-x86_64/0001-mke2fs-do-not-warn-about-a-pre-existing-partition-table-when-using-a-non-zero-offset.patch 2021-08-02 11:54:31 UTC (rev 421033)
@@ -0,0 +1,79 @@
+commit 942b00cb9d2f2b52f4c58877d523145ee59a89b0
+Author: Theodore Ts'o <tytso at mit.edu>
+Date: Wed Jul 21 15:46:09 2021 -0400
+
+ mke2fs: do not warn about a pre-existing partition table when using a non-zero offset
+
+ The existing code attempted to avoid warning about a pre-existing file
+ system with a non-zero offset, but because the offset was not set at
+ the time of the check, this intention was not actually working. So
+ this commit will suppress warnings about pre-existing a partition
+ table as well as pre-existing file system when there is a non-zero
+ offset.
+
+ Addresses-Debian-Bug: #989612
+ Signed-off-by: Theodore Ts'o <tytso at mit.edu>
+
+diff --git a/lib/support/plausible.c b/lib/support/plausible.c
+index 2a3ae140..bbed2a70 100644
+--- a/lib/support/plausible.c
++++ b/lib/support/plausible.c
+@@ -282,11 +282,11 @@ int check_plausibility(const char *device, int flags, int *ret_is_dev)
+ return !has_magic;
+ }
+ #endif
+-
+- ret = check_partition_table(device);
+- if (ret >= 0)
+- return ret;
+-
++ if (flags & CHECK_FS_EXIST) {
++ ret = check_partition_table(device);
++ if (ret >= 0)
++ return ret;
++ }
+ return 1;
+ }
+
+diff --git a/misc/mke2fs.c b/misc/mke2fs.c
+index 5a35e9ef..c7b32316 100644
+--- a/misc/mke2fs.c
++++ b/misc/mke2fs.c
+@@ -1973,18 +1973,8 @@ profile_error:
+ profile_get_integer(profile, "options", "proceed_delay", 0, 0,
+ &proceed_delay);
+
+- /* The isatty() test is so we don't break existing scripts */
+- flags = CREATE_FILE;
+- if (isatty(0) && isatty(1) && !offset)
+- flags |= CHECK_FS_EXIST;
+- if (!quiet)
+- flags |= VERBOSE_CREATE;
+- if (fs_blocks_count == 0)
+- flags |= NO_SIZE;
+- else
++ if (fs_blocks_count)
+ explicit_fssize = 1;
+- if (!check_plausibility(device_name, flags, &is_device) && !force)
+- proceed_question(proceed_delay);
+
+ check_mount(device_name, force, _("filesystem"));
+
+@@ -2650,6 +2640,17 @@ profile_error:
+
+ free(fs_type);
+ free(usage_types);
++
++ /* The isatty() test is so we don't break existing scripts */
++ flags = CREATE_FILE;
++ if (isatty(0) && isatty(1) && !offset)
++ flags |= CHECK_FS_EXIST;
++ if (!quiet)
++ flags |= VERBOSE_CREATE;
++ if (!explicit_fssize)
++ flags |= NO_SIZE;
++ if (!check_plausibility(device_name, flags, &is_device) && !force)
++ proceed_question(proceed_delay);
+ }
+
+ static int should_do_undo(const char *name)
Copied: e2fsprogs/repos/testing-x86_64/MIT-LICENSE (from rev 421032, e2fsprogs/trunk/MIT-LICENSE)
===================================================================
--- testing-x86_64/MIT-LICENSE (rev 0)
+++ testing-x86_64/MIT-LICENSE 2021-08-02 11:54:31 UTC (rev 421033)
@@ -0,0 +1,25 @@
+Copyright (c) 2003-2007 Theodore Ts'o <tytso at mit.edu>
+Copyright (c) 1997-2003 Yann Dirson <dirson at debian.org>
+Copyright (c) 2001 Alcove <http://www.alcove.com/>
+Copyright (c) 1997 Klee Dienes
+Copyright (c) 1995-1996 Michael Nonweiler <mrn20 at cam.ac.uk>
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject
+to the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
+KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
+WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
+BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
+AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
+IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
Copied: e2fsprogs/repos/testing-x86_64/PKGBUILD (from rev 421032, e2fsprogs/trunk/PKGBUILD)
===================================================================
--- testing-x86_64/PKGBUILD (rev 0)
+++ testing-x86_64/PKGBUILD 2021-08-02 11:54:31 UTC (rev 421033)
@@ -0,0 +1,78 @@
+# Maintainer: Ronald van Haren <ronald.archlinux.org>
+# Contributor: judd <jvinet at zeroflux.org>
+
+pkgname=e2fsprogs
+pkgver=1.46.3
+pkgrel=2
+pkgdesc="Ext2/3/4 filesystem utilities"
+arch=('x86_64')
+license=('GPL' 'LGPL' 'MIT')
+url="http://e2fsprogs.sourceforge.net"
+depends=('sh' 'util-linux-libs')
+makedepends=('systemd' 'util-linux')
+provides=('libcom_err.so'
+ 'libe2p.so'
+ 'libext2fs.so'
+ 'libss.so')
+backup=('etc/mke2fs.conf')
+options=('staticlibs')
+validpgpkeys=('3AB057B7E78D945C8C5591FBD36F769BC11804F0') # Theodore Ts'o <tytso at mit.edu>
+source=("https://www.kernel.org/pub/linux/kernel/people/tytso/${pkgname}/v${pkgver}/${pkgname}-${pkgver}.tar."{xz,sign}
+ '0001-mke2fs-do-not-warn-about-a-pre-existing-partition-table-when-using-a-non-zero-offset.patch'
+ 'MIT-LICENSE')
+sha256sums=('86d1580facdd49f2e0e6b027e26b1e6c48af538762dc40aeed2a87153c1f11b7'
+ 'SKIP'
+ '48ac4367d729aede1ba84974a237e5c3421ea9b4371b17a83842b54b62931a80'
+ 'cc45386c1d71f438ad648fd7971e49e3074ad9dbacf9dd3a5b4cb61fd294ecbb')
+
+
+prepare() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ # revert: mke2fs: do not warn about a pre-existing partition table when using a non-zero offset
+ patch -Np1 -R < ../0001-mke2fs-do-not-warn-about-a-pre-existing-partition-table-when-using-a-non-zero-offset.patch
+
+ # Remove unnecessary init.d directory
+ sed -i '/init\.d/s|^|#|' misc/Makefile.in
+}
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ ./configure \
+ --prefix=/usr \
+ --with-root-prefix="" \
+ --libdir=/usr/lib \
+ --sbindir=/usr/bin \
+ --enable-elf-shlibs \
+ --disable-fsck \
+ --disable-uuidd \
+ --disable-libuuid \
+ --disable-libblkid
+
+ make
+
+ # regenerate locale files
+ find po/ -name '*.gmo' -delete
+ make -C po update-gmo
+}
+
+package() {
+ unset MAKEFLAGS
+
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ make DESTDIR="${pkgdir}" install install-libs
+
+ sed -i -e 's/^AWK=.*/AWK=awk/' "${pkgdir}/usr/bin/compile_et"
+
+ # remove references to build directory
+ sed -i -e 's#^SS_DIR=.*#SS_DIR="/usr/share/ss"#' "${pkgdir}/usr/bin/mk_cmds"
+ sed -i -e 's#^ET_DIR=.*#ET_DIR="/usr/share/et"#' "${pkgdir}/usr/bin/compile_et"
+
+ # remove static libraries with a shared counterpart
+ rm "${pkgdir}"/usr/lib/lib{com_err,e2p,ext2fs,ss}.a
+
+ # install MIT license
+ install -Dm644 "${srcdir}/MIT-LICENSE" \
+ "${pkgdir}/usr/share/licenses/${pkgname}/MIT-LICENSE"
+}
More information about the arch-commits
mailing list