Commit Graph

203 Commits

Author SHA1 Message Date
Matthias Andree cf41c5e996 sysutils/e2fsprogs: update to new upstream release v1.46.0
https://git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git/plain/doc/RelNotes/v1.46.0.txt?h=v1.46.0

The major item in porting is to switch from GNU libc's qsort_r()
interface to ours, but see https://reviews.freebsd.org/D17083

Also, it appears at cursory glance that it takes the FUSEFS option
to get HAVE_PTHREAD_H #defined. Just pass -DHAVE_PTHREAD_H through
CPPFLAGS without further investigation.

Finally, there appears to be some confusion around __u64 vs.
unsigned long long, we get format string complaints. Use <inttypes.h>
and leverage the PRIu64 macro.

I do not intend to MFH this.
2021-02-06 15:42:06 +00:00
Matthias Andree 7360a0378a e2fsprogs: make build more robust
Depending on external circumstances and options that I have not fully
investigated, several build-time failures occurred that were one of:
- missing symbols in liblzma (static build missed libmd)
  on some versions with LIBUNWIND enabled
- sometimes /bin/csh being pulled up for scripting, breaking in
  various places, reason unclear, possibly artifact of next one:
- questionable BASHTESTS handling cleaned up

As these are fixes for a potentially broken build,
no PORTREVISION bump necessary.

MFH:		2021Q1
2021-02-04 01:50:47 +00:00
Matthias Andree cf77141b0c sysutils/e2fsprogs: update to new 1.45.7 upstream release
Changelog:
https://git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git/plain/doc/RelNotes/v1.45.7.txt?h=v1.45.7

MFH:		2021Q1
2021-02-02 23:15:15 +00:00
Mark Linimon 177f25e27d Extend use of files/extrapatch-no-sbrk to riscv64 to fix build there.
Approved by:	portmgr (tier-2 blanket)
2021-01-01 23:03:53 +00:00
Juraj Lutter dca4f12df3 sysutils/e2fsprogs: Fix pkg-install
Fix pkg-install script where a closing ']' was missing.

Submitted by:	Giacomo Olgeni
Reviewed by:	osa (mentor), mandree
Approved by:	osa (mentor), mandree
Differential Revision:	https://reviews.freebsd.org/D27693
2020-12-21 15:23:01 +00:00
Matthias Andree 36892eaa48 - make /sbin/e2fsck and /sbin/fsck_ext2fs visible in pkg catalog/"pkg which",
so that "pkg which /sbin/e2fsck" yields the proper result.

  * this entails symlinking from $PREFIX/sbin to /sbin, and the pkg-install
    script will attempt to replace the symlinks by hard links if possible.
    pkg 1.15.4 cannot deal with packaged hard links and will fail.

  * Note that it is unavoidable that these be in /sbin because /usr/local or
    /usr may not be mounted and consequently ext2 file systems could not
    be fsck-ed or mounted from /etc/fstab.

  There will be no port option to avoid /sbin installs for now. We have too
  many options already and the testing effort increases exponentially.

- make sure pkg-message appears on both install and upgrade

- clean up and document/comment pkg-install so that armchair experts
  will not pester me with meaningless change requests

- bugfix/change: logic of mke2fs.conf upgrade handling to present less work for
  users on port/package upgrades

- bump PORTREVISION

PR:	249284 (related)
2020-09-23 12:44:16 +00:00
Matthias Andree 180bbe2e0d sysutils/e2fsprogs: fix "blkid" probe-all feature
e2fsprogs's misc/blkid utility would expect a /proc/partitions file
in a Linux-specific format.  Add code to read the kern.geom.conftxt
sysctl(3) value instead, and adjust parser.

While here, patch /etc/blkid.tab location to ${ETCDIR}.

Reported by:	Adam Dobrawy (private mail)
Tip to:		bapt@ (for the pointer to kern.geom.conftxt)
2020-06-25 18:44:30 +00:00
Matthias Andree 327c7cebcb e2fsprogs, rawtherapee: Repair more UCL pkg-message conversion errors.
Both pkg-message texts are relevant for updates.

Reverting this part of UNAUTHORIZED commits, and bump PORTREVISION.
Clean up pkg-message.

