[comp.sys.sun] Sun-Spots Digest, v5n56

Sun-Spots-Request@RICE.EDU.UUCP (11/05/87)

SUN-SPOTS DIGEST         Tuesday, 3 November 1987      Volume 5 : Issue 56

Today's Topics:
                              Administrivia
        Sun User Group Conference & Exhibit -- December, San Jose
                Re: Generating Sun2 binaries on a Sun3 (3)
                         Re: Overloaded Ethernet
                           Re: troff previewers
                             Re: APL on Suns
                    System-Wide C Shell Initialization
             Disk controllers -- Rimfire versus Xylogics 451
                   uuencode problem: Permission denied.
                               Named pipes
                      Need to rent or lease Sun-3's
                      Need info on NeWS for the Mac
                        Information about Suntops?
                             fortran_editor?
                         varargs: bug or feature?

----------------------------------------------------------------------

Date:    Tue,  3 Nov 87 14:21:08 CST
From:    William LeFebvre <phil@Rice.edu>
Subject: Administrivia

I have gotten a little behind in generating digests.  As a result, there
is a large backlog of messages waiting to go out (on the order of 100K).
There are also one or two important press releases that should go out
soon.  I will do the best I can in the time I have.  Please forgive the
current lag time and also any oversized digests that might come your way
in the near future.  For those of you who have noticed that the archives
were lagging behind the digests, the archives are now up to date.

				William LeFebvre
				<phil@Rice.edu>

------------------------------

Date:    Thu, 23 Oct 86 13:15:52 PDT
From:    users@sun.com
Subject: Sun User Group Conference & Exhibit -- December, San Jose

The Sun User Group invites you to attend the Sun User Group 5th Annual
Technical Conference and Exhibit.  This is the largest gathering of Sun
workstations, Catalyst vendors, and Sun users in the WORLD.  With this
year's conference in Sun's "backyard", it will surely be our biggest and
best ever.  Join Sun users from around the globe to disseminate
information about Sun Workstations, Sun Products, and related software. 

  WHO - The Sun User Group (SUG), 
        The International Organization of Sun Users
 
 WHAT - Fifth Annual Technical Conference and Exhibit

 WHEN - December 7-9, 1987

