Commit graph

36 commits

Author SHA1 Message Date
Xin LI 9047451891 Disable byteswap.h for now.
Ideally we should be testing __FreeBSD_version (1400079) and/or
BOOTSTRAPPING from an older version, but restore compatibility to
older FreeBSD versions and macOS while we find out a better way to
fix it.
2023-09-11 23:24:08 -07:00
Xin LI 898496ee09 MFV: file 5.45.
MFC after:	3 days
2023-09-10 12:21:16 -07:00
Xin LI a2dfb7224e file: upgrade to 5.43.
MFC after:	3 days
2022-09-24 19:16:39 -07:00
Xin LI a4d6d3b891 file: upgrade to 5.42.
MFC after:	2 weeks
2022-07-03 17:11:09 -07:00
Jose Luis Duran f5ccb3a33e file: Fix cross-compilation on Darwin/macOS
Darwin/macOS does not have pipe2(2).

Apply a similar guard as in f3d7ace4b2
after 43a5ec4eb4.

Pull Request: https://github.com/freebsd/freebsd-src/pull/574
2022-01-07 07:52:34 -07:00
Warner Losh f3d7ace4b2 file: Turns out we need xlocal.h protection
It turns out that we still need xlocal.h protection for when we're
cross building on Linux. Linux doesn't have this file, but os/x
does. Before, we'd assume we didn't have it, like old FreeBSD, when
cross compiling. After the latest update, all that code was removed so
cross compiling needs to be handled separaetly. Do so by defining
HAVE_XLOCALE_H only when we're not building on linux. This allows us
to build the mkmagic build tool needed to build file(1).

Sponsored by:		Netflix
Reviewed by:		jrtc27
Differential Revision:	https://reviews.freebsd.org/D33741
2022-01-04 14:12:59 -07:00
Xin LI 43a5ec4eb4 file: upgrade to 5.41.
MFC after:	2 weeks
2022-01-03 22:03:39 -08:00
Xin LI 9026652101 libmagic: Remove support for older FreeBSD where xlocale was not available.
The MINIMUM_SUPPORTED_OSREL is 1002501 (FreeBSD 10.3), and xlocale is
supported there.

While I'm there, explicitly use config.h generated with --disable-bzlib
--disable-xzlib instead of deleting them manually.

MFC after:	2 weeks
2022-01-02 18:05:08 -08:00
Xin LI 2726a70148 MFV r362254: file 5.39.
MFC after:	2 weeks
2020-06-17 07:41:28 +00:00
Xin LI d38c30c092 MFV r357712: file 5.38.
MFC after:	2 weeks
2020-02-11 07:02:48 +00:00
Xin LI 48c779cdec MFV r354582: file 5.37.
MFC after:	3 days
2019-11-10 17:00:23 +00:00
Gordon Tetlow 40427cca7a MFV r323678: file 5.32
Approved by:	emaste (mentor)
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D12400
2017-09-17 19:14:38 +00:00
Xin LI a5d223e641 MFV r308392: file 5.29.
MFC after:	2 weeks
2016-11-07 15:54:47 +00:00
Xin LI 282e23f07b MFV r302218: file 5.28.
Relnotes:	yes
MFC after:	2 weeks
Approved by:	re (gjb)
2016-06-27 01:29:17 +00:00
Xin LI 20f8619da0 MFV r299716: file 5.27
MFC after:	2 weeks
Relnotes:	yes
2016-05-14 08:52:37 +00:00
Xin LI 3e41d09d08 MFV r298178:
Update file to 5.26.

MFC after:	2 weeks
Relnotes:	yes
2016-04-18 07:36:24 +00:00
Xin LI 9ce06829f2 MFV r288140: update file to 5.25.
MFC after:	1 month
2015-09-23 05:39:20 +00:00
Xin LI 9fc5c47fa5 MFV r287451 + 287452: file 5.24 + fix for bin/181436.
PR:		181436
MFC after:	2 weeks
2015-09-04 05:56:14 +00:00
Xin LI 5f0216bd88 MFV r284234:
Update file to 5.23.

