diff options
-rw-r--r-- | README.md | 22 | ||||
-rwxr-xr-x | tl-build.sh | 1 | ||||
-rw-r--r-- | tlobsd | 6 | ||||
-rw-r--r-- | tlobsd-getbiber | 77 |
4 files changed, 103 insertions, 3 deletions
@@ -58,8 +58,7 @@ for OpenBSD provides the following: | |||
58 | - xindy | 58 | - xindy |
59 | - LuaMetaTeX (ConTeXt) | 59 | - LuaMetaTeX (ConTeXt) |
60 | - asymptote | 60 | - asymptote |
61 | 61 | - biber (see below) | |
62 | biber will soon be added to this list. | ||
63 | 62 | ||
64 | ### TeX Live for OpenBSD at Utah | 63 | ### TeX Live for OpenBSD at Utah |
65 | 64 | ||
@@ -249,6 +248,25 @@ tlobsd mksymlinks | |||
249 | 248 | ||
250 | Just as `tlobsd tlmgr`, this command requires the `subversion` package. | 249 | Just as `tlobsd tlmgr`, this command requires the `subversion` package. |
251 | 250 | ||
251 | ### `biber` | ||
252 | |||
253 | A binay version of `biber`, the backend processor for BibLaTeX, is | ||
254 | available for TeX Live for OpenBSD. It can be installed or updated | ||
255 | with `tlobsd` as follows: | ||
256 | |||
257 | ```sh | ||
258 | tlobsd getbiber | ||
259 | ``` | ||
260 | |||
261 | This commands downloads a `biber` executable and attempts to verify it | ||
262 | with the public key that is used to sign the TeX Live for OpenBSD | ||
263 | binaries. See | ||
264 | [above](#installing-tex-live-on-openbsd-with-ready-to-use-binaries). | ||
265 | |||
266 | Direct link to `biber` binary: <https://www.ekdosis.org/texlive>. This | ||
267 | binary can be installed by hand into the TeX Live binary directory. | ||
268 | The suffix must be removed and the file renamed to exactly "`biber`". | ||
269 | |||
252 | ### More information on `tlobsd`: | 270 | ### More information on `tlobsd`: |
253 | 271 | ||
254 | ```sh | 272 | ```sh |
diff --git a/tl-build.sh b/tl-build.sh index dcf3bfe..b538401 100755 --- a/tl-build.sh +++ b/tl-build.sh | |||
@@ -149,6 +149,7 @@ function include_extras { | |||
149 | if [[ -d ${tl_sourcedir}/inst/bin ]];then | 149 | if [[ -d ${tl_sourcedir}/inst/bin ]];then |
150 | tl_bindir=${tl_sourcedir}/inst/bin/`ls ${tl_sourcedir}/inst/bin` | 150 | tl_bindir=${tl_sourcedir}/inst/bin/`ls ${tl_sourcedir}/inst/bin` |
151 | install -m 0755 ${this_dir}/tlobsd-mksymlinks ${tl_bindir}/tlobsd-mksymlinks | 151 | install -m 0755 ${this_dir}/tlobsd-mksymlinks ${tl_bindir}/tlobsd-mksymlinks |
152 | install -m 0755 ${this_dir}/tlobsd-getbiber ${tl_bindir}/tlobsd-getbiber | ||
152 | install -m 0755 ${this_dir}/tlobsd ${tl_bindir}/tlobsd | 153 | install -m 0755 ${this_dir}/tlobsd ${tl_bindir}/tlobsd |
153 | fi | 154 | fi |
154 | } | 155 | } |
@@ -1,6 +1,6 @@ | |||
1 | #!/bin/sh | 1 | #!/bin/sh |
2 | # | 2 | # |
3 | # $TeX Live for OpenBSD, 2024/04/27 $ | 3 | # $TeX Live for OpenBSD, 2024/06/08 $ |
4 | 4 | ||
5 | cmd=$@ | 5 | cmd=$@ |
6 | export tlobsd=1 | 6 | export tlobsd=1 |
@@ -13,6 +13,7 @@ Known actions to \033[1mtlobsd\033[0m: | |||
13 | \033[4mtlmgr\033[0m\t\tThis action accepts the exact same options and arguments as \033[4mtlmgr(1)\033[0m. | 13 | \033[4mtlmgr\033[0m\t\tThis action accepts the exact same options and arguments as \033[4mtlmgr(1)\033[0m. |
14 | \033[4mmksymlinks\033[0m\tUpdates all existing links in \033[4m${TLBINPATH}\033[0m | 14 | \033[4mmksymlinks\033[0m\tUpdates all existing links in \033[4m${TLBINPATH}\033[0m |
15 | \t\tand installs new links. | 15 | \t\tand installs new links. |
16 | \033[4mgetbiber\033[0m\tInstalls or updates biber executable for OpenBSD. | ||
16 | \033[4mversion\033[0m\tGives version information. | 17 | \033[4mversion\033[0m\tGives version information. |
17 | " | 18 | " |
18 | } | 19 | } |
@@ -31,6 +32,9 @@ elif [[ $1 == "tlmgr" ]];then | |||
31 | # symlinks | 32 | # symlinks |
32 | elif [[ $1 == "mksymlinks" ]];then | 33 | elif [[ $1 == "mksymlinks" ]];then |
33 | tlobsd-mksymlinks $2 | 34 | tlobsd-mksymlinks $2 |
35 | # getbiber | ||
36 | elif [[ $1 == "getbiber" ]];then | ||
37 | tlobsd-getbiber | ||
34 | # version | 38 | # version |
35 | elif [[ $1 == "version" ]];then | 39 | elif [[ $1 == "version" ]];then |
36 | TL_RELEASE=$(tlmgr version | awk 'FNR == 3 { print $0 }') | 40 | TL_RELEASE=$(tlmgr version | awk 'FNR == 3 { print $0 }') |
diff --git a/tlobsd-getbiber b/tlobsd-getbiber new file mode 100644 index 0000000..e5a7944 --- /dev/null +++ b/tlobsd-getbiber | |||
@@ -0,0 +1,77 @@ | |||
1 | #!/bin/sh | ||
2 | # | ||
3 | # $TeX Live for OpenBSD, 2024/06/08 $ | ||
4 | |||
5 | TLBINDIR=$(dirname $0) | ||
6 | BINREPO=https://www.ekdosis.org/texlive | ||
7 | TMPDIR=$(mktemp -d) | ||
8 | OPENBSD_VERSION=$(sysctl -n kern.version | awk 'FNR == 1 { print $2 }' | sed 's/\.//') | ||
9 | UPDATING=$(curl -s ${BINREPO}/status.txt | grep updating= | sed 's/.*=//') | ||
10 | |||
11 | if [[ ! -w ${TLBINDIR} ]]; then | ||
12 | echo "You do not have write permissions to ${TLBINDIR}" | ||
13 | exit 1 | ||
14 | fi | ||
15 | |||
16 | if [[ ${tlobsd} -ne 1 ]];then | ||
17 | echo "Please use 'tlobsd getbiber' instead of this command." | ||
18 | exit 1 | ||
19 | fi | ||
20 | |||
21 | |||
22 | if [[ ${UPDATING} == "yes" ]];then | ||
23 | echo "The binaries are being updated. Please re-run this command later." | ||
24 | else | ||
25 | curl ${BINREPO}/biber-openbsd${OPENBSD_VERSION}.xz \ | ||
26 | -o ${TMPDIR}/biber-openbsd${OPENBSD_VERSION}.xz | ||
27 | curl ${BINREPO}/biber-openbsd${OPENBSD_VERSION}.xz.asc \ | ||
28 | -o ${TMPDIR}/biber-openbsd${OPENBSD_VERSION}.xz.asc | ||
29 | gpg --verify ${TMPDIR}/biber-openbsd${OPENBSD_VERSION}.xz.asc | ||
30 | if [[ $? -eq 0 ]];then | ||
31 | unxz ${TMPDIR}/biber-openbsd${OPENBSD_VERSION}.xz | ||
32 | cp ${TMPDIR}/biber-openbsd${OPENBSD_VERSION} ${TLBINDIR}/biber | ||
33 | chmod +x ${TLBINDIR}/biber | ||
34 | echo "Installation complete." | ||
35 | else | ||
36 | echo "" | ||
37 | echo "The signature could not be verified." | ||
38 | echo " Please import the public key used to sign biber-openbsd${OPENBSD_VERSION}.xz" | ||
39 | echo " as described on the TeX Live for OpenBSD web page, or verify this file from" | ||
40 | echo " the user account that was used to install TeX Live for OpenBSD. (Assumably," | ||
41 | echo " this user has already imported the public key into his keyring. Any user" | ||
42 | echo " whose keyring contains the public key of TeX Live for OpenBSD can be used.)" | ||
43 | echo "" | ||
44 | echo " The file to be verified can be found here: ${TMPDIR}/biber-openbsd${OPENBSD_VERSION}.xz." | ||
45 | echo "" | ||
46 | echo " Would you like me to attempt to verify the file from an account that has" | ||
47 | echo " the public key in its keyring?" | ||
48 | echo "" | ||
49 | read whattodo?"[Y]es/[C]ontinue without verifying/[A]bort installation) [Y]: " | ||
50 | [[ "${whattodo}" == '' ]] && whattodo=y | ||
51 | case $whattodo in | ||
52 | [yY] ) | ||
53 | read username?"Enter any user name whose keyring contains the public key of TeX Live for OpenBSD: " | ||
54 | chmod 755 ${TMPDIR} | ||
55 | doas -u ${username} gpg --verify ${TMPDIR}/biber-openbsd${OPENBSD_VERSION}.xz.asc | ||
56 | if [[ $? -eq 0 ]];then | ||
57 | unxz ${TMPDIR}/biber-openbsd${OPENBSD_VERSION}.xz | ||
58 | cp ${TMPDIR}/biber-openbsd${OPENBSD_VERSION} ${TLBINDIR}/biber | ||
59 | chmod +x ${TLBINDIR}/biber | ||
60 | echo "Installation complete." | ||
61 | else | ||
62 | exit 1 | ||
63 | fi | ||
64 | ;; | ||
65 | [cC] ) | ||
66 | unxz ${TMPDIR}/biber-openbsd${OPENBSD_VERSION}.xz | ||
67 | cp ${TMPDIR}/biber-openbsd${OPENBSD_VERSION} ${TLBINDIR}/biber | ||
68 | chmod +x ${TLBINDIR}/biber | ||
69 | echo "Installation complete." | ||
70 | ;; | ||
71 | * ) | ||
72 | echo "Aborting..." | ||
73 | exit 1 | ||
74 | ;; | ||
75 | esac | ||
76 | fi | ||
77 | fi | ||