WHERE - San Jose, CA (Fairmont Hotel)

  WHY - Exhibit:
 	  100 Sun Workstations and third-party "Catalyst" 
	  vendors demonstrating their most advanced products
	  for the Sun environment.

        Technical Conference:
	  Three days of Technical Workshops (presentations and
	  open discussions with Sun's top engineers), User and 
	  Vendor Application Talks, Special Interest Group 
          discussions covering today's most interesting 
          applications and topics, Sun factory tours, and 
          user donated software exchange (Sun specific public-
          domain software).
 	
        Registration fees include -   
	  Access to the exhibits and technical sessions, conference
	  material, breakfast snack and lunch (Monday, Dec. 7th & 
          Wednesday, Dec. 9th), two cocktail receptions, and Sun
	  factory tour.  We will also include a "free" SUG T-Shirt
	  to any attendee who registers by November 15th:

				SUG Member	Non-Member
				----------	----------
		 In advance:	  $175		   $250
		At-the-door:	  $250		   $350
		
		NOTE: Advance registration ends November 30th.  An 
                      individual membership in the Sun User Group
		      is ONLY $30.  We will accept the "SUG Member"
		      fee from a non-member if the $30 membership 
 		      fee is included.

You can register by email (sun!users) or call the Sun User Group
conference "hot-line" at (415)691-4112.  We accept VISA or MasterCard.

For attendee discounts on transportation arrangements and hotel
accomodations, call Kathy or J.R. at Hickory-TravelForum:

			Outside CA	(800)222-1035
			 Within CA	(408)749-9883

For additional information about Sun User Group membership, activities and
products - call (415)691-4343.  Thank you.

	Sanford "Sandy" Meltzer
	Executive Director, SUG

------------------------------

Date:    Fri, 23 Oct 87 18:18:14 EDT
From:    allegra!bill@ucbvax.berkeley.edu
Subject: Re: Generating Sun2 binaries on a Sun3 (1)

Didn't we figure this problem out several issues ago?  Anyway, I find the
following works very well.  I have a shell script called sun2cc that
contains the following line:

cc -m68010 -L/pub.MC68010 -L/usr.MC68010/lib $*

The reason this works is that ld searches the directories specified with
the -L option first, before the standard ones.  This is not made clear in
the cc manual page but is in the ld manual page.  This assumes that the
Sun-2 libraries are in the places specified after the -L options above, of
course.  The actual locations for these may vary.

-Bill Schell
 allegra!bill
 AT&T Bell Labs, Murray Hill, NJ

[[ Thanks also to these people who sent in similar suggestions:
Dan Trinkle <trinkle@purdue.edu>,
Richard Tobin <richard%aiva.edinburgh.ac.uk@nss.cs.ucl.ac.uk>,
John P. Nelson <decvax!genrad!jpn@ucbvax.berkeley.edu>.  John added the
following comment:  "Apparantly, cc still hard codes /lib/crt0.o, but it
appears that this is a sun2 object file, even on sun3 machines!"  --wnl ]]

------------------------------

Date:    Tue, 27 Oct 87 11:55:39 PST
From:    Fred Douglis <douglis%ginger.Berkeley.EDU@berkeley.edu>
Subject: Re: Generating Sun2 binaries on a Sun3 (2)

I noticed that issue 54 didn't have any more replies to the question about
68010 binaries, and the messages in issue 53 didn't really say much except
that cc/ld should be smarter.  The following is a message I sent to my
research group regarding a local version of "cc" that solves this problem:

    I have modified the sun version of cc to use different libraries if
    the -m68010 option is specified while running on a sun3.  The default
    runtime libraries will be taken from /usr/lib.10 instead of /lib or
    /usr/lib.  Since we don't have the source to ld, I couldn't change /ld
    to look in lib.10 for files specified by the "-l" option.  Instead, I
    wrote a shell script (/usr/lib.10/ld) that converts "-l" options as
    needed, then invokes /bin/ld.  It is called by cc only in the event
    that -m68010 is specified on a sun3, so the rest of the time no shell
    script will be run and ld will be as fast as usual.

The change to cc was possible because we have the cc driver (the one that
invokes cpp, ccom, ld, etc.).  I suppose that a cc shell script could do
the same thing: automatically change "-l..." arguments on the fly, but as
the previous message to sun-spots mentioned, that doesn't catch things
like "-g".  Any better suggestions?

- Fred -

------------------------------

Date:    31 Oct 87 23:39:03 GMT
From:    mcvax!daimi!pederch@uunet.uu.net (Peder Chr. N|rgaard)
Subject: Re: Generating Sun2 binaries on a Sun3 (3)

I realize this topic has been beaten a lot, but I have seen nothing like
this worksaver of mine for generating binaries for both a Sun2 and a Sun3
(on a Sun3 of course, that's much quicker!).

The really difficult thing is not "How To Do It" but "How To Make 'make'
Do It Without Too Much Typing". To Do It, mount the following:

sun2fs:/usr.MC68010             /usr.MC68010            nfs ro,bg    0 0
sun2fs:/pub.MC68010/lib         /lib.MC68010            nfs ro,bg    0 0

on newly created directories /usr.MC68010 and /lib.MC68010 on your Sun3.
(If your machine is a heterogeneous fileserver they are already there).

Then to generate a Sun2 binary call cc with the following arguments:

cc -mc68010 -Qoption cpp -I/usr.MC68010/include \
	-L/lib.MC68010 -L/usr.MC68010/lib -L/usr.MC68010/local/lib \
	<the other relevant arguments...>

When you have done this a few times you get tired of typing, especially
when it comes to typing:

make "CFLAGS=-mc68010...<other arguments>" "LDFLAGS=-L/lib.MC6810 ...<o.a.>" ..

What I do to save the typing is using the fact, that I have never seen
anybody redefining the CC macro of make. So I make one little program,
listed below, called cc_sun2, and call it this way:

make "CC=cc_sun2" <other arguments>

This I find an acceptable amount of typing! Of course it depends on your
makefile being nice, that is, not calling the compiler as "cc" but as
"$(CC)". Most makefiles I have seen do this, otherwise they are easy to
change.

An equally nice way to do it is to substitute the /bin/cc program with a
program that checks some environment variable and call the "real" cc with
those extra seven arguments if Sun2 binaries are requested.

Here is the program:
#include <stdio.h>

char *add_args[] = {
  "-mc68010",
  "-Qoption", "cpp", "-I/usr.MC68010/include",
  "-L/lib.MC68010", "-L/usr.MC68010/lib", "-L/usr.MC68010/local/lib"
  };

extern char **environ;
extern char *calloc();

main(argc,argv)
     int argc; char **argv;
{
  char **newargv;
  unsigned int newargc;
  int i;

  newargc = argc + sizeof(add_args)/sizeof(char *);
  newargv = (char **) calloc(newargc + 1, sizeof(char *));

  newargv[0] = "cc";
  for (i = 1; i <= sizeof(add_args)/sizeof(char *); i++)
    newargv[i] = add_args[i-1];
  for (argc--; argc > 0; argc--, i++)
    newargv[i] = *(++argv);
  newargv[i] = (char *) 0;

  execve("/bin/cc", newargv, environ);
}
End of program.

   Peder Chr. Norgaard
   Computer Science Department  phone:   +45 6 12 83 55   
   Aarhus University            telex:   64767 aausci dk  
   Ny Munkegade 116             e-mail:  pederch@daimi.dk 
   DK-8000 Aarhus C, DENMARK.            (..uunet!mcvax!diku!daimi!pederch)

------------------------------

Date:    25 Oct 87 15:41 EST
From:    stpeters%dawn.tcpip@ge-crd.arpa
Subject: Re: Overloaded Ethernet

> Set up a hierarchy of Ethernets using gateway machines.  Keep the diskless
> machines on very lightly loaded Ethernet trunks.  If you have a lot of
> Suns, put them in clusters and restrict NFS to machines within a cluster.
> Don't export *and* import NFS filesystems on the same machine.

This is a mixture of a little good advice, some bad advice, and some
unnecessary restrictions.  Do cluster diskless nodes, but instead of "a
hierarchy of Ethernets", set up a single hierarchical Ethernet.  Put each
cluster on an Ethernet segment and use *bridges*, not gateways, to connect
each segment to a main trunk.

The important thing is to confine *paging* (ND) traffic to a single
segment, but the emphasis on "very lightly loaded" is overdone.  Within a
cluster, the bottleneck is far more likely to be the ND server than the
network.

If you don't use gateways, there is no need at all to confine NFS to
machines within a cluster.  Nor is there any need not to both import and
export NFS filesystems on a given machine.  Do limit any server's imported
filesystems to be read-only, mounted 'soft'.  (Actually, not importing any
filesystems on a server could help limit its use for things other than
serving, a big performance plus, but it can be a pain for the server's
SA.)

Our 160 Suns share a single hierarchical Ethernet (about five segments
plus main trunk) with a like number of other machines, including many
mostly-diskless Symbolics Lisp Machines, with NFS cross-mounts all over.
My Sun mounts at least one filesystem from every segment, from Suns, an
Ultrix VAX, and a Lisp Machine.

Thanks to our network hardware elves, this all works well.

Dick St.Peters                        
GE Corporate R&D, Schenectady, NY
stpeters@ge-crd.arpa              
uunet!steinmetz!stpeters

------------------------------

Date:    Mon, 26 Oct 87 09:23:33 EST
From:    lj@spdcc.com (Len Jacobs)
Subject: Re: troff previewers

In response to the queries regarding troff previewers for Suns, no one
mentioned that Malcolm Slaney from Schlumerger Research in Palo Alto has
written a quite adequate public version for ditroff.  It uses vfonts and
seems to do the job quite well.

Apparently a copy is on purdue.edu and one should probably be placed at
rice.edu.  The previewer available from Elan seems quite similar but is
certainly more expensive!

Len Jacobs

------------------------------

Date:    Mon 26 Oct 87 06:44:07-PST
From:    Ivan Auger <LAWRENCE.Auger@bionet-20.arpa>
Subject: Re: APL on Suns

STSC sell's APL*PLUS UNX for Suns and other unix machines.  Although I
have not used the unix version, we have been very please with STSC's
APL*PLUS PC on IBM PC's.  The price depends on the particular
configuration.  STSC's phone number is: 800-592-0050 or 301-984-5123.
Their address is 2115 East Jefferson Street, Rockville, Maryland 20852.

Ivan Auger
NYS Dept. of Health
Albany, NY 12201

------------------------------

Date:    Sat, 24 Oct 87 14:36:34 EDT
From:    umix!itivax!lokkur!scs@rutgers.edu (Steve Simmons)
Subject: System-Wide C Shell Initialization

The Sun 3.0 C shell does not support a system-wide initialization file.
We wanted one, and hacked the 3.0 C shell to do it.  It works just fine;
and has made life a lot easier.  If you're interested, the diffs are at
the end of this posting.

So what's the problem?  We have only source to 3.0, and are beginning to
fall behind the times.  Among other things, we'd like to have the 3.2
filename completion feature.  Since the system-wide inits seem a very
useful feature and installations can disable it by simply not creating the
init files, we'd like to see it be a part of the standard Sun release. If
enough other folks think so and all of you ask Sun politely, it might not
be too late to get this into 4.0.  So please, pass on the request.

We should also point out that there are a number of other csh variants
which already have this feature, like (boo, hiss) Xenix.

Steve.

[[ The diffs are small enough.  --wnl ]]

	*	*	*     Diffs	*	*	*

The following diffs, applied to the 3.0 c shell, will create a new
version which looks for "/usr/cshrc" and "/usr/login" to execute
before ~/.cshrc and ~/.login, respectively.  This is rather analogous
to the way the Bourne shell uses /etc/profile before ~/.profile.
If you don't like the choice of file names, feel free to change them.

362a363,366
> 		srccat("/usr", "/cshrc",0);
> 		if (loginsh) {
> 			srccat("/usr", "/login",0);
> 		}
364c368
< 		srccat(value("home"), "/.cshrc");
---
> 		srccat(value("home"), "/.cshrc",1);
368c372
< 			srccat(value("home"), "/.login");
---
> 			srccat(value("home"), "/.login",1);
457c461
< srccat(cp, dp)
---
> srccat(cp, dp, local)
458a463
> 	bool local; /* true (1) if local sourcing */
468c473,476
< 	srcunit(unit, 1, 0);
---
> 	if (local)
> 		srcunit(unit, 1, 0);
> 	else /* global source from some public (hopefully secure) place */
> 		srcunit(unit, 0, 0);
621c629
< 			srccat(value("home"), "/.logout");
---
> 			srccat(value("home"), "/.logout",1);

	*	*	*  End of Diffs	*	*	*

Steve Simmons, Schlumberger/Applicon, Ann Arbor, MI.
...ihnp4!itivax!lokkur!scs

------------------------------

Date:    Mon, 26 Oct 87 11:10:39 EST
From:    Ned D. Danieley <ndd@cs.duke.edu>
Subject: Disk controllers -- Rimfire versus Xylogics 451

We have a Ciprico Rimfire controller and a super Eagle disk drive on
order. We would like to add these to our current network, and I'm trying
to decide what the best course of action is. We currently have one super
Eagle and Xylogics 451 controller in our 3/280, which also has a 6250 tape
drive. My options are:

1) put the rimfire and new disk in a 3/260 (also on order). this would
spread out the file serving load some, but would require backups of the
new disk to go over the net.

2) put the new stuff on the existing 280, possibly shuffling the file
system around so that the heavily used stuff is on the fast controller.

3) stop using the 451, and put both disks on the rimfire.

Any suggestions?

Ned Danieley (ndd@sunbar.mc.duke.edu)
Basic Arrhythmia Laboratory
Duke University Medical Center
Durham, NC  27710
(919) 684-6807 or 684-6942

------------------------------

Date:    Sat, 24 Oct 87 10:49 PST
From:    <JON%UCLASTRO.BITNET@wiscvm.wisc.edu>
Subject: uuencode problem: Permission denied.

To All Spots,

I am having trouble with uuencode.  I have been sent a couple files that
were encoded.  In trying to uudecode, I keep getting a permission denied
error on the file it is trying to create.  I changed the mod after the
begin in the file and it still don't work.  Being confused, I decided to
try my own encoding/decoding.  I tried the following:

        # uuencode a.file a.new.file > encoded.file
        # uudecode encoded.file
        a.new.file: Permission denied.

This happens even when I am root.  According to the man pages,
uuencode/decode don't refer to any other files (like alias files, etc.).
All the information comes from the encoded file.  So what is wrong?

Jonathan Eisenhamer
"Oops! My non-unix is showing!"
UCLA Astronomy
JON@UCLASTRO.BITNET
BONNIE::JON (SPAN 5828)
(213) 206-8596

[[ The problem is that uuencode and uudecode run setuid to the user
"uucp".  This has something to do with security when the automatic part of
uucp decides to use these programs.  This is not a problem when you try to
use uuencode, because the program never creates any files.  But uudecode
first tries to create the file named at the start of the input (the
"begin 622 filename" line).  This will not work unless the current
directory is writable by uucp.  Solution?  Do "chmod o+w ." before the
uudecode and "chmod o-w ." afterwards.  --wnl ]]

------------------------------

Date:    26 Oct 87 20:18:43 GMT
From:    marantz@athos.rutgers.edu (Roy Marantz)
Subject: Named pipes

Can anyone tell me (or give me an example program) how to set up a "named
pipe"?  What I want is a program that will be used as a filter for
programs that don't send there output to stdout (i.e. can't be piped).  I
envision doing something like this (from user level):

	filter			; this creates /dev/frob
	prog -f /dev/frob	; this read/writes (or maybe just reads)
				; to /dev/frob

