apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Branko ─îibej <br...@xbc.nu>
Subject Re: Win32: Ruby & APR; build problems for Ruby Subversion SWIG bindings
Date Thu, 21 Apr 2005 22:23:41 GMT
Erik Huelsmann wrote:

>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 
This, I think, is a classic case of programmers' hubris. We should've 
defined apr_pid_t &co. on all platforms, not polluted the namespace with 
names that APR doesn't own (and that will clash with any Windows 
implementation of a POSIX-like API).

>in win32.h from the ruby-mswin32-1.8.2 zip:
>#define pid_t int
>#define gid_t int
>#define uid_t int
But of course this is even worse. Both APR and Ruby should be fixed.

-- Brane

View raw message