Failure-inducing commits:

------------------------------------------------------------------------
r508837 | mat | 2019-08-13 18:03:11 +0200 (Tue, 13 Aug 2019) | 2 lines

Convert to UCL & cleanup pkg-message (categories e-g)

------------------------------------------------------------------------
r508909 | mat | 2019-08-14 14:16:12 +0200 (Wed, 14 Aug 2019) | 2 lines

Convert to UCL & cleanup pkg-message (categories s)

------------------------------------------------------------------------
2020-04-12 02:34:26 +00:00
Matthias Andree f45845ec9d sysutils/e2fsprogs: install extfs.info (if DOCS is enabled)
This should have appened along with r453102/r453120 on 2017-10-29,
when shared libext2fs and headers were added to the install.

Bump PORTREVISION.

Reported by:	swills@
2020-03-31 22:10:59 +00:00
Matthias Andree 4564a5daec sysutils/e2fsprogs: Add a note about _XOPEN_SOURCE patching vs SIGINFO
This only affects a non-applied banner text for a patch, so
no code changes, no rebuilds, no PORTREVISION bump.
2020-03-24 09:54:00 +00:00
Matthias Andree f352bb8973 sysutils/e2fsprogs: Update to 1.45.6
Add three patches (one was extended) by Ted Y. Ts'o to fix various
issues (loff_t and type related).

Drop our own obsolete patches.

While here, drop obsolete parts of some of our patches
(malloc.h -> stdlib.h).

Since the online release notes are not available yet,
this is from doc/RelNotes/v1.45.6.txt, omitting Linux-/Hurd-specifics.

UI and Features
---------------
Debugfs will ignore lines in its command files which start with a
comment character ("#").