I've heard that named Unix domain sockets will crash the Sun.  If someone
has a fix (not just defensive code) for this or know of another way
(System V compatibility package maybe?) I'd appreciate hearing about it.
Please respond directly to me.  If anything useful comes in I'll
summarize.  Thanks for any help.

Roy

[[ The other problem with 4.2 Unix-domain sockets is that they are sockets
and sockets do not behave like any other file type on the system.  A
program cannot merely "open" a socket, it must "connect" to it, even if
the program is acting solely as a client.  Unless Sun has added the System
V FIFO files, named pipes cannot be done under Sun Unix.  --wnl ]]

------------------------------

Date:    23 Oct 87 01:42:05 GMT
From:    bambam!hjp@seismo.css.gov (Howard J. Postley)
Subject: Need to rent or lease Sun-3's

Help!
I just got a bunch of data dumpped in my lap that has to be processed
before Dec 1 on Suns.  I need to get 6-10 workstations for the month of
Nov.  Sun in my area says they can't help;  the delivery is 30-45 days.

If any of you know of a place that can rent or lease (or sell) me these
machines quickly, I would be extraordinarily grateful.  I would prefer not
to have to *buy* used machines because I already have several new ones on
order.  I just need them now for the month.

Thanks in advance,
Howard
(uunet!bambam!hjp)

