FreeBSD Bugzilla – Attachment 218010 Details for
Bug 249284
sysutils/e2fsprogs: installs files outside ${PREFIX}
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
proposed fixed port, also fixes some borderline cases - see changes_4
e2fsprogs_4.shar (text/plain), 52.23 KB, created by
Matthias Andree
on 2020-09-16 19:20:25 UTC
(
hide
)
Description:
proposed fixed port, also fixes some borderline cases - see changes_4
Filename:
MIME Type:
Creator:
Matthias Andree
Created:
2020-09-16 19:20:25 UTC
Size:
52.23 KB
patch
obsolete
># This is a shell archive. Save it in a file, remove anything before ># this line, and then unpack it by entering "sh file". Note, it may ># create directories; files and directories will be owned by you and ># have default permissions. ># ># This archive contains: ># ># e2fsprogs/ ># e2fsprogs/pkg-plist ># e2fsprogs/distinfo ># e2fsprogs/Makefile ># e2fsprogs/pkg-install ># e2fsprogs/files ># e2fsprogs/files/patch-lib_blkid_devname.c ># e2fsprogs/files/patch-tests_Makefile.in ># e2fsprogs/files/patch-0-tytso-3-tests-use-grep-E-for-better-portability-in-r_inline_.patch ># e2fsprogs/files/extrapatch-e2fsck_sigcatcher.c ># e2fsprogs/files/patch-0-tytso-1-Use-ext2_loff_t-instead-of-loff_t.patch ># e2fsprogs/files/patch-misc_e2fuzz.c ># e2fsprogs/files/fsck_ext2fs.8 ># e2fsprogs/files/patch-lib__uuid__gen_uuid.c ># e2fsprogs/files/unwanted ># e2fsprogs/files/patch-misc_blkid.8.in ># e2fsprogs/files/patch-lib_support_plausible.c ># e2fsprogs/files/patch-0-tytso-2-e2fsck-fix-various-gcc-Wall-nits.patch ># e2fsprogs/files/patch-lib__ext2fs__tst_bitops.c ># e2fsprogs/files/patch-e2fsck__unix.c ># e2fsprogs/files/patch-misc__Makefile.in ># e2fsprogs/files/fsck_ext2fs.c ># e2fsprogs/files/extrapatch-no-sbrk ># e2fsprogs/pkg-message ># e2fsprogs/changes_4 ># e2fsprogs/pkg-descr ># >echo c - e2fsprogs/ >mkdir -p e2fsprogs/ > /dev/null 2>&1 >echo x - e2fsprogs/pkg-plist >sed 's/^X//' >e2fsprogs/pkg-plist << 'bf73443d33b5ad70ee259060a87cfd6a' >X/sbin/e2fsck >X/sbin/fsck_ext2fs >Xbin/chattr >Xbin/e2fsprogs-compile_et >X%%FUSEFS%%bin/fuse2fs >Xbin/lsattr >Xetc/mke2fs.conf.dist >Xinclude/e2fsprogs/com_err.h >Xinclude/e2fsprogs/e2p/e2p.h >Xinclude/e2fsprogs/et/com_err.h >Xinclude/e2fsprogs/ext2fs/bitops.h >Xinclude/e2fsprogs/ext2fs/ext2_err.h >Xinclude/e2fsprogs/ext2fs/ext2_ext_attr.h >Xinclude/e2fsprogs/ext2fs/ext2_fs.h >Xinclude/e2fsprogs/ext2fs/ext2_io.h >Xinclude/e2fsprogs/ext2fs/ext2_types.h >Xinclude/e2fsprogs/ext2fs/ext2fs.h >Xinclude/e2fsprogs/ext2fs/ext3_extents.h >Xinclude/e2fsprogs/ext2fs/hashmap.h >Xinclude/e2fsprogs/ext2fs/qcow2.h >Xinclude/e2fsprogs/ext2fs/tdb.h >Xlib/e2fsprogs/libcom_err.so >Xlib/e2fsprogs/libcom_err.so.2 >Xlib/e2fsprogs/libcom_err.so.2.1 >Xlib/e2fsprogs/libe2p.a >Xlib/e2fsprogs/libe2p.so >Xlib/e2fsprogs/libe2p.so.2 >Xlib/e2fsprogs/libe2p.so.2.3 >Xlib/e2fsprogs/libext2fs.a >Xlib/e2fsprogs/libext2fs.so >Xlib/e2fsprogs/libext2fs.so.2 >Xlib/e2fsprogs/libext2fs.so.2.4 >Xlibdata/pkgconfig/com_err.pc >Xlibdata/pkgconfig/e2p.pc >Xlibdata/pkgconfig/ext2fs.pc >Xman/man1/chattr.1.gz >Xman/man1/e2fsprogs-compile_et.1.gz >X%%FUSEFS%%man/man1/fuse2fs.1.gz >Xman/man1/lsattr.1.gz >Xman/man5/e2fsck.conf.5.gz >Xman/man5/mke2fs.conf.5.gz >Xman/man5/ext2.5.gz >Xman/man5/ext3.5.gz >Xman/man5/ext4.5.gz >Xman/man8/badblocks.8.gz >Xman/man8/debugfs.8.gz >Xman/man8/dumpe2fs.8.gz >Xman/man8/e2fsck.8.gz >Xman/man8/e2image.8.gz >Xman/man8/e2label.8.gz >Xman/man8/e2mmpstatus.8.gz >Xman/man8/e2undo.8.gz >Xman/man8/mke2fs.8.gz >Xman/man8/mklost+found.8.gz >Xman/man8/resize2fs.8.gz >Xman/man8/tune2fs.8.gz >Xman/man8/fsck.ext2.8.gz >Xman/man8/fsck.ext3.8.gz >Xman/man8/fsck.ext4.8.gz >Xman/man8/mkfs.ext2.8.gz >Xman/man8/mkfs.ext3.8.gz >Xman/man8/mkfs.ext4.8.gz >Xman/man8/findfs.8.gz >Xman/man8/blkid.8.gz >Xman/man8/logsave.8.gz >Xman/man8/fsck_ext2fs.8.gz >Xman/man8/e2freefrag.8.gz >Xsbin/badblocks >Xsbin/blkid >Xsbin/debugfs >Xsbin/dumpe2fs >Xsbin/e2freefrag >Xsbin/e2fsck >Xsbin/e2image >Xsbin/e2label >Xsbin/e2mmpstatus >Xsbin/e2undo >Xsbin/findfs >Xsbin/fsck.ext2 >Xsbin/fsck.ext3 >Xsbin/fsck.ext4 >Xsbin/fsck_ext2fs >Xsbin/logsave >Xsbin/mke2fs >Xsbin/mkfs.ext2 >Xsbin/mkfs.ext3 >Xsbin/mkfs.ext4 >Xsbin/mklost+found >Xsbin/resize2fs >Xsbin/tune2fs >X%%DATADIR%%/et/et_c.awk >X%%DATADIR%%/et/et_h.awk >X%%PORTDOCS%%share/info/libext2fs.info.gz >X%%NLS%%share/locale/ca/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/cs/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/da/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/de/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/eo/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/es/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/fi/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/fr/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/hu/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/id/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/it/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/ms/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/nl/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/pl/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/pt/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/sr/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/sv/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/tr/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/uk/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/vi/LC_MESSAGES/e2fsprogs.mo >X%%NLS%%share/locale/zh_CN/LC_MESSAGES/e2fsprogs.mo >bf73443d33b5ad70ee259060a87cfd6a >echo x - e2fsprogs/distinfo >sed 's/^X//' >e2fsprogs/distinfo << 'a3332d3d9b00fd7436f7a143c59f01eb' >XTIMESTAMP = 1584954798 >XSHA256 (e2fsprogs-1.45.6.tar.xz) = ffa7ae6954395abdc50d0f8605d8be84736465afc53b8938ef473fcf7ff44256 >XSIZE (e2fsprogs-1.45.6.tar.xz) = 5572144 >a3332d3d9b00fd7436f7a143c59f01eb >echo x - e2fsprogs/Makefile >sed 's/^X//' >e2fsprogs/Makefile << 'da2c5ae5bfd3df6f8c202d112b281632' >X# Created by: Maxim Sobolev <sobomax@FreeBSD.org> >X# $FreeBSD: head/sysutils/e2fsprogs/Makefile 540401 2020-06-25 18:44:30Z mandree $ >X >XPORTNAME= e2fsprogs >XPORTVERSION= 1.45.6 >XPORTREVISION?= 4 >XCATEGORIES?= sysutils >XMASTER_SITES= KERNEL_ORG/linux/kernel/people/tytso/${PORTNAME}/v${PORTVERSION} >X >XMAINTAINER?= mandree@FreeBSD.org >XCOMMENT?= Utilities & library to manipulate ext2/3/4 filesystems >X >XLICENSE?= GPLv2+ >X.if !defined(_no_license_file) >XLICENSE_FILE?= ${WRKSRC}/NOTICE >X.endif >XLICENSE_DISTFILES_GPLv2+ = ${DISTNAME}${EXTRACT_SUFX} >X >XUSES= cpe gmake makeinfo pkgconfig tar:xz >XCPE_VENDOR= e2fsprogs_project >XUSE_CSTD= gnu99 >X# this seems a bit redundant to the --rpath below, but >X# the latter should be more robust in case someone needs >X# to deal with the file systems from a system not yet fully booted. >X.if !defined(PKGNAMESUFFIX) >XUSE_LDCONFIG= ${PREFIX}/lib/e2fsprogs >X.endif >XGNU_CONFIGURE= yes >X >X# while we use the system blkid, we need to --enable-libblkid >X# so that the tools get built: >XCONFIGURE_ARGS?=--disable-fsck \ >X --disable-e2initrd-helper \ >X --disable-libuuid \ >X --disable-uuidd \ >X --enable-libblkid \ >X --enable-elf-shlibs \ >X --libdir='${PREFIX}/lib/e2fsprogs/' \ >X --includedir='${PREFIX}/include/e2fsprogs/' \ >X --with-root-prefix='${PREFIX}' \ >X --without-included-gettext \ >X LDFLAGS='${LDFLAGS} -L${LOCALBASE}/lib -Wl,--rpath -Wl,${LOCALBASE}/lib/e2fsprogs' >XCONFIGURE_ENV?= LIBS='-Wl,--as-needed ${LIBS} -lexecinfo -lelf' >XCPPFLAGS+= -I${WRKSRC}/lib -I${LOCALBASE}/include # -D_EXT2_USE_C_VERSIONS >XMAKE_ARGS+= pkgconfigdir='${PREFIX}/libdata/pkgconfig' >XMAKE_ENV+= CHECK_CMD=@true >X >XPORTSCOUT= ignore # cannot handle the version in the directory >X >X.if !defined(MASTERDIR) >XINSTALL_TARGET= install install-libs >X >XOPTIONS_DEFINE= DOCS NLS FUSEFS PARALLELTESTS SLOWTESTS BASHTESTS LIBUNWIND >XOPTIONS_EXCLUDE+= EXAMPLES >XOPTIONS_SUB= yes >X >XOPTIONS_SINGLE= SELFTEST >XOPTIONS_SINGLE_SELFTEST= NOTESTS SMALLTESTS ALLTESTS >XOPTIONS_DEFAULT= SMALLTESTS >XFUSEFS_DESC= Build user-land ext2/3/4 FUSE module (slow!) >XSELFTEST_DESC= Choose which set of self-tests to run >XNOTESTS_DESC= Do not run any self-tests (Tier-1, DISCOURAGED) >XSMALLTESTS_DESC=Run tests that need <500 MB disk space (DEFAULT) >XALLTESTS_DESC= Run most self-tests (needs more RAM/disk space) >XPARALLELTESTS_DESC= Parallelize self-tests (needs more disk space) >XSLOWTESTS_DESC= Enable slow tests that are skipped by default >XBASHTESTS_DESC= Enable tests that require the GNU bash shell >XLIBUNWIND_DESC= Backtrace with libunwind (do set WITH_DEBUG_PORTS+=${PKGORIGIN}!) >X >XFUSEFS_CONFIGURE_ENABLE= fuse2fs >X >XBUILD_DEPENDS+= gdd:sysutils/coreutils >XBASHTESTS_BUILD_DEPENDS= ${BASH_CMD}:shells/bash >XBASH_CMD= ${LOCALBASE}/bin/bash >X >XLIB_DEPENDS+= libblkid.so:misc/e2fsprogs-libblkid >XLIB_DEPENDS+= libss.so:devel/e2fsprogs-libss >XLIB_DEPENDS+= libuuid.so:misc/e2fsprogs-libuuid >X >XLIBUNWIND_LIB_DEPENDS= libunwind.so:devel/libunwind >XLIBUNWIND_LIBS+= -L${LOCALBASE}/lib -lunwind >XLIBUNWIND_LDFLAGS+= -rdynamic >XLIBUNWIND_EXTRA_PATCHES=${FILESDIR}/extrapatch-e2fsck_sigcatcher.c >X >XPORTDOCS= NOTICE README RELEASE-NOTES SUBMITTING-PATCHES >X.endif >X >X# even under DEVELOPER, no REINPLACE_CMD warnings desired >X# it simply makes no sense to warn about dozens of files >X# for systematic edits that run over files that don't need the edits. >X# a "warn if nothing was edited by one command" would be acceptable, >X# but until we have that in the framework, just >X# avoid Tools/scripts/sed_checked altogether: >XREINPLACE_CMD= ${SED} ${REINPLACE_ARGS} >X >XPKGDEINSTALL= ${PKGINSTALL} >X >XMAKE_ARGS+= V=1 >X >X.include <bsd.port.options.mk> >X >X. if ! empty(ARCH:Mpowerpc*) >X# Fix powerpc64/powerpc SIGSEGV, >X# see https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=231570 (ppc64) >X# see https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=242798 (ppc32 - untested) >XUSES+= compiler:c11 >X. endif >X >X.if ${PORT_OPTIONS:MFUSEFS} >XUSES+= fuse >X.endif >X >X.if ${PORT_OPTIONS:MNLS} >XUSES+= gettext iconv:build >X.endif >X >X.if empty(PORT_OPTIONS:MNOTESTS) && ${MASTERDIR} == ${.CURDIR} >XUSES+= perl5 >XUSE_PERL5= build >X.endif >X >X.include <bsd.port.pre.mk> >X >X.if ${PORT_OPTIONS:MNLS} >X. if empty(ICONV_LIB) >Xlibintl= ${LOCALBASE}/lib/libintl.a >X. else >Xlibintl= ${LOCALBASE}/lib/libintl.a ${LOCALBASE}/lib/libiconv.a >X. endif >X.else >XCONFIGURE_ARGS+=--disable-nls >Xlibintl= >X.endif >X >X.if ${MASTERDIR} == ${.CURDIR} && ${ARCH} == "aarch64" >XEXTRA_PATCHES+= ${FILESDIR}/extrapatch-no-sbrk >X.endif >X >X# d_fallocate_blkmap appears to fail on some systems for unknown reasons. >Xpost-patch:: >X @${REINPLACE_CMD} -E -e 's/md5sum ([^ ]*)/printf "%s %s\\n" $$(md5 -q \1) \1/' \ >X -e "s/ == 0/ = 0/" -e "s/tar x$$/tar xf -/" -e "s/\<dd\>/gdd/" \ >X ${WRKSRC}/tests/[a-z]_*/script >X @${REINPLACE_CMD} -e 's/<malloc\.h>/<stdlib.h>/' ${WRKSRC}/*/*.c >X @${REINPLACE_CMD} -e 's,/etc/blkid.tab,${ETCDIR}/blkid.tab,' ${WRKSRC}/misc/blkid* ${WRKSRC}/lib/blkid/blkidP.h >X @${REINPLACE_CMD} -E -e 's/__GNUC_PREREQ\>/__GNUC_PREREQ__/' ${WRKSRC}/*/*/*.[ch] ${WRKSRC}/*/*.c >X.if empty(PORT_OPTIONS:MALLTESTS) >X. for i in \ >X d_fallocate_blkmap \ >X f_baddir \ >X f_bbfile \ >X f_convert_bmap \ >X f_detect_junk \ >X f_inode_ea_collision \ >X f_lpffile \ >X f_no_cache_corrupt_inode \ >X f_opt_extent \ >X j_corrupt_descr_csum \ >X m_bigjournal \ >X m_hugefile_slack \ >X m_offset \ >X m_raid_opt \ >X r_32to64bit \ >X r_32to64bit_expand_full \ >X r_32to64bit_meta \ >X r_32to64bit_move_itable \ >X r_64to32bit \ >X r_64to32bit_meta \ >X r_expand_full \ >X r_min_itable \ >X t_change_uuid_mounted \ >X t_dangerous \ >X t_disable_changed_csum_seed_mounted \ >X t_disable_mcsum \ >X t_disable_mcsum_noinitbg \ >X t_disable_mcsum_yesinitbg \ >X t_enable_mcsum \ >X t_enable_mcsum_initbg \ >X t_iexpand_full \ >X t_iexpand_mcsum \ >X t_uninit_bg_rm \ >X u_dryrun \ >X u_mke2fs_opt_offset >X @${MV} ${WRKSRC}/tests/${i} ${WRKSRC}/tests/disabled_test-${i} >X. endfor >X.endif >X.if ${PORT_OPTIONS:MBASHTESTS} >X ${REINPLACE_CMD} -e 's}^SHELL *=.*}SHELL = ${_CHECK_SHELL}}' ${WRKSRC}/MCONFIG.in >X.else >X. for i in f_large_dir >X @${MV} ${WRKSRC}/tests/${i} ${WRKSRC}/tests/disabled_test-${i} >X. endfor >X.endif >X >X############################################################## >X# Master port stuff that is not to be seen by the slave ports. >X############################################################## >X.if ${MASTERDIR} == ${.CURDIR} >X# NOTE: The previous .if block goes all the way to the end of the file. >X >X.if !empty(PORT_OPTIONS:MNOTESTS) && (${OPSYS} == FreeBSD) && (${OSVERSION} >= 1200000 || ((${ARCH} != i386) && (${ARCH} != amd64))) >XBROKEN= it was not tested on your system by the maintainer; you must run self-tests >X.endif >X >Xpre-build: >X# fix up Makefile ordering for parallel builds >X cd ${WRKSRC}/lib/et && ${DO_MAKE_BUILD} compile_et >X cd ${WRKSRC}/lib/support && ${DO_MAKE_BUILD} prof_err.h >X >X.if ${PORT_OPTIONS:MPARALLELTESTS} >X_CHECK_JOBS=${_MAKE_JOBS} >X.else >X_CHECK_JOBS= >X.endif >X >X.if ${PORT_OPTIONS:MBASHTESTS} >X_CHECK_SHELL=${SHELL} >X.else >X_CHECK_SHELL=${LOCALBASE}/bin/bash >X.endif >X >X_checkaddargs= >X.if !defined(TMPDIR) >X_checkaddargs+=TMPDIR=${WRKDIR}/tmp >X.endif >X >X.if ${PORT_OPTIONS:MBASHTESTS} >X_checkaddargs+=--eval SHELL:=${BASH_CMD} >X.endif >X >X.if ${PORT_OPTIONS:MSLOWTESTS} >X_check_target=SKIP_SLOW_TESTS= check >X_check_timeout=7200 >X.else >X_check_target=check >X_check_timeout=180 >X.endif >X >X.if ${PORT_OPTIONS:MLIBUNWIND} >X_staticlibs+=${LOCALBASE}/lib/libunwind.a /usr/lib/liblzma.a >X.endif >X >Xpost-build: >X# Relink e2fsck statically - We need to make sure that tools for the root file >X# system are statically linked against anything that is outside the root fs, >X# else we're in trouble if e2fsck is needed for boot: >X# (we don't use e2fsck.static, since we can link libc.so dynamically) >X# NOTE: we need to link libgcc statically, it might be under /usr/local! >X# => do not add a -Bdynamic - but instead list the dynamic libraries >X# before the -Bstatic >X cd ${WRKSRC}/e2fsck && ${RM} -f e2fsck \ >X && ${MAKE_CMD} e2fsck V=1 \ >X LIBS="-static-libgcc -lc -Bstatic ../lib/libsupport.a ../lib/libext2fs.a ../lib/libcom_err.a \ >X ${_staticlibs} /usr/lib/libexecinfo.a /usr/lib/libelf.a \ >X ${LOCALBASE}/lib/libblkid.a ${LOCALBASE}/lib/libuuid.a ${libintl} ../lib/libe2p.a " \ >X && ${STRIP_CMD} e2fsck >X# Regression check: avoid a port (not upstream!) regression from 1.40.5, >X# check that e2fsck isn't dynalinked against anything but libc.so: >X @${ECHO_CMD} -n "===> checking that e2fsck depends on no shared objects outside /lib: " >X @a="$$(ldd ${WRKSRC}/e2fsck/e2fsck 2>/dev/null \ >X | ${GREP} -v 'not a dynamic executable' \ >X | ${GREP} '=>' \ >X | ${AWK} '{print $$3;}' \ >X | ${EGREP} -v '^/lib/lib.*\.so\.' || :)"; \ >X if test "x$$a" = "x" ; then echo 'PASS' ; else \ >X echo 'FAIL' ; echo '===> e2fsck depends on:' ; echo "$$a" ; exit 1 ; fi >X# Update translation binary files >X.if ${PORT_OPTIONS:MNLS} >X cd ${WRKSRC}/po && ${MAKE_CMD} update-gmo >X.endif >X# Build fsck(8) wrapper >X ${CC} ${CPPFLAGS} ${CFLAGS} ${LDFLAGS} -s ${LIBS} \ >X -o ${WRKSRC}/fsck_ext2fs ${FILESDIR}/fsck_ext2fs.c >X# While the ${MAKE} check can take a minute on an end user's system, the >X# correctness of tools such as e2fsck is critical to the health of the >X# file systems. The upstream is not using any *BSD as his development >X# system, and therefore let's exercise due diligence in running the self- >X# test on each and every system and not just package building hosts. >X# There have been subtle failures induced by Linux-isms in the past. >X# -- Matthias Andree, package maintainer, 2007-09-18 >X.if empty(PORT_OPTIONS:MNOTESTS) >X @${ECHO_CMD} '===> Running e2fsprogs self-test suite' >X# do not add -j options unconditionally to ${MAKE_CMD} below, this might break >X# due to excessive disk space use. >X cd ${WRKSRC}/tests && \ >X ulimit -t ${_check_timeout} && \ >X ${MKDIR} ${WRKDIR}/tmp && \ >X ${SETENV} e2fsprogs_inhibit_SIGINFO=1 BLKID_FILE=${WRKDIR}/tmp/blkid.tab SHELL=${_CHECK_SHELL} \ >X ${MAKE_CMD} ${_check_target} ${_CHECK_JOBS} ${_checkaddargs} \ >X || { head -n30000 ${WRKSRC}/tests/*.failed 2>/dev/null ; exit 1 ; } >X.else >X @${ECHO_CMD} '===> SKIPPING e2fsprogs self-test suite (DISCOURAGED!)' >X.endif >X >Xpost-install: >X # pkg workaround time again; >X # the whole purpose of this dance is to move the necessities for >X # /etc/fstab fsck'ing into /sbin, and symlink to these guys >X # in the regular hierarchy, normally $PREFIX/sbin. Hard links may >X # crash the install if /usr[/local] is a separate file system from /, >X # and pkg 1.15.4 can't automatically unroll or install relative symlinks. >X ${MKDIR} ${STAGEDIR}/sbin >X ${MV} -f ${STAGEDIR}${PREFIX}/sbin/e2fsck ${STAGEDIR}/sbin/ # from INSTALL_TARGET >X ${INSTALL_PROGRAM} ${WRKSRC}/fsck_ext2fs ${STAGEDIR}/sbin/ # from port >X # according to TPH 6.1.1 Handling Symbolic Links, these are to be absolute, >X # yet stage-qa warns about these on 2020-09-16: >X ${LN} -fs /sbin/fsck_ext2fs ${STAGEDIR}${PREFIX}/sbin/ >X ${LN} -fs /sbin/e2fsck ${STAGEDIR}${PREFIX}/sbin/ >X # these are made hardlinks to symlinks - -P avoids following them to /sbin: >X ${LN} -fP ${STAGEDIR}${PREFIX}/sbin/e2fsck ${STAGEDIR}${PREFIX}/sbin/fsck.ext2 >X ${LN} -fP ${STAGEDIR}${PREFIX}/sbin/e2fsck ${STAGEDIR}${PREFIX}/sbin/fsck.ext3 >X ${LN} -fP ${STAGEDIR}${PREFIX}/sbin/e2fsck ${STAGEDIR}${PREFIX}/sbin/fsck.ext4 >X # now the remainder of the usual post-install jobs: >X ${INSTALL_MAN} ${FILESDIR}/fsck_ext2fs.8 ${STAGEDIR}${PREFIX}/man/man8/ >X.if ${PORT_OPTIONS:MDOCS} >X ${MKDIR} ${STAGEDIR}${DOCSDIR} >X.for i in ${PORTDOCS} >X ${INSTALL_DATA} ${WRKSRC}/${i} ${STAGEDIR}${DOCSDIR} >X.endfor >X.endif >X # remove or relocate files installed by other ports already, or shadowing system files: >X cd ${STAGEDIR}${PREFIX} && \ >X ${XARGS} <${FILESDIR}/unwanted ${RM} && \ >X ${RMDIR} include/e2fsprogs/blkid include/e2fsprogs/ss share/ss >X ${MV} ${STAGEDIR}${PREFIX}/bin/compile_et ${STAGEDIR}${PREFIX}/bin/e2fsprogs-compile_et >X ${MV} ${STAGEDIR}${PREFIX}/man/man1/compile_et.1 ${STAGEDIR}${PREFIX}/man/man1/e2fsprogs-compile_et.1 >X ${MKDIR} ${STAGEDIR}${DATADIR}/et/ >X ${MV} ${STAGEDIR}${PREFIX}/share/et/* ${STAGEDIR}${DATADIR}/et/ >X ${REINPLACE_CMD} -e 's}^DIR=.*$$}DIR=${DATADIR}/et}' -i '' ${STAGEDIR}${PREFIX}/bin/e2fsprogs-compile_et >X ${RMDIR} ${STAGEDIR}${PREFIX}/share/et >X >X# >X# the next line closes .if ${MASTERDIR} == ${.CURDIR} >X.endif >X >X.include <bsd.port.post.mk> >da2c5ae5bfd3df6f8c202d112b281632 >echo x - e2fsprogs/pkg-install >sed 's/^X//' >e2fsprogs/pkg-install << '66515d0aaa957750231152cba1f59ba0' >X#!/bin/sh >Xset -eu >X >XPKGNAME="$1" >XMODE="$2" # PRE-INSTALL, POST-INSTALL, DEINSTALL, POST-DEINSTALL >X >Xcase "$MODE" in >XPOST-INSTALL) >X # try to replace the e2fsck and its wrapper, fsck_ext2fs, >X # symbolic links by hard links if possible (pkg ships them as symlinks) >X d1=${PKG_ROOTDIR}/sbin/ ; dev1=$(stat -Lf %Xd "$d1") >X d2=${PKG_ROOTDIR}${PKG_PREFIX}/sbin/ ; dev2=$(stat -Lf %Xd "$d2") >X if [ "$dev1" = "$dev2" ] && [ "$(realpath "$d1")" != "$(realpath "$d2")"; then >X for i in e2fsck fsck_ext2fs ; do >X ln -fhP ${d1}${i} ${d2}${i} >X done >X for i in ext2 ext3 ext4 ; do >X ln -fhP ${d2}e2fsck ${d2}fsck.$i >X done >X fi >X # >X # install configuration file and update config files from >X # old "ext4dev" to current "ext4" name. >X # >X if test -s ${PKG_PREFIX}/etc/mke2fs.conf; then >X if cmp -s ${PKG_PREFIX}/etc/mke2fs.conf.dist \ >X ${PKG_PREFIX}/etc/mke2fs.conf; then >X true >X else >X rc=0 >X grep -q ext4dev ${PKG_PREFIX}/etc/mke2fs.conf || rc=$? >X case $rc in >X 1) # ext4dev not found (old name) >X cp -f -p ${PKG_PREFIX}/etc/mke2fs.conf.dist \ >X ${PKG_PREFIX}/etc/mke2fs.conf.e2fsprogs-new >X echo "===========================================================================" >X echo "Warning: installing mke2fs.conf in ${PKG_PREFIX}/etc/mke2fs.conf.e2fsprogs-new" >X echo "Check to see if you need to update your ${PKG_PREFIX}/etc/mke2fs.conf" >X echo "===========================================================================" >X ;; >X 0) # ext4dev found (old name) >X mv ${PKG_PREFIX}/etc/mke2fs.conf \ >X ${PKG_PREFIX}/etc/mke2fs.conf.e2fsprogs-old >X cp -f -p ${PKG_PREFIX}/etc/mke2fs.conf.dist \ >X ${PKG_PREFIX}/etc/mke2fs.conf >X echo "===========================================================================" >X echo "Your mke2fs.conf is too old. Backing up old version in" >X echo "${PKG_PREFIX}/etc/mke2fs.conf.e2fsprogs-old. Please check to see" >X echo "if you have any local customizations that you wish to preserve." >X echo "===========================================================================" >X ;; >X *) # grep failed >X exit $rc >X ;; >X esac >X fi >X else >X # missing -> install >X cp -p ${PKG_PREFIX}/etc/mke2fs.conf.dist \ >X ${PKG_PREFIX}/etc/mke2fs.conf >X fi >X ;; >XDEINSTALL) >X if cmp -s ${PKG_PREFIX}/etc/mke2fs.conf \ >X ${PKG_PREFIX}/etc/mke2fs.conf.dist >X then >X rm -f ${PKG_PREFIX}/etc/mke2fs.conf >X else >X echo "If and only if you are deleting e2fsprogs forever," >X echo "remember to delete ${PKG_PREFIX}/etc/mke2fs.conf." >X fi >X # e2fsck.conf is no longer part of the distribution, but still supported, >X # => no pkg-list @sample line possible >X # and no reference e2fsck.conf.sample or e2fsck.conf.dist is available >X if test -f ${PKG_PREFIX}/etc/e2fsck.conf >X then >X echo "If and only if you are deleting e2fsprogs forever," >X echo "remember to delete ${PKG_PREFIX}/etc/e2fsck.conf." >X fi >X ;; >Xesac >66515d0aaa957750231152cba1f59ba0 >echo c - e2fsprogs/files >mkdir -p e2fsprogs/files > /dev/null 2>&1 >echo x - e2fsprogs/files/patch-lib_blkid_devname.c >sed 's/^X//' >e2fsprogs/files/patch-lib_blkid_devname.c << '9d940d3d02d52951f49fa8e23ad27577' >X--- lib/blkid/devname.c.orig 2020-03-21 04:24:04 UTC >X+++ lib/blkid/devname.c >X@@ -40,6 +40,9 @@ >X #include <sys/sysmacros.h> >X #endif >X #include <time.h> >X+#ifdef __FreeBSD__ >X+#include <sys/sysctl.h> >X+#endif >X >X #include "blkidP.h" >X >X@@ -397,11 +400,15 @@ evms_probe_all(blkid_cache cache, int only_if_new) >X static int probe_all(blkid_cache cache, int only_if_new) >X { >X FILE *proc; >X+#ifndef __FreeBSD__ >X char line[1024]; >X+ int ma, mi; >X+#else >X+ char *line; >X+#endif /* __FreeBSD__ */ >X char ptname0[129], ptname1[129], *ptname = 0; >X char *ptnames[2]; >X dev_t devs[2]; >X- int ma, mi; >X unsigned long long sz; >X int lens[2] = { 0, 0 }; >X int which = 0, last = 0; >X@@ -423,20 +430,68 @@ static int probe_all(blkid_cache cache, int only_if_ne >X lvm_probe_all(cache, only_if_new); >X #endif >X >X+#ifndef __FreeBSD__ >X proc = fopen(PROC_PARTITIONS, "r"); >X if (!proc) >X return -BLKID_ERR_PROC; >X >X while (fgets(line, sizeof(line), proc)) { >X+#else >X+ size_t len, bufsiz = 4096; >X+ char *buf = NULL; >X+ >X+ for(;;) { >X+ buf = realloc(buf, bufsiz); >X+ if (!buf) return -BLKID_ERR_MEM; >X+ len = bufsiz - 1; >X+ if (sysctlbyname("kern.geom.conftxt", buf, &len, NULL, 0)) { >X+ if (ENOMEM != errno) { >X+ free(buf); >X+ return -BLKID_ERR_IO; >X+ } >X+ bufsiz <<= 1; >X+ } else { >X+ if (len < bufsiz) buf[len] = '\0'; >X+ else buf[bufsiz - 1] = '\0'; >X+ break; >X+ } >X+ } >X+ char *str = buf; >X+ while (line = strsep(&str, "\n")) { >X+#endif /* __FreeBSD__ */ >X last = which; >X which ^= 1; >X ptname = ptnames[which]; >X >X+#ifndef __FreeBSD__ >X if (sscanf(line, " %d %d %llu %128[^\n ]", >X &ma, &mi, &sz, ptname) != 4) >X continue; >X devs[which] = makedev(ma, mi); >X+#else >X+ char type[5]; >X+ int dummy; >X >X+ if (sscanf(line, "%*d %5s %128[^ ] %lld %d", >X+ type, ptname, &sz, &dummy) != 4) >X+ continue; >X+ sz /= 1024; >X+ >X+ if (strcmp("PART", type) && strcmp("DISK", type)) >X+ continue; >X+ { >X+ struct stat st; >X+ char dn[128]; >X+ if (snprintf(dn, sizeof dn, "/dev/%s", ptname) >= sizeof dn) >X+ continue; >X+ >X+ if (stat(dn, &st)) >X+ continue; >X+ >X+ devs[which] = st.st_rdev; >X+ } >X+#endif /* __FreeBSD__ */ >X+ >X DBG(DEBUG_DEVNAME, printf("read partition name %s\n", ptname)); >X >X /* Skip whole disk devs unless they have no partitions. >X@@ -507,7 +562,11 @@ static int probe_all(blkid_cache cache, int only_if_ne >X if (lens[which]) >X probe_one(cache, ptname, devs[which], 0, only_if_new); >X >X+#ifndef __FreeBSD__ >X fclose(proc); >X+#else >X+ free(buf); >X+#endif /* __FreeBSD__ */ >X blkid_flush_cache(cache); >X return 0; >X } >9d940d3d02d52951f49fa8e23ad27577 >echo x - e2fsprogs/files/patch-tests_Makefile.in >sed 's/^X//' >e2fsprogs/files/patch-tests_Makefile.in << 'c8a933aac7543d8b8c888509b7f22816' >X--- tests/Makefile.in.orig 2019-07-15 01:03:14 UTC >X+++ tests/Makefile.in >X@@ -16,7 +16,7 @@ all:: @DO_TEST_SUITE@ test_one test_script >X test_one: $(srcdir)/test_one.in Makefile mke2fs.conf test_data.tmp >X @echo "Creating test_one script..." >X @[ -f test_one ] && chmod u+w test_one || true >X- @echo "#!/bin/sh" > test_one >X+ @echo "#!${SHELL}" > test_one >X @echo "HTREE=y" >> test_one >X @echo "QUOTA=y" >> test_one >X @echo "SRCDIR=@srcdir@" >> test_one >c8a933aac7543d8b8c888509b7f22816 >echo x - e2fsprogs/files/patch-0-tytso-3-tests-use-grep-E-for-better-portability-in-r_inline_.patch >sed 's/^X//' >e2fsprogs/files/patch-0-tytso-3-tests-use-grep-E-for-better-portability-in-r_inline_.patch << '30161156e3d7af696c0b90385034101f' >XFrom e3b002dcc43364972275fe32438af299dd6629a0 Mon Sep 17 00:00:00 2001 >XFrom: Theodore Ts'o <tytso@mit.edu> >XDate: Sun, 22 Mar 2020 23:56:14 -0400 >XSubject: [PATCH 3/3] tests: use grep -E for better portability in >X r_inline_xattr >X >XSince r_inline_xattr is using an extended regexp, we need grep -E on >Xsome implementations of grep. >X >XSigned-off-by: Theodore Ts'o <tytso@mit.edu> >X--- >X tests/r_inline_xattr/expect | 4 ++-- >X tests/r_inline_xattr/script | 8 ++++---- >X 2 files changed, 6 insertions(+), 6 deletions(-) >X >Xdiff --git a/tests/r_inline_xattr/expect b/tests/r_inline_xattr/expect >Xindex 885de59d..773db102 100644 >X--- ./tests/r_inline_xattr/expect >X+++ b/tests/r_inline_xattr/expect >X@@ -1,5 +1,5 @@ >X resize2fs test >X-debugfs -R ''stat file'' test.img 2>&1 | grep ''^Inode\|in inode body\|user.name ('' >X+debugfs -R ''stat file'' test.img 2>&1 | grep -E ''^Inode\|in inode body\|user.name \('' >X Inode: 1550 Type: regular Mode: 0644 Flags: 0x0 >X user.name (11) = "propervalue" >X Exit status is 0 >X@@ -8,7 +8,7 @@ Resizing the filesystem on test.img to 5120 (1k) blocks. >X The filesystem on test.img is now 5120 (1k) blocks long. >X >X Exit status is 0 >X-debugfs -R ''stat file'' test.img 2>&1 | grep ''^Inode\|in inode body\|user.name ('' >X+debugfs -R ''stat file'' test.img 2>&1 | grep -E ''^Inode\|in inode body\|user.name \('' >X Inode: 12 Type: regular Mode: 0644 Flags: 0x0 >X user.name (11) = "propervalue" >X Exit status is 0 >Xdiff --git a/tests/r_inline_xattr/script b/tests/r_inline_xattr/script >Xindex 4e7dd94c..2f754e60 100644 >X--- ./tests/r_inline_xattr/script >X+++ b/tests/r_inline_xattr/script >X@@ -13,8 +13,8 @@ gunzip < $IMAGE > $TMPFILE >X echo "resize2fs test" > $OUT.new >X >X # Look at existing inline extended attribute >X-echo "debugfs -R ''stat file'' test.img 2>&1 | grep ''^Inode\|in inode body\|user.name (''" >> $OUT.new >X-$DEBUGFS -R "stat file" $TMPFILE 2>&1 | grep "^Inode\|in inode body\|user.name (" >> $OUT.new >X+echo "debugfs -R ''stat file'' test.img 2>&1 | grep -E ''^Inode\|in inode body\|user.name \\(''" >> $OUT.new >X+$DEBUGFS -R "stat file" $TMPFILE 2>&1 | grep -E "^Inode|in inode body|user.name \(" >> $OUT.new >X status=$? >X echo Exit status is $status >> $OUT.new >X >X@@ -25,8 +25,8 @@ status=$? >X echo Exit status is $status >> $OUT.new >X >X # Look at inline extended attribute in resized fs >X-echo "debugfs -R ''stat file'' test.img 2>&1 | grep ''^Inode\|in inode body\|user.name (''" >> $OUT.new >X-$DEBUGFS -R "stat file" $TMPFILE 2>&1 | grep "^Inode\|in inode body\|user.name (" >> $OUT.new >X+echo "debugfs -R ''stat file'' test.img 2>&1 | grep -E ''^Inode\|in inode body\|user.name \\(''" >> $OUT.new >X+$DEBUGFS -R "stat file" $TMPFILE 2>&1 | grep -E "^Inode|in inode body|user.name \(" >> $OUT.new >X status=$? >X echo Exit status is $status >> $OUT.new >X >X-- >X2.24.1 >X >30161156e3d7af696c0b90385034101f >echo x - e2fsprogs/files/extrapatch-e2fsck_sigcatcher.c >sed 's/^X//' >e2fsprogs/files/extrapatch-e2fsck_sigcatcher.c << '1e19659a90bb8419511234b330c48b39' >X--- e2fsck/sigcatcher.c.orig 2020-01-06 23:10:17 UTC >X+++ e2fsck/sigcatcher.c >X@@ -17,6 +17,7 @@ >X #ifdef HAVE_EXECINFO_H >X #include <execinfo.h> >X #endif >X+#include <libunwind.h> >X >X #include "e2fsck.h" >X >X@@ -376,7 +377,7 @@ static void die_signal_handler(int signum, siginfo_t * >X void *stack_syms[32]; >X int frames; >X >X- frames = backtrace(stack_syms, 32); >X+ frames = unw_backtrace(stack_syms, 32); >X backtrace_symbols_fd(stack_syms, frames, 2); >X } >X #endif >1e19659a90bb8419511234b330c48b39 >echo x - e2fsprogs/files/patch-0-tytso-1-Use-ext2_loff_t-instead-of-loff_t.patch >sed 's/^X//' >e2fsprogs/files/patch-0-tytso-1-Use-ext2_loff_t-instead-of-loff_t.patch << 'a366e13277039d4132ac7f92fef117e0' >XThe patch was provided by Ted Y. Ts'o, with the final loff_t -> >Xext2_loff_t manually added by mandree@FreeBSD.org >X-------------- >X >XFrom 3fab0b6872b74ae0efab1ebdc6318924fda5f3a5 Mon Sep 17 00:00:00 2001 >XFrom: Theodore Ts'o <tytso@mit.edu> >XDate: Sun, 22 Mar 2020 23:30:14 -0400 >XSubject: [PATCH 1/3] Use ext2_loff_t instead of loff_t >X >XThe loff_t type is a glibc'ism and is not fully portable. Use >Xext2_loff_t instead. >X >XFixes: 382ed4a1c2b6 ("e2fsck: use proper types for variables") >XSigned-off-by: Theodore Ts'o <tytso@mit.edu> >XReported-by: Matthias Andree <matthias.andree@gmx.de> >X--- >X lib/ext2fs/imager.c | 2 +- >X misc/e2fuzz.c | 9 +++++---- >X 2 files changed, 6 insertions(+), 5 deletions(-) >X >Xdiff --git a/lib/ext2fs/imager.c b/lib/ext2fs/imager.c >Xindex b3ede9a8..1aebe625 100644 >X--- ./lib/ext2fs/imager.c >X+++ b/lib/ext2fs/imager.c >X@@ -67,7 +67,7 @@ errcode_t ext2fs_image_inode_write(ext2_filsys fs, int fd, int flags) >X blk64_t blk; >X ssize_t actual; >X errcode_t retval; >X- loff_t r; >X+ ext2_loff_t r; >X >X buf = malloc(fs->blocksize * BUF_BLOCKS); >X if (!buf) >Xdiff --git a/misc/e2fuzz.c b/misc/e2fuzz.c >Xindex 7c0f776f..f22c9f32 100644 >X--- ./misc/e2fuzz.c >X+++ b/misc/e2fuzz.c >X@@ -33,9 +33,10 @@ static unsigned long long user_corrupt_bytes = 0; >X static double user_corrupt_pct = 0.0; >X >X #if !defined HAVE_PWRITE64 && !defined HAVE_PWRITE >X-static ssize_t my_pwrite(int fd, const void *buf, size_t count, off_t offset) >X+static ssize_t my_pwrite(int fd, const void *buf, size_t count, >X+ ext2_loff_t offset) >X { >X- if (lseek(fd, offset, SEEK_SET) < 0) >X+ if (ext2fs_llseek(fd, offset, SEEK_SET) < 0) >X return 0; >X >X return write(fd, buf, count); >X@@ -82,7 +83,7 @@ static int find_block_helper(ext2_filsys fs EXT2FS_ATTR((unused)), >X } >X >X static errcode_t find_metadata_blocks(ext2_filsys fs, ext2fs_block_bitmap bmap, >X- off_t *corrupt_bytes) >X+ ext2_loff_t *corrupt_bytes) >X { >X dgrp_t i; >X blk64_t b, c; >X@@ -181,7 +182,7 @@ static int process_fs(const char *fsname) >X int flags, fd; >X ext2_filsys fs = NULL; >X ext2fs_block_bitmap corrupt_map; >X- loff_t hsize, count, off, offset, corrupt_bytes; >X+ ext2_loff_t hsize, count, off, offset, corrupt_bytes; >X unsigned char c; >X- loff_t i; >X+ ext2_loff_t i; >X >X-- >X2.24.1 >X >a366e13277039d4132ac7f92fef117e0 >echo x - e2fsprogs/files/patch-misc_e2fuzz.c >sed 's/^X//' >e2fsprogs/files/patch-misc_e2fuzz.c << 'd867baecc4c6cb19dd8525cacbd899f4' >X--- misc/e2fuzz.c.orig 2020-03-23 08:29:36 UTC >X+++ misc/e2fuzz.c >X@@ -278,8 +278,8 @@ static int process_fs(const char *fsname) >X c |= 0x80; >X if (verbose) >X printf("Corrupting byte %lld in block %lld to 0x%x\n", >X- off % fs->blocksize, >X- off / fs->blocksize, c); >X+ (long long)off % fs->blocksize, >X+ (long long)off / fs->blocksize, c); >X if (dryrun) >X continue; >X #ifdef HAVE_PWRITE64 >d867baecc4c6cb19dd8525cacbd899f4 >echo x - e2fsprogs/files/fsck_ext2fs.8 >sed 's/^X//' >e2fsprogs/files/fsck_ext2fs.8 << '9fc66a2d5c67daf3740fc43bd201604f' >X.TH fsck_ext2fs 8 2006-07-02 "Matthias Andree" "FreeBSD Ports" >X.\" >X.\" fsck_ext2fs.8 - manual page for fsck_ext2fs wrapper >X.\" >X.\" (C) Copyright 2006 by Matthias Andree <matthias.andree@gmx.de> >X.\" >X.\" License: This file may be redistributed in accordance with the terms >X.\" of the GNU General Public License v2. >X.\" >X.\" Upstream $Id: fsck_ext2fs.8,v 1.3 2006/07/02 11:45:21 emma Exp $ >X.\" $FreeBSD: head/sysutils/e2fsprogs/files/fsck_ext2fs.8 340872 2014-01-24 00:14:07Z mat $ >X.\" >X.SH NAME >X.B fsck_ext2fs >X\- compatibility wrapper for e2fsck >X.SH SYNOPSIS >X.P >X.B fsck_ext2fs >X[\fB\-Fpfnyv\fR] [\fB\-b\fR \fIblock\fR] >X.SH DESCRIPTION >X.P >X\fBfsck_ext2fs\fR maps the traditional FreeBSD \fBfsck_ffs\fR options to >Xoptions with the same functionality for \fBe2fsck,\fR runs \fBe2fsck\fR >Xand then maps its exit status to values that FreeBSD understands. >X\fBe2fsck\fR is a utility to check and repair ext2 and ext3 file >Xsystems. >X >X.SH OPTIONS >X.IP \fB\-F\fR >X(check foreground mode required) Immediately exits with status 1 to tell >X\fBfsck\fR that ext2fs cannot be checked in the background. \fBfsck\fR >Xusually runs \fBfsck_*\fR programs twice, first with \fB\-F\fR to find >Xout if they can do background checking, then either immediately without >X\fB\-F\fR for foreground checking or deferred in the background with >X\fB\-B\fR. >X.IP \fB\-p\fR >X(preen mode) This option suppresses adding the \fB\-f\fR option (unless >X\fB\-f\fR is also given) and adds the \fB\-p\fR option to the >X\fBe2fsck\fR command line. This causes \fBe2fsck\fR to automatically fix >Xany filesystem problems that can safely be fixed without operator >Xintervention. Without this option given, \fBe2fsck\fR will be run with >Xthe \fB\-f\fR option to force a check, since interactive scan and repair >Xmode is the default on FreeBSD, but not on Linux where \fBe2fsck\fR >Xcomes from. >X.IP \fB\-f\fR >X(force check) This option forces the check of a clean file system while >Xpreening and is passed to \fBe2fsck\fR verbatim. >X.IP \fB\-n\fR >X("no" mode) This option causes the file system to be opened in read-only >Xmode and assume "no" as answer to all questions. This is the only way to >Xsafely run \fBfsck\fR on a mounted ext2 or ext3 file system. This option >Xis passed to \fBe2fsck\fR verbatim. >X.IP \fB\-y\fR >X("yes" mode) This option is passed verbatim to \fBe2fsck\fR and causes >Xit to assume "yes" as answer to all questions. This allows the >Xnon-interactive use of e2fsck but is rather aggressive. Use with care. >X.IP \fB\-v\fR >X(verbose output) This option is passed verbatim to \fBe2fsck\fR and >Xcauses it to verbosely report its progress. >X.IP "\fB\-b\fR \fIblock\fR" >X(use alternate super block) This option is passed verbatim to >X\fBe2fsck\fR and selects an alternate super block, for use when the >Xprimary super block has been damaged. Please see the \fBe2fsck\fR(8) >Xmanual page for details. >X >X.SH EXIT STATUS >XIf errors remain after \fBe2fsck\fR, an invalid option or too many >Xoptions have been specified, \fBe2fsck\fR was killed with a signal or >Xthe \fIfork\fB system call failed, \fBfsck_ext2fs\fR exits with status >XEXIT_FAILURE (usually 1). If \fBe2fsck\fR cannot be started, exits with >Xstatus 127. If the file system is clean after \fBe2fsck\fR operation, >Xexits with status EXIT_SUCCESS (0). >X >X.SH NOTES >X.P >XThis utility is merely meant as an adaptor so that \fBe2fsck\fR can be >Xrun during the boot process, it does not support all options that >X\fBe2fsck\fR offers. If you need one of its advanced options, please run >X\fBe2fsck\fR directly. >X >X.SH FILES >X.TP >X.I /sbin/e2fsck >Xis the location of the \fBe2fsck\fR program to run. >X >X.SH AUTHOR >X.P >XMatthias Andree <matthias.andree@gmx.de> wrote the program and this >Xmanual page. >X.SH CONFORMING TO >XThe FreeBSD 6.1 command line interface for \fBfsck_ufs\fR(8). >X.SH SEE ALSO >X.BR fsck (8), >X.BR e2fsck (8) >Xand >X.BR fsck_ufs (8). >9fc66a2d5c67daf3740fc43bd201604f >echo x - e2fsprogs/files/patch-lib__uuid__gen_uuid.c >sed 's/^X//' >e2fsprogs/files/patch-lib__uuid__gen_uuid.c << '48b8894e2b0e7d5866f397fe9a294264' >X--- lib/uuid/gen_uuid.c.orig 2020-03-21 04:24:04 UTC >X+++ lib/uuid/gen_uuid.c >X@@ -94,6 +94,7 @@ >X #ifdef HAVE_SYS_RESOURCE_H >X #include <sys/resource.h> >X #endif >X+#include <ifaddrs.h> >X >X #include "uuidP.h" >X #include "uuidd.h" >X@@ -300,6 +301,28 @@ static int get_node_id(unsigned char *node_id) >X } >X } >X close(sd); >X+#else >X+ struct ifaddrs *ifaddrsp, *ifaddrp; >X+ unsigned char *a; >X+ >X+ if (getifaddrs(&ifaddrsp) < 0) >X+ return -1; >X+ for (ifaddrp = ifaddrsp; ifaddrp != NULL; ifaddrp = ifaddrp->ifa_next) >X+ { >X+ if (ifaddrp->ifa_addr == NULL) >X+ continue; >X+ if (ifaddrp->ifa_addr->sa_family != AF_LINK) >X+ continue; >X+ a = LLADDR((struct sockaddr_dl *)ifaddrp->ifa_addr); >X+ if (!a[0] && !a[1] && !a[2] && !a[3] && !a[4] && !a[5]) >X+ continue; >X+ if (node_id) { >X+ memcpy(node_id, a, 6); >X+ freeifaddrs(ifaddrsp); >X+ return 1; >X+ } >X+ } >X+ freeifaddrs(ifaddrsp); >X #endif >X return 0; >X } >X@@ -484,7 +507,7 @@ static void close_all_fds(void) >X } >X #endif /* defined(USE_UUIDD) && defined(HAVE_SYS_UN_H) */ >X >X-#if __GNUC_PREREQ (4, 6) >X+#if __GNUC_PREREQ__ (4, 6) >X #pragma GCC diagnostic push >X #if !defined(USE_UUIDD) || !defined(HAVE_SYS_UN_H) >X #pragma GCC diagnostic ignored "-Wunused-parameter" >X@@ -572,7 +595,7 @@ fail: >X #endif >X return -1; >X } >X-#if __GNUC_PREREQ (4, 6) >X+#if __GNUC_PREREQ__ (4, 6) >X #pragma GCC diagnostic pop >X #endif >X >48b8894e2b0e7d5866f397fe9a294264 >echo x - e2fsprogs/files/unwanted >sed 's/^X//' >e2fsprogs/files/unwanted << 'a7437b2e25607ce5e23f77883e3c4de3' >Xbin/mk_cmds >Xinclude/e2fsprogs/blkid/blkid.h >Xinclude/e2fsprogs/blkid/blkid_types.h >Xinclude/e2fsprogs/ss/ss.h >Xinclude/e2fsprogs/ss/ss_err.h >Xlib/e2fsprogs/libblkid.a >Xlib/e2fsprogs/libblkid.so >Xlib/e2fsprogs/libblkid.so.1 >Xlib/e2fsprogs/libblkid.so.1.0 >Xlib/e2fsprogs/libcom_err.a >Xlib/e2fsprogs/libss.a >Xlib/e2fsprogs/libss.so >Xlib/e2fsprogs/libss.so.2 >Xlib/e2fsprogs/libss.so.2.0 >Xlibdata/pkgconfig/blkid.pc >Xlibdata/pkgconfig/ss.pc >Xman/man1/mk_cmds.1 >Xman/man3/com_err.3 >Xman/man3/libblkid.3 >Xshare/ss/ct_c.awk >Xshare/ss/ct_c.sed >a7437b2e25607ce5e23f77883e3c4de3 >echo x - e2fsprogs/files/patch-misc_blkid.8.in >sed 's/^X//' >e2fsprogs/files/patch-misc_blkid.8.in << 'dbc188a8d021fec431b54d0e91b51033' >X--- misc/blkid.8.in.orig 2020-03-21 04:24:04 UTC >X+++ misc/blkid.8.in >X@@ -144,10 +144,10 @@ option. >X Display tokens from only the specified device. It is possible to >X give multiple >X .I device >X-options on the command line. If none is given, all devices which >X-appear in >X-.I /proc/partitions >X-are shown, if they are recognized. >X+options on the command line. If none is given, all DISK and PART devices which >X+appear in the >X+.I kern.geom.conftxt >X+sysctl variable are shown, if they are recognized. >X .SH "RETURN CODE" >X If the specified token was found, or if any tags were shown from (specified) >X devices, 0 is returned. If the specified token was not found, or no >dbc188a8d021fec431b54d0e91b51033 >echo x - e2fsprogs/files/patch-lib_support_plausible.c >sed 's/^X//' >e2fsprogs/files/patch-lib_support_plausible.c << '582748c15a059ea6fda612e54e9ed787' >X--- lib/support/plausible.c.orig 2020-01-06 23:10:17 UTC >X+++ lib/support/plausible.c >X@@ -62,7 +62,7 @@ static void *magic_handle; >X static int magic_library_available(void) >X { >X if (!magic_handle) { >X- magic_handle = dlopen("libmagic.so.1", RTLD_NOW); >X+ magic_handle = dlopen("libmagic.so", RTLD_NOW); >X if (!magic_handle) >X return 0; >X >582748c15a059ea6fda612e54e9ed787 >echo x - e2fsprogs/files/patch-0-tytso-2-e2fsck-fix-various-gcc-Wall-nits.patch >sed 's/^X//' >e2fsprogs/files/patch-0-tytso-2-e2fsck-fix-various-gcc-Wall-nits.patch << '5c3e2522c3c68f02b9b8de02fa26ea3f' >XFrom ef858c7194ff6f3dc0de162fe7bd82a8cb5e8fba Mon Sep 17 00:00:00 2001 >XFrom: Theodore Ts'o <tytso@mit.edu> >XDate: Sun, 22 Mar 2020 23:47:12 -0400 >XSubject: [PATCH 2/3] e2fsck: fix various gcc -Wall nits >X >XSigned-off-by: Theodore Ts'o <tytso@mit.edu> >X--- >X e2fsck/rehash.c | 4 ++-- >X e2fsck/unix.c | 2 +- >X e2fsck/util.c | 4 ++-- >X 3 files changed, 5 insertions(+), 5 deletions(-) >X >Xdiff --git a/e2fsck/rehash.c b/e2fsck/rehash.c >Xindex 1616d07a..30e510a6 100644 >X--- ./e2fsck/rehash.c >X+++ b/e2fsck/rehash.c >X@@ -109,7 +109,7 @@ static int fill_dir_block(ext2_filsys fs, >X void *priv_data) >X { >X struct fill_dir_struct *fd = (struct fill_dir_struct *) priv_data; >X- struct hash_entry *new_array, *ent; >X+ struct hash_entry *ent; >X struct ext2_dir_entry *dirent; >X char *dir; >X unsigned int offset, dir_offset, rec_len, name_len; >X@@ -460,7 +460,7 @@ static errcode_t copy_dir_entries(e2fsck_t ctx, >X struct hash_entry *ent; >X struct ext2_dir_entry *dirent; >X unsigned int rec_len, prev_rec_len, left, slack, offset; >X- int i; >X+ blk_t i; >X ext2_dirhash_t prev_hash; >X int csum_size = 0; >X struct ext2_dir_entry_tail *t; >Xdiff --git a/e2fsck/unix.c b/e2fsck/unix.c >Xindex e71d7833..1b7ccea9 100644 >X--- ./e2fsck/unix.c >X+++ b/e2fsck/unix.c >X@@ -1439,7 +1439,7 @@ int main (int argc, char *argv[]) >X fputs("<?xml version=\"1.0\" encoding=\"utf-8\"?>\n", >X ctx->problem_logf); >X fprintf(ctx->problem_logf, "<problem_log time=\"%lu\">\n", >X- ctx->now); >X+ (unsigned long) ctx->now); >X fprintf(ctx->problem_logf, "<invocation prog=\"%s\"", >X argv[0]); >X for (i = 1; i < argc; i++) >Xdiff --git a/e2fsck/util.c b/e2fsck/util.c >Xindex d98b8e47..8cebd95a 100644 >X--- ./e2fsck/util.c >X+++ b/e2fsck/util.c >X@@ -126,7 +126,7 @@ void *e2fsck_allocate_memory(e2fsck_t ctx, unsigned long size, >X printf("Allocating %u bytes for %s...\n", size, description); >X #endif >X if (ext2fs_get_memzero(size, &ret)) { >X- sprintf(buf, "Can't allocate %u bytes for %s\n", >X+ sprintf(buf, "Can't allocate %lu bytes for %s\n", >X size, description); >X fatal_error(ctx, buf); >X } >X@@ -436,7 +436,7 @@ void print_resource_track(e2fsck_t ctx, const char *desc, >X #define kbytes(x) (((unsigned long long)(x) + 1023) / 1024) >X #ifdef HAVE_MALLINFO >X /* don't use mallinfo() if over 2GB used, since it returns "int" */ >X- if ((char *)sbrk(0) - (char *)track->brk_start < 2ULL << 30) { >X+ if ((char *)sbrk(0) - (char *)track->brk_start < 2LL << 30) { >X struct mallinfo malloc_info = mallinfo(); >X >X log_out(ctx, _("Memory used: %lluk/%lluk (%lluk/%lluk), "), >X-- >X2.24.1 >X >5c3e2522c3c68f02b9b8de02fa26ea3f >echo x - e2fsprogs/files/patch-lib__ext2fs__tst_bitops.c >sed 's/^X//' >e2fsprogs/files/patch-lib__ext2fs__tst_bitops.c << '18d40c1c07ad0153e1ae5640b1cd99d6' >X--- lib/ext2fs/tst_bitops.c.orig 2014-10-16 00:29:23 UTC >X+++ lib/ext2fs/tst_bitops.c >X@@ -104,7 +104,7 @@ int main(int argc, char **argv) >X bigarray = malloc(1 << 29); >X if (!bigarray) { >X fprintf(stderr, "Failed to allocate scratch memory!\n"); >X- exit(1); >X+ exit(0); >X } >X >X bigarray[BIG_TEST_BIT >> 3] = 0; >18d40c1c07ad0153e1ae5640b1cd99d6 >echo x - e2fsprogs/files/patch-e2fsck__unix.c >sed 's/^X//' >e2fsprogs/files/patch-e2fsck__unix.c << '6c7adbf920231b5219fcdd987ef7c2ba' >X// SIGINFO is a Berkeley extension, so we need to >X// remove the #define _XOPEN_SOURCE 600 >X// It would hide all non-POSIX declarations, including SIGINFO. >X >X--- e2fsck/unix.c.orig 2020-03-21 04:24:04 UTC >X+++ e2fsck/unix.c >X@@ -9,8 +9,6 @@ >X * %End-Header% >X */ >X >X-#define _XOPEN_SOURCE 600 /* for inclusion of sa_handler in Solaris */ >X- >X #include "config.h" >X #include <stdio.h> >X #ifdef HAVE_STDLIB_H >X@@ -602,6 +600,24 @@ static int e2fsck_update_progress(e2fsck_t ctx, int pa >X return 0; >X } >X >X+static int e2fsck_progress_once(e2fsck_t ctx, int pass, unsigned long cur, unsigned long max) >X+{ >X+ char buf[80]; >X+ float percent; >X+ >X+ if (pass == 0) >X+ return 0; >X+ >X+ percent = calc_percent(&e2fsck_tbl, pass, cur, max); >X+ e2fsck_simple_progress(ctx, ctx->device_name, >X+ percent, 0); >X+ >X+ printf("\n"); >X+ ctx->progress = 0; >X+ return 0; >X+} >X+ >X+ >X #define PATH_SET "PATH=/sbin" >X >X /* >X@@ -635,6 +651,17 @@ static void signal_progress_on(int sig EXT2FS_ATTR((un >X ctx->progress = e2fsck_update_progress; >X } >X >X+static void signal_progress_now(int sig EXT2FS_ATTR((unused))) >X+{ >X+ e2fsck_t ctx = e2fsck_global_ctx; >X+ >X+ if (!ctx) >X+ return; >X+ >X+ ctx->progress = e2fsck_progress_once; >X+ ctx->progress_fd = 0; >X+} >X+ >X static void signal_progress_off(int sig EXT2FS_ATTR((unused))) >X { >X e2fsck_t ctx = e2fsck_global_ctx; >X@@ -1111,6 +1138,10 @@ static errcode_t PRS(int argc, char *argv[], e2fsck_t >X sigaction(SIGUSR1, &sa, 0); >X sa.sa_handler = signal_progress_off; >X sigaction(SIGUSR2, &sa, 0); >X+ sa.sa_handler = signal_progress_now; >X+ if (!getenv("e2fsprogs_inhibit_SIGINFO")) { >X+ sigaction(SIGINFO, &sa, 0); >X+ } >X #endif >X >X /* Update our PATH to include /sbin if we need to run badblocks */ >6c7adbf920231b5219fcdd987ef7c2ba >echo x - e2fsprogs/files/patch-misc__Makefile.in >sed 's/^X//' >e2fsprogs/files/patch-misc__Makefile.in << 'b66bd3f4a397642a41be36413337e7d2' >X--- misc/Makefile.in.orig 2020-01-06 23:10:17 UTC >X+++ misc/Makefile.in >X@@ -34,17 +34,17 @@ INSTALL = @INSTALL@ >X >X SPROGS= mke2fs badblocks tune2fs dumpe2fs $(BLKID_PROG) logsave \ >X $(E2IMAGE_PROG) @FSCK_PROG@ e2undo >X-USPROGS= mklost+found filefrag e2freefrag $(UUIDD_PROG) \ >X+USPROGS= mklost+found e2freefrag $(UUIDD_PROG) \ >X $(E4DEFRAG_PROG) $(E4CRYPT_PROG) >X SMANPAGES= tune2fs.8 mklost+found.8 mke2fs.8 dumpe2fs.8 badblocks.8 \ >X e2label.8 $(FINDFS_MAN) $(BLKID_MAN) $(E2IMAGE_MAN) \ >X- logsave.8 filefrag.8 e2freefrag.8 e2undo.8 \ >X- $(UUIDD_MAN) $(E4DEFRAG_MAN) $(E4CRYPT_MAN) @FSCK_MAN@ \ >X+ logsave.8 e2freefrag.8 e2undo.8 \ >X+ $(E4DEFRAG_MAN) $(E4CRYPT_MAN) @FSCK_MAN@ \ >X e2mmpstatus.8 >X FMANPAGES= mke2fs.conf.5 ext4.5 >X >X-UPROGS= chattr lsattr $(FUSE_PROG) @UUID_CMT@ uuidgen >X-UMANPAGES= chattr.1 lsattr.1 @UUID_CMT@ uuidgen.1 >X+UPROGS= chattr lsattr $(FUSE_PROG) >X+UMANPAGES= chattr.1 lsattr.1 >X UMANPAGES+= @FUSE_CMT@ fuse2fs.1 >X >X LPROGS= @E2INITRD_PROG@ >X@@ -147,14 +147,14 @@ profiled: >X >X mke2fs.conf: $(srcdir)/mke2fs.conf.in >X if test -f $(srcdir)/mke2fs.conf.custom.in ; then \ >X- cp $(srcdir)/mke2fs.conf.custom.in mke2fs.conf; \ >X+ cp $(srcdir)/mke2fs.conf.custom.in mke2fs.conf.dist; \ >X else \ >X- cp $(srcdir)/mke2fs.conf.in mke2fs.conf; \ >X+ cp $(srcdir)/mke2fs.conf.in mke2fs.conf.dist; \ >X fi >X >X default_profile.c: mke2fs.conf $(srcdir)/profile-to-c.awk >X $(E) " PROFILE_TO_C mke2fs.conf" >X- $(Q) $(AWK) -f $(srcdir)/profile-to-c.awk < mke2fs.conf \ >X+ $(Q) $(AWK) -f $(srcdir)/profile-to-c.awk < mke2fs.conf.dist \ >X > default_profile.c >X findsuper: findsuper.o >X $(E) " LD $@" >X@@ -605,34 +605,9 @@ install: all $(SMANPAGES) $(UMANPAGES) installdirs >X (cd $(DESTDIR)$(man5dir); \ >X $(LN) $(LINK_INSTALL_FLAGS) ext4.5 $$i.5); \ >X done >X- $(Q) if test -f $(DESTDIR)$(root_sysconfdir)/mke2fs.conf; then \ >X- if cmp -s $(DESTDIR)$(root_sysconfdir)/mke2fs.conf \ >X- mke2fs.conf; then \ >X- true; \ >X- else \ >X- if grep -q ext4dev $(DESTDIR)$(root_sysconfdir)/mke2fs.conf ; then \ >X- $(ES) " INSTALL_DATA $(root_sysconfdir)/mke2fs.conf.e2fsprogs-new"; \ >X- $(INSTALL_DATA) mke2fs.conf \ >X- $(DESTDIR)$(root_sysconfdir)/mke2fs.conf.e2fsprogs-new; \ >X- echo "Warning: installing mke2fs.conf in $(DESTDIR)$(root_sysconfdir)/mke2fs.conf.e2fsprogs-new"; \ >X- echo "Check to see if you need to update your $(root_sysconfdir)/mke2fs.conf"; \ >X- else \ >X- $(ES) " INSTALL_DATA $(root_sysconfdir)/mke2fs.conf"; \ >X- mv $(DESTDIR)$(root_sysconfdir)/mke2fs.conf \ >X- $(DESTDIR)$(root_sysconfdir)/mke2fs.conf.e2fsprogs-old; \ >X- $(INSTALL_DATA) mke2fs.conf \ >X- $(DESTDIR)$(root_sysconfdir)/mke2fs.conf; \ >X- echo "Your mke2fs.conf is too old. Backing up old version in"; \ >X- echo "$(DESTDIR)$(root_sysconfdir)/mke2fs.conf.e2fsprogs-old. Please check to see"; \ >X- echo "if you have any local customizations that you wish to preserve."; \ >X- fi; \ >X- echo " "; \ >X- fi; \ >X- else \ >X- $(ES) " INSTALL_DATA $(root_sysconfdir)/mke2fs.conf"; \ >X- $(INSTALL_DATA) mke2fs.conf \ >X- $(DESTDIR)$(root_sysconfdir)/mke2fs.conf; \ >X- fi >X+ $(Q) $(ES) " INSTALL_DATA $(root_sysconfdir)/mke2fs.conf"; \ >X+ $(INSTALL_DATA) mke2fs.conf.dist \ >X+ $(DESTDIR)$(root_sysconfdir)/mke2fs.conf.dist >X >X install-strip: install >X $(Q) for i in $(SPROGS); do \ >b66bd3f4a397642a41be36413337e7d2 >echo x - e2fsprogs/files/fsck_ext2fs.c >sed 's/^X//' >e2fsprogs/files/fsck_ext2fs.c << '0f427da36b417e45cada276b03eecdd1' >X/* >X * fsck_ext2fs - wrapper for e2fsck on FreeBSD >X * Copyright (C) 2004,2006 Matthias Andree <matthias.andree@gmx.de> >X * redistributable in accordance with the >X * GNU General Public License v2 >X * >X * $FreeBSD: head/sysutils/e2fsprogs/files/fsck_ext2fs.c 340872 2014-01-24 00:14:07Z mat $ >X * >X * Upstream: $Id: fsck_ext2fs.c,v 1.6 2006/07/02 11:37:49 emma Exp $ >X * >X * format: gindent -kr >X */ >X >X#include <sys/types.h> >X#include <unistd.h> >X#include <stdlib.h> >X#include <stdio.h> >X#include <string.h> >X#include <sys/wait.h> >X#include <sys/time.h> >X#include <sys/resource.h> >X#include <errno.h> >X >X__attribute__ ((noreturn)) >Xstatic int die(const char *tag) >X{ >X perror(tag); >X exit(EXIT_FAILURE); >X} >X >Xint main(int argc, char **argv) >X{ >X int ch, i = 1, force = 0, status, verbose = 0, t; >X long block = 0; >X enum { normal, preen, yes, no } mode = normal; >X char *cmd[256]; >X pid_t pid; >X >X cmd[0] = "/sbin/e2fsck"; >X while ((ch = getopt(argc, argv, "BFpfnyb:v")) != -1) { >X switch (ch) { >X case 'p': >X mode = preen; >X break; >X case 'f': >X force = 1; >X break; >X case 'n': >X mode = no; >X break; >X case 'y': >X mode = yes; >X break; >X case 'b': >X block = atol(optarg); >X break; >X case 'v': >X verbose++; >X break; >X case 'F': >X /* e2fsck does not support background checking, >X * hence exit with nonzero status to force >X * the foreground check. */ >X exit(1); >X case 'B': >X default: >X fprintf(stderr, "%s: unknown option -%c\n", >X argv[0], optopt); >X exit(EXIT_FAILURE); >X } >X } >X >X if (force) >X cmd[i++] = "-f"; >X >X switch (mode) { >X case normal: >X /* FreeBSD needs -f to force a check only in context >X * with -p -- so map normal to force to match >X * expectations */ >X if (!force) >X cmd[i++] = "-f"; >X break; >X case yes: >X cmd[i++] = "-y"; >X break; >X case no: >X cmd[i++] = "-n"; >X break; >X case preen: >X cmd[i++] = "-p"; >X break; >X } >X >X if (block) { >X static char b[30]; >X >X sprintf(b, "-b %ld", block); >X cmd[i++] = b; >X } >X >X /* silently limit verbose to 15 so we don't overflow the cmd array */ >X if (verbose > 15) >X verbose = 15; >X >X for (t = verbose; t > 1; t--) >X cmd[i++] = "-v"; >X >X while (optind < argc) { >X cmd[i++] = argv[optind++]; >X /* sanity check so we don't overflow the cmd buffer */ >X if (i+1 == sizeof(cmd)/sizeof(cmd[0])) { >X errno = E2BIG; >X die(argv[0]); >X } >X } >X >X cmd[i++] = 0; >X >X if (verbose) { >X for (i=0; cmd[i]; i++) >X fputs(cmd[i], stderr), >X fputc(' ', stderr); >X fputc('\n', stderr); >X } >X >X pid = fork(); >X switch (pid) { >X case -1: >X /* error */ >X die("fork"); >X break; >X case 0: >X /* child */ >X (void) execv(cmd[0], cmd); >X perror("execve"); >X _exit(127); >X default: >X /* parent */ >X if (pid != waitpid(pid, &status, 0)) >X die("waitpid"); >X if (WIFSIGNALED(status) >X || (WIFEXITED(status) && WEXITSTATUS(status) >= 4)) >X exit(EXIT_FAILURE); >X } >X exit(EXIT_SUCCESS); >X} >0f427da36b417e45cada276b03eecdd1 >echo x - e2fsprogs/files/extrapatch-no-sbrk >sed 's/^X//' >e2fsprogs/files/extrapatch-no-sbrk << '76c816940ace16e4e1779ee274ad7be3' >Xdiff -up ./e2fsck/e2fsck.h.orig ./e2fsck/e2fsck.h >X--- ./e2fsck/e2fsck.h.orig 2018-05-16 01:42:44.000000000 +0200 >X+++ ./e2fsck/e2fsck.h 2018-07-07 12:50:43.420944000 +0200 >X@@ -134,7 +134,7 @@ struct dx_dirblock_info { >X #define DX_FLAG_FIRST 4 >X #define DX_FLAG_LAST 8 >X >X-#define RESOURCE_TRACK >X+#undef RESOURCE_TRACK >X >X #ifdef RESOURCE_TRACK >X /* >Xdiff -up ./resize/resource_track.c.orig ./resize/resource_track.c >X--- ./resize/resource_track.c.orig 2018-05-16 01:42:44.000000000 +0200 >X+++ ./resize/resource_track.c 2018-07-07 14:24:54.728576000 +0200 >X@@ -27,7 +27,6 @@ void init_resource_track(struct resource >X io_stats io_start = 0; >X >X track->desc = desc; >X- track->brk_start = sbrk(0); >X gettimeofday(&track->time_start, 0); >X #ifdef HAVE_GETRUSAGE >X #ifdef sun >X@@ -84,9 +83,7 @@ void print_resource_track(ext2_resize_t >X kbytes(malloc_info.arena), kbytes(malloc_info.hblkhd), >X kbytes(malloc_info.uordblks), kbytes(malloc_info.fordblks)); >X #else >X- printf("Memory used: %lu, ", >X- (unsigned long) (((char *) sbrk(0)) - >X- ((char *) track->brk_start))); >X+ printf("Memory used: unknown, "); >X #endif >X #ifdef HAVE_GETRUSAGE >X getrusage(RUSAGE_SELF, &r); >76c816940ace16e4e1779ee274ad7be3 >echo x - e2fsprogs/pkg-message >sed 's/^X//' >e2fsprogs/pkg-message << '2de8d1c5808b82dc6b888f992fa15d79' >X[ >X{ message: <<EOM >XNote: this is a modified version of the e2fsprogs package, not the official >Xpackage. Report all building and run-time trouble that originates in the >Xpackage to the port maintainer, mandree@FreeBSD.org. >XEOM >X} >X] >2de8d1c5808b82dc6b888f992fa15d79 >echo x - e2fsprogs/changes_4 >sed 's/^X//' >e2fsprogs/changes_4 << 'f1dd867028bf175ee1565cbcf8483a77' >X- make sure pkg-message appears on install and upgrade >X- make /sbin/e2fsck and /sbin/fsck_ext2fs visible in pkg catalog/pkg which >X * this entails symlinking from $PREFIX/sbin to /sbin, >X and pkg-install will attempt to replace the links by hard links if >X possible. pkg 1.15.4 cannot deal with packaged hard links and will fail >X- clean up and document pkg-install so that armchair experts don't pester me >X with meaningless change requests >X- change logic of mke2fs.conf upgrade handling to present less work for users >X on port/package upgrades >X- bump PORTREVISION >f1dd867028bf175ee1565cbcf8483a77 >echo x - e2fsprogs/pkg-descr >sed 's/^X//' >e2fsprogs/pkg-descr << 'dc56ac15b12b36ac98c366542257de18' >XSet of utilities and library to manipulate an ext2, ext3 or ext4 filesystem. >X >XWWW: http://e2fsprogs.sourceforge.net/ >dc56ac15b12b36ac98c366542257de18 >exit >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 249284
: 218010