SQLite Archiver

Ticket Change Details
Login
Overview

Artifact ID: ff69f7f1b82889b18fc3d5132d7d4b41b4bdbcf5
Ticket: 3e634a02c6d3e024351b8b5ecf4432ab7e18d772
Werror fails on GCC 11
User & Date: anonymous 2022-04-01 20:47:41
Changes

  1. foundin changed to: "372361d5526ed537|372361d552"
  2. icomment:
    GCC 11 picks up an indentation problem as a warning, and so -Werror fails the build.  This doesn't change the software from functioning but anything that causes a build with default options to fail is going to exclude it from software packaging systems.
    
    ```
    $ make
    gcc -g -I. -D_FILE_OFFSET_BITS=64 -Wall -Werror   -DSQLITE_THREADSAFE=0 -DSQLITE_OMIT_LOAD_EXTENSION -c sqlite3.c
    sqlite3.c: In function ‘sqlite3DefaultRowEst’:
    sqlite3.c:103150:3: error: this ‘if’ clause does not guard... [-Werror=misleading-indentation]
    103150 |   if( pIdx->pPartIdxWhere!=0 ) a[0] -= 10;  assert( 10==sqlite3LogEst(2) );
           |   ^~
    In file included from sqlite3.c:11616:
    sqlite3.c:103150:45: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
    103150 |   if( pIdx->pPartIdxWhere!=0 ) a[0] -= 10;  assert( 10==sqlite3LogEst(2) );
           |                                             ^~~~~~
    sqlite3.c:103151:3: error: this ‘if’ clause does not guard... [-Werror=misleading-indentation]
    103151 |   if( a[0]<33 ) a[0] = 33;                  assert( 33==sqlite3LogEst(10) );
           |   ^~
    In file included from sqlite3.c:11616:
    sqlite3.c:103151:45: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
    103151 |   if( a[0]<33 ) a[0] = 33;                  assert( 33==sqlite3LogEst(10) );
           |                                             ^~~~~~
    cc1: all warnings being treated as errors
    make: *** [Makefile:21: sqlite3.o] Error 1
    $ gcc --version
    gcc (GCC) 11.2.0
    Copyright (C) 2021 Free Software Foundation, Inc.
    This is free software; see the source for copying conditions.  There is NO
    warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
    
    $ 
    ```
    
  3. login: "anonymous"
  4. mimetype: "text/x-markdown"
  5. private_contact changed to: "38ce3484cda437461eb30faef0d79d520dcac827"
  6. severity changed to: "Important"
  7. status changed to: "Open"
  8. title changed to: "Werror fails on GCC 11"
  9. type changed to: "Build_Problem"