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

147 Commits

Author SHA1 Message Date
Bruce Mitchener
ae6c1dbd6a
make: Use builtin macro $(RM) rather than /bin/rm. (#311) 2021-01-28 18:16:23 +00:00
Bruce Mitchener
40d91f0afb
make: Fix LDFLAGS ordering to fix cygwin build. (#313)
Cygwin has a linker that requires the libs to come last.

Closes Interlisp/medley#170.
2021-01-28 06:30:16 +00:00
Nick Briggs
f7113d53ee
Remove provision for offline assembler peephole optimizations on SunOS3/4 (#304)
We no longer need to run a separate peephole optimization pass over the
compiler generated or hand-coded assembler for SunOS3 and SunOS4 on 68K or SPARC

We remove the preprocessor symbols and code controlled by them
	SUN4_OS4_IL
	SUN3_OS3_IL
	SUN3_OS4_IL
and	SUN3_OS3_OR_OS4_IL
2021-01-26 16:44:40 -08:00
Bruce Mitchener
eba664771a
Fix tty.c to compile. (#180)
This removes a bit of the debug info printing, but other than
that, is pretty close to what it was before.

We also now build it in both the make and cmake build systems.
2021-01-26 17:42:17 +00:00
Nick Briggs
d8257e7659
make makefile-tail cleanup target remove everything (#303) 2021-01-26 16:25:28 +00:00
Nick Briggs
9ca86a662f
Remove the check_unix_password functionality from uutils.c (#297)
This code has not worked for a long time.  Most systems now maintain
the password entries so that a password is not accessible through the
getpwent() interface.  The SUBR that calls this interface may be
removed at a future time.
2021-01-25 21:53:36 -08:00
Bruce Mitchener
987c38b465
Build .o files for executables separately. (#296)
We need to build `.o` files for the executables separately from
their link step. This lets us have the `CFLAGS` only get used
by the compilation step and not the link step (which uses
`LDFLAGS` or a variant).

This is a prerequisite for doing automatic dependency tracking.
2021-01-25 09:52:53 -08:00
Bruce Mitchener
07aed60cc7
Remove bbtsub.h, duplicate of bbtsubdefs.h. (#294)
`bbtsubdefs.h` and `bbtsub.h` were close to the same. We only
need one.
2021-01-24 23:22:28 -08:00
Bruce Mitchener
d4cbb6c9dc
Don't enable NOPIXRECT when XWINDOW is defined. (#287)
This used to be required, but has been fixed now.
2021-01-24 18:20:13 -08:00
Bruce Mitchener
04b4b64b87
Remove optck (#286)
This was for checking for a bug in old versions of the SunOS
tools and is no longer relevant.
2021-01-24 18:14:11 -08:00
Bruce Mitchener
95e406ba2e
Remove extra DOS build files. (#285)
None of these work and we currently have no path towards
compiling for DOS that would use any of them.
2021-01-24 17:55:30 -08:00
Bruce Mitchener
2e9776edf2
Remove OLD_CURSOR from our builds. (#284)
This is no longer used under X11, which all of our builds are using.

Closes Interlisp/medley#84.
2021-01-24 17:53:06 -08:00
Bruce Mitchener
db21b00a9f
Make sure OLD_CURSOR code is only for SUNDISPLAY. (#279)
This is work in progress on Interlisp/medley#84.
2021-01-24 16:58:18 -08:00
Bruce Mitchener
ab28391c18
Remove -fwrapv compiler flag. (#278)
This was making sure that the overflow in some our opcode
implementations was visible to the C code so that overflow
detection would work in gcc and clang.

This is now handled on those compilers by using some built-ins
that detect overflow.

The `-fwrapv` should no longer be needed.

Closes Interlisp/medley#90.
2021-01-24 16:55:51 -08:00
Bruce Mitchener
cc060be1c7
Remove assembly fn call optimizations. (#276)
These were for old platforms and not used in recent history.

There's no NOASMFNCALL flag as there's no more asm fn call code.
2021-01-24 16:39:32 -08:00
Bruce Mitchener
23a244a0fa
Remove some unused variables from makefiles. (#275)
Removed are:

* `FPFLAGS`
* `INLINE`
* `INLINEFLAGS`
* `BITBLTFILE`
* `BYTESWAPFILES`

A couple of other minor cleanups were also included.
2021-01-24 04:23:02 +00:00
Bruce Mitchener
9e9f8c4475
Remove profile.h (#272)
This no longer had anything to do with profiling and was
only doing some defines for the switch case block addresses,
which we no longer need since there's no longer optional
asm generated for them.
2021-01-23 18:39:55 +00:00
Bruce Mitchener
85e8cb21ec
Remove special rules for building xc.c. (#273)
This also removes the special `DISP*` flags that were used for
building some files, including `xc.c`.
2021-01-23 18:29:37 +00:00
Bruce Mitchener
b7e9529322
Begin to modernize optimized dispatch. (#271)
This feature was controlled by the compilation flag `OPDISP`
which would enable some bits of assembler on the x86 (ISC or DOS)
or some other specialized code on SPARC. On SPARC hardware, there
was a special compilation process that would preprocess the code
and generate dispatch tables.

We do this now when this feature is enabled using gcc's computed
gotos feature. This is available in clang and some other compilers.
Notably, it isn't present in Visual Studio.

This doesn't decrease our portability at all as this feature is
optional and it replaces specialized assembler code with C using
compiler extensions (making it cross-platform).

In doing this, we've removed a bunch of related code, however,
it is likely that other pieces yet remain and will be removed
in subsequent commits as we clean things up and refine them.

This feature remains disabled by default for now.
2021-01-22 12:28:16 -08:00
Bruce Mitchener
3b25bc27ee
build: Don't run ls -l when building ldeether. (#268)
Perhaps this was there as a reminder about it needing to be
`setuid`, but it shouldn't be in the default build output.
2021-01-21 13:20:17 -08:00
Bruce Mitchener
bf15105d3c
Remove 'release' support from makeright. (#265)
This is the old way that releases were built and isn't relevant
today. It made a variety of assumptions about how things were
linked and allowed for the user to re-link an executable, but
that isn't something we need to do any longer.

This doesn't yet remove the checksum, ldechecksum, and related
scripts.
2021-01-21 13:03:11 -08:00
Bruce Mitchener
421685bd49
Remove find-writes and fixid. (#264) 2021-01-20 23:43:26 -08:00
Bruce Mitchener
979c3ad6be
Remove flags for LINUX, OPENBSD, FREEBSD, MACOSX from build system. (#261)
We now can handle these via `inc/maiko/platform.h` and the
constants defined there.

This doesn't change `OS5` for Solaris yet as that's a much wider
set of changes.
2021-01-20 23:38:15 -08:00
Bruce Mitchener
164b5651b7
Remove obsolete testdsp. (#235)
This was an old executable from the SUNDISPLAY days and is not
needed any longer.
2021-01-20 18:34:45 -08:00
Bruce Mitchener
45d67305e7
Remove ANSICC and related variables. (#257)
In the SunOS 4 days, the system cc apparently couldn't compile
the lp* files, so there was an arrangement to use an `ANSICC`,
which was just `gcc`, to build those files.

We no longer have this issue.
2021-01-20 09:43:46 -08:00
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