Option --disable-static-shell breaks .dbinfo command

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Option --disable-static-shell breaks .dbinfo command

Nate Case

When building with the --disable-static-shell configure option from
the autoconf release package, it looks like the sqlite default CFLAGS
only get passed into direct gcc invocations and not the libtool

One consequence of this is that ".dbinfo" doesn't work because
SQLITE_ENABLE_DBPAGE_VTAB didn't get enabled.

To reproduce:

    $ tar -xf sqlite-autoconf-3290000.tar.gz
    $ cd sqlite-autoconf-3290000 ; ./configure --disable-static-shell
    checking for a BSD-compatible install... /usr/bin/install -c
    checking whether build environment is sane... yes
    checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
    config.status: creating Makefile
    config.status: creating sqlite3.pc
    config.status: executing depfiles commands
    config.status: executing libtool commands

    $ make
    /bin/sh ./libtool  --tag=CC   --mode=compile gcc
    -DPACKAGE_NAME=\"sqlite\" -DPACKAGE_TARNAME=\"sqlite\"
    -DPACKAGE_VERSION=\"3.29.0\" -DPACKAGE_STRING=\"sqlite\ 3.29.0\"
    -g -O2 -MT sqlite3.lo -MD -MP -MF .deps/sqlite3.Tpo -c -o sqlite3.lo
    gcc -DPACKAGE_NAME=\"sqlite\" -DPACKAGE_TARNAME=\"sqlite\"
    -DPACKAGE_VERSION=\"3.29.0\" -DPACKAGE_STRING=\"sqlite\ 3.29.0\"
    sqlite3-shell.o -MD -MP -MF .deps/sqlite3-shell.Tpo -c -o
    sqlite3-shell.o `test -f 'shell.c' || echo './'`shell.c

    $ ./sqlite3 path/to/test.db .dbinfo
    the ".dbinfo" command requires the -DSQLITE_ENABLE_DBPAGE_VTAB compile-time options

Older versions would simply report "unable to read database header"

Repeating this without --disable-static-shell works fine.

This *seems* like a bug to me.  The broken .dbinfo command issue has
been present since version 3.21.0 with the introduction of the
sqlite_dbpage virtual table.  I can work around this easily enough
by forcing the CFLAGS back in, but I thought I'd report this so it could
potentially be addressed upstream.


Nate Case <[hidden email]>

sqlite-users mailing list
[hidden email]