Commit Graph

14516 Commits

Author SHA1 Message Date
Stefan Eßer
252884ae7e Import new 2-clause BSD licenced implementation of the bc and dc commands
These implementations of the bc and dc programs offer a number of advantages
compared to the current implementations in the FreeBSD base system:

- They do not depend on external large number functions (i.e. no dependency
  on OpenSSL or any other large number library)

- They implements all features found in GNU bc/dc (with the exception of
  the forking of sub-processes, which the author of this version considers
  as a security issue).

- They are significantly faster than the current code in base (more than
  2 orders of magnitude in some of my tests, e.g. for 12345^100000).

- They should be fully compatible with all features and the behavior of the
  current implementations in FreeBSD (not formally verified).

- They support POSIX message catalogs and come with localized messages in
  Chinese, Dutch, English, French, German, Japanese, Polish, Portugueze,
  and Russian.

- They offer very detailed man-pages that provide far more information than
  the current ones.

The upstream sources contain a large number of tests, which are not
imported with this commit. They could be integrated into our test
framework at a latter time.

Installation of this version is controlled by the option "MK_GH_BC=yes".
This option will be set to yes by default in 13-CURRENT, but will be off
by default in 12-STABLE.

Approved by:	imp
Obtained from:	https://git.yzena.com/gavin/bc
MFC after:	4 weeks
Relnotes:	yes
Differential Revision:	https://reviews.freebsd.org/D19982
2020-06-27 12:02:01 +00:00
Dimitry Andric
bd74205d6a Regenerate ReStructuredText based manpages for llvm-project tools:
* bugpoint.1
* clang.1
* llc.1
* lldb.1
* lli.1
* llvm-ar.1
* llvm-as.1
* llvm-bcanalyzer.1
* llvm-cov.1
* llvm-diff.1
* llvm-dis.1
* llvm-dwarfdump.1
* llvm-extract.1
* llvm-link.1
* llvm-mca.1
* llvm-nm.1
* llvm-pdbutil.1
* llvm-profdata.1
* llvm-symbolizer.1
* llvm-tblgen.1
* opt.1

Add newly generated manpages for:

* llvm-addr2line.1 (this is an alias of llvm-symbolizer)
* llvm-cxxfilt.1
* llvm-objcopy.1
* llvm-ranlib.1 (this is an alias of llvm-ar)

Note that llvm-objdump.1 is an exception, as upstream has both a plain
.1 file, and a .rst variant. These will have to be reconciled upstream
first.

MFC after:	3 days
2020-06-27 11:56:49 +00:00
Fernando Apesteguía
c842df4889 killall(1): Clarify -d, -s and -v options
-d and -v are not equivalent options. The former is more verbose than the
latter and the former does not actually send the signals while the latter does.
Let them have their own paragraphs.

From the point of view of the output, -v is equivalent to -s, so describe them
close to each other. The difference is that former actually sends the signals
and the latter doesn't.

PR:	247411
Approved by:	manpages(0mp)
Differential Revision:	https://reviews.freebsd.org/D25413
2020-06-27 11:28:11 +00:00
Fernando Apesteguía
fe5bc3e6af rev(1): Add EXAMPLES section
Very simple example.

Approved by:	imp, 0mp, manpages(bcr)
Differential Revision:	https://reviews.freebsd.org/D25468
2020-06-27 11:19:18 +00:00
Fernando Apesteguía
9c7337903a limits(1): Add EXAMPLES section
* Add four examples showing flags -e, -b, -d, -s
 * Remove extra space at the end of the line reported by igor

Approved by:	bcr@
Differential Revision:	https://reviews.freebsd.org/D25426
2020-06-25 16:46:27 +00:00
Conrad Meyer
0a9ab9f549 Add WITH_CLANG_FORMAT option
clang-format is enabled conditional on either WITH_CLANG_EXTRAS or
WITH_CLANG_FORMAT.  Some sources in libclang are build conditional on
either rule, and obviously the clang-format binary itself depends on the
rule.

