I had a problem compiling OgreKit in Étoilé trunk revision 4439.

Some information about my system:

dop % onig-config --version
5.9.1

dop % gcc -v
Using built-in specs.
Target: i586-suse-linux
Configured with: ../configure --prefix=/usr --infodir=/usr/share/info
--mandir=/usr/share/man --libdir=/usr/lib --libexecdir=/usr/lib
--enable-languages=c,c++,objc,fortran,obj-c++,java,ada
--enable-checking=release --with-gxx-include-dir=/usr/include/c++/4.3
--enable-ssp --disable-libssp
--with-bugurl=http://bugs.opensuse.org/--with-pkgversion='SUSE Linux'
--disable-libgcj --disable-libmudflap
--with-slibdir=/lib --with-system-zlib --enable-__cxa_atexit
--enable-libstdcxx-allocator=new --disable-libstdcxx-pch
--enable-version-specific-runtime-libs --program-suffix=-4.3
--enable-linux-futex --without-system-libunwind --with-cpu=generic
--build=i586-suse-linux
Thread model: posix
gcc version 4.3.2 [gcc-4_3-branch revision 141291] (SUSE Linux)


Building Étoilé with `make' I've got:

...

Build Project: OgreKit

Making all in subprojects of framework OgreKit...
Making all in subprojects of subproject Source...
Making all for subproject RegularExpression...
 Compiling file OGRegularExpression.m ...
OGRegularExpression.m:22:5: error: #error HAVE_STDARG_H is not defined
OGRegularExpression.m:25:5: error: #error HAVE_STDARG_PROTOTYPES is not
defined
cc1obj: warnings being treated as errors
OGRegularExpression.m: In function '-[OGRegularExpression
initWithString:options:syntax:escapeCharacter:]':
OGRegularExpression.m:311: error: call to function 'onig_error_code_to_str'
without a real prototype
/usr/include/oniguruma.h:715: note: 'onig_error_code_to_str' was declared
here
make[5]: *** [obj/OGRegularExpression.m.o] Error 1
make[4]: *** [RegularExpression.all.subproject.variables] Error 2
make[3]: *** [Source.all.subproject.variables] Error 2
make[2]: *** [OgreKit.all.framework.variables] Error 2
make[1]: *** [internal-all] Error 2
make: *** [internal-all] Error 2

I've put these lines in OGRegularExpression.m before #import <oniguruma.h>:

#ifndef HAVE_STDARG_H
#   error HAVE_STDARG_H is not defined
#endif
#ifndef HAVE_STDARG_PROTOTYPES
#   error HAVE_STDARG_PROTOTYPES is not defined
#endif

so i get errors about HAVE_STDARG_* not being defined. If i define
HAVE_STDARG_H OgreKit compiles.

It seems oniguruma.h is #import'ed twice in
Etoile/Frameworks/OgreKit/Source/OGRegularExpression.m -- once explicitly
and once with <OgreKit/OGRegularExpression.h>. I've removed #import
<oniguruma.h> from OGRegularExpression.m
and defined HAVE_STDARG_H in OGRegularExpression.h.

Why HAVE_STDARG_H isn't defined?


Donatas
_______________________________________________
Etoile-discuss mailing list
[email protected]
https://mail.gna.org/listinfo/etoile-discuss

Répondre à