Fixes
-----
Fixed a number of potential out of bounds memory accesses caused by
fuzzed / malicious file systems.  (Addresses Google Bug: #147849134)

Fix a spurious complaint from e2fsck when a directory which previously
had more than 32000 subdirectories has the number of subdirectories
drops below 32000.

Mke2fs -d now correctly sets permission with files where the owner
permissions are not rwx.

Improve e2fsck's ability to deal with file systems with very large
number of directories, such that various data structures take more than
2GiB of memory.  Use better structure packing to improve the memory
efficiency of these data structures.

Fix debugfs so it correctly prints inode numbers > 2**31.

Filefrag now supports very large files (with > 4 billion blocks), as
well as block sizes up to 1 GiB.

Updated and clarified various man pages.  (Addresses Debian Bugs:
#953493, #953494, #951808)

Performance, Internal Implementation, Development Support etc.
--------------------------------------------------------------
Reserved the error code EXT2_ET_NO_GDESC (which will be used in
e2fsprogs v1.46+)

Added a thread-safe variant of e2p_feature2string(),
e2p_feature_to_string() to the libe2p library.

Fixed portability problems caused by gcc 10.

Synchronized changes from Android's AOSP e2fsprogs tree.

Update the Malay translation from the translation project.

Obtained from:	tytso@mit.edu (files/patch-0-tytso*)
MFH:		2020Q1
2020-03-23 09:42:54 +00:00
Mathieu Arnold b2dcd7927c Ports MUST NOT set WITH_DEBUG.
WITH_DEBUG is a user facing variable.  When a user wants to build a port
with debugging symbols enabled, they either set WITH_DEBUG globally, or
WITH_DEBUG_PORTS+=category/port.

Approved by:	bapt
With hat:	portmgr
Differential Revision:	https://reviews.freebsd.org/D23940
2020-03-03 12:56:15 +00:00
Matthias Andree 173f5b4ed3 sysutils/e2fsprogs: Fix powerpc32 build
PR:		242798
Reported by:	canardo909@gmx.com
Obtained from:	Theodore Y. Ts'o <tytso@mit.edu> (upstream maintainer)
MFH:		2020Q1 (fixes build on powerpc)
2020-02-17 21:54:23 +00:00
Matthias Andree 0346c473f7 Be more careful about what and how we link.
Only link what we need (--as-needed) to get unnecessary dependencies
out of the executables.

Be sure to properly link libc dynamically and the rest statically,
especially libgcc (-static-libgcc, should fix powerpc* builds => [1])

After two years, drop the "for now" LLD_UNSAFE=yes (r457508 by emaste@).

As e2fsprogs dlopen()s libmagic these days, our LIBMAGIC override is
useless.  Instead patch libmagic.so.1 -> libmagic.so (12.1 calls it
libmagic.so.4; patch to lib/support/plausible.c).

Refresh files/patch-misc__Makefile.in

PR:		242798 [1]
2020-02-03 00:34:15 +00:00
Matthias Andree 3267c080d7 Try to fix powerpc build, add LIBUNWIND option.
We've had a USES+=compiler:c11 on powerpc64,
see <https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=231570>
extend and use it on all powerpc* in an attempt to fix PR 242798.

If that doesn't help, add a LIBUNWIND option that makes e2fsck's
signal catcher use libunwind instead of libexecinfo - FreeBSD's
stack unwinder doesn't currently work from signal handlers (#243746),
libunwind does and is supposed to work on powerpc and powerpc64,
among others.

PR:		242798
Reported by:	canardo909@gmx.com
2020-01-31 02:13:24 +00:00
Matthias Andree a366c5a1bf sysutils/e2fsprogs: Try and enable backtrace() where possible.
The configure script doesn't find backtrace() because it does not
attempt linking against -lexecinfo -lelf.

Note that currently backtrace() is broken at least on 12.1 amd64, and
does not return any frames.  Filed separately as
<https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=243746>

PR:		242798 (which prompts this change, but is not fixed)
2020-01-30 23:07:43 +00:00
Matthias Andree 44413ed672 e2fsprogs security update to 1.45.5
Release Notes:
http://e2fsprogs.sourceforge.net/e2fsprogs-release.html#1.45.5

MFH:		2020Q1 (patchlevel upgrade with security fixes)
Security:       8b61308b-322a-11ea-b34b-1de6fb24355d
Security:       CVE-2019-5188
2020-01-11 18:34:14 +00:00
Matthias Andree 24cad6ecc4 sysutils/e2fsprogs: update to 1.45.4 (security fix)
Release Notes:	http://e2fsprogs.sourceforge.net/e2fsprogs-release.html#1.45.4

This removes some patches or hunks that were integrated upstream.

MFH:		2019Q4
Security:	ad3451b9-23e0-11ea-8b36-f1925a339a82
Security:	CVE-2019-5094
2019-12-21 11:22:17 +00:00
Tobias Kortkamp c8b9433fc5 Fix some misspelled or duplicated LICENSE_* 2019-09-17 19:21:45 +00:00
Mathieu Arnold bc89cd3d2c Convert to UCL & cleanup pkg-message (categories s) 2019-08-14 12:16:12 +00:00
Matthias Andree 9536ccbad1 Fix f_pre_1970_date_encoding on all 32-bit architectures but i386.
e2fsck would misparse the E2FSCK_TIME environment variable on architectures
where sizeof(long) < sizeof(time_t), i. e. all 32-bit architectures but i386.
This led to f_pre_1970_date_encoding test failures.

Note that I haven't tested the change for lack of respective hardware
or qemu rigs, and prior to receiving the reporter feedback, but
it would appear the fix is safe and plausible in itself.

Bump PORTREVISION as this changes the code on all architectures,
and to trigger version-based rebuild attempts where needed.

See also:	https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=932906
Reported by:	Thorsten Glaser <tg@mirbsd.de> against Debian
Reported by:	Stanislav S. Grinkin (privately) against FreeBSD
Reported by:	prior fall-out and BROKEN_<ARCH> tags
Obtained from:	https://git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git/commit/?id=a368e0cbfb33d3050dcccccf0bf5a5539d3dac39
MFH:		2019Q3
2019-07-30 11:59:29 +00:00
Gerald Pfeifer ea8c8ec7da Bump PORTREVISION for ports depending on the canonical version of GCC
as defined in Mk/bsd.default-versions.mk which has moved from GCC 8.3
to GCC 9.1 under most circumstances now after revision 507371.

This includes ports
 - with USE_GCC=yes or USE_GCC=any,
 - with USES=fortran,
 - using Mk/bsd.octave.mk which in turn features USES=fortran, and
 - with USES=compiler specifying openmp, nestedfct, c11, c++0x, c++11-lang,
   c++11-lib, c++14-lang, c++17-lang, or gcc-c++11-lib
plus, everything INDEX-11 shows with a dependency on lang/gcc9 now.

PR:		238330
2019-07-26 20:46:53 +00:00
Matthias Andree 7134875225 Update e2fsprogs to new upstream release 1.45.3.
Moves fuse2fs from $(PREFIX)/sbin to $(PREFIX)/bin (it does not
require privileges).

Bugfix for e2fsck file systems that enabled large_dir and inline
directories at the same time.

Translation bug fixes.

Release Notes: <http://e2fsprogs.sourceforge.net/e2fsprogs-release.html#1.45.3>

MFH:		2019Q3
2019-07-20 09:10:42 +00:00
Matthias Andree c9cffaa492 Update e2fsprogs to new upstream release 1.45.2
Various bugfixes, and added Portuguese locale.
Update the Czech, Malay, Polish, Spanish, Swedish, and Ukarainian translations.

Release notes:
<http://e2fsprogs.sourceforge.net/e2fsprogs-release.html#1.45.2>

MFH:		2019Q2
2019-06-01 13:27:32 +00:00
Matthias Andree 6419937ab2 Update e2fsprogs suite to v1.45.0.
Sorry that this happens so short before the 2019Q2 branch; the
e2fsprogs.sourceforge.net website hadn't been updated for 1.44.6 and 1.45.0.

I am not packaging e2scrub[_all] as FreeBSD does not support LVM,
Linux's logical volume manager.

Changelogs:
<https://raw.githubusercontent.com/tytso/e2fsprogs/master/doc/RelNotes/v1.44.6.txt>
<https://raw.githubusercontent.com/tytso/e2fsprogs/master/doc/RelNotes/v1.45.0.txt>

While here, reset misc/e2fsprogs-libuuid PORTREVISION back to 0 now that
the included PORTVERSION got bumped.
2019-03-29 21:49:03 +00:00
Matthias Andree b46eb418a9 Update sysutils/e2fsprogs to new upstream release 1.44.5
Release notes:
<http://e2fsprogs.sourceforge.net/e2fsprogs-release.html#1.44.5>

MFH:		2018Q4
2018-12-22 09:53:38 +00:00
Gerald Pfeifer a9f015d155 Bump PORTREVISION for ports depending on the canonical version of GCC
defined via Mk/bsd.default-versions.mk which has moved from GCC 7.4 t
GCC 8.2 under most circumstances.

This includes ports
 - with USE_GCC=yes or USE_GCC=any,
 - with USES=fortran,
 - using Mk/bsd.octave.mk which in turn features USES=fortran, and
 - with USES=compiler specifying openmp, nestedfct, c11, c++0x, c++11-lang,
   c++11-lib, c++14-lang, c++17-lang, or gcc-c++11-lib
plus, as a double check, everything INDEX-11 showed depending on lang/gcc7.

PR:		231590
2018-12-12 01:35:33 +00:00
Matthias Andree b017a6d66f Align *_DEPENDS and use paths for bash in my ports; fix var name.
On systems where bash is in $PATH but not in ${LOCALBASE}/bin/bash,
ilmbase would fail to build, and e2fsprogs might fail if the
BASHTESTS option was enabled.
Make sure that the _DEPENDS and the actual path handed to the configure or
test rig match to the letter, to avoid a time-of-check vs. time-of-use
discrepancy.

In e2fsprogs, the helper variable was also mistyped and would never
amend to BUILD_DEPENDS. Fix typo.

Check my other ports, but wiggle and xmlto [textproc/] seem unaffected.

Reported by:	J R Matthews (direct email)
MFH:		2018Q4
2018-12-04 22:36:34 +00:00
Matthias Andree d8967d87f6 Attempt to fix build on powerpc64.
Since the reporter has refused to test my proposed patch twice,
I am committing this anyways.

PR:		231570
Reported by:	Piotr Kubaj <pkubaj@anongoth.pl>
2018-09-22 14:40:13 +00:00
Matthias Andree d4f87f8b23 Update sysutils/e2fsprogs to new upstream release 1.44.4.
This is a bug fixing release.

Full release notes:
<http://e2fsprogs.sourceforge.net/e2fsprogs-release.html#1.44.4>

MFH:		2018Q3
2018-08-27 23:45:26 +00:00
Matthias Andree 9867fe2790 Update to new upstream release 1.44.3.
* several features for debugfs added
* there is a new e2mmpstatus command
* there are several bug fixes, among them endianness fixes and robustness
  fixes against corrupted input.
* add hashmap.h header file, for libext2fs users
* a few type fixes for format strings,
  found while building for MIPS, ARM, or i386
* add new option SLOWTESTS which prevents skipping of slow tests
* add new option BASHTESTS which enables tests that require bash
  (currently affects only the test f_large_dir that is also marked
   as slow)

Full release notes:
<http://e2fsprogs.sourceforge.net/e2fsprogs-release.html#1.44.3>

Reset PORTREVISION in slave ports, e2fsprogs{-libss,-libuuid} now
that we have bumped PORTVERSION.

MFH:		2018Q3
2018-07-10 13:48:31 +00:00
Matthias Andree c12dbd3151 sysutils/e2fsprogs: unmark broken on MIPS and ARM:
f_pre_1970_date_encoding self-test passes on MIPS64 w/ releng/11.2.
2018-07-07 21:58:29 +00:00
Matthias Andree 51e56bef9c sysutils/e2fsprogs: fixup regression of MASTERDIR check. 2018-07-07 20:00:31 +00:00
Matthias Andree 0491fdc713 Apply no-sbrk() patch only to master port. 2018-07-07 19:20:59 +00:00
Matthias Andree 3f7114d870 Unbreak aarch64 compilation by removing sbrk() references. 2018-07-07 13:05:32 +00:00
Mark Linimon 85657604aa Also mark broken on other tier-2 archs.
Approved by:	portmgr (tier-2 blanket)
2018-06-08 03:59:36 +00:00
Matthias Andree a268a9a651 Update to new upstream release 1.44.2.
Most important changes over 1.44.1_1:

e2fsck: adjust quota counters when clearing orphaned inodes
e2fsprogs: fix Free Software Foundation address
mke2fs: print error string if ext2fs_close_free() fails
po: update pl.po (from translationproject.org)
Use @AR@ instead of hardcoded 'ar'

Changelog over 1.44.1:
<http://e2fsprogs.sourceforge.net/e2fsprogs-release.html#1.44.2>

MFH:		2018Q2
2018-05-18 19:36:48 +00:00
Matthias Andree 0aeb79805c Cherry-pick upstream bug fixes from Git.
This is pending an 1.44.2 release, and contains these fixes from maint:
filefrag: avoid temporary buffer overflow
libext2fs: add sanity checks for ea_in_inode
e2image: fix metadata image handling on big endian systems
e2fsck: warn if checkinterval and broken_system_clock both set
tests: don't leave temp files behind after running i_bitmaps
tests: add new test f_ea_inode_self_ref
chattr.1: 'a' and 'i' attribute do not affect existing file

MFH:		2018Q2
2018-05-11 11:56:29 +00:00
Dag-Erling Smørgrav 41fa00b12b Don't set USE_LDCONFIG for child ports. They will do so themselves if
they need it.  Also, use PREFIX instead of LOCALBASE.

Not bumping PORTREVISION as the only observable effect is the absence of
a warning message caused by running ldconfig on a non-existent directory.

Approved by:	maintainer (mandree@)
2018-05-11 10:51:36 +00:00
Matthias Andree f6c54f567f Regression/bug fix update to e2fsprogs 1.44.1.
ChangeLog:
<http://e2fsprogs.sourceforge.net/e2fsprogs-release.html#1.44.1>

MFH:		2018Q2
2018-04-28 14:30:24 +00:00
Matthias Andree de9abc3317 Security/bug fix update to e2fsprogs 1.44.0
Changelog:
<http://e2fsprogs.sourceforge.net/e2fsprogs-release.html#1.44.0>

Reported by:	Dutchman01
MFH:		2018Q1
Security:	2aa9967c-27e0-11e8-9ae1-080027ac955c
2018-03-14 23:40:02 +00:00
Matthias Andree f9e7b577cc Bugfix update e2fsprogs to new upstream release 1.43.9.
Changelog: <http://e2fsprogs.sourceforge.net/e2fsprogs-release.html#1.43.9>

Reset e2fsprogs-libuuid's PORTREVISION.
2018-02-20 22:14:17 +00:00
Mark Linimon e4bf9eda16 Mark broken on both armv6 and armv7.
Approved by:	portmgr (tier-2 blanket)
2018-02-19 05:18:06 +00:00
Matthias Andree ae9c8bdf77 Bugfix update to new upstream release 1.43.8.
This fixes a few important bugs where updates are missed, displayed data is
incorrect, a use-after-free-bug and fixes important bugs WRT super block
handling on big-endian systems (missed byte-swaps).

Changelog: <http://e2fsprogs.sourceforge.net/e2fsprogs-release.html#1.43.8>

MFH:		2018Q1
2018-01-03 12:35:12 +00:00
Ed Maste fda7443dba sysutils/e2fsprogs: set LLD_UNSAFE to avoid linking with lld
One test fails when this port is linked with lld:

d_loaddump: debugfs load/dump test: failed

--- d_loaddump/expect	2017-10-16 05:45:45.000000000 +0000
+++ d_loaddump.log	2017-12-28 13:00:42.099973000 +0000
@@ -10,7 +10,7 @@
 Pass 3: Checking directory connectivity
 Pass 4: Checking reference counts
 Pass 5: Checking group summary information
-test_filesys: 12/64 files (0.0% non-contiguous), 158/512 blocks
+test_filesys: 12/64 files (0.0% non-contiguous), 156/512 blocks
 Exit status is 0
 debugfs -R ''dump test_data d_loaddump.ver.tmp'' test.img
 Exit status is 0

This looks like a very unusual failure and careful investigation into
lld's behaviour is warranted, but for now set LLD_UNSAFE to fall back
to ld.bfd so the port continues to build for users using lld as
/usr/bin/ld.

PR:		214864
Approved by:	portmgr (LLD_UNSAFE blanket)
Sponsored by:	The FreeBSD Foundation
2017-12-29 15:20:54 +00:00
Matthias Andree ef45605556 e2fsprogs, prepend new .so dir to RPATH/RUNPATH...
...so that the tools other than e2fsck find their libraries.

Reported by: ehaupt@
2017-10-30 19:04:02 +00:00
Matthias Andree a25818bf29 Reconcile e2fsprogs ./. krb5-* conflicts.
* Move conflicting e2fsprogs headers & libs into .../e2fsprogs/... subdirs.
* Move conflicting awk scripts into ${DATADIR}.
* Rename and patch compile_et to e2fsprogs-compile_et.
* Remove conflict markers (from e2fsprogs and krb5-*).
* Add CPPFLAGS/LDFLAGS to sysutils/fusefs-ext2, including
  --rpath setting.

While here, also:
* sort pkg-plist and files/unwanted
* use FUSEFS_CONFIGURE_ENABLE=fuse2fs to prevent e2fsprogs from picking up
  fusefs (implies --disable-fuse2fs if the option remains disabled)
* add --without-included-gettext to CONFIGURE_ARGS just to be on the safe
  side.

And of course, bump PORTREVISION to 3 in e2fsprogs. Since other ports
do not change files or runtime behaviour, their PORTREVISION remains
untouched.
2017-10-30 16:55:26 +00:00
Matthias Andree 2435367970 Add CONFLICTS between krb5-* and e2fsprogs.
Reported by: jbeich@
2017-10-30 00:16:28 +00:00
Matthias Andree b5a8749dc8 Also add com_err headers, .pc file, and compile_et.
Reported by: ehaupt@
2017-10-29 23:59:46 +00:00
Matthias Andree 11a1e89fc7 Install header and .pc (pkg-config) files, too.
Reported by:	ehaupt@
2017-10-29 15:42:09 +00:00