clang-format could still use a manual page.

Reviewed by:	emaste
Differential Revision:	https://reviews.freebsd.org/D25427
2020-06-24 17:03:42 +00:00
Jung-uk Kim
d836a9dbe3 Fix build with recent byacc. 2020-06-24 02:08:08 +00:00
Conrad Meyer
9f7e5bdad1 sort(1): Fix two wchar-related bugs in radixsort
Sort(1)'s radixsort implementation was broken for multibyte LC_CTYPEs in at
least two ways:

  * In actual radix sort, it would only bucket the least significant
    byte from each wchar, ignoring the 24 most-significant bits of each
    unicode character.

  * In degenerate cases / "fast paths," it would fall back to another
    sorting algorithm (default: mergesort) with a bogus comparator
    offset.  The string comparison functions in sort(1) take an offset
    in units of the operating character size.  However, radixsort was
    passing an offset in units of bytes.  The byte offset must be
    divided by sizeof(wchar_t).

This revision addresses both discovered issues.

Some example testcases:

  $ (echo 耳 ; echo 脳 ; echo 耳) | \
  LC_CTYPE=ja_JP.UTF-8 LC_COLLATE=C LANG=C sort --radixsort --debug

  $ (echo 耳 ; echo 脳 ; echo 耳) | \
  LC_CTYPE=C LC_COLLATE=C LANG=C           sort --radixsort --debug

  $ (for i in $(jot 34); do echo 耳耳耳耳耳; echo 耳耳耳耳脳; echo 耳耳耳耳脴; done) | \
  LC_CTYPE=ja_JP.UTF-8 LC_COLLATE=C LANG=C sort --radixsort --debug

PR:		247494
Reported by:	knu
MFC after:	I do not intend to, but parties interested in stable might want to
2020-06-23 16:43:48 +00:00
Mateusz Piotrowski
c47514db10 colrm.1: Add a missing colon 2020-06-23 10:27:41 +00:00
Mateusz Piotrowski
9ec571021d tee.1: Add a missing article 2020-06-23 10:22:58 +00:00
Fernando Apesteguía
e18baae63f colrm(1): Add EXAMPLES section
Add a couple of simple examples

Approved by:	bcr@
Differential Revision:	https://reviews.freebsd.org/D25196
2020-06-23 10:15:08 +00:00
Fernando Apesteguía
fcc879ad25 tee(1): Add EXAMPLES section
Add one simple example

Approved by:	bcr@
Differential Revision:	https://reviews.freebsd.org/D25337
2020-06-23 10:05:07 +00:00
Fernando Apesteguía
63280725b2 od(1): Add EXAMPLES section
* Add two small examples showing the use of -a, -c, -j and -N
 * While here, remove obsolete .Tn reported by mandoc(1)

Approved by:	0mp@
Differential Revision:	https://reviews.freebsd.org/D25372
2020-06-23 07:48:48 +00:00
Baptiste Daroussin
5b990a9463 Revert r362466
Such change should not have happen without prior discussion and review.

With hat:	transitioning core
2020-06-22 07:46:24 +00:00
Hans Petter Selasky
7747001b12 Improve wording to be more precise and clear.
No functional change intended.

s/Master Boot/Main Boot/ (also called MBR)

MFC after:	1 week
Sponsored by:	Mellanox Technologies
2020-06-21 13:34:08 +00:00
Yuri Pankov
2d3725d62a w: use locale-based string format specifiers
Use locale-based string format specifiers when printing
the process names/arguments.

Reviewed by:	pstef
Differential Revision:	https://reviews.freebsd.org/D25174
2020-06-21 11:42:49 +00:00
Fernando Apesteguía
69ad6e739b join(1): Add EXAMPLES section
Add EXAMPLES covering options -e, -o, -t, -v, -1

