This is the mail archive of the cygwin@sources.redhat.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

AFPL Ghostscript 6.50 cc errors


Hello Cygwin List,

I am needing to build Ghostscript from source and am using Cygwin (latest) 
on WinNT to do it. I have gotten pretty far (I think) but the whole thing is 
now stopped at a part that uses the pthreads (POSIX thread API). I am 
getting a parse error from gcc and I wonder if anyone can help with a clue.

The section of code affected in the AFPL gs source is this:

----- code, watch for wrapping and low-flying owls -----
[filename:  gp_psync.c,v 1.2 2000/09/19]

  21  #include "std.h"
  22  #include "malloc_.h"
  23  #include <pthread.h>
  24  #include "gserror.h"
  25  #include "gserrors.h"
  26  #include "gpsync.h"
// /--/
  45  
  46  typedef struct pt_semaphore_t {
  47      int count;
  48      pthread_mutex_t mutex;
  49      pthread_cond_t cond;
  50  } pt_semaphore_t;
  51  
------ end code ------
----- the error --- watch for wrapping ------
./src/gp_psync.c:49: parse error before `pthread_cond_t'
./src/gp_psync.c:49: warning: no semicolon at end of struct or union
./src/gp_psync.c:50: warning: type defaults to `int' in declaration of `pt_semaphore_t'
./src/gp_psync.c:50: warning: data definition has no type or storage class
./src/gp_psync.c: In function `gp_semaphore_open':
./src/gp_psync.c:68: parse error before `const'
./src/gp_psync.c:73: `sem' undeclared (first use in this function)
./src/gp_psync.c:73: (Each undeclared identifier is reported only once
./src/gp_psync.c:73: for each function it appears in.)
./src/gp_psync.c:76: warning: implicit declaration of function `pthread_cond_init'
./src/gp_psync.c: In function `gp_semaphore_close':
./src/gp_psync.c:83: parse error before `const'
./src/gp_psync.c:86: warning: implicit declaration of function `pthread_cond_destroy'
./src/gp_psync.c:86: `sem' undeclared (first use in this function)
./src/gp_psync.c: In function `gp_semaphore_wait':
./src/gp_psync.c:96: parse error before `const'
./src/gp_psync.c:99: `sem' undeclared (first use in this function)
./src/gp_psync.c:103: warning: implicit declaration of function `pthread_cond_wait'
./src/gp_psync.c: In function `gp_semaphore_signal':
./src/gp_psync.c:118: parse error before `const'
./src/gp_psync.c:121: `sem' undeclared (first use in this function)
./src/gp_psync.c:125: warning: implicit declaration of function `pthread_cond_signal'
./src/gp_psync.c: In function `gp_create_thread':
./src/gp_psync.c:223: warning: implicit declaration of function `pthread_attr_setdetachstate'
make: *** [obj/gp_psync.o] Error 1

----- end console text -- end low-flying owls -----

I really need (as opposed to am doing as an academic exercise of 
some sort) to build this Ghostscript from source for my WinNT 
system because I need to compile-in a custom device driver 
("hpdj") for HP Officejet hardware.

If anyone has successfully built this newest release of gs on 
Cygwin, perhaps you'd be kind enough to offer some clues about 
your procedure. Or if anyone has some clue about pthreads and 
how it figures, is it really necessary, etc.

  Many Thanks,
     soren andersen


--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]