Please consider a donation to the Higher Intellect project. See https://preterhuman.net/donate.php or the Donate to Higher Intellect page for more info.

Newbie Guide To A/UX (Apple UNIX): Difference between revisions

From Higher Intellect Vintage Wiki
Line 63: Line 63:
==Compiling A/UX Software==
==Compiling A/UX Software==
===Installing GCC===
===Installing GCC===
Since this is a newbie guide, this will only discuss GCC 2.7.2 from the old jagubox server as it is packaged specifically for A/UX. Download the archive ftp://ftp.atlas.altexxa.net/software/mac/unix/gcc-2.7.2.bin.tar.gz to your workstation and extract it. As root, execute the "install-gcc-aux" script. On my system this only worked properly the second time around... On my Quadra 700 the install script took more than 20 minutes or so. If it doesn't take this long on your system, it probably didn't finish properly so re-run it. As mentioned earlier on this page, you'll probably need to update your user profile PATH attributes for /usr/include/Gnu.
Since this is a newbie guide, this will only discuss GCC 2.7.2 from the old jagubox server as it is packaged specifically for A/UX. Download the archive ftp://ftp.atlas.altexxa.net/software/mac/unix/gcc-2.7.2.bin.tar.gz to your workstation and extract it. As root, execute the "install-gcc-aux" script. On my system this only worked properly the second time around... On my Quadra 700 the install script took more than 20 minutes or so. If it doesn't take this long on your system, it probably didn't finish properly so re-run it. As mentioned earlier on this page, you'll probably need to update your user profile PATH attributes for /usr/local/Gnu.


===Compiler Options===
===Compiler Options===

Revision as of 17:18, 26 March 2019

This will be a compilation of information designed to help first time A/UX users, or anyone not fully familiar with the workings of UNIX, to get A/UX (Apple UNIX) installed and configured.

Installation

Configuration

Customization

Using bash shell

You can obtain a compiled binary of the bash shell (also includes info for compiling yourself) from a jagubox mirror (http://polysoft.fr/jagubox/AA.new_files/bash-aux.bin.tar.gz). Place the binary in /bin, perform a "chmod 755", perform a "chown bin", edit the /etc/shells file to include the path /bin/bash as a known shell. Edit the /etc/passwd file and change your desired user account line to use /bin/bash as the shell (instead of /bin/csh for example). Establish a new shell connection and you should be dropped into the bash shell.

User shell profile tweaks

The two changes I wanted to make to my shell profile include adding /usr/local/Gnu (used by the gcc package from jagubox) plus /lib to the path config and also tweaking my shell prompt to be a little more Linux-like. In my case I simply used the Mac side text editor to open the ".profile" file in my A/UX user directory and add to the PATH line. Below is what I've used for my shell prompt.

# OLD
# PS1="`hostname`.$LOGNAME $prmp"
# NEW
PS1="[$LOGNAME@`hostname`]:\w $prmp"

(the above config produces the below prompt with the bash shell)
[netfreak@apollo]:/usr/bin $

Compatible additions to Mac system folder

The "Mac" side of A/UX only went as high as system version 7.0.1. You cannot upgrade this, but you can add elements from other system versions or third party extensions to make the Mac side of things more convenient. Here's a few things you may find convenient to add to your A/UX user's system folder:

  • WindowShade - this control panel from System 7.5 allows you to collapse Mac windows via title bar and appears to work fine
  • DOS Mounter 95 - supports the use of DOS formatted disks as this was not included with the Mac system software until around System 7.5
  • Apple Menu Options - this control panel from System 7.5 allows you to expand a directory tree via the Apple menu for convenient menu browsing
  • Moire v3.0 - popular Macintosh screensaver which seems to work without any issue

Helpful Commands

Uncompress a .Z archive

The stock A/UX install doesn't include gzip/gunzip and tar will not extract Z files. A number of the A/UX files online such as via jagubox mirror will be in .gz format, so here is how you would extract the gzip archive (http://polysoft.fr/jagubox/Utilities/gzip-124.bin.tar.Z) using zcat and tar:

# zcat gzip-124.bin.tar.Z | tar -xvf -
x gunzip, 52780 bytes, 104 tape blocks
x gunzip.1.Z, 8187 bytes, 16 tape blocks
x gzexe, 3858 bytes, 8 tape blocks
x gzexe.1.Z, 1050 bytes, 3 tape blocks
gzip linked to gunzip
gzip.1.Z linked to gunzip.1.Z
zcat linked to gunzip
zcat.1.Z linked to gunzip.1.Z
x zcmp, 2006 bytes, 4 tape blocks
x zcmp.1.Z, 679 bytes, 2 tape blocks
zdiff linked to zcmp
zdiff.1.Z linked to zcmp.1.Z
x zforce, 1010 bytes, 2 tape blocks
x zforce.1.Z, 565 bytes, 2 tape blocks
x zgrep, 1339 bytes, 3 tape blocks
x zgrep.1.Z, 805 bytes, 2 tape blocks
x zmore, 1074 bytes, 3 tape blocks
x zmore.1.Z, 2708 bytes, 6 tape blocks
x znew, 3508 bytes, 7 tape blocks
x znew.1.Z, 833 bytes, 2 tape blocks

Uncompress a .gz archive

First do the above process for extracting the gzip binary downloaded from a jagubox mirror. Copy the binaries such as gzip/gunzip to a convenient path such as /usr/bin. Any user should now be able to uncompress .gz archives:

# gunzip telnet-aux.tar.gz

Compiling A/UX Software

Installing GCC

Since this is a newbie guide, this will only discuss GCC 2.7.2 from the old jagubox server as it is packaged specifically for A/UX. Download the archive ftp://ftp.atlas.altexxa.net/software/mac/unix/gcc-2.7.2.bin.tar.gz to your workstation and extract it. As root, execute the "install-gcc-aux" script. On my system this only worked properly the second time around... On my Quadra 700 the install script took more than 20 minutes or so. If it doesn't take this long on your system, it probably didn't finish properly so re-run it. As mentioned earlier on this page, you'll probably need to update your user profile PATH attributes for /usr/local/Gnu.

Compiler Options

(from http://www.nleymann.de/appleAUX/) Make sure that the "-g" option is switched off. The debugging options produces objects files which are 10-100 times bigger than the optimized versions. This will usually result in an "out of memory" message from the linker. "-g" is the standard option used by the gnu configure scripts! Use something like 'CFLAGS="-O" ./configure <other options>'

/bin/sh vs. /bin/ksh

(from http://www.nleymann.de/appleAUX/) The standard /bin/sh which comes with A/UX is broken and causes the confiure scripts to terminate. As a simple workaround replace /bin/sh with /bin/ksh in the configure scripts.