UnQLite Users Forum

unqlite.h:651:15: error: changes meaning of ‘pgno’ from ‘typedef sxu64 pgno’ [-fpermissive]

append delete ttkdroid

Just downloaded the unqlite.c and unqlite.h, created a new project in Eclipse, copied one of the examples from unqlite.org website and i'm getting the following error:

21:37:51 **** Build of configuration Debug for project nosql ****
make all
Building file: ../main.cpp
Invoking: Cross G++ Compiler
g++ -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"main.d" -MT"main.d" -o "main.o" "../main.cpp"
In file included from ../main.cpp:49:0:
../unqlite.h:661:8: error: declaration of ‘pgno unqlite_page::pgno’ [-fpermissive]
pgno pgno; /* Page number for this page */
../unqlite.h:651:15: error: changes meaning of ‘pgno’ from ‘typedef sxu64 pgno’ [-fpermissive]
typedef sxu64 pgno;
subdir.mk:25: recipe for target 'main.o' failed
make: *** [main.o] Error 1

21:37:51 Build Finished (took 171ms)

what is the trick?

I'm using

gcc version 4.9.2 (Debian 4.9.2-10)



Reply RSS


append delete #1. chm

Try to apply this patch: http://unqlite.org/db/g++421patch.diff or compile using a C compiler (gcc instead of g++à


(Leave this as-is, it’s a trap!)

There is no need to “register”, just enter the same name + password of your choice every time.

Pro tip: Use markup to add links, quotes and more.

Your friendly neighbourhood moderators: chm_at_symisc, devel_at_symisc