Approved by:	0mp@
Differential Revision: https://reviews.freebsd.org/D25186
2020-06-20 11:27:59 +00:00
Fernando Apesteguía
f3ec6af0e4 seq(1): complete EXAMPLES section
* Add a small description before the EXAMPLES that are already in the man page
  to explicitely state what we are trying to show instead of having the user
  guess what the example is doing.

* Add two more examples to show usage of -s, -t and -f

* mandoc -Tlint reports irrelevant use of .Tn so remove them since according to
  mdoc(7) it is there only for compatibility and should not be used in new
  manuals.

Approved by:	0mp@
2020-06-20 11:24:29 +00:00
Fernando Apesteguía
1831993577 cmp(1): Add EXAMPLES section
Add a small number of examples depicting the use of -l, -z and byte offsets

Approved by:	0mp@
2020-06-20 11:20:16 +00:00
Fernando Apesteguía
204fa3b066 diff(1): Add EXAMPLES section
Add examples for -r, -u, -N, -x, -q and -I

Approved by:	0mp@
Differential Revision:	https://reviews.freebsd.org/D25345
2020-06-19 06:48:16 +00:00
Jung-uk Kim
7e38239042 MFV: r362286
Merge flex 2.6.4.
2020-06-18 18:09:16 +00:00
Fernando Apesteguía
e48cafb55d split(1): Add EXAMPLES section
Add EXAMPLES covering -d, -n and -p
Include small explanation about the size of the chunks for the -n option

Approved by:	0mp
Differential Revision:	https://reviews.freebsd.org/D25198
2020-06-18 15:14:10 +00:00
Gordon Bergling
1d733bbc0d Add HISTORY sections to banner(6), basename(1), limits(1) and vmstat(8)
Reviewed by:	bcr (mentor)
Approved by:	bcr (mentor)
MFC after:	7 days
Differential Revision:	https://reviews.freebsd.org/D25019
2020-06-18 13:19:56 +00:00
Mateusz Piotrowski
cf0b74eee6 Clean up and improve manual page for fuser(1)
- Mention option's arguments in the list of options (so that now we mention
  "-N system" instead of just "-N").
- Stylize signals and other constants like O_APPEND with Dv.
- Sort options.
- Change indentation width for readability.
- Fix a couple of typos.
- Sort symbols list.
- Use Sy instead of Cm for symbols. They are not command modifiers.
- Use Ex -std in the EXIT STATUS section for consistency with other manual
  pages.
- Use Ql instead of Dq Li for inline code examples as Li has recently been
  deprecated by mdoc.

Reviewed by:	bcr
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D25332
2020-06-18 11:18:26 +00:00
Fernando Apesteguía
d70bfedd08 tee(1): Add EXAMPLES section
Probably the simplest one ever.

Approved by:	gbe@, 0mp@
Differential Revision:	https://reviews.freebsd.org/D25206
2020-06-18 10:48:37 +00:00
Fernando Apesteguía
15597d5df2 lockf(1): Add EXAMPLES section
* Add pretty small EXAMPLES section
 * While here, fix a warning in line 98 (new sentence in new line)

Approved by:	bcr@
Differential Revision:	https://reviews.freebsd.org/D25205
2020-06-18 08:31:04 +00:00
Fernando Apesteguía
43ad0e153d nl(1): Add EXAMPLES section
Add EXAMPLES section covering flags -b[ap] -n -i -s -v

Approved by:	bcr@
Differential Revision:	Add EXAMPLES section covering flags -b[ap] -n -i -s -v
2020-06-18 08:26:26 +00:00
Mateusz Piotrowski
78ef79139e Clean up fstat.1
- Sort options in the list & indent for readability.
- Pet linters
  - Use "\(em" instead of "--"
  - Remove Tn macros
- Use Ql instead of Dq Li
- Add arguments to the -M, -N, -p, and -u options in their descriptions.
- Use Sy instead of Li for field names. Li is deprecated, and Ql makes no
  sense here.
- Replace a literal block with a list for the table of special names
  related to FD.
- Use Ql instead of ``X''.
- Add a dot after etc.
- Reference fuser(1).