MFC after:	2 weeks
2015-06-10 19:22:41 +00:00
Dimitry Andric 39a9ae0f39 Since the merge of file 5.21 in r276415 and r276416, stable/9 and
stable/10 cannot be built from FreeBSD 8.x.  This is because the
build-tools stage requires libmagic, but lib/libmagic/config.h was
generated on head, and it now enables using the xlocale.h APIs, which
are not supported on 8.x (and on 9.x before __FreeBSD_version 900506).

See also the start of this thread on -stable:
https://lists.freebsd.org/pipermail/freebsd-stable/2015-January/081521.html

To fix this, conditionalize the use of xlocale.h APIs to make
bootstrapping from older FreeBSD versions work correctly.

Reviewed by:	delphij
MFC after:	3 days
Differential Revision: https://reviews.freebsd.org/D1518
2015-01-13 20:37:57 +00:00
Xin LI 4460e5b02d MFV r276568:
Update file to 5.22.

MFC after:	2 weeks
2015-01-02 21:20:02 +00:00
Xin LI c293113327 MFV r275696: file 5.21.
MFC after:	 2 weeks
2014-12-11 06:52:10 +00:00
Xin LI b6cee71de3 MFV r267843: update file/libmagic to 5.19.
MFC after:	2 weeks
2014-06-26 06:03:39 +00:00
David E. O'Brien c2774610af r235638 is not the clean way to add support for building on ancient FreeBSD
versions.  Instead use Imp's good work on "legacy" and follow the outcome
of the previous TRB discussions on this topic.

Now use the libc getline() if it exists, and only where it doesn't
create a bootstraping version.
2012-09-11 22:38:33 +00:00
Marcel Moolenaar aaa975e19d Don't depend on getline being on the build machine. That's
not the case for FreeBSD 7.x machines.
2012-05-19 02:30:10 +00:00
David E. O'Brien 80c86c3659 Update file(1) to version 5.11. 2012-04-19 03:20:13 +00:00
Marius Strobl ae4ecfff1e Update to a config.h created by a file 5.03 configure script. This causes
file.1 to contain the correct version number and SIZEOF_LONG_LONG to be
defined as appropriate, which is crucial for 64-bit big-endian ELF files
to be handled correctly on big-endian systems.

PR:		146387
Reviewed by:	delphij
MFC after:	3 days
2010-05-20 08:56:50 +00:00
David E. O'Brien 7dbb948b5f Merge vendor/file/dist@191739, bringing FILE 5.00 to 8-CURRENT. 2009-05-04 00:37:44 +00:00
Konstantin Belousov 20e76cb365 Add strndup(3) prototype to string.h.
This change was erronously ommitted from the r185690, and attempt
to simply add the prototype to string.h has revealed that several
contributed programs defined local prototypes for strndup(), controlled
by autoconfed config.h. So, manually change #undef HAVE_STRNDUP to
#define HAVE_STRNDUP 1. Next import of the corresponding program would
regenerate config.h, overriding the changes in this commit.

No objections from: kan
2008-12-08 21:04:24 +00:00
David E. O'Brien ef19c627f8 Update for the 'file' 4.23 import. 2008-01-13 20:37:19 +00:00
David E. O'Brien 79f6e0e6b4 FreeBSD has <limits.h>. 2007-05-24 22:10:22 +00:00
David E. O'Brien 8cbe72bdb7 Update for the 'file' 4.21 import. 2007-05-24 22:02:49 +00:00
David E. O'Brien a90b38c0b1 Update for the 'file' 4.19 import. 2007-05-24 16:14:38 +00:00
David E. O'Brien b3f1b4a2c7 Update for the 'file' 4.17 import. 2006-06-19 08:10:23 +00:00
David E. O'Brien efd3a489a7 Catch up with file 4.12 import. 2004-12-28 04:35:01 +00:00
David E. O'Brien 20164649ea Bmake the library containing and processing the magic. 2004-08-09 08:48:28 +00:00