1833052 Members
2564 Online
110049 Solutions
New Discussion

Re: Old and new Xwindows

 
Eder Urruela
Frequent Advisor

Old and new Xwindows

Hi, I am trying to compile an old recompile an old program on an itanium machine, the problem I am working now is with the Xwindows libraries, I have added the X11, Xw and Xm folders in my makefile flags.

In the source files I'm compiling I have many call to sistem fuctions such as:
void XtRemoveAllCallbacks(object, callback_name)
or that library structs as StringSourceData which has changed.

Where I could get manual from the old and the new libraries in order to compare. I need to know how to change the way of working with this libraries and system fuctions.

Thanks!
7 REPLIES 7
Steven E. Protter
Exalted Contributor

Re: Old and new Xwindows

Shalom,

It would be extremely helpful to know the version of HP-UX, the compiler you are trying to use and the actual names of the X windows programs you are working with.

Knowing the source would make answering your question less of a fishing expedition.

If you have tried a compile and gotten an error message that would help too.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Eder Urruela
Frequent Advisor

Re: Old and new Xwindows

Shalom.

I don't know if it's enought but making uname -a I get the following information:

"HP-UX SCEH2 B.11.31 U ia64 2650913535 licencia de usuarios ilimitados."

I don't also know how to get the cc version, but in the man pages I have found this:

HP C/aC++ Version A.06.20.

>Knowing the source would make answering >your question less of a fishing expedition.

I have many source files which are giving me probles so I am not going to wirte all the fucntion but I type one example function.

#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include

/*--------------------------------------------------------------------------+*/
static unsigned char Look(data, position, direction)
/*--------------------------------------------------------------------------+*/
StringSourcePtr data;
XwTextPosition position;
XwScanDirection direction;
{
/* Looking left at pos 0 or right at position data->length returns newline */
if (direction == XwsdLeft) {
if (position == 0)
return(0);
else
return(data->buffer[position-1]);
}
else {
if (position == data->length)
return(0);
else
return(data->buffer[position]);
}
}

the error for this says that the funcion does not return a compitilble type on that line:

return(data->buffer[position-1]);

on the old function data->buffer refers to unsigned char * but in the system one refers to a buff_elf struct.

The declaration is in SourceP.h

Other problem I am findding frequently is like this


(*((XwTextEditClassRec *)(w->core.widget_class))->textedit_class.set_selection)
(w, left, right);

"TextEdit.c", line 2233: error #2140: too many arguments in function call
(w, left, right);
^

textedit_class.set_selection is an call to the system fucntion XtWidgetProc.

That are two of many example, but all of them are related to the obsolescence of the source.

Thanks again for your help.
Dennis Handly
Acclaimed Contributor

Re: Old and new Xwindows

>I don't also know how to get the cc version

cc -V

>SEP: It would be extremely helpful to know the version of HP-UX,

This is related to Eder's other thread:
http://forums.itrc.hp.com/service/forums/questionanswer.do?threadId=1333502

Eder Urruela
Frequent Advisor

Re: Old and new Xwindows

Another problem is this

"Valuator.c", line 648: error #2140: too many arguments in function call
XtRemoveAllCallbacks (vw, XtNsliderMoved, vw -> valuator.slider_moved);
^

It is another sistem fuction whis has changed, I think I should use as following?:
XtRemoveAllCallbacks (vw-> valuator.slider_moved, XtNsliderMoved);

Thanks!
Eder Urruela
Frequent Advisor

Re: Old and new Xwindows

The cc version.

cc: HP C/aC++ B3910B A.06.20 [May 13 2008]
ld: 92453-07 linker ld HP Itanium(R) B.12.52 IPF/IPF

Where can I find a manual for this libaries.

Thanks!
Dennis Handly
Acclaimed Contributor

Re: Old and new Xwindows

>Where can I find a manual for this libaries?

(I'm not sure why you listed the C and linker versions, they have nothing to do with Motif.)

You can just do: man XtRemoveAllCallbacks

This is part of: X11MotifDevKit.X11R6-PRG-MAN
Eder Urruela
Frequent Advisor

Re: Old and new Xwindows

After some trials I didn't get any satisfactory result so I think that the problem is not the librarias.

So thank you for your time.