apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erik Huelsmann <ehu...@gmail.com>
Subject Win32: Ruby & APR; build problems for Ruby Subversion SWIG bindings
Date Wed, 20 Apr 2005 14:22:31 GMT
Having taken upon me the task to provide a Windows build for
Subversion, I run into a problem with the Ruby SWIG bindings. The
problem is with APR and Ruby Win32 header files though.

For those who don't know any of the terms used:
Subversion: the next generation of centralised version control
(http://www.tigris.org/; down until probably somewhere tomorrow)
SWIG: a plugin generator for programming languages (http://www.swig.org)
Ruby: a programming language (http://www.ruby-lang.org)
APR: the Apache Portable Runtime (http://apr.apache.org) upon which
Subversion has been built


Ok. So now for the real problem:

Windows does not define pid_t, gid_t or uid_t in any of the system
headers. Both APR and Ruby *do* define these 3 types:

in apr.hw (renamed to apr.h during windows build):

typedef int pid_t 
typedef int gid_t 
typedef int uid_t 

in win32.h from the ruby-mswin32-1.8.2 zip:

#define pid_t int
#define gid_t int
#define uid_t int

Normally I would resolve this problem by including apr.h first, then
followed by ruby.h; however, I use SWIG to generate the wrappers and
SWIG includes ruby.h first. Now the compiler is generating errors that
there are lines like this in the sources:

typedef int int 

which is ofcourse absolute non-sense.

Because I want to build to distribute, I don't want to modify any of
the headers involved. I do need some help getting out of this mess
though!


bye,

Erik.

Mime
View raw message