summary refs log tree commit diff
path: root/doc
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--doc/pdf/.gitignore1
-rw-r--r--doc/pdf/Makefile31
-rw-r--r--doc/rfc/.gitignore3
-rw-r--r--doc/rfc/Makefile21
-rw-r--r--doc/rfc/rfc.vim30
-rw-r--r--doc/rfc/rfctags.pl28
-rw-r--r--doc/zlib/Makefile (renamed from Makefile)0
-rw-r--r--doc/zlib/adler32.3 (renamed from adler32.3)0
-rw-r--r--doc/zlib/adler32_combine.3 (renamed from adler32_combine.3)0
-rw-r--r--doc/zlib/compress.3 (renamed from compress.3)0
-rw-r--r--doc/zlib/compressBound.3 (renamed from compressBound.3)0
-rw-r--r--doc/zlib/crc32.3 (renamed from crc32.3)0
-rw-r--r--doc/zlib/crc32_combine.3 (renamed from crc32_combine.3)0
-rw-r--r--doc/zlib/deflate.3 (renamed from deflate.3)0
-rw-r--r--doc/zlib/deflateBound.3 (renamed from deflateBound.3)0
-rw-r--r--doc/zlib/deflateCopy.3 (renamed from deflateCopy.3)0
-rw-r--r--doc/zlib/deflateEnd.3 (renamed from deflateEnd.3)0
-rw-r--r--doc/zlib/deflateGetDictionary.3 (renamed from deflateGetDictionary.3)0
-rw-r--r--doc/zlib/deflateInit.3 (renamed from deflateInit.3)0
-rw-r--r--doc/zlib/deflateInit2.3 (renamed from deflateInit2.3)0
-rw-r--r--doc/zlib/deflateParams.3 (renamed from deflateParams.3)0
-rw-r--r--doc/zlib/deflatePending.3 (renamed from deflatePending.3)0
-rw-r--r--doc/zlib/deflatePrime.3 (renamed from deflatePrime.3)0
-rw-r--r--doc/zlib/deflateReset.3 (renamed from deflateReset.3)0
-rw-r--r--doc/zlib/deflateSetDictionary.3 (renamed from deflateSetDictionary.3)0
-rw-r--r--doc/zlib/deflateSetHeader.3 (renamed from deflateSetHeader.3)0
-rw-r--r--doc/zlib/deflateTune.3 (renamed from deflateTune.3)0
-rw-r--r--doc/zlib/gzbuffer.3 (renamed from gzbuffer.3)0
-rw-r--r--doc/zlib/gzclose.3 (renamed from gzclose.3)0
-rw-r--r--doc/zlib/gzdirect.3 (renamed from gzdirect.3)0
-rw-r--r--doc/zlib/gzeof.3 (renamed from gzeof.3)0
-rw-r--r--doc/zlib/gzerror.3 (renamed from gzerror.3)0
-rw-r--r--doc/zlib/gzflush.3 (renamed from gzflush.3)0
-rw-r--r--doc/zlib/gzfread.3 (renamed from gzfread.3)0
-rw-r--r--doc/zlib/gzfwrite.3 (renamed from gzfwrite.3)0
-rw-r--r--doc/zlib/gzgetc.3 (renamed from gzgetc.3)0
-rw-r--r--doc/zlib/gzgets.3 (renamed from gzgets.3)0
-rw-r--r--doc/zlib/gzoffset.3 (renamed from gzoffset.3)0
-rw-r--r--doc/zlib/gzopen.3 (renamed from gzopen.3)0
-rw-r--r--doc/zlib/gzprintf.3 (renamed from gzprintf.3)0
-rw-r--r--doc/zlib/gzputc.3 (renamed from gzputc.3)0
-rw-r--r--doc/zlib/gzputs.3 (renamed from gzputs.3)0
-rw-r--r--doc/zlib/gzread.3 (renamed from gzread.3)0
-rw-r--r--doc/zlib/gzseek.3 (renamed from gzseek.3)0
-rw-r--r--doc/zlib/gzsetparams.3 (renamed from gzsetparams.3)0
-rw-r--r--doc/zlib/gzungetc.3 (renamed from gzungetc.3)0
-rw-r--r--doc/zlib/gzwrite.3 (renamed from gzwrite.3)0
-rw-r--r--doc/zlib/inflate.3 (renamed from inflate.3)0
-rw-r--r--doc/zlib/inflateBack.3 (renamed from inflateBack.3)0
-rw-r--r--doc/zlib/inflateBackEnd.3 (renamed from inflateBackEnd.3)0
-rw-r--r--doc/zlib/inflateBackInit.3 (renamed from inflateBackInit.3)0
-rw-r--r--doc/zlib/inflateCopy.3 (renamed from inflateCopy.3)0
-rw-r--r--doc/zlib/inflateEnd.3 (renamed from inflateEnd.3)0
-rw-r--r--doc/zlib/inflateGetDictionary.3 (renamed from inflateGetDictionary.3)0
-rw-r--r--doc/zlib/inflateGetHeader.3 (renamed from inflateGetHeader.3)0
-rw-r--r--doc/zlib/inflateInit.3 (renamed from inflateInit.3)0
-rw-r--r--doc/zlib/inflateInit2.3 (renamed from inflateInit2.3)0
-rw-r--r--doc/zlib/inflateMark.3 (renamed from inflateMark.3)0
-rw-r--r--doc/zlib/inflatePrime.3 (renamed from inflatePrime.3)0
-rw-r--r--doc/zlib/inflateReset.3 (renamed from inflateReset.3)0
-rw-r--r--doc/zlib/inflateSetDictionary.3 (renamed from inflateSetDictionary.3)0
-rw-r--r--doc/zlib/inflateSync.3 (renamed from inflateSync.3)0
-rw-r--r--doc/zlib/uncompress.3 (renamed from uncompress.3)0
-rw-r--r--doc/zlib/zlibCompileFlags.3 (renamed from zlibCompileFlags.3)0
-rw-r--r--doc/zlib/zlibVersion.3 (renamed from zlibVersion.3)0
65 files changed, 114 insertions, 0 deletions
diff --git a/doc/pdf/.gitignore b/doc/pdf/.gitignore
new file mode 100644
index 00000000..a1363379
--- /dev/null
+++ b/doc/pdf/.gitignore
@@ -0,0 +1 @@
+*.pdf
diff --git a/doc/pdf/Makefile b/doc/pdf/Makefile
new file mode 100644
index 00000000..7afbdcf2
--- /dev/null
+++ b/doc/pdf/Makefile
@@ -0,0 +1,31 @@
+PDFS += abi.pdf
+PDFS += c11.pdf
+PDFS += elf.pdf
+PDFS += intel-64-opt.pdf
+PDFS += intel-64-sdm-vol-1.pdf
+PDFS += intel-64-sdm-vol-2.pdf
+PDFS += intel-64-sdm-vol-3.pdf
+PDFS += intel-64-sdm-vol-4.pdf
+PDFS += multiboot.pdf
+
+ELF = https://refspecs.linuxbase.org/elf
+INTEL = https://software.intel.com/sites/default/files/managed
+
+URL.abi.pdf = ${ELF}/x86_64-abi-0.99.pdf
+URL.c11.pdf = http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1570.pdf
+URL.elf.pdf = ${ELF}/elf.pdf
+URL.intel-64-opt.pdf = ${INTEL}/9e/bc/64-ia-32-architectures-optimization-manual.pdf
+URL.intel-64-sdm-vol-1.pdf = ${INTEL}/a4/60/253665-sdm-vol-1.pdf
+URL.intel-64-sdm-vol-2.pdf = ${INTEL}/a4/60/325383-sdm-vol-2abcd.pdf
+URL.intel-64-sdm-vol-3.pdf = ${INTEL}/a4/60/325384-sdm-vol-3abcd.pdf
+URL.intel-64-sdm-vol-4.pdf = ${INTEL}/22/0d/335592-sdm-vol-4.pdf
+URL.multiboot.pdf = https://www.gnu.org/software/grub/manual/multiboot/multiboot.pdf
+
+all: ${PDFS}
+
+${PDFS}:
+	curl -Lf -o $@ ${URL.$@}
+	chmod a-w $@
+
+clean:
+	rm -f ${PDFS}
diff --git a/doc/rfc/.gitignore b/doc/rfc/.gitignore
new file mode 100644
index 00000000..808cd63e
--- /dev/null
+++ b/doc/rfc/.gitignore
@@ -0,0 +1,3 @@
+*.txt
+*.txt.gz
+tags
diff --git a/doc/rfc/Makefile b/doc/rfc/Makefile
new file mode 100644
index 00000000..87462a6c
--- /dev/null
+++ b/doc/rfc/Makefile
@@ -0,0 +1,21 @@
+PREFIX ?= ~/.local
+
+MODULE = ftp.rfc-editor.org::rfcs-text-only
+
+tags: rfctags.pl rfc-index.txt.gz
+	perl rfctags.pl | sort -f > $@
+
+rfc-index.txt.gz:
+	rsync -ptz ${MODULE}/rfc-index.txt ${MODULE}/'rfc[1-9]*.txt' .
+	gzip -9f *.txt
+
+clean:
+	rm -f tags *.txt *.txt.gz
+
+install: tags rfc.vim
+	install -d ${PREFIX}/share/rfc ${PREFIX}/share/nvim/site/plugin
+	ln -f tags *.txt.gz ${PREFIX}/share/rfc
+	install -m 644 rfc.vim ${PREFIX}/share/nvim/site/plugin
+
+uninstall:
+	rm -fr ${PREFIX}/share/rfc ${PREFIX}/share/nvim/site/plugin/rfc.vim
diff --git a/doc/rfc/rfc.vim b/doc/rfc/rfc.vim
new file mode 100644
index 00000000..2455d8a6
--- /dev/null
+++ b/doc/rfc/rfc.vim
@@ -0,0 +1,30 @@
+if !exists('g:rfc_path')
+	let g:rfc_path = expand('<sfile>:h:h:h:h') . '/rfc'
+endif
+
+function! s:RFC(number)
+	if !empty(a:number)
+		let number = str2nr(matchstr(a:number, '\d\+'), 10)
+	else
+		let number = '-index'
+	endif
+	let path = expand(g:rfc_path . '/rfc' . number . '.txt.gz')
+	if filereadable(path)
+		execute 'silent' 'noswapfile' 'view' path
+	else
+		echohl ErrorMsg | echo 'No such RFC' a:number | echohl None
+	endif
+endfunction
+
+function! s:BufRead()
+	setlocal readonly
+	setlocal keywordprg=:RFC
+	setlocal iskeyword=a-z,A-Z,48-57,.,[,],-,_
+	nmap <buffer> <silent> gO :call search('^Table of Contents', 'bcs')<CR>
+endfunction
+
+command! -bar -nargs=? RFC call s:RFC(<q-args>)
+augroup RFC
+	autocmd!
+	autocmd BufRead rfc*.txt.gz call s:BufRead()
+augroup END
diff --git a/doc/rfc/rfctags.pl b/doc/rfc/rfctags.pl
new file mode 100644
index 00000000..01324a0d
--- /dev/null
+++ b/doc/rfc/rfctags.pl
@@ -0,0 +1,28 @@
+use strict;
+use warnings;
+use open ':encoding(ISO-8859-1)';
+
+use IO::Uncompress::Gunzip qw($GunzipError);
+
+($,, $\) = ("\t", "\n");
+print '!_TAG_FILE_SORTED', 2, $0; # Promise to pipe this through sort -f
+for my $rfc (<*.txt.gz>) {
+	my $handle = new IO::Uncompress::Gunzip $rfc
+		or die "${rfc}: ${GunzipError}";
+	while (<$handle>) {
+		chomp;
+		# Section headings
+		if (/^([\d.]+|[A-Z][.])\s+([^\t]+)?/) {
+			print $1, $rfc, $.;
+			print $2, $rfc, $. if $2;
+			print $1, $rfc, $. if $1 =~ /^([\d.]+)[.]$/;
+		}
+		# References
+		if (/^\s*(\[[\w-]+\])\s{2,}/) {
+			print $1, $rfc, $.;
+			print "\\$1", $rfc, $.; # vim ^] prepends \ to [
+		}
+	}
+	die "${rfc}: $!" if $!;
+	close $handle;
+}
diff --git a/Makefile b/doc/zlib/Makefile
index 6cfd4a42..6cfd4a42 100644
--- a/Makefile
+++ b/doc/zlib/Makefile
diff --git a/adler32.3 b/doc/zlib/adler32.3
index c58a34e7..c58a34e7 100644
--- a/adler32.3
+++ b/doc/zlib/adler32.3
diff --git a/adler32_combine.3 b/doc/zlib/adler32_combine.3
index 55e801e9..55e801e9 100644
--- a/adler32_combine.3
+++ b/doc/zlib/adler32_combine.3
diff --git a/compress.3 b/doc/zlib/compress.3
index 16445e2f..16445e2f 100644
--- a/compress.3
+++ b/doc/zlib/compress.3
diff --git a/compressBound.3 b/doc/zlib/compressBound.3
index d61891eb..d61891eb 100644
--- a/compressBound.3
+++ b/doc/zlib/compressBound.3
diff --git a/crc32.3 b/doc/zlib/crc32.3
index a42df2af..a42df2af 100644
--- a/crc32.3
+++ b/doc/zlib/crc32.3
diff --git a/crc32_combine.3 b/doc/zlib/crc32_combine.3
index b25da679..b25da679 100644
--- a/crc32_combine.3
+++ b/doc/zlib/crc32_combine.3
diff --git a/deflate.3 b/doc/zlib/deflate.3
index be182d96..be182d96 100644
--- a/deflate.3
+++ b/doc/zlib/deflate.3
diff --git a/deflateBound.3 b/doc/zlib/deflateBound.3
index be97494c..be97494c 100644
--- a/deflateBound.3
+++ b/doc/zlib/deflateBound.3
diff --git a/deflateCopy.3 b/doc/zlib/deflateCopy.3
index f20e0a9e..f20e0a9e 100644
--- a/deflateCopy.3
+++ b/doc/zlib/deflateCopy.3
diff --git a/deflateEnd.3 b/doc/zlib/deflateEnd.3
index 0abaabe1..0abaabe1 100644
--- a/deflateEnd.3
+++ b/doc/zlib/deflateEnd.3
diff --git a/deflateGetDictionary.3 b/doc/zlib/deflateGetDictionary.3
index b9dabfe2..b9dabfe2 100644
--- a/deflateGetDictionary.3
+++ b/doc/zlib/deflateGetDictionary.3
diff --git a/deflateInit.3 b/doc/zlib/deflateInit.3
index 52179883..52179883 100644
--- a/deflateInit.3
+++ b/doc/zlib/deflateInit.3
diff --git a/deflateInit2.3 b/doc/zlib/deflateInit2.3
index a7d68b99..a7d68b99 100644
--- a/deflateInit2.3
+++ b/doc/zlib/deflateInit2.3
diff --git a/deflateParams.3 b/doc/zlib/deflateParams.3
index 9eb5ca16..9eb5ca16 100644
--- a/deflateParams.3
+++ b/doc/zlib/deflateParams.3
diff --git a/deflatePending.3 b/doc/zlib/deflatePending.3
index 35fa6d38..35fa6d38 100644
--- a/deflatePending.3
+++ b/doc/zlib/deflatePending.3
diff --git a/deflatePrime.3 b/doc/zlib/deflatePrime.3
index 10a2924b..10a2924b 100644
--- a/deflatePrime.3
+++ b/doc/zlib/deflatePrime.3
diff --git a/deflateReset.3 b/doc/zlib/deflateReset.3
index 1a18c507..1a18c507 100644
--- a/deflateReset.3
+++ b/doc/zlib/deflateReset.3
diff --git a/deflateSetDictionary.3 b/doc/zlib/deflateSetDictionary.3
index 3e66d3cf..3e66d3cf 100644
--- a/deflateSetDictionary.3
+++ b/doc/zlib/deflateSetDictionary.3
diff --git a/deflateSetHeader.3 b/doc/zlib/deflateSetHeader.3
index 03d4f4d3..03d4f4d3 100644
--- a/deflateSetHeader.3
+++ b/doc/zlib/deflateSetHeader.3
diff --git a/deflateTune.3 b/doc/zlib/deflateTune.3
index ea4dd915..ea4dd915 100644
--- a/deflateTune.3
+++ b/doc/zlib/deflateTune.3
diff --git a/gzbuffer.3 b/doc/zlib/gzbuffer.3
index 92438c48..92438c48 100644
--- a/gzbuffer.3
+++ b/doc/zlib/gzbuffer.3
diff --git a/gzclose.3 b/doc/zlib/gzclose.3
index bfcc583e..bfcc583e 100644
--- a/gzclose.3
+++ b/doc/zlib/gzclose.3
diff --git a/gzdirect.3 b/doc/zlib/gzdirect.3
index 640fd4c5..640fd4c5 100644
--- a/gzdirect.3
+++ b/doc/zlib/gzdirect.3
diff --git a/gzeof.3 b/doc/zlib/gzeof.3
index ba823aa6..ba823aa6 100644
--- a/gzeof.3
+++ b/doc/zlib/gzeof.3
diff --git a/gzerror.3 b/doc/zlib/gzerror.3
index a9e175fc..a9e175fc 100644
--- a/gzerror.3
+++ b/doc/zlib/gzerror.3
diff --git a/gzflush.3 b/doc/zlib/gzflush.3
index 476f7c09..476f7c09 100644
--- a/gzflush.3
+++ b/doc/zlib/gzflush.3
diff --git a/gzfread.3 b/doc/zlib/gzfread.3
index 7bf57fc5..7bf57fc5 100644
--- a/gzfread.3
+++ b/doc/zlib/gzfread.3
diff --git a/gzfwrite.3 b/doc/zlib/gzfwrite.3
index 6835db3a..6835db3a 100644
--- a/gzfwrite.3
+++ b/doc/zlib/gzfwrite.3
diff --git a/gzgetc.3 b/doc/zlib/gzgetc.3
index db9143ec..db9143ec 100644
--- a/gzgetc.3
+++ b/doc/zlib/gzgetc.3
diff --git a/gzgets.3 b/doc/zlib/gzgets.3
index c1435b39..c1435b39 100644
--- a/gzgets.3
+++ b/doc/zlib/gzgets.3
diff --git a/gzoffset.3 b/doc/zlib/gzoffset.3
index b03c557e..b03c557e 100644
--- a/gzoffset.3
+++ b/doc/zlib/gzoffset.3
diff --git a/gzopen.3 b/doc/zlib/gzopen.3
index 9da647e1..9da647e1 100644
--- a/gzopen.3
+++ b/doc/zlib/gzopen.3
diff --git a/gzprintf.3 b/doc/zlib/gzprintf.3
index a2a241a2..a2a241a2 100644
--- a/gzprintf.3
+++ b/doc/zlib/gzprintf.3
diff --git a/gzputc.3 b/doc/zlib/gzputc.3
index 66897b5e..66897b5e 100644
--- a/gzputc.3
+++ b/doc/zlib/gzputc.3
diff --git a/gzputs.3 b/doc/zlib/gzputs.3
index 71833ab2..71833ab2 100644
--- a/gzputs.3
+++ b/doc/zlib/gzputs.3
diff --git a/gzread.3 b/doc/zlib/gzread.3
index 4118eca7..4118eca7 100644
--- a/gzread.3
+++ b/doc/zlib/gzread.3
diff --git a/gzseek.3 b/doc/zlib/gzseek.3
index a14b2db6..a14b2db6 100644
--- a/gzseek.3
+++ b/doc/zlib/gzseek.3
diff --git a/gzsetparams.3 b/doc/zlib/gzsetparams.3
index f6ff9ed7..f6ff9ed7 100644
--- a/gzsetparams.3
+++ b/doc/zlib/gzsetparams.3
diff --git a/gzungetc.3 b/doc/zlib/gzungetc.3
index fbe9371c..fbe9371c 100644
--- a/gzungetc.3
+++ b/doc/zlib/gzungetc.3
diff --git a/gzwrite.3 b/doc/zlib/gzwrite.3
index 73407ef5..73407ef5 100644
--- a/gzwrite.3
+++ b/doc/zlib/gzwrite.3
diff --git a/inflate.3 b/doc/zlib/inflate.3
index 255e0f84..255e0f84 100644
--- a/inflate.3
+++ b/doc/zlib/inflate.3
diff --git a/inflateBack.3 b/doc/zlib/inflateBack.3
index fcda7452..fcda7452 100644
--- a/inflateBack.3
+++ b/doc/zlib/inflateBack.3
diff --git a/inflateBackEnd.3 b/doc/zlib/inflateBackEnd.3
index 39fbea8f..39fbea8f 100644
--- a/inflateBackEnd.3
+++ b/doc/zlib/inflateBackEnd.3
diff --git a/inflateBackInit.3 b/doc/zlib/inflateBackInit.3
index d029542e..d029542e 100644
--- a/inflateBackInit.3
+++ b/doc/zlib/inflateBackInit.3
diff --git a/inflateCopy.3 b/doc/zlib/inflateCopy.3
index 167b879b..167b879b 100644
--- a/inflateCopy.3
+++ b/doc/zlib/inflateCopy.3
diff --git a/inflateEnd.3 b/doc/zlib/inflateEnd.3
index 54945b50..54945b50 100644
--- a/inflateEnd.3
+++ b/doc/zlib/inflateEnd.3
diff --git a/inflateGetDictionary.3 b/doc/zlib/inflateGetDictionary.3
index 9290850c..9290850c 100644
--- a/inflateGetDictionary.3
+++ b/doc/zlib/inflateGetDictionary.3
diff --git a/inflateGetHeader.3 b/doc/zlib/inflateGetHeader.3
index 57f7c443..57f7c443 100644
--- a/inflateGetHeader.3
+++ b/doc/zlib/inflateGetHeader.3
diff --git a/inflateInit.3 b/doc/zlib/inflateInit.3
index 66a1d4f7..66a1d4f7 100644
--- a/inflateInit.3
+++ b/doc/zlib/inflateInit.3
diff --git a/inflateInit2.3 b/doc/zlib/inflateInit2.3
index 5b8b49ac..5b8b49ac 100644
--- a/inflateInit2.3
+++ b/doc/zlib/inflateInit2.3
diff --git a/inflateMark.3 b/doc/zlib/inflateMark.3
index 90e2ee0b..90e2ee0b 100644
--- a/inflateMark.3
+++ b/doc/zlib/inflateMark.3
diff --git a/inflatePrime.3 b/doc/zlib/inflatePrime.3
index 66953665..66953665 100644
--- a/inflatePrime.3
+++ b/doc/zlib/inflatePrime.3
diff --git a/inflateReset.3 b/doc/zlib/inflateReset.3
index 53c4ffe2..53c4ffe2 100644
--- a/inflateReset.3
+++ b/doc/zlib/inflateReset.3
diff --git a/inflateSetDictionary.3 b/doc/zlib/inflateSetDictionary.3
index 291c97e8..291c97e8 100644
--- a/inflateSetDictionary.3
+++ b/doc/zlib/inflateSetDictionary.3
diff --git a/inflateSync.3 b/doc/zlib/inflateSync.3
index 56d3ca28..56d3ca28 100644
--- a/inflateSync.3
+++ b/doc/zlib/inflateSync.3
diff --git a/uncompress.3 b/doc/zlib/uncompress.3
index 1047ad91..1047ad91 100644
--- a/uncompress.3
+++ b/doc/zlib/uncompress.3
diff --git a/zlibCompileFlags.3 b/doc/zlib/zlibCompileFlags.3
index 59cc24a8..59cc24a8 100644
--- a/zlibCompileFlags.3
+++ b/doc/zlib/zlibCompileFlags.3
diff --git a/zlibVersion.3 b/doc/zlib/zlibVersion.3
index 04377527..04377527 100644
--- a/zlibVersion.3
+++ b/doc/zlib/zlibVersion.3