Operating System - HP-UX
1833704 Members
2616 Online
110062 Solutions
New Discussion

ghostscript on HP-UX 11.00

 
Steve Khoo
Advisor

ghostscript on HP-UX 11.00

Anyone have ghostscript binary package for HP-UX 11.00? I tried ompiling the 8.62 src from http://hpux.connect.org.uk and 8.71 src from http://ghostscript.com , but no luck so far...

I'd appreciate any help.

Thanks,

Steve
8 REPLIES 8
Steven E. Protter
Exalted Contributor

Re: ghostscript on HP-UX 11.00

Shalom Steve,

Post your errors, someone might be abel to help.

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
Steve Khoo
Advisor

Re: ghostscript on HP-UX 11.00

Hi Steven,

Thanks for the tip. I was hoping I would find someone that has the precompiled package. :-)

While compiling 8.71 configure as:

./configure --without-jasper --without-jbig2dec CC=/opt/ansic/bin/cc

I get the following error:

...
./obj/echogs -e .dev -a- ./obj/dpsnext -oper zdpnext
./obj/echogs -e .dev -a- ./obj/dpsnext -ps gs_dpnxt
/opt/ansic/bin/cc -DHAVE_MKSTEMP -DHAVE_HYPOT -DHAVE_FILE64 -O -DSYS_TYPES_HAS_STDINT_TYPES -DGX_COLOR_INDEX_TYPE="unsigned long long" -I./obj -I./base -o ./obj/gsnogc.o -c ./base/gsnogc.c
cc: "base/gsnogc.c", line 35: error 1610: Attempting to return value from function of type void.
cc: "base/gsnogc.c", line 83: warning 604: Pointers are not assignment-compatible.
cc: "base/gsnogc.c", line 83: warning 563: Argument #1 is not the correct type.
cc: "base/gsnogc.c", line 87: warning 604: Pointers are not assignment-compatible.
cc: "base/gsnogc.c", line 87: warning 563: Argument #1 is not the correct type.
make: *** [obj/gsnogc.o] Error 1
#

I'd appreciate any help.

Thanks,

Steve
Dennis Handly
Acclaimed Contributor

Re: ghostscript on HP-UX 11.00

>cc: "base/gsnogc.c", line 35: error 1610: Attempting to return value from function of type void.

What's on this line? What's the start of the function look like?
Steve Khoo
Advisor

Re: ghostscript on HP-UX 11.00

Line 35 is the return statement below...

/* Free a string. */
static void
nogc_free_string(gs_memory_t * mem, byte * str, uint size, client_name_t cname)
{
return gs_free_object(mem, str, cname);
}

HP compiler apparently doesn't like return statement in function of type void. I was able to compile the same code on another system using gcc on HP-UX 11.23. Instead of modifying the src code I'm going to see if I can find gcc for HP-UX 11.00.

Steve
Dennis Handly
Acclaimed Contributor

Re: ghostscript on HP-UX 11.00

>HP compiler apparently doesn't like return statement in function of type void.

That's correct, this is illegal code.

>Instead of modifying the source code I'm going to see if I can find gcc for HP-UX 11.00.

Why not fix the code? Just see what gs_free_object returns and if nogc_free_string is expected to return something.
Steve Khoo
Advisor

Re: ghostscript on HP-UX 11.00

well... It doesn't appear that nogc_free_string require a returned value, so I removed it.

So I got beyond the error 1610. Then I started getting the following error.

/opt/ansic/bin/cc -DHAVE_MKSTEMP -DHAVE_HYPOT -DHAVE_FILE64 -O -DSYS_TYPES_HAS_STDINT_TYPES -DGX_COLOR_INDEX_TYPE="unsigned long long" -I./obj -I./base -Itiff/libtiff -I./obj -Izlib -o ./obj/gdevtfax.o -c ./base/gdevtfax.c
cc: "base/stdpre.h", line 249: error 1713: Illegal redeclaration for identifier "ushort".
cc: "base/stdpre.h", line 250: error 1713: Illegal redeclaration for identifier "uint".
make: *** [obj/gdevtfax.o] Error 1
#

According to HP-UX doc, I'm supposed to remove the Illegal redeclaration. So I did. Then I get the following error...

cc -O -DHAVE_STDINT_H -DGX_COLOR_INDEX_TYPE="unsigned long long" -I./base -o ./obj/genconf ./base/genconf.c
cc: "base/genconf.c", line 779: error 1000: Unexpected symbol: "strlen".
cc: "base/genconf.c", line 778: error 1621: Too few arguments for sprintf.
cc: "base/genconf.c", line 781: warning 527: Integral value implicitly converted to pointer in assignment.
cc: "base/genconf.c", line 781: warning 563: Argument #1 is not the correct type.
make: *** [obj/genconf] Error 1
#

Now I'm tired of chasing this and pretty much out of time. I've given up on this approach for the moment and have found a work around. I was finally able to compile it with gcc 3.0.1.

Thanks for the advice and tip Dennis.

Steve
Steve Khoo
Advisor

Re: ghostscript on HP-UX 11.00

ghostscript 8.71 will not compile with HP-UX 11.00 ANSI C compiler, but it does compile with gcc 3.0.1. Use the following to configure.

./configure --without-jasper --without-jbig2dec CC=gcc

Steve
Dennis Handly
Acclaimed Contributor

Re: ghostscript on HP-UX 11.00

>Then I get the following error.

What's on these lines in base/genconf.c?