1
0
mirror of https://github.com/Interlisp/maiko.git synced 2026-01-11 23:43:19 +00:00

222 Commits

Author SHA1 Message Date
Bruce Mitchener
85fa89ba88
Remove key checking code. (#251)
This wasn't actually hooked up any more, so it was pretty much
all dead code. The handling of this in the command line options
is gone.

In `bin/makefile-tail`, `DEVFILES` and `LIBFILES` became identical, so
`DEVFILES` went away.
2021-01-19 23:47:55 -08:00
Bruce Mitchener
d99209916a
Remove bin/launch.asm. (#249)
This was a copy of `src/launch.asm`. Part of the DOS build process
made a copy, but that isn't something that needs to be in version
control.
2021-01-20 06:10:11 +00:00
Bruce Mitchener
f4c2f872a1
Remove bin/runlisp* (#250)
These are from when people were running lde on a small set of hosts
and needed some keys hardcoded. They are no longer relevant.
2021-01-20 06:07:45 +00:00
Bruce Mitchener
c51aff7bf3
Remove endiffix relics. (#248)
This isn't something we need around or even have the full source
for. It is a SPARC binary and a lexer script.
2021-01-19 21:45:43 -08:00
Bruce Mitchener
e63c53cc06
Move SunOS 3 and 4 makefiles to legacy directory. (#245)
We don't remove them for now as we still reference the build
options as we work through things.
2021-01-19 21:27:22 -08:00
Bruce Mitchener
3318e75f7a
Remove csh version of makeright. (#246)
In 2001, makeright was ported from csh to bash. This is the old
csh version.
2021-01-19 21:26:09 -08:00
Bruce Mitchener
0a057dec6b
Delete code related to NATIVETRAN feature. (#232)
* Delete code related to NATIVETRAN feature.

This was obsolete work that had been done for generating
native code from the bytecode.

Closes Interlisp/medley#89.

* Remove unused SaveD6.
2021-01-19 17:57:53 -08:00
Bruce Mitchener
db6b351397
Remove FORKCOMM define. (#238)
This code path was followed everywhere except DOS, so remove
it from the build system, and adjust the code.
2021-01-18 22:12:41 -08:00
Nick Briggs
2bb5854303
Remove -funsigned-char from standard compilation options (Issue Interlisp/medley#152) (#229)
Add standardized options for Oracle Developer Studio C compiler (aka SunPro C)

Using -funsigned-char causes the Oracle Developer Studio C compiler typedefs for
int8_t to become unsigned (uint8_t) rather than signed, with no warning or
other indication that this has happened.
2021-01-15 19:47:06 -08:00
Bruce Mitchener
19329883d5
Add missing foreigndefs.h, includes to foreign.c. (#214) 2021-01-12 17:14:19 -08:00
Bruce Mitchener
c7314dcb31
Remove -DLINUX from Cygwin makefile. (#213)
This might have been necessary before where we had bits of code
that were still `#ifdef LINUX`, but that's mostly gone now, so
this should no longer be required.
2021-01-12 17:46:48 +00:00
Bruce Mitchener
5cb18c0710
Merge hacks.c into foreign.c. (#212)
This code was not really valid ANSI C in the way that it was
used, and it was only used by foreign.c, which is #ifdef'd out.
2021-01-11 22:45:49 -08:00
Bruce Mitchener
5a8f20c0ca
Default NOFORN to defined. (#209)
The NOFORN flag controls foreign function interface code, which
was written using the dld_* APIs which haven't existed in years.

There was a GNU dld that provided this API, but it was withdrawn
in 2006.

If this code is to be re-enabled, it will have to be changed to
use the `dlopen` family of APIs.
2021-01-11 18:17:42 -08:00
Alex Segura
68d7908ee6
Support building on OpenBSD, x86-64 (#207)
* Support building on OpenBSD, x86-64

* Clean up OpenBSD Makefile

* Add OpenBSD to cmake build

* Use clang as CC for OpenBSD

Co-authored-by: Alex Segura <alex@lispm.dev>
2021-01-11 17:10:57 -08:00
Bruce Mitchener
fa13cc964c
Switch to compiling as ISO C99 + GNU extensions. (#203)
We currently build for ISO C90 with GNU extensions. The GNU
extensions include both library and language features.
Compiling without GNU extensions results in a number of compilation
failures due to use of those library features.

With this, we'll build for ISO C99 with the GNU extensions and
can evaluate what's going on with those library features in the
future.
2021-01-10 20:47:55 -08:00
Bruce Mitchener
19033bba89
Remove extra flags for gcc on some platforms. (#202)
On Linux x86 and x86_64 as well as Cygwin, we were adding some
flags to the (commented out) usage of gcc. These shouldn't be
here.
2021-01-10 17:24:42 -08:00
Bruce Mitchener
2b5f8eae1c
Remove sysatms.h/c (#201)
The C file was empty, and the H file only had unused constants
in it.
2021-01-10 17:23:32 -08:00
Bruce Mitchener
b45e249a08
Remove mention of TRASE. (#197)
This macro no longer exists and one message had it as a typo.
2021-01-09 10:17:03 -08:00
Bruce Mitchener
16c6b8f7c3
Fix typos. (#196) 2021-01-08 21:42:11 -08:00
Bruce Mitchener
2dcdf14334
Migrate to POSIX signals. (#190)
This removes SYSVSIGNALS as we're always and only using POSIX
signals now.

Some platform differences have been papered over. We used to
only ignore SIGPIPE when using BSD signals, but we now ignore
it all the time.

While the SIGFPE code will now compile, it hasn't been updated
to work on modern OSes fully yet as it will need to enable
the correct FP exceptions.
2021-01-09 04:55:39 +00:00
Bruce Mitchener
a1e0e750d4
Remove F_SETSIG (#164)
* Remove F_SETSIG call from Linux on X11 display.

Presumably, this was added to be like the `I_SETSIG` call on Solaris.
But it is the only `F_SETSIG` done on Linux and there isn't an
equivalent on the other platforms that we support as it is a GNU
extension.

Also, `F_SETSIG` with an argument of `0`, as here, means to send
the `SIGIO` signal, which is what is done by default.

From the man page:

    F_SETSIG (int)

    Set the signal sent when input or output becomes possible
    to the value given in arg. A value of zero means to send
    the default SIGIO signal. Any other value (including SIGIO)
    is the signal to send instead, and in this case additional
    info is available to the signal handler if installed with
    SA_SIGINFO.

    By using F_SETSIG with a nonzero value, and setting
    SA_SIGINFO for the signal handler (see sigaction(2)),
    extra information about I/O events is passed to the
    handler in a siginfo_t structure. If the si_code field
    indicates the source is SI_SIGIO, the si_fd field gives
    the file descriptor associated with the event. Otherwise,
    there is no indication which file descriptors are
    pending, and you should use the usual mechanisms
    (select(2), poll(2), read(2) with O_NONBLOCK set etc.)
    to determine which file descriptors are available for I/O.

We aren't setting a non-zero value and we aren't establishing signal
handlers via `sigaction` with `SA_SIGINFO` set, so this shouldn't
be doing anything important for us.

* Stop setting _GNU_SOURCE for GNU libc extensions.

We were previously doing this to get access to the
`F_SETSIG` flag for `fcntl`, but this isn't being
used any longer.
2021-01-02 21:21:16 +00:00
Bruce Mitchener
848177aa95
The SYSVONLY flag is no longer used or needed. (#153)
Welcome to the world of being mostly POSIX!
2020-12-31 17:13:05 -08:00
Nick Briggs
d28334bd24
Fix makefile fragment for linux on arm (#147)
* Update comments describing configuration this makefile fragment supports.

* Remove extra compiler options for suggested gcc build

* Remove unnecessary -m32 option for suggested clang build

* switch default compiler from clang to gcc
2020-12-30 22:18:28 -08:00
Bruce Mitchener
f1647df8b1
Default to NOETHER, only enable on Solaris. (#149)
* Default to NOETHER, only enable on Solaris.

* DOS: NOETHER controlled by inc/version.h

We set NOETHER by default on DOS, so no need for it here in the
build system.
2020-12-31 01:33:58 +00:00
Bruce Mitchener
7a74d6e66f
Control VM config via RELEASE. (#136)
When `RELEASE` is set, then `inc/version.h` configures some
defines appropriately, including `BIGATOMS`, `BIGVM`, and
`NEWCDRCODING`. There's no need to manage it directly on
the compiler command line.
2020-12-30 14:32:31 -08:00
Bruce Mitchener
01926fc232
NEW_STORAGE is no longer new. (#135)
* Always follow NEW_STORAGE code paths.

This removes the code paths for the pre-NEW_STORAGE code.

* Remove NEW_STORAGE from build system.

The code no longer refers to `NEW_STORAGE`, so we can remove
this from the build system.
2020-12-28 10:10:43 -08:00
Bruce Mitchener
0880b2f3dd
Remove UNSAFE flag. (#134)
This flag was for SunOS 3 and 4 on sun3 hardware (68k).

It enabled some unsafe optimizations via assembler. This hasn't
actually been built since the DOS port (since the header for this
was renamed, but the code in `xc.c` wasn't updated).

The optimizations here made assumptions that were specific to the
68k hardware and register allocation. They aren't likely to be
of much use moving forward, and we've got plenty of safe performance
improvements from the last 30 years of hardware advances.
2020-12-26 20:53:47 +00:00
Larry Masinter
e452a97e22 setup for cygwin (compiles but crashes) 2020-12-24 01:55:27 +00:00
Larry Masinter
e801373222 X11 definitions moved for MacPorts X11 2020-12-23 11:01:10 -08:00
Larry Masinter
973db49422 Add a simple test.vm that runs opcode tests (fails on pi) 2020-12-22 12:39:17 -08:00
Bruce Mitchener
3246af571e
Remove dead entries from makefile-tail. (#114) 2020-12-21 22:17:46 -08:00
Bruce Mitchener
9a21f5339a
Remove XV11R4 and related defines. (#113)
We no longer have anything predicated upon the version of X11 that
we're using (and these versions are all ancient anyway).
2020-12-21 22:11:39 -08:00
Bruce Mitchener
37c410eb31
X*.h headers weren't cleaned up after renaming and merging. (#112)
* Check.h, Stipple.h, XCursors.h, XWaitCur.h, Xcursdef.h,
  Xdefcur.h, and Xicon.h were combined into xbitmaps.h.
* Xdisplay.h is not used and the contents are in MyWindow.h, which
  is used.
* XVersion.h and Xdeflt.h became xdefs.h. Remove 2 stragglers
  that were still including XVersion.h.
2020-12-21 19:13:30 -08:00
Nick Briggs
fc0ae89fcf
Update FreeBSD makefile to use clang and new standard for configuring options (#105) 2020-12-20 17:06:59 -08:00
Bruce Mitchener
41d28e01b5
Fix timer.c compilation on non-x86_64 GNU/Linux. (#104)
`timer.c` uses `F_SETSIG` which is a GNU extension. As such, it
needs `_GNU_SOURCE` to be defined, but this was only done for
x86_64, not the other Linux platforms that we have build system
support for.

Closes interlisp/medley#97.
2020-12-20 17:42:37 +00:00
Bruce Mitchener
810e33125b
Update how we configure gcc / clang command lines. (#103)
* Move clang/gcc options into makefile-header.

This puts all of the shared options into a single place so that
we can easily update it.

* Add -fwrapv to the clang/gcc command lines.

This is a step along the way to fixing interlisp/medley#90.

Enabling `-fwrapv` will let overflow checks that rely upon undefined
behavior to work correctly. Without this, with modern versions of
clang and gcc, the overflow checks in the C code are eliminated
by the compiler, resulting in incorrect behavior on the part of
Maiko.

See the linked bug for details and discussion.

Hopefully, this usage of `-fwrapv` will go away once we're using
the correct compiler builtins to detect and handle overflow
correctly.
2020-12-19 20:16:31 -08:00
Bruce Mitchener
942b22886e
Remove CLX support. (#90)
CLX is a Common Lisp implementation of the X client library.

It has some code in C, which was present here as `src/socket.c`
and `src/socdvr.c`, exposed via opcodes in `src/subr.c`. This code
had been removed (with prejudice apparently) by commenting out
the code in `src/subr.c` with `#if NEVER`.

This code would've been used by the Medley system images, but
that code doesn't appear to be present. (There may or may not
be something related in `XMAS` in the Medley repository.)
2020-12-19 19:59:41 -08:00
Bruce Mitchener
d4f72d96e1
Remove FSERROR define as it is always on. (#96)
The FSERROR define is on all the time now. It was not controlling
all of the functionality, with many places setting Lisp_errnno
outside of the code controlled by the define.
2020-12-17 09:33:20 -08:00
Bruce Mitchener
7a1abc9cc6
Remove commented out directives for SunOS4 dispatch loop hacks. (#84)
On SunOS4, we build `xc.c` by jumping through a lot of hoops to
perform a particular set of operations. We don't do that on other
platforms and this will help clean up the Linux and FreeBSD makefiles.

These directives were already not present in the macOS makefiles.
2020-12-16 11:03:40 -08:00
Bruce Mitchener
c728571c5f
Remove commented out CLXFLAGS from non-SunOS makefiles. (#83)
CLX was an alternate client library for X11, isn't really supported
by Maiko, and is unlikely to be in the future on these platforms.
2020-12-16 10:53:38 -08:00
Bruce Mitchener
5dd1b1bdac
SunOS5/SPARC and init.sparc now define FSERROR. (#86)
All other targets that we build were defining `FSERROR` except
these two.
2020-12-16 10:47:28 -08:00
Bruce Mitchener
6b590edafc
Update old makefiles for renaming of byteswapfns.c (#80)
This was renamed long ago for the DOS port, but not all of
the makefiles were updated.
2020-12-16 07:02:16 +00:00
Bruce Mitchener
847af10c0a
main.c has no dependency upon unixfork.h. (#79)
This avoids a bit of confusion, since unixfork.c isn't built into
the same executable as main.c. (It is part of `lde` instead.)
2020-12-16 05:52:42 +00:00
Nick Briggs
6a336a186e
macOS installation of XQuartz when SIP is enabled does not link /usr/X11 to /opt/X11 (#73) 2020-12-15 13:07:18 -08:00
Nick Briggs
8e66ec841f Add missing -DNEW_STORAGE to makefile-sunos5.sparc-x configuration. 2020-12-15 13:22:52 -05:00
Bruce Mitchener
8c617452f7
Remove __USE_BSD define that was copied from Linux. (#68)
This isn't / wasn't needed on FreeBSD.
2020-12-15 10:09:39 -08:00
Bruce Mitchener
4862e8bbb6
Remove -D__USE_BSD from Linux builds. (#67)
This is an internal macro to GNU libc and wasn't meant to be
defined like this. Well, it was. It was deprecated and removed
some years ago, so it isn't doing anything at all here now.
2020-12-15 10:06:15 -08:00
Bruce Mitchener
680e8485fe
Remove unused timeoday.c and timeofday.c files. (#62) 2020-12-15 08:09:04 -08:00
Bruce Mitchener
433a659063
Require termios on Unix. (#61)
Remove the USETERMIOS preprocessor definition as well.
2020-12-15 08:05:59 -08:00
Bruce Mitchener
fb7e88aba4
Remove makewrong, remnant from Sun3 days. (#53) 2020-12-14 20:38:09 -08:00