diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2022-07-21 07:13:21 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2022-07-21 07:13:21 -0700 |
commit | 35a0332d1dcf2dbd743e5a24cc6f7d2b15fb8b8c (patch) | |
tree | 03892007f5955361413aea32fea2ca7bacf66de3 /txr.c | |
parent | 14cb5835e5ecb14be8ecc6ac2a6811e4bb143354 (diff) | |
download | txr-35a0332d1dcf2dbd743e5a24cc6f7d2b15fb8b8c.tar.gz txr-35a0332d1dcf2dbd743e5a24cc6f7d2b15fb8b8c.tar.bz2 txr-35a0332d1dcf2dbd743e5a24cc6f7d2b15fb8b8c.zip |
Install a txrlisp hard link.
* Makefile (LN): New variable. On platforms where
you can't hard link, this can be replaced with some
other command. Possibly "true" not to have the alternative
executable name created at all.
(HARDLINK): New macro.
(install): Use HARDLINK to create a link named txrlisp
pointing to the same file as txr in the destination
directory.
* txr.c (txr_main): If the executable ends with "lisp"
(or "lisp.exe" on Windows), then default the txr_lisp_p
variable to t, which has the effect as if --lisp had
been processed.
* txr.1: Documented.
Diffstat (limited to 'txr.c')
-rw-r--r-- | txr.c | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -587,6 +587,11 @@ int txr_main(int argc, char **argv) static char alt_args_buf[128 + 7] = "@(txr):", *alt_args = alt_args_buf + 7; + if (ends_with(lit("lisp" EXE_SUFF), prog_path, nil, nil)) + txr_lisp_p = t; + else if (ends_with(lit("vm" EXE_SUFF), prog_path, nil, nil)) + txr_lisp_p = chr('o'); + setvbuf(stderr, 0, _IOLBF, 0); if (compat_val && length(compat_val) != zero) { |