From 9444b8e4bc847f8fd9d02466976b962288cedf31 Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Sun, 17 May 2020 20:07:52 -0400 Subject: 9c, 9l: accept CC9FLAGS from config Also, if CC9FLAGS includes -fsanitize=address (ASAN), predefine PLAN9PORT_ASAN for use by programs that need to know (mainly libthread). The 9c script used to have a variable called ngflags, which was ccflags except -g (ng stood for "no g"), but nothing needs it split out anymore, so simplify to just ccflags. --- man/man1/install.1 | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'man/man1') diff --git a/man/man1/install.1 b/man/man1/install.1 index 8fcc9e41..17411af2 100644 --- a/man/man1/install.1 +++ b/man/man1/install.1 @@ -89,6 +89,15 @@ If contains a line .B WSYSTYPE=nowsys then the system is built without using X11. +.B LOCAL.config +may also list settings for +.B CC9 +(the host C compiler) +and +.B CC9FLAGS +(any additional flags to pass to the compiler). +Values more complex than single words should be quoted +with single quotes. .PP On most Linux systems, the X11 header packages need to be installed to build using X11. On Debian. the required packages are -- cgit v1.2.3 From bfe4377e409ce271c479665e6ef966a7b6008626 Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Mon, 18 May 2020 23:51:35 -0400 Subject: man: update man pages to say $HOME when accurate Fixes #386. --- man/man1/acid.1 | 30 +++++++++++++++--------------- man/man1/acme.1 | 8 ++++---- man/man1/rc.1 | 4 ++++ man/man1/sam.1 | 28 ++++++++++++++-------------- 4 files changed, 37 insertions(+), 33 deletions(-) (limited to 'man/man1') diff --git a/man/man1/acid.1 b/man/man1/acid.1 index e76aeb25..ed0b24db 100644 --- a/man/man1/acid.1 +++ b/man/man1/acid.1 @@ -48,7 +48,7 @@ is a programmable symbolic debugger. It can inspect one or more processes that share an address space. A program to be debugged may be specified by the process id of a running or defunct process, -or by the name of the program's text file +or by the name of the program's text file .RB ( a.out by default). At the prompt, @@ -63,7 +63,7 @@ Allow the textfile to be modified. Print variable renamings at startup. .TP .BI -l " library -Load from +Load from .I library at startup; see below. .TP @@ -84,8 +84,8 @@ obtains standard function definitions from the library file architecture-dependent functions from .BR \*9/acid/$objtype , user-specified functions from -.BR $home/lib/acid , -and further functions from +.BR $HOME/lib/acid , +and further functions from .B -l files. Definitions in any file may override previously defined functions. @@ -106,7 +106,7 @@ to create .I acid functions for examining data structures. .SS Language -Symbols of the program being debugged become integer +Symbols of the program being debugged become integer variables whose values are addresses. Contents of addresses are obtained by indirection. Local variables are qualified by @@ -114,7 +114,7 @@ function name, for example .BR main:argv . When program symbols conflict with .I acid -words, distinguishing +words, distinguishing .B $ signs are prefixed. Such renamings are reported at startup; option @@ -127,7 +127,7 @@ and formats are inferred from assignments. Truth values false/true are attributed to zero/nonzero integers or floats and to empty/nonempty lists or strings. Lists are sequences of expressions surrounded by -.BR {\^} +.BR {\^} and separated by commas. .PP Expressions are much as in C, @@ -219,7 +219,7 @@ Same as .BR spr();gpr() . .TP .BI fmt( expr , format ) -Expression +Expression .I expr with format given by the character value of expression .IR format . @@ -243,7 +243,7 @@ List current source directories. Add a source directory to the list. .TP .BI filepc( where ) -Convert a string of the form +Convert a string of the form .IB sourcefile : linenumber to a machine address. .TP @@ -288,7 +288,7 @@ interpreted according to a string of format codes. .BI dump( address , n , string\fP) Like .BR mem (), -repeated for +repeated for .I n consecutive blocks. .TP @@ -300,7 +300,7 @@ Start a new process with arguments given as a string and halt at the first instruction. .TP .B new() -Like +Like .IR newproc (), but take arguments (except .BR argv[0] ) @@ -308,7 +308,7 @@ from string variable .BR progargs . .TP .B win() -Like +Like .IR new (), but run the process in a separate window. .TP @@ -337,7 +337,7 @@ When a pid or core file is specified on the command line, .I acid will, as part of its startup, determine the set of shared libraries in use by the process image and map those at appropriate locations. -If +If .I acid is started without a pid or core file and is subsequently attached to a process via @@ -414,7 +414,7 @@ acid: *argv0 acid: bpset(ls) acid: cont() 70094: breakpoint ls ADD $-0x16c8,R29 -acid: +acid: .EE .PP Display elements of a linked list of structures: @@ -499,7 +499,7 @@ acid: cont() .br .B \*9/acid/truss .br -.B $home/lib/acid +.B $HOME/lib/acid .SH SOURCE .B \*9/src/cmd/acid .SH "SEE ALSO" diff --git a/man/man1/acme.1 b/man/man1/acme.1 index 182bcc7b..f21566f9 100644 --- a/man/man1/acme.1 +++ b/man/man1/acme.1 @@ -300,7 +300,7 @@ Delete window without checking for dirtiness. Write the state of .I acme to the file name, if specified, or -.B $home/acme.dump +.B $HOME/acme.dump by default. .TP .B Edit @@ -403,7 +403,7 @@ commands named as arguments. Restore the state of .I acme from a file (default -.BR $home/acme.dump ) +.BR $HOME/acme.dump ) created by the .B Dump command. @@ -745,9 +745,9 @@ and .I awd reside. .SH FILES -.TF $home/acme.dump +.TF $HOME/acme.dump .TP -.B $home/acme.dump +.B $HOME/acme.dump default file for .B Dump and diff --git a/man/man1/rc.1 b/man/man1/rc.1 index 792cdc95..7553707d 100644 --- a/man/man1/rc.1 +++ b/man/man1/rc.1 @@ -806,6 +806,10 @@ is set to its process id. .B $home The default directory for .BR cd . +Defaults to +.B $HOME +or else +.LR / . .TP .B $ifs The input field separators used in backquote substitutions. diff --git a/man/man1/sam.1 b/man/man1/sam.1 index 460fd6d6..8e771833 100644 --- a/man/man1/sam.1 +++ b/man/man1/sam.1 @@ -1,7 +1,7 @@ .TH SAM 1 .ds a \fR*\ \fP .SH NAME -sam, B, E, sam.save, samterm, samsave \- screen editor with structural regular expressions +sam, B, E, sam.save, samterm, samsave \- screen editor with structural regular expressions .SH SYNOPSIS .B sam [ @@ -43,7 +43,7 @@ The options are .TP .B -a Autoindent. In this mode, when a newline character is typed -in the terminal interface, +in the terminal interface, .I samterm copies leading white space on the current line to the new line. .TP @@ -121,7 +121,7 @@ is the beginning of the file. .TP .BI ? regexp ? The substring that matches the regular expression, -found by looking toward the end +found by looking toward the end .RB ( / ) or beginning .RB ( ? ) @@ -248,7 +248,7 @@ or is reversed. .PP It is an error for a compound address to represent a malformed substring. -Some useful idioms: +Some useful idioms: .IB a1 +- \%(\f2a1\fB-+\f1) selects the line containing @@ -258,7 +258,7 @@ locates the first match of the expression in the file. (The form .B 0;// sets dot unnecessarily.) -.BI ./ regexp /// +.BI ./ regexp /// finds the second following occurrence of the expression, and .BI .,/ regexp / @@ -276,7 +276,7 @@ newline may not appear literally; .B \en may be typed for newline; and .B \e/ -quotes the delimiter, here +quotes the delimiter, here .LR / . Backslash is otherwise interpreted literally, except in .B s @@ -284,7 +284,7 @@ commands. .PP Most commands may be prefixed by an address to indicate their range of operation. -Those that may not are marked with a +Those that may not are marked with a .L * below. If a command takes @@ -347,12 +347,12 @@ Substitute .I text for the first match to the regular expression in the range. Set dot to the modified range. -In +In .I text the character .B & stands for the string -that matched the expression. +that matched the expression. Backslash behaves as usual unless followed by a digit: .BI \e d @@ -500,7 +500,7 @@ Plan 9 command. .BI \*acd " directory Change working directory. If no directory is specified, -.B $home +.B $HOME is used. .PD .PP @@ -543,7 +543,7 @@ For each match of the regular expression in the range, run the command with dot set to the match. Set dot to the last match. If the regular -expression and its slashes are omitted, +expression and its slashes are omitted, .L /.*\en/ is assumed. Null string matches potentially occur before every character @@ -652,7 +652,7 @@ If no address is specified (the command is a newline) dot is extended in either direction to line boundaries and printed. If dot is thereby unchanged, it is set to -.B .+1 +.B .+1 and printed. .PD .SS Grouping and multiple changes @@ -713,7 +713,7 @@ of a rectangle. from the command window or the whole screen, depending on where the null rectangle is. .TF resize -.TP +.TP .B new Create a new, empty file. .TP @@ -819,7 +819,7 @@ typed in a command. Send the text in dot, or the snarf buffer if dot is the null string, as if it were typed to the command window. Saves the sent text in the snarf buffer. -(Command window only.) +(Command window only.) .PD .SS Simulated buttons For systems without a three-button mouse, the keyboard modifier -- cgit v1.2.3 From 95220bf88775deab4a037264d08b21bacc612d70 Mon Sep 17 00:00:00 2001 From: sean Date: Thu, 21 May 2020 16:10:30 +0100 Subject: ed: handle Unicode beyond the BMP correctly in list mode. List mode was constrained to the BMP. This change introduces the following new list mode convention, using Go string literal syntax: Non-printing ASCII characters display as \xhh. Non-ASCII characters in the BMP display as \uhhhh. Characters beyond the BMP display as \Uhhhhhhhh. --- man/man1/ed.1 | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'man/man1') diff --git a/man/man1/ed.1 b/man/man1/ed.1 index 00eb095a..9b161b29 100644 --- a/man/man1/ed.1 +++ b/man/man1/ed.1 @@ -441,10 +441,18 @@ a backspace as .LR \eb , backslashes as .LR \e\e , -and non-printing characters as +and non-printing ASCII characters as a backslash, an .LR x , -and four hexadecimal digits. +and two hexadecimal digits. +non-ASCII characters in the Basic Multilingual Plane +are printed as a backslash, a small +.LR u , +and four hexadecimal digits; and characters above the +Basic Multilingual Plane are printed as a backslash, +a big +.LR U , +and six hexadecimal digits. Long lines are folded, with the second and subsequent sub-lines indented one tab stop. If the last character in the line is a blank, -- cgit v1.2.3 From 01b505613590f3107c4a8849b18da2cbefd98466 Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Fri, 29 May 2020 21:42:54 -0400 Subject: ed(1): fix documentation for list mode I changed from 6 to 8 digits but forgot to update the man page. --- man/man1/ed.1 | 72 +++++++++++++++++++++++++++++------------------------------ 1 file changed, 36 insertions(+), 36 deletions(-) (limited to 'man/man1') diff --git a/man/man1/ed.1 b/man/man1/ed.1 index 9b161b29..41071c7e 100644 --- a/man/man1/ed.1 +++ b/man/man1/ed.1 @@ -35,7 +35,7 @@ of character counts by .LR r , and .L w -commands and of the confirming +commands and of the confirming .L ! by .L ! @@ -46,7 +46,7 @@ commands. Write all output to the standard error file except writing by .L w commands. -If no +If no .I file is given, make .B /dev/stdout @@ -62,7 +62,7 @@ in the buffer have no effect on the file until a (write) command is given. The copy of the text being edited resides -in a temporary file called the +in a temporary file called the .IR buffer . .PP Commands to @@ -78,7 +78,7 @@ These addresses specify one or more lines in the buffer. Missing addresses are supplied by default. .PP In general, only one command may appear on a line. -Certain commands allow the +Certain commands allow the addition of text to the buffer. While .I ed @@ -87,13 +87,13 @@ to be in .I "input mode." In this mode, no commands are recognized; all input is merely collected. -Input mode is left by typing a period +Input mode is left by typing a period .L . alone at the beginning of a line. .PP .I Ed -supports the +supports the .I "regular expression" notation described in .IR regexp (7). @@ -108,7 +108,7 @@ the regular expression metacharacters as an ordinary character, that character may be preceded by .RB ` \e '. This also applies to the character bounding the regular -expression (often +expression (often .LR / ) and to .L \e @@ -132,7 +132,7 @@ customarily called `dot', addresses the current line. .TP 2. -The character +The character .L $ addresses the last line of the buffer. .TP @@ -163,7 +163,7 @@ If necessary the search wraps around to the beginning of the buffer. .TP 6. -A regular expression enclosed in queries +A regular expression enclosed in queries .L ? addresses the line found by searching backward from the current line @@ -173,7 +173,7 @@ If necessary the search wraps around to the end of the buffer. .TP 7. -An address followed by a plus sign +An address followed by a plus sign .L + or a minus sign .L - @@ -182,7 +182,7 @@ followed by a decimal number specifies that address plus The plus sign may be omitted. .TP 8. -An address followed by +An address followed by .L + (or .LR - ) @@ -190,20 +190,20 @@ followed by a regular expression enclosed in slashes specifies the first matching line following (or preceding) that address. The search wraps around if necessary. -The +The .L + may be omitted, so .L 0/x/ addresses the .I first -line in the buffer with an +line in the buffer with an .LR x . -Enclosing the regular expression in +Enclosing the regular expression in .L ? reverses the search direction. .TP 9. -If an address begins with +If an address begins with .L + or .L - @@ -214,7 +214,7 @@ is understood to mean .LR .-5 . .TP 10. -If an address ends with +If an address ends with .L + or .LR - , @@ -236,9 +236,9 @@ line less 2. .TP 11. To maintain compatibility with earlier versions of the editor, -the character +the character .L ^ -in addresses is +in addresses is equivalent to .LR - . .PP @@ -254,7 +254,7 @@ Addresses are separated from each other typically by a comma .LR , . They may also be separated by a semicolon .LR ; . -In this case the current line +In this case the current line is set to the previous address before the next address is interpreted. If no address precedes a comma or semicolon, line 1 is assumed; @@ -285,7 +285,7 @@ and append it after the addressed line. Dot is left on the last line input, if there were any, otherwise at the addressed line. -Address +Address .L 0 is legal for this command; text is placed at the beginning of the buffer. @@ -293,7 +293,7 @@ at the beginning of the buffer. .RB (\|\fL.,.\fP\|) \|b [ +- ][\fIpagesize\fP][ pln\fR] Browse. Print a `page', normally 20 lines. -The optional +The optional .L + (default) or .L - @@ -305,11 +305,11 @@ is the number of lines in a page. The optional .LR p , .LR n , -or +or .L l causes printing in the specified format, initially .LR p . -Pagesize and format are remembered between +Pagesize and format are remembered between .L b commands. Dot is left at the last line displayed. @@ -397,7 +397,7 @@ and .L v are not permitted in the command list. Any character other than space or newline may -be used instead of +be used instead of .L / to delimit the regular expression. The second and third forms mean @@ -452,7 +452,7 @@ and four hexadecimal digits; and characters above the Basic Multilingual Plane are printed as a backslash, a big .LR U , -and six hexadecimal digits. +and eight hexadecimal digits. Long lines are folded, with the second and subsequent sub-lines indented one tab stop. If the last character in the line is a blank, @@ -542,13 +542,13 @@ defaults to 1 if missing), the .IR n th matched string is replaced by the replacement specified. -If the global replacement indicator +If the global replacement indicator .L g appears after the command, all subsequent matches on the line are also replaced. It is an error for the substitution to fail on all addressed lines. Any character other than space or newline -may be used instead of +may be used instead of .L / to delimit the regular expression and the replacement. @@ -560,7 +560,7 @@ The second may be omitted if the replacement is empty. .IP -An ampersand +An ampersand .L & appearing in the replacement is replaced by the string matching the regular expression. @@ -584,7 +584,7 @@ is determined by counting occurrences of .L ( starting from the left. .IP -A literal +A literal .LR & , .LR / , .L \e @@ -594,7 +594,7 @@ by prefixing it with .TP .RB (\|\fL.,.\fP\|) \|t\|\fIa Transfer. -Copy the addressed lines +Copy the addressed lines after the line addressed by .IR a . Dot is left at the last line of the copy. @@ -622,7 +622,7 @@ it is created with mode 666 (readable and writable by everyone). If no .I filename is given, the remembered file name, if any, is used. -The file name is remembered if there were no +The file name is remembered if there were no remembered file name already. Dot is unchanged. If the write is successful, the number of characters written is @@ -638,7 +638,7 @@ Print the line number of the addressed line. Dot is unchanged. .TP .BI ! shell\ command -Send the remainder of the line after the +Send the remainder of the line after the .L ! to .IR rc (1) @@ -647,7 +647,7 @@ Dot is unchanged. .TP .RB (\| .+1 )\| An address without a command is taken as a -.L p +.L p command. A terminal .L / @@ -657,11 +657,11 @@ A blank line alone is equivalent to it is useful for stepping through text. .PP -If an interrupt signal +If an interrupt signal .SM (DEL) is sent, .I ed -prints a +prints a .L ? and returns to its command level. .PP @@ -679,7 +679,7 @@ and all characters after the last newline. .SH SOURCE .B \*9/src/cmd/ed.c .SH "SEE ALSO" -.IR sam (1), +.IR sam (1), .IR sed (1), .IR regexp (7) .SH DIAGNOSTICS -- cgit v1.2.3