Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[vdr] Problems compiling plugins using STL (__STL_CONFIG_H)



Hello List,

I have some problems compiling plugins (e.g. my pim-plugin) under gcc 2.95.4

__STL_CONFIG_H is defined to prevent the "redefinition of swap" error (vdr/tools.h).

I've now tracked it down to a simple c++ programm using STL - when
__STL_CONFIG_H is defined it doesn't compile
(see error messages at end of post)

It seems the global flag __STL_CONFIG_H is used in the global stl-header-files too
and does some bad things in the background.

For a test I've renamed __STL_CONFIG_H in vdr/tools.h and used this new flag
in my Makefile -> worked.

So my proposal is to rename __STL_CONFIG_H in vdr/tools.h

Bye
Achim

sepp:~# cat x.C
#include <vector>
int main(int argc, char** argv)
{
}
sepp:~# g++ -D__STL_CONFIG_H x.C
In file included from /usr/lib/gcc-lib/i386-linux/2.95.4/../../../../include/g++-3/stl_algobase.h:39,
from /usr/lib/gcc-lib/i386-linux/2.95.4/../../../../include/g++-3/vector:30,
from x.C:1:
/usr/lib/gcc-lib/i386-linux/2.95.4/../../../../include/g++-3/stl_relops.h:36: syntax error before `template'
In file included from /usr/lib/gcc-lib/i386-linux/2.95.4/../../../../include/g++-3/stl_algobase.h:42,
from /usr/lib/gcc-lib/i386-linux/2.95.4/../../../../include/g++-3/vector:30,
from x.C:1:
/usr/lib/gcc-lib/i386-linux/2.95.4/../../../../include/g++-3/stl_pair.h:36: syntax error before `template'

< ... many more lines ... >















Home | Main Index | Thread Index