esp32-idf-sqlite3
esp32-idf-sqlite3 copied to clipboard
How to compile using idf.py instead of make
Can't compile using idf.py. How to compile using idf.py instead of make
Tried directly including, but the following result /main/sqlite3.c ../main/sqlite3.c: In function 'strftimeFunc': ../main/sqlite3.c:13957:27: warning: cast between incompatible function types from 'int (*)(void )' to 'void ()(void )' [-Wcast-function-type] #define SQLITE_DYNAMIC ((sqlite3_destructor_type)sqlite3MallocSize) ^ ../main/sqlite3.c:21749:52: note: in expansion of macro 'SQLITE_DYNAMIC' z==zBuf ? SQLITE_TRANSIENT : SQLITE_DYNAMIC); ^~~~~~~~~~~~~~ ../main/sqlite3.c: In function 'sqlite3ErrorWithMsg': ../main/sqlite3.c:13957:27: warning: cast between incompatible function types from 'int ()(void )' to 'void ()(void )' [-Wcast-function-type] #define SQLITE_DYNAMIC ((sqlite3_destructor_type)sqlite3MallocSize) ^ ../main/sqlite3.c:30000:54: note: in expansion of macro 'SQLITE_DYNAMIC' sqlite3ValueSetStr(db->pErr, -1, z, SQLITE_UTF8, SQLITE_DYNAMIC); ^~~~~~~~~~~~~~ ../main/sqlite3.c: In function 'balance_nonroot': ../main/sqlite3.c:70620:11: warning: unused variable 'key' [-Wunused-variable] u32 key = get4byte(&apNew[i]->aData[8]); ^~~ ../main/sqlite3.c: In function 'balance': ../main/sqlite3.c:70741:6: warning: unused variable 'aBalanceQuickSpace' [-Wunused-variable] u8 aBalanceQuickSpace[13]; ^~~~~~~~~~~~~~~~~~ ../main/sqlite3.c: In function 'sqlite3VdbeMemSetStr': ../main/sqlite3.c:13957:27: warning: cast between incompatible function types from 'int ()(void )' to 'void ()(void )' [-Wcast-function-type] #define SQLITE_DYNAMIC ((sqlite3_destructor_type)sqlite3MallocSize) ^ ../main/sqlite3.c:74734:19: note: in expansion of macro 'SQLITE_DYNAMIC' }else if( xDel==SQLITE_DYNAMIC ){ ^~~~~~~~~~~~~~ ../main/sqlite3.c: In function 'valueFromExpr': ../main/sqlite3.c:13957:27: warning: cast between incompatible function types from 'int ()(void )' to 'void ()(void *)' [-Wcast-function-type] #define SQLITE_DYNAMIC ((sqlite3_destructor_type)sqlite3MallocSize) ^ ../main/sqlite3.c:75139:55: note: in expansion of macro 'SQLITE_DYNAMIC' sqlite3ValueSetStr(pVal, -1, zVal, SQLITE_UTF8, SQLITE_DYNAMIC); ^~~~~~~~~~~~~~ ../main/sqlite3.c: In function 'sqlite3VdbeHalt': ../main/sqlite3.c:20225:34: error: statement with no effect [-Werror=unused-value]
define sqlite3VdbeCheckFk(p,i) 0
^
../main/sqlite3.c:78355:7: note: in expansion of macro 'sqlite3VdbeCheckFk' sqlite3VdbeCheckFk(p, 0); ^~~~~~~~~~~~~~~~~~ ../main/sqlite3.c: In function 'sqlite3AlterFinishAddColumn': ../main/sqlite3.c:101398:10: warning: variable 'pTab' set but not used [-Wunused-but-set-variable] Table pTab; / Table being altered / ^~~~ ../main/sqlite3.c: In function 'printfFunc': ../main/sqlite3.c:13957:27: warning: cast between incompatible function types from 'int ()(void )' to 'void ()(void )' [-Wcast-function-type] #define SQLITE_DYNAMIC ((sqlite3_destructor_type)sqlite3MallocSize) ^ ../main/sqlite3.c:111863:25: note: in expansion of macro 'SQLITE_DYNAMIC' SQLITE_DYNAMIC); ^~~~~~~~~~~~~~ ../main/sqlite3.c: In function 'sqlite3Insert': ../main/sqlite3.c:116145:1: error: label 'insert_end' defined but not used [-Werror=unused-label] insert_end: ^~~~~~~~~~ ../main/sqlite3.c: In function 'generateColumnNames': ../main/sqlite3.c:13957:27: warning: cast between incompatible function types from 'int ()(void )' to 'void ()(void )' [-Wcast-function-type] #define SQLITE_DYNAMIC ((sqlite3_destructor_type)sqlite3MallocSize) ^ ../main/sqlite3.c:125012:58: note: in expansion of macro 'SQLITE_DYNAMIC' sqlite3VdbeSetColName(v, i, COLNAME_NAME, zName, SQLITE_DYNAMIC); ^~~~~~~~~~~~~~ ../main/sqlite3.c:13957:27: warning: cast between incompatible function types from 'int ()(void )' to 'void ()(void )' [-Wcast-function-type] #define SQLITE_DYNAMIC ((sqlite3_destructor_type)sqlite3MallocSize) ^ ../main/sqlite3.c:125019:52: note: in expansion of macro 'SQLITE_DYNAMIC' sqlite3VdbeSetColName(v, i, COLNAME_NAME, z, SQLITE_DYNAMIC); ^~~~~~~~~~~~~~ ../main/sqlite3.c: In function 'flattenSubquery': ../main/sqlite3.c:1456:29: error: statement with no effect [-Werror=unused-value] #define SQLITE_OK 0 / Successful result */ ^ ../main/sqlite3.c:18824:41: note: in expansion of macro 'SQLITE_OK'
define sqlite3AuthCheck(a,b,c,d,e) SQLITE_OK
^~~~~~~~~
../main/sqlite3.c:126949:17: note: in expansion of macro 'sqlite3AuthCheck' TESTONLY(i =) sqlite3AuthCheck(pParse, SQLITE_SELECT, 0, 0, 0); ^~~~~~~~~~~~~~~~ ../main/sqlite3.c: In function 'sqlite3Select': ../main/sqlite3.c:1456:29: error: statement with no effect [-Werror=unused-value] #define SQLITE_OK 0 /* Successful result */ ^ ../main/sqlite3.c:18824:41: note: in expansion of macro 'SQLITE_OK'
define sqlite3AuthCheck(a,b,c,d,e) SQLITE_OK
^~~~~~~~~
../main/sqlite3.c:128924:7: note: in expansion of macro 'sqlite3AuthCheck' sqlite3AuthCheck(pParse, SQLITE_READ, pItem->zName, "", pItem->zDatabase); ^~~~~~~~~~~~~~~~ ../main/sqlite3.c: In function 'sqlite3DropTriggerPtr': ../main/sqlite3.c:130532:12: warning: variable 'pTable' set but not used [-Wunused-but-set-variable] Table pTable; ^~~~~~ ../main/sqlite3.c: In function 'sqlite3VtabBeginParse': ../main/sqlite3.c:133021:7: warning: variable 'iDb' set but not used [-Wunused-but-set-variable] int iDb; / The database the table is being created in / ^~~ ../main/sqlite3.c: In function 'whereLoopAddBtree': ../main/sqlite3.c:141187:10: warning: variable 'rLogSize' set but not used [-Wunused-but-set-variable] LogEst rLogSize; / Logarithm of the number of rows in the table / ^~~~~~~~ ../main/sqlite3.c: In function 'sqlite3InvokeBusyHandler': ../main/sqlite3.c:153341:12: warning: cast between incompatible function types from 'int ()(void , int)' to 'int ()(void , int, sqlite3_file )' {aka 'int ()(void , int, struct sqlite3_file )'} [-Wcast-function-type] xTra = (int()(void,int,sqlite3_file))p->xBusyHandler; ^ ../main/sqlite3.c: In function 'sqlite3_busy_timeout': ../main/sqlite3.c:153419:30: warning: cast between incompatible function types from 'int ()(void , int, sqlite3_file )' {aka 'int ()(void , int, struct sqlite3_file )'} to 'int ()(void , int)' [-Wcast-function-type] sqlite3_busy_handler(db, (int()(void,int))sqliteDefaultBusyCallback, ^ ../main/sqlite3.c: At top level: ../main/sqlite3.c:14199:20: warning: 'sqlite3BtreeIncrVacuum' declared 'static' but never defined [-Wunused-function] SQLITE_PRIVATE int sqlite3BtreeIncrVacuum(Btree ); ^~~~~~~~~~~~~~~~~~~~~~ ../main/sqlite3.c:14416:22: warning: 'sqlite3BtreeIntegrityCheck' declared 'static' but never defined [-Wunused-function] SQLITE_PRIVATE char sqlite3BtreeIntegrityCheck(Btree, int aRoot, int nRoot, int, int); ^~~~~~~~~~~~~~~~~~~~~~~~~~ ../main/sqlite3.c:15258:20: warning: 'sqlite3PagerMovepage' declared 'static' but never defined [-Wunused-function] SQLITE_PRIVATE int sqlite3PagerMovepage(Pager,DbPage,Pgno,int); ^~~~~~~~~~~~~~~~~~~~ ../main/sqlite3.c:18893:22: warning: 'sqlite3HexToBlob' declared 'static' but never defined [-Wunused-function] SQLITE_PRIVATE void sqlite3HexToBlob(sqlite3, const char z, int n); ^~~~~~~~~~~~~~~~ ../main/sqlite3.c:18957:21: warning: 'sqlite3RootPageMoved' declared 'static' but never defined [-Wunused-function] SQLITE_PRIVATE void sqlite3RootPageMoved(sqlite3, int, int, int); ^~~~~~~~~~~~~~~~~~~~ ../main/sqlite3.c:20134:20: warning: 'sqlite3VdbeList' declared 'static' but never defined [-Wunused-function] SQLITE_PRIVATE int sqlite3VdbeList(Vdbe); ^~~~~~~~~~~~~~~ ../main/sqlite3.c:20173:28: warning: 'sqlite3OpcodeName' declared 'static' but never defined [-Wunused-function] SQLITE_PRIVATE const char sqlite3OpcodeName(int); ^~~~~~~~~~~~~~~~~ ../main/sqlite3.c:115455:12: warning: 'xferOptimization' declared 'static' but never defined [-Wunused-function] static int xferOptimization( ^~~~~~~~~~~~~~~~ ../main/sqlite3.c: In function 'sqlite3_db_status': ../main/sqlite3.c:20572:10: warning: this statement may fall through [-Wimplicit-fallthrough=] op = SQLITE_DBSTATUS_CACHE_WRITE+1; ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ../main/sqlite3.c:20574:5: note: here case SQLITE_DBSTATUS_CACHE_HIT: ^~~~ ../main/sqlite3.c: In function 'sqlite3_str_vappendf': ../main/sqlite3.c:27280:19: warning: this statement may fall through [-Wimplicit-fallthrough=] flag_long = sizeof(char)==sizeof(i64) ? 2 : ~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ sizeof(char*)==sizeof(long int) ? 1 : 0; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ../main/sqlite3.c:27283:7: note: here case etORDINAL: ^~~~ ../main/sqlite3.c:27285:19: warning: this statement may fall through [-Wimplicit-fallthrough=] cThousand = 0; ~~~~~~~~~~^~~ ../main/sqlite3.c:27287:7: note: here case etDECIMAL: ^~~~ ../main/sqlite3.c: In function 'sqlite3GetToken': ../main/sqlite3.c:151072:9: warning: this statement may fall through [-Wimplicit-fallthrough=] if( !sqlite3Isdigit(z[1]) ) ^ ../main/sqlite3.c:151081:5: note: here case CC_DIGIT: { ^~~~ ../main/sqlite3.c: In function 'sqlite3ExprCodeTarget': ../main/sqlite3.c:99150:25: warning: this statement may fall through [-Wimplicit-fallthrough=] case TK_AGG_COLUMN: { ^ ../main/sqlite3.c:99163:5: note: here case TK_COLUMN: { ^~~~ ../main/sqlite3.c: In function 'resolveP2Values': ../main/sqlite3.c:76200:13: warning: this statement may fall through [-Wimplicit-fallthrough=] if( pOp->p2!=0 ) p->readOnly = 0; ^ ../main/sqlite3.c:76203:9: note: here case OP_AutoCommit: ^~~~ ../main/sqlite3.c:76241:26: warning: this statement may fall through [-Wimplicit-fallthrough=] case OP_VFilter: { ^ ../main/sqlite3.c:76250:9: note: here default: { ^~~~~~~ ../main/sqlite3.c: In function 'resolveExprStep': ../main/sqlite3.c:95012:20: warning: this statement may fall through [-Wimplicit-fallthrough=] case TK_ISNOT: { ^ ../main/sqlite3.c:95028:5: note: here case TK_BETWEEN: ^~~~ ../main/sqlite3.c: In function 'impliesNotNullRow': ../main/sqlite3.c:100692:8: warning: this statement may fall through [-Wimplicit-fallthrough=] if( (pExpr->pLeft->op==TK_COLUMN && IsVirtual(pExpr->pLeft->pTab)) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ || (pExpr->pRight->op==TK_COLUMN && IsVirtual(pExpr->pRight->pTab)) ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ../main/sqlite3.c:100696:5: note: here default: ^~~~~~~ ../main/sqlite3.c: In function 'sqlite3GenerateConstraintChecks': ../main/sqlite3.c:116561:17: warning: this statement may fall through [-Wimplicit-fallthrough=] onError = OE_Abort; ^ ../main/sqlite3.c:116564:7: note: here case OE_Rollback: ^~~~ ../main/sqlite3.c:116624:9: warning: this statement may fall through [-Wimplicit-fallthrough=] sqlite3UpsertDoUpdate(pParse, pUpsert, pTab, 0, iDataCur); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ../main/sqlite3.c:116628:7: note: here case OE_Ignore: { ^~~~ ../main/sqlite3.c:116833:9: warning: this statement may fall through [-Wimplicit-fallthrough=] sqlite3UpsertDoUpdate(pParse, pUpsert, pTab, pIdx, iIdxCur+ix); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ../main/sqlite3.c:116837:7: note: here case OE_Ignore: { ^~~~ ../main/sqlite3.c: In function 'sqlite3VdbeExec': ../main/sqlite3.c:83605:5: warning: this statement may fall through [-Wimplicit-fallthrough=] if( (pIn3->flags & MEM_Null)==0 ) break; ^ ../main/sqlite3.c:83639:1: note: here case OP_Halt: { ^~~~ ../main/sqlite3.c:83772:5: warning: this statement may fall through [-Wimplicit-fallthrough=] if( pOp->p1>db->aLimit[SQLITE_LIMIT_LENGTH] ){ ^ ../main/sqlite3.c:83791:1: note: here case OP_String: { /* out2 / ^~~~ ../main/sqlite3.c:86833:19: warning: this statement may fall through [-Wimplicit-fallthrough=] case OP_IfNoHope: { / jump, in3 / ^ ../main/sqlite3.c:86841:1: note: here case OP_NoConflict: / jump, in3 */ ^~~~ ../main/sqlite3.c:87769:38: warning: this statement may fall through [-Wimplicit-fallthrough=] p->aCounter[SQLITE_STMTSTATUS_SORT]++;
../main/sqlite3.c:87788:1: note: here
case OP_Rewind: { /* jump */
^~~~
../main/sqlite3.c:89069:15: warning: this statement may fall through [-Wimplicit-fallthrough=]
pOp->opcode = OP_AggStep1;
^
../main/sqlite3.c:89072:1: note: here
case OP_AggStep1: {
^~~~
../main/sqlite3.c:89932:15: warning: this statement may fall through [-Wimplicit-fallthrough=]
pOp->opcode += 2;
~~~~~~~~~~~~^~~~
../main/sqlite3.c:89935:1: note: here
case OP_PureFunc: /* group */
^~~~
At top level:
../main/sqlite3.c:127533:15: warning: 'isSimpleCount' defined but not used [-Wunused-function]
static Table *isSimpleCount(Select *p, AggInfo *pAggInfo){
^~~~~~~~~~~~~
../main/sqlite3.c:126012:12: warning: 'generateOutputSubroutine' defined but not used [-Wunused-function]
static int generateOutputSubroutine(
^~~~~~~~~~~~~~~~~~~~~~~~
../main/sqlite3.c:120022:12: warning: 'integrityCheckResultRow' defined but not used [-Wunused-function]
static int integrityCheckResultRow(Vdbe *v){
^~~~~~~~~~~~~~~~~~~~~~~
../main/sqlite3.c:116222:12: warning: 'checkConstraintUnchanged' defined but not used [-Wunused-function]
static int checkConstraintUnchanged(Expr *pExpr, int *aiChng, int chngRowid){
^~~~~~~~~~~~~~~~~~~~~~~~
../main/sqlite3.c:75997:21: warning: 'sqlite3VdbeReusable' defined but not used [-Wunused-function]
SQLITE_PRIVATE void sqlite3VdbeReusable(Vdbe *p){
^~~~~~~~~~~~~~~~~~~
../main/sqlite3.c:75790:21: warning: 'sqlite3VdbeMultiLoad' defined but not used [-Wunused-function]
SQLITE_PRIVATE void sqlite3VdbeMultiLoad(Vdbe *p, int iDest, const char *zTypes, ...){
^~~~~~~~~~~~~~~~~~~~
../main/sqlite3.c:72141:12: warning: 'btreeHeapPull' defined but not used [-Wunused-function]
static int btreeHeapPull(u32 *aHeap, u32 *pOut){
^~~~~~~~~~~~~
../main/sqlite3.c:72131:13: warning: 'btreeHeapInsert' defined but not used [-Wunused-function]
static void btreeHeapInsert(u32 *aHeap, u32 x){
^~~~~~~~~~~~~~~
../main/sqlite3.c:65591:20: warning: 'sqlite3BtreeGetAutoVacuum' defined but not used [-Wunused-function]
SQLITE_PRIVATE int sqlite3BtreeGetAutoVacuum(Btree *p){
^~~~~~~~~~~~~~~~~~~~~~~~~
../main/sqlite3.c:65567:20: warning: 'sqlite3BtreeSetAutoVacuum' defined but not used [-Wunused-function]
SQLITE_PRIVATE int sqlite3BtreeSetAutoVacuum(Btree *p, int autoVacuum){
^~~~~~~~~~~~~~~~~~~~~~~~~
../main/sqlite3.c:63163:13: warning: 'invalidateAllOverflowCache' defined but not used [-Wunused-function]
static void invalidateAllOverflowCache(BtShared *pBt){
^~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
ninja: build stopped: subcommand failed.
ninja failed with exit code 1