Re: UPS with underlying gdb on HP-UX doesn't work

From: Rod Armstrong (rod_at_San-Jose.ate.slb.com)
Date: Wed Sep 16 1998 - 20:23:31 BST


Thomas,
	Sadly the ups-gdb support has been broken since ups 3.07 and
gdb 4.13 timeframe. I haven't had time (or expertise in Perl) to look at
it. I was hoping that someone else might take up the challenge.

	I dug out some old mail about this. Essentially HP is only supported
in the non native mode that uses the gdb libraries (UPS 3.7), but this
is broken in 3.14. Also, there are code/script changes necessary to work
with the lastest  gdb libraries.

Rod Armstrong

--------------------------------------------------------------------------------
From: Guenter Pollak <Guenter.Pollak_at_aut.alcatel.at>
Subject: how to build ups-3.7-alpha on HPUX
To: ups-users_at_ukc.ac.uk
Date: Tue, 18 Apr 95 18:58:05 METDST
Cc: pollak_g%atuhc15_at_dnisun.aut.alcatel.at
Mailer: Elm [revision: 70.85]
Status: RO


After hearing that Mark's time is exclusively taken by getting
ups working for Solaris I finally tried to build ups-3.7-alpha
on my HP machine. Building with a gdb-4.13 (from hpux.csc.liv.ac.uk)
worked fine. When I started ups, I first encountered the same problem 
as Bob:

 "I'm sorry, Dave, I can't do that.  Symbol format `som' unknown."

After some debugging of ups and gdb-4.13 (breakpoint on 'find_sym_fns')
I found the reason: 

1.) The functions of the file 'somread.c' are missing in Mark's munged gdb
    library.
2.) Those functions are used by the gdb-4.13 on HP-UX. 
3.) The last entry in gdbconf/initlist is 'paread' and not 'somread'

Hence the solution is simple: unpack the ups tarfile as usual, then
change 'paread' to 'somread' in 'gdbconf/initlist', then proceed with steps
3 and 4 of the README file.

After I did that, ups works fine on my HP 712 und HPUX A.09.05.

Hope this helps! (Wonder why it took so long to find it. Or did some HP user
find it but forgot to publish it in the mailing list?)

Guenter Pollak
Alcatel Austria
pollak_g_at_aut.alcatel.at

P.S.: The only problem I encountered so far: The color of the editable
      text is not yellow, and cannot be set with Ups.EditlinesColor. 
      I guess this has to do with my X resources, because ups prints the
      following warning message: 

"Can't open editfont 
 -bitstream-prestige-bold-r-normal--19-160-72-72-m-110-hp-roman8 - trying 
 -*-fixed-bold-r-normal--15-*-*-*-*-*-*-*"
  

__________________________________________________________________
Date: Wed, 6 Mar 1996 14:42:46 -0500 (EST)
From: Brad Palmquist <blp_at_latte.harvard.edu>
X-Sender: blp_at_palm.harvard.edu
To: ups-users_at_ukc.ac.uk
Subject: Re: Want to use UPS
In-Reply-To: <9603061845.ZM10040_at_jcarroll.hpl.hp.com>
Message-Id: <Pine.HPP.3.91.960306143446.18823A-100000_at_palm.harvard.edu>
Mime-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
Status: RO

On Wed, 6 Mar 1996, Jeremy Carroll wrote:

> bruce (b.o.c.) munro wrote:
> >
> > But I don't think it's ever been put onto HP-UX has it. A guy here had
> > a crack at it a couple of years ago, but with no luck. Is there anyone
> > looking at an HP-UX version?
> 
> ups 3.07 alpha is meant to run on HP-UX, not that I have got round to it yet.
> 

Presumably you mean ups 3.7 alpha.  I posted this question to the
group last year and got a very helpful reply from Guenter Pollak:

> As I wrote in this mailing list, I recently succeeded to build ups-3.7-alpha
> from /pub/misc/unix/ups on unix.hensa.ac.uk on my HP workstation.
> You'll need the following:
> 
> - A working GNU toolchain with gcc, gas, and gdb 4.13
> - An official distribution of gdb-4.13 source code that builds successfully on
>   HP 700 architectures (gdb-4.14 won't work)
> - perl version 4.x (5.x won't work)
> 
> - to change 'paread' to 'somread' in the file 'gdbconf/initlist'
> 
> - to do changes like the following in the ups Makefile:
> 
> X11LIB = /usr/lib/X11R5/libX11.a  (your own path to the X11 library)
>          ^^^^^^^^^^^^^^^^^^^^^^^
> 
> SUBMAKEFLAGS= CC="${CC}" RANLIB="${RANLIB}" \
> CFLAGS="${CFLAGS}" X11LIB="$(X11LIB)" ${EXTRA_SUBMAKEFLAGS}
>                    ^^^^^^^^^^^^^^^^^^
> 
> `testedit' is not a library but an executable, therefore it needs
> the path to the X11 library.
> 
> Then you should be able to build ups as described in the README file
> 
> If so, the following X resouces may be useful (to read yellow on white
> is not everybody's taste):
> 
> Ups.Background: NavyBlue
> Ups.Foreground: white
> Ups.Geometry:   800x900

With these hints I was also able to build ups.  But N.B. you must have
gdb, gcc, and gas first!

In my build I had a few minor problems:

In 4 places gcc complained about incompatible pointer types.
1) The first instance, a pointer assignment in hppa-tdep.c (lines 365
   and 416) does seem to be wrong when I look at it.  "objfile" is
   passed as a (struct objfile *) and so the assignment should
   use objfile->psymobol_obstack, not &objfile->psymobol_obstack.
   I can't tell if this should be problematic.

b) The other instances all seem to involve passing NULL pointers.
   As long as all pointers have the same size, this shouldn't be
   a problem.  For example:

   ../wn_event.c: In function `select_on_mask':
   ../wn_event.c:206: warning: passing arg 2 of `select' from incompatible \
                               pointer type


According to Guenter last year, "ups-3.14-beta is a native ups on Solaris.
No connection to the HP world."  I haven't noticed any mention of a more
recent version of ups that can be built for HPUX.  But I haven't paid
close attention so maybe someone else knows more about this.

Good Luck!  (I don't recommend sending any further queries to me about
the build because it's been almost a year now since I did it and I'm
not likely to remember any more of the details.)

-Brad

__________________________________________________________________
Brad Palmquist
Department of Government                  617-495-9564
Harvard University                        b_palmquist_at_harvard.edu
__________________________________________________________________


This archive was generated by hypermail 2.1.4 : Wed Feb 13 2002 - 21:51:32 GMT