![]() |
Blitz Support : |
From: Julian C. Cummings (cummings_at_[hidden])
Date: 2003-11-03 16:19:22
Hi Alexander,
The first error refers to the "macro" index. It is very likely that
somewhere in your code you have defined a CPP macro called "index", and that
it is interfering with the code in the blitz header file blitz/extremum.h,
which uses "index" as a method name. You'll need to track this down in your
code and consider renaming the macro. It's a good idea to stick to the
convention of using all uppercase letters and underscores for macro names,
in part to avoid problems like this.
Regards, Julian C.
P.S. The rest of the errors reported probably result from this initial
problem.
> -----Original Message-----
> From: blitz-support-bounces_at_[hidden]
> [mailto:blitz-support-bounces_at_[hidden]] On Behalf Of
> Alexander Macdonald
> Sent: Saturday, November 01, 2003 4:34 AM
> To: blitz-support_at_[hidden]
> Subject: [Blitz-support] newbie compile problem
>
>
> Hi there,
>
> I've got blitz 0.7 compiled and installed fine, I've checked
> it works by
> running some small example programs...however when i compile my main
> project i'm working on it spews out this:- (I know this cant be a
> problem with blitz, but I'm lost as to what in my code could
> cause such
> errors)
>
> g++ material/material.o material/texture.o material/texeffect.o
> camera/camera.o misc/accessmonitor.o misc/Semaphore.o object/object.o
> object/object_mesh.o lights/lighting.o material/texturemanager.o
> object/node.o -Wall -pedantic -g -ggdb -ansi -pg
> -L/usr/X11R6/lib -lGL
> -lGLU -lX11 -lXi -lXmu -lSDL -lglut -L/usr/lib -lm -ldl
> -lXext -lImlib2
> -lxml++-0.1 -lxml2 -lz -lpthread -lblitz -I/usr/include/libxml++-1.0
> -I/usr/lib/libxml++-1.0/include crazygolf.cpp -o crazygolf
>
> In file included from /usr/include/blitz/vecglobs.h:42,
> from /usr/include/blitz/vector.h:473,
> from /usr/include/blitz/tinyvec.h:437,
> from object/node.h:6,
> from object/object.h:5,
> from crazygolf.h:17,
> from crazygolf.cpp:1:
> /usr/include/blitz/extremum.h:53:19: macro "index" requires 2
> arguments,
> but only 1 given
> In file included from /usr/include/blitz/vecglobs.h:42,
> from /usr/include/blitz/vector.h:473,
> from /usr/include/blitz/tinyvec.h:437,
> from object/node.h:6,
> from object/object.h:5,
> from crazygolf.h:17,
> from crazygolf.cpp:1:
> /usr/include/blitz/extremum.h:53: syntax error before `const'
> /usr/include/blitz/extremum.h:56: semicolon missing after
> declaration of `
> blitz::Extremum<P_numtype, P_index>'
> /usr/include/blitz/extremum.h: In constructor
> `blitz::Extremum<P_numtype,
> P_index>::Extremum(P_numtype, P_index)':
> /usr/include/blitz/extremum.h:47: class `blitz::Extremum<P_numtype,
> P_index>'
> does not have any field named `value_'
> /usr/include/blitz/extremum.h:47: class `blitz::Extremum<P_numtype,
> P_index>'
> does not have any field named `index_'
> /usr/include/blitz/extremum.h: At global scope:
> /usr/include/blitz/extremum.h:56: syntax error before `)' token
> /usr/include/blitz/extremum.h:57: two or more data types in
> declaration of `
> setValue'
> /usr/include/blitz/extremum.h:57: semicolon missing after
> declaration of
> `class
> blitz::Extremum<P_numtype, P_index>'
> /usr/include/blitz/extremum.h:59: syntax error before `)' token
> /usr/include/blitz/extremum.h: In function `void
> blitz::setIndex(...)':
> /usr/include/blitz/extremum.h:60: `index_' undeclared (first use this
> function)
> /usr/include/blitz/extremum.h:60: (Each undeclared identifier is
> reported only
> once for each function it appears in.)
> /usr/include/blitz/extremum.h: At global scope:
> /usr/include/blitz/extremum.h:62: syntax error before `(' token
> /usr/include/blitz/extremum.h:62: syntax error before `(' token
> /usr/include/blitz/extremum.h:67: 'T_index' is used as a
> type, but is not
> defined as a type.
> /usr/include/blitz/extremum.h:68: syntax error before `}' token
> In file included from /usr/include/blitz/vecglobs.cc:19,
> from /usr/include/blitz/vecglobs.h:50,
> from /usr/include/blitz/vector.h:473,
> from /usr/include/blitz/tinyvec.h:437,
> from object/node.h:6,
> from object/object.h:5,
> from crazygolf.h:17,
> from crazygolf.cpp:1:
> /usr/include/blitz/vecmin.cc:21: non-template type `Extremum'
> used as a
> template
> /usr/include/blitz/vecmin.cc: In function `int
> blitz::_bz_vec_min(P_expr)':
> /usr/include/blitz/vecmin.cc:53: non-template type `Extremum'
> used as a
> template
> /usr/include/blitz/vecmin.cc: At global scope:
> /usr/include/blitz/vecmin.cc:59: non-template type `Extremum'
> used as a
> template
> /usr/include/blitz/vecmin.cc:67: non-template type `Extremum'
> used as a
> template
> /usr/include/blitz/vecmin.cc:75: non-template type `Extremum'
> used as a
> template
> /usr/include/blitz/vecmin.cc:83: non-template type `Extremum'
> used as a
> template
> In file included from /usr/include/blitz/vecglobs.cc:19,
> from /usr/include/blitz/vecglobs.h:50,
> from /usr/include/blitz/vector.h:473,
> from /usr/include/blitz/tinyvec.h:437,
> from object/node.h:6,
> from object/object.h:5,
> from crazygolf.h:17,
> from crazygolf.cpp:1:
> /usr/include/blitz/vecmin.cc:93:49: macro "index" requires 2
> arguments,
> but only 1 given
> /usr/include/blitz/vecmin.cc:101:33: macro "index" requires 2
> arguments,
> but only 1 given
> /usr/include/blitz/vecmin.cc:108:49: macro "index" requires 2
> arguments,
> but only 1 given
> /usr/include/blitz/vecmin.cc:115:49: macro "index" requires 2
> arguments,
> but only 1 given
> In file included from /usr/include/blitz/vecglobs.cc:20,
> from /usr/include/blitz/vecglobs.h:50,
> from /usr/include/blitz/vector.h:473,
> from /usr/include/blitz/tinyvec.h:437,
> from object/node.h:6,
> from object/object.h:5,
> from crazygolf.h:17,
> from crazygolf.cpp:1:
> /usr/include/blitz/vecmax.cc:21: non-template type `Extremum'
> used as a
> template
> /usr/include/blitz/vecmax.cc: In function `int
> blitz::_bz_vec_max(P_expr)':
> /usr/include/blitz/vecmax.cc:53: non-template type `Extremum'
> used as a
> template
> /usr/include/blitz/vecmax.cc: At global scope:
> /usr/include/blitz/vecmax.cc:59: non-template type `Extremum'
> used as a
> template
> /usr/include/blitz/vecmax.cc:67: non-template type `Extremum'
> used as a
> template
> /usr/include/blitz/vecmax.cc:75: non-template type `Extremum'
> used as a
> template
> /usr/include/blitz/vecmax.cc:84: non-template type `Extremum'
> used as a
> template
> In file included from /usr/include/blitz/vecglobs.cc:20,
> from /usr/include/blitz/vecglobs.h:50,
> from /usr/include/blitz/vector.h:473,
> from /usr/include/blitz/tinyvec.h:437,
> from object/node.h:6,
> from object/object.h:5,
> from crazygolf.h:17,
> from crazygolf.cpp:1:
> /usr/include/blitz/vecmax.cc:95:33: macro "index" requires 2
> arguments,
> but only 1 given
> /usr/include/blitz/vecmax.cc:103:49: macro "index" requires 2
> arguments,
> but only 1 given
> /usr/include/blitz/vecmax.cc:110:49: macro "index" requires 2
> arguments,
> but only 1 given
> /usr/include/blitz/vecmax.cc:117:49: macro "index" requires 2
> arguments,
> but only 1 given
> make: *** [golf] Error 1
>
>
> Any help would be greatly appreciated, thanks.
>
> _______________________________________________
> Blitz-support mailing list
> Blitz-support_at_[hidden]
> http://www.oonumerics.org/mailman/listinfo.cgi/blitz-support
>