You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I get a strange compile error building partio on centos 6.2. I'm actually building the redpawfx fork, but at a glance, it looks like the issue is not in the forked changes, so I'll post the issue here - please let me know if you'd like me to move the issue to that repo!
Anyway, when building the PDB files, I get a lot of errors similar to this
[ 20%] Building CXX object src/lib/CMakeFiles/partio.dir/io/PDB.o
cd /home/users/matteb/Downloads/partio/partio.build/src/lib && /usr/bin/c++ -DPARTIO_USE_ZLIB -fPIC -O3 -DNDEBUG -I/home/users/matteb/Downloads/partio/src/lib -Wall -o CMakeFiles/partio.dir/io/PDB.o -c /home/users/matteb/Downloads/partio/src/lib/io/PDB.cpp
In file included from /usr/include/stdio.h:929,
from /home/users/matteb/Downloads/partio/src/lib/io/pdb.h:48,
from /home/users/matteb/Downloads/partio/src/lib/io/PDB.cpp:41:
/usr/include/bits/stdio.h: In function ‘int PDB::vprintf(const char_, va_list_tag)’:
/usr/include/bits/stdio.h:39: error: cannot convert ‘PDB::IO_FILE’ to ‘FILE’ for argument ‘1’ to ‘int PDB::vfprintf(FILE_, const char_, va_list_tag)’
/usr/include/bits/stdio.h: In function ‘int PDB::fgetc_unlocked(FILE)’:
/usr/include/bits/stdio.h:56: error: invalid use of incomplete type ‘struct _IO_FILE’
/usr/include/stdio.h:45: error: forward declaration of ‘struct _IO_FILE’
/usr/include/bits/stdio.h:56: error: invalid use of incomplete type ‘struct _IO_FILE’
/usr/include/stdio.h:45: error: forward declaration of ‘struct _IO_FILE’
...
I'm not an expert with C++ build issues, but I noticed it was looking at PDB::fgetc, which seems like it's putting the standard library stuff in the PDB namespace. I edited PDB.cpp and removed the:
namespace PDB
from around:
#include "pdb.h"
and put the namespace PDB in pdb.h directly, after
#include <stdio.h>
#include <stdlib.h>
This now compiles correctly.
Is this a genuine bug? Or maybe a mis-configuration on this system?
cheers
The text was updated successfully, but these errors were encountered:
Hi,
I get a strange compile error building partio on centos 6.2. I'm actually building the redpawfx fork, but at a glance, it looks like the issue is not in the forked changes, so I'll post the issue here - please let me know if you'd like me to move the issue to that repo!
Anyway, when building the PDB files, I get a lot of errors similar to this
[ 20%] Building CXX object src/lib/CMakeFiles/partio.dir/io/PDB.o
cd /home/users/matteb/Downloads/partio/partio.build/src/lib && /usr/bin/c++ -DPARTIO_USE_ZLIB -fPIC -O3 -DNDEBUG -I/home/users/matteb/Downloads/partio/src/lib -Wall -o CMakeFiles/partio.dir/io/PDB.o -c /home/users/matteb/Downloads/partio/src/lib/io/PDB.cpp
In file included from /usr/include/stdio.h:929,
from /home/users/matteb/Downloads/partio/src/lib/io/pdb.h:48,
from /home/users/matteb/Downloads/partio/src/lib/io/PDB.cpp:41:
/usr/include/bits/stdio.h: In function ‘int PDB::vprintf(const char_, va_list_tag)’:
/usr/include/bits/stdio.h:39: error: cannot convert ‘PDB::IO_FILE’ to ‘FILE’ for argument ‘1’ to ‘int PDB::vfprintf(FILE_, const char_, va_list_tag)’
/usr/include/bits/stdio.h: In function ‘int PDB::fgetc_unlocked(FILE)’:
/usr/include/bits/stdio.h:56: error: invalid use of incomplete type ‘struct _IO_FILE’
/usr/include/stdio.h:45: error: forward declaration of ‘struct _IO_FILE’
/usr/include/bits/stdio.h:56: error: invalid use of incomplete type ‘struct _IO_FILE’
/usr/include/stdio.h:45: error: forward declaration of ‘struct _IO_FILE’
...
I'm not an expert with C++ build issues, but I noticed it was looking at PDB::fgetc, which seems like it's putting the standard library stuff in the PDB namespace. I edited PDB.cpp and removed the:
namespace PDB
from around:
#include "pdb.h"
and put the namespace PDB in pdb.h directly, after
#include <stdio.h>
#include <stdlib.h>
This now compiles correctly.
Is this a genuine bug? Or maybe a mis-configuration on this system?
cheers
The text was updated successfully, but these errors were encountered: