gpg-error.h possible(?) syntax error: #define GPG_ERR_SYSTEM_ERROR (1 << 15)

Hedge Hog hedgehogshiatus at
Sun Nov 1 11:04:55 CET 2009

I'm not a C/C++ guru so would appreciate anyone indicating if the
following is a bug in the generated gpg-error.h file.

This issue arose in the process of trying to create a ruby interface for gpgme.

After checking out the source for libgpg-error-1.7 and running:
./configure --enable-maintainer-mode

I run swig on an interface file that includes the generated gpg-error.h file.
I get the following error from swig (ver 1.3.36):

libgpg-error-1.7/src/gpg-error.h:346: Error: Syntax error in input(1).

lines 345-7 in gpg-error.h are:

    /* The following error codes are used to map system errors.  */
#define GPG_ERR_SYSTEM_ERROR	(1 << 15)

It is not clear to me if this is an problem with gpg-error.h or swig.

Appreciate any insight.


More information about the Gnupg-users mailing list