summaryrefslogtreecommitdiff
path: root/lib/libmagic
AgeCommit message (Collapse)Author
2025-10-26packages: Install development manpages in the -dev packageLexi Winter
Add a new per-group SUBPACKAGE option to bsd.man.mk. When MANSPLITPKG is enabled, this is forced to "-man", otherwise it defaults to empty but can be overridden by the caller. Use this in bsd.lib.mk to install library manpages in the -dev package instead of the base package. This is nearly always preferable, since library manpages are usually in section 2 or 3 and are only relevant to people with development packages installed. For manpages which should be installed in the base package even for libraries, add a new MANNODEV group in bsd.lib.mk. Update existing Makefiles to use this where appropriate. MFC after: 3 days Discussed with: olce Reviewed by: olce Sponsored by: https://www.patreon.com/bsdivy Differential Revision: https://reviews.freebsd.org/D52832
2025-01-07libmagic: Unbreak for older FreeBSD releases.Xin LI
byteswap.h is introduced in FreeBSD 13.2 but was not available in earlier versions. In order to support upgrading from an earlier FreeBSD release we would need to tell the build system that fact. PR: bin/273736 Reported by: philip MFC after: 3 days
2024-12-08MFV: file 5.46.Xin LI
MFC after: 2 weeks
2024-10-14Update Makefile.depend filesSimon J. Gerraty
After building packages we have a number of new and updated Makefile.depend files Reviewed by: stevek
2024-03-27libmagic: Use HOST_CC when compiling hostprog used by buildStephen J. Kiernan
The "mkmagic" program should be built with the host compiler. Only use BTOOLSPATH if not building for host Obtained from: Juniper Networks, Inc. Reviewed by: sjg Differential Revision: https://reviews.freebsd.org/D44539
2023-09-11Disable byteswap.h for now.Xin LI
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-10MFV: file 5.45.Xin LI
MFC after: 3 days
2023-08-16Remove $FreeBSD$: one-line sh patternWarner Losh
Remove /^\s*#[#!]?\s*\$FreeBSD\$.*$\n/
2022-09-24file: upgrade to 5.43.Xin LI
MFC after: 3 days
2022-08-11Install working pkgconfig .pc files for compat librariesAlex Richardson
The default ones are install them to /usr/libdata/pkgconfig, and we can't use this path for compat libraries, so we use /usr/lib<suffix>/pkgconfigi here. Test Plan: grep -rn libdir= ./usr/lib32/pkgconfig/*.pc MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D34939
2022-07-03file: upgrade to 5.42.Xin LI
MFC after: 2 weeks
2022-01-07file: Fix cross-compilation on Darwin/macOSJose Luis Duran
Darwin/macOS does not have pipe2(2). Apply a similar guard as in f3d7ace4b235422e5ccff0315f2965ac935241d8 after 43a5ec4eb41567cc92586503212743d89686d78f. Pull Request: https://github.com/freebsd/freebsd-src/pull/574
2022-01-04file: Turns out we need xlocal.h protectionWarner Losh
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-03file: upgrade to 5.41.Xin LI
MFC after: 2 weeks
2022-01-02libmagic: Remove support for older FreeBSD where xlocale was not available.Xin LI
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
2021-03-16Convert libs with pc files to use PCFILESEmmanuel Vadot
Now the .pc ends up in the correct package (-dev) Reviewed by: bapt, emaste Differential Revision: https://reviews.freebsd.org/D29172 MFC after: 2 weeks
2020-06-17Fix installation of magic file.Xin LI
Reported by: lwhsu MFC after: 2 weeks X-MFC-with: r362258 Notes: svn path=/head/; revision=362279
2020-06-17MFV r362254: file 5.39.Xin LI
MFC after: 2 weeks Notes: svn path=/head/; revision=362258
2020-02-11MFV r357712: file 5.38.Xin LI
MFC after: 2 weeks Notes: svn path=/head/; revision=357757
2019-12-19Tweaks for DIRDEPS_BUILDSimon J. Gerraty
libmagic only depend on mkmagic if not DIRDEPS_BUILD libpmc fix -I for libpmcstat local.dirdeps.mk be even more careful about adding gnu/lib/csu to DIRDEPS Reviewed by: bdrewery Differential Revision: https://reviews.freebsd.org/D22872 Notes: svn path=/head/; revision=355904
2019-12-11Update dirdeps.mk and gendirdeps.mkSimon J. Gerraty
The env space consumed by exporting all libc's .meta files left little room for command line, so unexport when done. Update dirdeps.mk to latest and add dirdeps-targets.mk to simplify/update targets/Makefile Makefile changes to go with Makefile.depend changes in D22494 Reviewed by: bdrewery MFC after: 1 week Sponsored by: Juniper Networks Differential Revision: https://reviews.freebsd.org/D22495 Notes: svn path=/head/; revision=355618
2019-12-11Update Makefile.depend filesSimon J. Gerraty
Update a bunch of Makefile.depend files as a result of adding Makefile.depend.options files Reviewed by: bdrewery MFC after: 1 week Sponsored by: Juniper Networks Differential Revision: https://reviews.freebsd.org/D22494 Notes: svn path=/head/; revision=355617
2019-11-10MFV r354582: file 5.37.Xin LI
MFC after: 3 days Notes: svn path=/head/; revision=354595
2019-06-15Fix .depend files to work for build tools.Bryan Drewery
This is somewhat of a follow-up to r335746. MFC after: 2 weeks Sponsored by: DellEMC Notes: svn path=/head/; revision=349062
2018-06-27Don't use CCACHE for linking.Bryan Drewery
MFC after: 2 weeks Sponsored by: Dell EMC Notes: svn path=/head/; revision=335733
2018-05-20Style fixup:Cy Schubert
A non-functional commit to make adjustment to an aesthetically unpleasing long line. Notes: svn path=/head/; revision=333923
2018-05-20Fix build post r333919.Cy Schubert
This commit results in an aesthetically unpleasing long line which will be fixed next commit. Notes: svn path=/head/; revision=333922
2018-03-09LIB32: Avoid linking in unneeded (and invalid lib32) libz for libmagic build ↵Bryan Drewery
tool. Usually this is just ignored: /usr/bin/ld: skipping incompatible /scratch/obj/root/git/freebsd/amd64.amd64/obj-lib32/lib/libz/libz.so when searching for -lz /usr/bin/ld: skipping incompatible /scratch/obj/root/git/freebsd/amd64.amd64/obj-lib32/lib/libz/libz.a when searching for -lz However some combination of newer toolchains simply fail here instead: /usr/bin/ld: error: /home/dstolfa/obj/home/dstolfa/cadets/amd64.amd64/obj-lib32/lib/libz/libz.so is incompatible with /usr/lib/crt1.o Libz is not needed for mkmagic so just exclude it. Reported by: Domagoj Stolfa <domagoj.stolfa@gmail.com> MFC after: 2 weeks Sponsored by: Dell EMC Notes: svn path=/head/; revision=330702
2017-10-31DIRDEPS_BUILD: Update dependencies.Bryan Drewery
Sponsored by: Dell EMC Isilon Notes: svn path=/head/; revision=325188
2017-09-17MFV r323678: file 5.32Gordon Tetlow
Approved by: emaste (mentor) MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D12400 Notes: svn path=/head/; revision=323683
2017-01-20Use SRCTOP-relative paths to other directories instead of .CURDIR-relative onesEnji Cooper
This simplifies pathing in make/displayed output MFC after: 3 weeks Sponsored by: Dell EMC Isilon Notes: svn path=/head/; revision=312497
2016-11-07MFV r308392: file 5.29.Xin LI
MFC after: 2 weeks Notes: svn path=/head/; revision=308420
2016-06-27Fix build: explicitly reference the generated magic.h as dependencyXin LI
of mkmagic and point its location. Reported by: jenkins Pointy hat to: delphij MFC after: 2 weeks X-MFC-With: 302221 Approved by: re (kib) Notes: svn path=/head/; revision=302222
2016-06-27MFV r302218: file 5.28.Xin LI
Relnotes: yes MFC after: 2 weeks Approved by: re (gjb) Notes: svn path=/head/; revision=302221
2016-05-14MFV r299716: file 5.27Xin LI
MFC after: 2 weeks Relnotes: yes Notes: svn path=/head/; revision=299736
2016-05-09DIRDEPS_BUILD: Run the staged bootstrap-tools version of build-tools.Bryan Drewery
This avoids running target binaries. Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=299289
2016-04-18MFV r298178:Xin LI
Update file to 5.26. MFC after: 2 weeks Relnotes: yes Notes: svn path=/head/; revision=298192
2016-04-16MFHGlen Barber
Sponsored by: The FreeBSD Foundation Notes: svn path=/projects/release-pkg/; revision=298092
2016-04-14META_MODE: Don't rebuild build-tools targets during normal build.Bryan Drewery
This avoids 'build command changed' due to CFLAGS/CC changes during the normal build. Without this the build-tools targets end up rebuilding for the *target* rather than keeping the native versions built in build-tools. Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=297997
2016-02-04First pass through library packaging.Glen Barber
Sponsored by: The FreeBSD Foundation Notes: svn path=/projects/release-pkg/; revision=295278
2015-11-25META MODE: Prefer INSTALL=tools/install.sh to lessen the need for xinstall.host.Bryan Drewery
This both avoids some dependencies on xinstall.host and allows bootstrapping on older releases to work due to lack of at least 'install -l' support. Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=291307
2015-09-23MFV r288140: update file to 5.25.Xin LI
MFC after: 1 month Notes: svn path=/head/; revision=288143
2015-09-04MFV r287451 + 287452: file 5.24 + fix for bin/181436.Xin LI
PR: 181436 MFC after: 2 weeks Notes: svn path=/head/; revision=287453
2015-06-16new dependsSimon J. Gerraty
Notes: svn path=/head/; revision=284481
2015-06-13Add META_MODE support.Simon J. Gerraty
Off by default, build behaves normally. WITH_META_MODE we get auto objdir creation, the ability to start build from anywhere in the tree. Still need to add real targets under targets/ to build packages. Differential Revision: D2796 Reviewed by: brooks imp Notes: svn path=/head/; revision=284345
2015-06-10MFV r284234:Xin LI
Update file to 5.23. MFC after: 2 weeks Notes: svn path=/head/; revision=284237
2015-06-08dirdeps.mk now sets DEP_RELDIRSimon J. Gerraty
Notes: svn path=/projects/bmake/; revision=284172
2015-05-27Merge sync of headSimon J. Gerraty
Notes: svn path=/projects/bmake/; revision=283595
2015-01-13Since the merge of file 5.21 in r276415 and r276416, stable/9 andDimitry Andric
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 Notes: svn path=/head/; revision=277147
2015-01-02MFV r276568:Xin LI
Update file to 5.22. MFC after: 2 weeks Notes: svn path=/head/; revision=276577