P.S.  Please reply directly to me, my news system has died and I don't want
      to miss any responses.

------------------------------

Date:    23 Oct 87 13:36:54 GMT
From:    harvard!bunny!mdf0@seismo.css.gov (Mark Feblowitz)
Subject: Need info on NeWS for the Mac

Will NeWS on the Mac support communication between Macs and Suns?

Does anyone out there have any info on NeWS for the Mac?

Mark Feblowitz
GTE Laboratories, Inc.
40 Sylvan Rd.
Waltham, MA 02254
(617) 466-2947

    UUCP:  feblowitz@bunny.UUCP
old UUCP:  harvard!bunny!mdf0
   CSNET:  feblowitz@GTE-LABS.CSNET

------------------------------

Date:    Fri, 23 Oct 87 16:22:14 EDT
From:    rbthomas@aramis.rutgers.edu (Rick Thomas)
Subject: Information about Suntops?

Does anybody know how to get a copy of a program called 'suntops' that
converts a Sun screendump rasterfile to PostScript?  Adobe used to
sell a program called PSSun, but has now discontinued it.  They
recommend instead that we get a copy of suntops, which they say is
public domain.  We need source code, so a binary copy is not enough.

Thanks in advance

Rick Thomas

rbthomas@caip.rutgers.edu
Rick Thomas
(201) 932-4301
uucp: {ames, cbosgd, harvard, moss, seismo}!rutgers!caip.rutgers.edu!rbthomas
arpa: rbthomas@CAIP.RUTGERS.EDU

------------------------------

Date:    Sat, 24 Oct 87 09:34:39 +0200
From:    gran!furu!anders@nta-odin.arpa (Anders Hvidsten)
Subject: fortran_editor?

Does there exist some sort of a FORTRAN editor to be invoked in my
suntools enviroment ??

anders Hvidsten

------------------------------

Date:    Mon, 26 Oct 87 11:17:49 +0100
From:    "Michael Schmidt" <unido!pbinfo!phoenix.pb!michael@uunet.uu.net>
Subject: varargs: bug or feature?

   From:    rsalz@pineapple.bbn.com

   Your code is broken; you're not supposed to do:
	   va_arg(foo, short)
   ....		       ^^^^^
   [[ ...I wish I had caught that before I sent the digest out.... --wnl ]]

Oh god. I really wasn't aware of this very unexpected unorthogonality in
the C definition. I did expect a short passed as short, although I
noticed, that Sun doesn't do it.

Sorry,
Michael

[[ T'sawright.  --wnl ]]


------------------------------

End of SUN-Spots Digest
***********************