[TUHS] 1bsd compatible ar utility

Clem Cole via TUHS tuhs at tuhs.org
Thu Jul 23 11:16:11 AEST 2026


Will,

The issue is you are skipping a few steps as it turns out.  BSD (a.k.a.
What we call 1BSD) probably cannt be installed on virgin V6 distribution.
By the time it was released there were two important V6 updates in the wild
that most likely of us (like Joy at UCB did) had already installed.  The
most important is the 50 fixes from Ken.    That is likely to get the
kernel itself closer to what Bill was running (remember Jen had already
done is sabbatical at UCB so all of those were there).   The second is the
first USENIX tape, often called the Harvard tape.  That will have a number
of utilities such as the updated ar and two new versions of tp (the C
rewrite from assembled and super tp - stp - which already started to become
the standard as it had some more graceful error support such as a second
copy of it directory at the end of tape).  Note to use tp (or v6tar which
Bill gives you a binary) you’ll need an updated tape driver.  All of that
in on the Harvard tape - but I’ve forgotten exactly where.

The other issue is the compiler.  Dennis has updated C and released his
replacement for Lesk’s portable C library with his new I/O library libS.a.
This compiler was bundled with the troff kit, as is often referred to as
“Typesetter C.”  It is also compiler Dennis and Brian are discussing in
K&R1.  Sadly we can’t seem to find a copy of that distribution but we have
mostly reconstructed much of it from other systems.

That compiler plus some other additions, ended up in V7 and libS.a was
folded into libc.a.

We had that compiler at CMU by 1976/77 timeframe, and I’m fairly sure UCB
had it also.  As I said it’s the compiler from K&R1 and a lot of sites (I
would suspect that most of the core USENIX sites outside of the Bell System
were using it, so Bill expecting it he there was really not surprising.


Talk to me offline and I can try help you with much of your stumbles. I
have gotten much of the original BSD tape to work.   FWIW Noel Chiappa’s
MIT V6++ system is probably the most comfortable V6 I’ve seen,  as it has
most things you might expect.    It has pretty much all the major upgrades
the we all tried to add to our V6 system. Im not 100% sure, but I would be
surprised if he don’t have Dennis compiler.  If might also want to you look
at
https://www.tuhs.org/Archive/Distributions/Research/Tim_Shoppa_v6/README Tim
Shoppa V6 system from UBC is also fairly complete.

Clem


Sent from a handheld expect more typos than usual

On Wed, Jul 22, 2026 at 7:17 PM Will Senn via TUHS <tuhs at tuhs.org> wrote:

>
> On 7/22/26 3:34 PM, Will Senn wrote:
> >
> > On 7/22/26 2:56 PM, segaloco via TUHS wrote:
> >> On Wednesday, July 22nd, 2026 at 12:20, Will Senn via TUHS<
> tuhs at tuhs.org> wrote:
> >>
> >>> Hi All,
> >>>
> >>> I am working through a 1BSD installation on Research Unix V6.
> >>> The||cont.a archives use magic |0177545|, which stock V6 ar does not
> >>> understand. V7 appears to be able to, but on V6 it immediately dies
> with
> >>> |Bad system call|. Inspection shows references to later calls including
> >>> |access|and |ioctl|, so it appears to have been linked against a
> post-V6
> >>> libc. I came across some old emails talking about this and an nar
> >>> utility... Does anyone know where the source for this |nar|utility
> >>> lives, or of a V6-native |ar|that supports |0177545|archives?
> >>>
> >>> newoldar on the host works fine, too, but I'd rather not extract on the
> >>> host. I'm hoping to do this native. I'm working with a pristine v6
> >>> installed from tape on pdp 11/70 with split I/D and FPP (opensimh).
> >>>
> >>> 1BSD doesn't include an ar utility in the tarball on TUHS. Did folks
> not
> >>> do this from pure v6? or what?
> >>>
> >>> Thanks,
> >>>
> >>> Will
> >>>
> >> Both USG PG3 and PWB1 have copies of ar(I) featuring the NARMAG value
> of 0177545, they may prove useful.
> >>
> >> https://www.tuhs.org/cgi-bin/utree.pl?file=USG_PG3/usr/source/cmd1/ar.c
> >> https://www.tuhs.org/cgi-bin/utree.pl?file=PWB1/sys/source/s1/ar.c
> >>
> >> - Matt G.
> >
> > Thanks, Matt,
> >
> > I pulled the PWB1 |ar.c|, made a few small changes for stock V6
> > compatibility (just enough for t and x support), and compiled it
> > natively under V6. The resulting binary successfully lists and
> > extracts the |0177545|1BSD archives.
> >
> > So the archive problem is "solved". Much appreciated.
> >
> > Will
> >
>
> The archive problem got solved, but I don't think 1bsd is truly meant
> for a pristine v6 from tape. ex, apparently requires a v7 cc, and ashell
> core dumps on syscalls that don't exist in v6:
> ./ashell
> Bad system call -- Core dumped
>
> READ_ME (for ashell):
>
> cat READ_ME
> Wed Oct 19, 1977
>
> This directory contains the source for a shell.
> It requires floating point to do the time command which is built-in
> so you will have to cc it -f on machines without floating point.
> It also requires a version 7 C compiler.
>
> Accurate documentation is in the file "sh.6" to be nroffed with
> /usr/man/man0/naa and a new "version 7" nroff.
>
> This shell requires the "htmp" data base also used by the editor "ex".
> If you do not set it up so that the "sethome" command is done by "login"
> then you should use the old "osethome" routine in ../s6 rather than
> "sethome"
> and reenable the execl of this sethome in the file "sh.c" (with the correct
> pathname).
>
>                                  Bill Joy
>                                  CS Division
>                                  Department of EE and CS
>                                  UC Berkeley
>                                  Berkeley, California  94704
>
>                                  (415) 524-4510          [HOME]
>                                  (415) 642-4948          [SCHOOL]
>
> Some of the utilities work fine:
>
> # ./version
> char    version[] "October 10, 1975";
> # ./version | ./wc
>        1       5      35
>
> but as I'm really just trying (again, but with more knowledge than
> before and an AI assist to boot) to recreate the experience of doing
> this the hard way, I want to get ashell working, pascal, ex, trek, etc.
> Any hints or tips on getting the correct starting evirons set up
> appreciated.
>
> Will
>


More information about the TUHS mailing list