MFC after:	1 week
2020-06-17 21:21:57 +00:00
Fernando Apesteguía
022ebaf543 cmp(1): Add EXAMPLES section
Add simple examples showing the use of -l, -z, stdin and offsets

Approved by:	bcr@
Differential Revision: https://reviews.freebsd.org/D25280
2020-06-16 15:54:59 +00:00
Toomas Soome
e7fd9688ea Move font related data structured to sys/font.c and update vtfontcvt
Prepare support to be able to handle font data in loader, consolidate
data structures to sys/font.h and update vtfontcvt.

vtfontcvt update is about to output set of glyphs in form of C source,
the implementation does allow to output compressed or uncompressed font
bitmaps.

Reviewed by:	bcr
Differential Revision:	https://reviews.freebsd.org/D24189
2020-06-14 06:58:58 +00:00
Konstantin Belousov
2b5d88fdcf Fix ldd for PIE binaries after rtld stopped accepting binaries for dlopen.
ldd proclaims ET_DYN objects as shared libraries and tries to
dlopen(RTLD_TRACE) them to get dependencies. Since PIE binaries are
ET_DYN | DF_1_PIE, refusal to dlopen such binaries breaks ldd.

Fix it by reading and parsing dynamic segment looking for DF_FLAG_1
and taking DF_1_PIE into account when deciding between binary and
library.

Reported by:	Dewayne Geraghty <dewayne@heuristicsystems.com.au>
Reviewed by:	markj
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
Differential revision:	https://reviews.freebsd.org/D25257
2020-06-13 18:21:31 +00:00
Fernando Apesteguía
f893fe7a1d sockstat(1): Add EXAMPLES to man page
Add three examples showing the use of -4, -6, -l, -L, -p and -P

Reviewed by:	gbe@
Approved by:	bcr@
2020-06-13 17:36:08 +00:00
Yuri Pankov
7d93dd0f34 awk(1): use -version instead of -V
-V is OpenBSD specific, use -version instead.

While here, fix issue reported by mandoc lint and drop nonexistent
script(7) reference.

PR:		247004
Reviewed by:	0mp, markj
Differential Revision:	https://reviews.freebsd.org/D25164
2020-06-13 09:16:07 +00:00
Yuri Pankov
6419bb529b locale: exit 1 if unknown keyword was specified
PR:		241906
Submitted by:	Akos Somfai <akos.somfai@gmail.com>
2020-06-13 08:37:24 +00:00
Gordon Bergling
7974b0046d Add myself (gbe) to committers-doc.dot and calendar.freebsd
Reviewed by:	bcr (mentor)
Approved by:	bcr (mentor)
Differential Revision:	https://reviews.freebsd.org/D25241
2020-06-12 09:34:10 +00:00
Mateusz Piotrowski
c6f7593c1d Remove some more duplicate test cases I accidentally committed
Reported by:	markj, yuripv
MFC after:	2 weeks
X-MFC-With:	362017
2020-06-11 18:14:34 +00:00
Fernando Apesteguía
20994eafc4 xargs(1): Add EXAMPLES to man page
Add EXAMPLES covering options I, J, L, n, P.

While here, fix warning (STYLE: no blank before trailing delimiter: Fl P,)
Bumping .Dd

Approved by:	bcr@
Differential Revision:	https://reviews.freebsd.org/D25214
2020-06-11 15:14:39 +00:00
Mateusz Piotrowski
df471ef449 Remove duplicate lines from sed tests
Reported by:	yuripv
Approved by:	pfg (src)
MFC after:	2 weeks
X-MFC-With:	362017
2020-06-11 03:03:52 +00:00
Mateusz Piotrowski
f9ab72bb47 Read commands from stdin when -f - is passed to sed(1)
This patch teaches sed to interpret a "-" in a special way when given
as an argument to the -f flag.

This behavior is also present in GNU sed.

