aboutsummaryrefslogtreecommitdiff
path: root/usr.bin/m4
Commit message (Collapse)AuthorAgeFilesLines
* usr.bin: Automated cleanup of cdefs and other formattingWarner Losh2023-11-271-1/+0
| | | | | | | | | | | | | | | | Apply the following automated changes to try to eliminate no-longer-needed sys/cdefs.h includes as well as now-empty blank lines in a row. Remove /^#if.*\n#endif.*\n#include\s+<sys/cdefs.h>.*\n/ Remove /\n+#include\s+<sys/cdefs.h>.*\n+#if.*\n#endif.*\n+/ Remove /\n+#if.*\n#endif.*\n+/ Remove /^#if.*\n#endif.*\n/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/types.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/param.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/capsicum.h>/ Sponsored by: Netflix
* usr.bin: Remove ancient SCCS tags.Warner Losh2023-11-2711-27/+0
| | | | | | | | Remove ancient SCCS tags from the tree, automated scripting, with two minor fixup to keep things compiling. All the common forms in the tree were removed with a perl script. Sponsored by: Netflix
* m4 tests: Update tests after $FreeBSD$ removalMark Johnston2023-08-232-2/+2
| | | | Fixes: d54a7d337331 ("Remove $FreeBSD$: one-line m4 tag")
* Remove $FreeBSD$: one-line bare tagWarner Losh2023-08-162-2/+0
| | | | Remove /^\s*\$FreeBSD\$$\n/
* Remove $FreeBSD$: two-line nroff patternWarner Losh2023-08-161-2/+0
| | | | Remove /^\.\\"\n\.\\"\s*\$FreeBSD\$$\n/
* Remove $FreeBSD$: one-line sh patternWarner Losh2023-08-1612-12/+0
| | | | Remove /^\s*#[#!]?\s*\$FreeBSD\$.*$\n/
* Remove $FreeBSD$: one-line .c patternWarner Losh2023-08-167-15/+0
| | | | Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
* Remove $FreeBSD$: one-line .h patternWarner Losh2023-08-164-4/+0
| | | | Remove /^\s*\*+\s*\$FreeBSD\$.*$\n/
* Remove $FreeBSD$: two-line .h patternWarner Losh2023-08-162-4/+0
| | | | Remove /^\s*\*\n \*\s+\$FreeBSD\$$\n/
* Remove $FreeBSD$: one-line m4 tagWarner Losh2023-08-1619-19/+0
| | | | Remove /^dnl\s*\$FreeBSD\$.*$\n/
* Fix spelling of "behavior" to be consistent with the rest of the fileBenedict Reuschling2023-06-231-1/+1
|
* m4: Miscellaneous man page fixes.Dag-Erling Smørgrav2023-06-211-5/+14
| | | | | | Sponsored by: Klara, Inc. Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D40701
* m4: Add -G option which reverses -g.Dag-Erling Smørgrav2023-06-212-4/+12
| | | | | | | | This matches GNU m4's -G / --traditional option, and although BSD m4 in non-GNU mode is not exactly identical to GNU mode in traditional mode, it's close enough. Sponsored by: Klara, Inc. Reviewed by: kevans, imp Differential Revision: https://reviews.freebsd.org/D40697
* m4: Support long options.Dag-Erling Smørgrav2023-06-212-17/+44
| | | | | | | | | | The option names are identical to those of the equivalent options in GNU m4, except of course for --gnu which does not exist in GNU m4. While here, make the argument to -d / --debug optional, with the same default behavior as in GNU m4, and document it properly. Sponsored by: Klara, Inc. Reviewed by: kevans, imp Differential Revision: https://reviews.freebsd.org/D40694
* Update/fix Makefile.depend for userlandSimon J. Gerraty2023-04-191-3/+0
|
* m4(1): Add a SEE ALSO section and reference an AT&T manualGordon Bergling2021-04-081-1/+12
| | | | | Obtained from: OpenBSD MFC after: 1 week
* Only set WARNS if not definedKyle Evans2020-09-111-1/+1
| | | | | | | | | | | | | This would allow interested parties to do experimental runs with an environment set appropriately to raise all the warnings throughout the build; e.g. env WARNS=6 NO_WERROR=yes buildworld. Not currently touching the numerous instances in ^/tools. MFC after: 1 week Notes: svn path=/head/; revision=365631
* Add necessary Makefile.inc1 infrastructure for building on non-FreeBSDAlex Richardson2020-08-251-3/+11
| | | | | | | | | | | | | | | | | | | | The most awkward bit in this patch is the bootstrapping of m4: We can't simply use the host version of m4 since that is not compatible with the flags passed by lex (at least on macOS, possibly also on Linux). Therefore we need to bootstrap m4, but lex needs m4 to build and m4 also depends on lex (which needs m4 to generate any files). To work around this cyclic dependency we can build a bootstrap version of m4 (with pre-generated files) then use that to build the real m4. This patch also changes the xz/unxz/dd tools to always use the host version since the version in the source tree cannot easily be bootstrapped on macOS or Linux. Reviewed By: brooks, imp (earlier version) Differential Revision: https://reviews.freebsd.org/D25992 Notes: svn path=/head/; revision=364760
* m4: import from OpenBSDBaptiste Daroussin2019-09-091-2/+2
| | | | | | | | | | | By deraadt@ mkstemp() returns -1 on failure Obtained from: OpenBSD Notes: svn path=/head/; revision=352070
* m4: import from OpenBSDBaptiste Daroussin2019-09-091-12/+31
| | | | | | | | | | | | | | | | | | patch by espie@ replace sloppy parsing of numeric values with strtonum (incr, decr, divert) still use integers, so use the natural bounds for these. POSIX says m4 should error when these use non numeric values, and now they do. okay millert@ Obtained from: OpenBSD Notes: svn path=/head/; revision=352069
* m4: import patch from OpenBSDBaptiste Daroussin2019-09-091-9/+8
| | | | | | | | | | | | | | | | | | by espie@ ifelse is special, fix argv parsing to avoid segfault problem noticed by Matthew Green (netbsd), slightly different fix so that argc counting makes more sense. we might want to warn on wrong number of parameters later, but this is somewhat inconsistent depending on the builtin right now. okay millert@ Obtained from: OpenBSD Notes: svn path=/head/; revision=352068
* m4: import patch from OpenBSDBaptiste Daroussin2019-09-091-4/+6
| | | | | | | | | | | Use waitpid()/EINTR idiom for the specific pid, rather than generic wait() Patch by: deraadt@ Obtained from: OpenBSD Notes: svn path=/head/; revision=352067
* Import from OpenBSD a patch which eliminates the link with -ly or -lyBaptiste Daroussin2019-09-092-1/+3
| | | | | | | | | patch by ibara@ Obtained from: OpenBSD Notes: svn path=/head/; revision=352066
* Import from OpenBSD: -E flagBaptiste Daroussin2019-09-097-21/+72
| | | | | | | | | | | | | Add -E flag (make warnings fatal), following the behavior of GNU m4 1.4.9+ Help and direction millert@ espie@ anton@ deraadt@ ok espie@ Obtained from: OpenBSD Notes: svn path=/head/; revision=352065
* m4: add annotations to various functionsEitan Adler2018-01-241-5/+5
| | | | | | | | | | Explain to the compiler that several functions are either noreturn or take printf like arguments Discussed with: swildner@DragonFlyBSD.org Notes: svn path=/head/; revision=328319
* various: general adoption of SPDX licensing ID tags.Pedro F. Giffuni2017-11-272-1/+5
| | | | | | | | | | | | | | | | | Mainly focus on files that use BSD 2-Clause license, however the tool I was using misidentified many licenses so this was mostly a manual - error prone - task. The Software Package Data Exchange (SPDX) group provides a specification to make it easier for automated tools to detect and summarize well known opensource licenses. We are gradually adopting the specification, noting that the tags are considered only advisory and do not, in any way, superceed or replace the license texts. No functional change intended. Notes: svn path=/head/; revision=326276
* General further adoption of SPDX licensing ID tags.Pedro F. Giffuni2017-11-208-5/+21
| | | | | | | | | | | | | | | | | Mainly focus on files that use BSD 3-Clause license. The Software Package Data Exchange (SPDX) group provides a specification to make it easier for automated tools to detect and summarize well known opensource licenses. We are gradually adopting the specification, noting that the tags are considered only advisory and do not, in any way, superceed or replace the license texts. Special thanks to Wind River for providing access to "The Duke of Highlander" tool: an older (2014) run over FreeBSD tree was useful as a starting point. Notes: svn path=/head/; revision=326025
* DIRDEPS_BUILD: Update dependencies.Bryan Drewery2017-10-311-1/+0
| | | | | | | Sponsored by: Dell EMC Isilon Notes: svn path=/head/; revision=325188
* Add HAS_TESTS to all Makefiles that are currently using theEnji Cooper2017-08-021-0/+1
| | | | | | | | | `SUBDIR.${MK_TESTS}+= tests` idiom. This is a follow up to r321912. Notes: svn path=/projects/make-check-sandbox/; revision=321914
* Convert traditional ${MK_TESTS} conditional idiom for including testEnji Cooper2017-08-021-3/+1
| | | | | | | | | | | | | | directories to SUBDIR.${MK_TESTS} idiom This is being done to pave the way for future work (and homogenity) in ^/projects/make-check-sandbox . No functional change intended. MFC after: 1 weeks Notes: svn path=/head/; revision=321912
* Adopt SRCTOP in usr.binWarner Losh2017-03-121-1/+1
| | | | | | | | | | | | Prefer ${SRCTOP}/foo over ${.CURDIR}/../../foo and ${SRCTOP}/usr.bin/foo over ${.CURDIR}/../foo for paths in Makefiles. Differential Revision: https://reviews.freebsd.org/D9932 Sponsored by: Netflix Silence on: arch@ (twice) Notes: svn path=/head/; revision=315170
* Merge ^/user/ngie/release-pkg-fix-tests to unbreak how test files are installedEnji Cooper2016-05-041-46/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | after r298107 Summary of changes: - Replace all instances of FILES/TESTS with ${PACKAGE}FILES. This ensures that namespacing is kept with FILES appropriately, and that this shouldn't need to be repeated if the namespace changes -- only the definition of PACKAGE needs to be changed - Allow PACKAGE to be overridden by callers instead of forcing it to always be `tests`. In the event we get to the point where things can be split up enough in the base system, it would make more sense to group the tests with the blocks they're a part of, e.g. byacc with byacc-tests, etc - Remove PACKAGE definitions where possible, i.e. where FILES wasn't used previously. - Remove unnecessary TESTSPACKAGE definitions; this has been elided into bsd.tests.mk - Remove unnecessary BINDIRs used previously with ${PACKAGE}FILES; ${PACKAGE}FILESDIR is now automatically defined in bsd.test.mk. - Fix installation of files under data/ subdirectories in lib/libc/tests/hash and lib/libc/tests/net/getaddrinfo - Remove unnecessary .include <bsd.own.mk>s (some opportunistic cleanup) Document the proposed changes in share/examples/tests/tests/... via examples so it's clear that ${PACKAGES}FILES is the suggested way forward in terms of replacing FILES. share/mk/bsd.README didn't seem like the appropriate method of communicating that info. MFC after: never probably X-MFC with: r298107 PR: 209114 Relnotes: yes Tested with: buildworld, installworld, checkworld; buildworld, packageworld Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=299094
* usr.bin: minor spelling fixes on comments.Pedro F. Giffuni2016-05-011-1/+1
| | | | | | | No functional change. Notes: svn path=/head/; revision=298879
* Use NULL instead of 0 for pointers.Marcelo Araujo2016-04-181-1/+1
| | | | | | | | | fopen(3) will return NULL in case it cannot open the STREAM. MFC after: 2 weeks. Notes: svn path=/head/; revision=298190
* MFHGlen Barber2016-03-101-0/+11
|\ | | | | | | | | | | | | Sponsored by: The FreeBSD Foundation Notes: svn path=/projects/release-pkg/; revision=296625
| * DIRDEPS_BUILD: Connect MK_TESTS.Bryan Drewery2016-03-091-0/+11
| | | | | | | | | | | | | | Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=296587
* | MFHGlen Barber2016-03-021-6/+0
|\| | | | | | | | | | | | | Sponsored by: The FreeBSD Foundation Notes: svn path=/projects/release-pkg/; revision=296318
| * DIRDEPS_BUILD: Regenerate without local dependencies.Bryan Drewery2016-02-241-6/+0
| | | | | | | | | | | | | | | | | | | | | | These are no longer needed after the recent 'beforebuild: depend' changes and hooking DIRDEPS_BUILD into a subset of FAST_DEPEND which supports skipping 'make depend'. Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=295989
* | First pass to fix the 'tests' packages.Glen Barber2016-02-021-0/+4
|/ | | | | | | Sponsored by: The FreeBSD Foundation Notes: svn path=/projects/release-pkg/; revision=295171
* Import misc.c,v 1.46 from OpenBSD (by espie@)Baptiste Daroussin2016-01-181-1/+3
| | | | | | | Yet another missed ferror call Notes: svn path=/head/; revision=294298
* Revert a modification that crept in and should notBaptiste Daroussin2015-11-211-1/+1
| | | | Notes: svn path=/head/; revision=291129
* Synchronize m4(1) with OpenBSDBaptiste Daroussin2015-11-216-45/+15
| | | | Notes: svn path=/head/; revision=291128
* Rename libohash to libopenbsd.Craig Rodrigues2015-11-042-3/+3
| | | | | | | | | | | | | | | libopenbsd is an internal library which to bring in compatibility stuff from OpenBSD. This will allow us to bring in more OpenBSD utilities into the FreeBSD base system. We similarly use libnetbsd for bringing in stuff from NetBSD. Reviewed by: bapt Differential Revision: https://reviews.freebsd.org/D4078 Notes: svn path=/head/; revision=290351
* Refactor the test/ Makefiles after recent changes to bsd.test.mk (r289158) andEnji Cooper2015-10-121-2/+0
| | | | | | | | | | | | | | | netbsd-tests.test.mk (r289151) - Eliminate explicit OBJTOP/SRCTOP setting - Convert all ad hoc NetBSD test integration over to netbsd-tests.test.mk - Remove unnecessary TESTSDIR setting - Use SRCTOP where possible for clarity MFC after: 2 weeks Sponsored by: EMC / Isilon Storage Divison Notes: svn path=/head/; revision=289172
* Add META_MODE support.Simon J. Gerraty2015-06-131-0/+29
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | 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
| * dirdeps.mk now sets DEP_RELDIRSimon J. Gerraty2015-06-081-2/+0
| | | | | | | | Notes: svn path=/projects/bmake/; revision=284172
| * Merge sync of headSimon J. Gerraty2015-05-2710-51/+109
| |\ | |/ |/| | | Notes: svn path=/projects/bmake/; revision=283595
| * Updated/new dependenciesSimon J. Gerraty2014-11-191-0/+1
| | | | | | | | Notes: svn path=/projects/bmake/; revision=274694
| * Merge from head@274682Simon J. Gerraty2014-11-197-782/+8
| |\ | | | | | | | | | Notes: svn path=/projects/bmake/; revision=274683
| * \ Merge head from 7/28Simon J. Gerraty2014-08-1924-653/+543
| |\ \ | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=270164