PR:		244872
Tested by:	antoine (exp-run)
Reviewed by:	pfg, tobik (older version)
Approved by:	pfg (src)
Relnotes:	yes
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D24079
2020-06-10 19:23:58 +00:00
Simon J. Gerraty
ef0b253881 Merge bmake-20200606
Relevant items from ChangeLog:

	o dir.c: cached_stats - don't confuse stat and lstat results.
	o var.c: add :Or for reverse sort.
2020-06-09 20:52:35 +00:00
Mateusz Piotrowski
19870105e1 Use Fl instead of Ar for long flags
Also, bump date after r361935.

MFC after:	1 week
2020-06-08 21:11:34 +00:00
Oleksandr Tymoshenko
c78cd98b8a Add VHDX support to mkimg(1)
VHDX is the successor of Microsoft's VHD file format. It increases
maximum capacity of the virtual drive to 64TB and introduces features
to better handle power/system failures.

VHDX is the required format for 2nd generation Hyper-V VMs.

Reviewed by:	marcel
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D25184
2020-06-08 20:28:32 +00:00
Benedict Reuschling
e6e3cf55d3 Add EXAMPLES to cover all flags except -f since it is analogous to -s.
An EXAMPLE section was adding with some basic examples that show the use of
uniq(1) with various flags.

Submitted by:	fernape@
Approved by:	bcr@
MFC after:	4 days
Relnotes:	yes (EXAMPLE section for uniq(1))
Differential Revision:	https://reviews.freebsd.org/D25149
2020-06-07 13:21:47 +00:00
Kyle Evans
3a4d70c588 sed: attempt to learn about hex escapes (e.g. \x27)
Somewhat predictably, software often wants to use \x27/\x24 among others so
that they can decline worrying about ugly escaping, if said escaping is even
possible. Right now, this software is using these and getting the wrong
results, as we'll interpret those as x27 and x24 respectively. Some examples
of this, when an exp-run was ran, were science/octopus and misc/vifm.

Go ahead and process these at all times.  We allow either one or two digits,
and the tests account for both.  If extra digits are specified, e.g. \x2727,
then the third and fourth digits are interpreted literally as one might
expect.

PR:		229925
MFC after:	2 weeks
2020-06-07 04:32:38 +00:00
Benjamin Kaduk
5ff9cf9f06 Belatedly bump .Dd for r361783
Reported by:	lwhsu
Pointy hat to:	bjk
2020-06-05 16:59:14 +00:00
John Baldwin
00a4311adc Refer to AES-CBC as "aes-cbc" rather than "rijndael-cbc" for IPsec.
At this point, AES is the more common name for Rijndael128.  setkey(8)
will still accept the old name, and old constants remain for
compatiblity.

Reviewed by:	cem, bcr (manpages)
MFC after:	2 weeks
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D24964
2020-06-04 22:58:37 +00:00
Benjamin Kaduk
a201343073 Add EXAMPLES to killall(1)
Submitted by:	fernape
Differential Revision:	https://reviews.freebsd.org/D25002
2020-06-04 04:29:43 +00:00
Dimitry Andric
b7ec5dea64 Update Subversion to 1.14.0 LTS. See contrib/subversion/CHANGES for a
summary of changes, or for a more thorough overview:

https://subversion.apache.org/docs/release-notes/1.14

NOTE: there is no need to dump and reload repositories, and the working
copy format is still the same as Subversion 1.8 through 1.13.

Relnotes:	yes
MFC after:	2 weeks
X-MFC-With:	r361677
2020-06-01 10:27:05 +00:00
Dimitry Andric
674baa3c4f Update apr-util to 1.6.1. See contrib/apr-util/CHANGES for a summary of
changes.

MFC after:	2 weeks
X-MFC-With:	r361677
2020-06-01 10:14:45 +00:00
Dimitry Andric
d21a42232f Follow-up r361678 (update apr to 1.7.0) by also regenerating the apr
internal headers through the upstream configure script, with some minor
custom tweaks.

MFC after:	2 weeks
X-MFC-With:	r361677
2020-06-01 10:08:18 +00:00