Fossil SCM
Begin adding infrastructure to support full-text search using FTS4.
Commit
9f9dfe3a9881aeb8ff912aa329871399c0b9ee87
Parent
47a9d3899a69b2c…
12 files changed
+22
-13
+303
+15
-3
+2
-2
+1
-1
+2
-2
+1
+1
-1
+1
-1
+11
-5
+14
-2
+12
-2
M
src/db.c
+22
-13
| --- src/db.c | ||
| +++ src/db.c | ||
| @@ -688,10 +688,25 @@ | ||
| 688 | 688 | z = 0; |
| 689 | 689 | } |
| 690 | 690 | db_finalize(&s); |
| 691 | 691 | return z; |
| 692 | 692 | } |
| 693 | + | |
| 694 | +/* | |
| 695 | +** Invoke sqlite3_close() but also check its return code and if the | |
| 696 | +** return code is SQLITE_BUSY, report errors. | |
| 697 | +*/ | |
| 698 | +static void db_close_with_checks(sqlite3 *db, int reportErrors){ | |
| 699 | + int rc = sqlite3_close(db); | |
| 700 | + if( rc==SQLITE_BUSY && reportErrors ){ | |
| 701 | + sqlite3_stmt *pStmt; | |
| 702 | + while( (pStmt = sqlite3_next_stmt(g.db, pStmt))!=0 ){ | |
| 703 | + fossil_warning("unfinalized SQL statement: [%s]", sqlite3_sql(pStmt)); | |
| 704 | + } | |
| 705 | + } | |
| 706 | +} | |
| 707 | + | |
| 693 | 708 | |
| 694 | 709 | /* |
| 695 | 710 | ** Initialize a new database file with the given schema. If anything |
| 696 | 711 | ** goes wrong, call db_err() to exit. |
| 697 | 712 | */ |
| @@ -822,10 +837,11 @@ | ||
| 822 | 837 | 0, 0 |
| 823 | 838 | ); |
| 824 | 839 | if( g.fSqlTrace ) sqlite3_trace(db, db_sql_trace, 0); |
| 825 | 840 | re_add_sql_func(db); |
| 826 | 841 | foci_register(db); |
| 842 | + ftsearch_add_sql_func(db); | |
| 827 | 843 | sqlite3_exec(db, "PRAGMA foreign_keys=OFF;", 0, 0, 0); |
| 828 | 844 | return db; |
| 829 | 845 | } |
| 830 | 846 | |
| 831 | 847 | |
| @@ -867,24 +883,24 @@ | ||
| 867 | 883 | } |
| 868 | 884 | |
| 869 | 885 | /* |
| 870 | 886 | ** Close the user database. |
| 871 | 887 | */ |
| 872 | -void db_close_config(){ | |
| 888 | +void db_close_config(int reportErrors){ | |
| 873 | 889 | if( g.useAttach ){ |
| 874 | 890 | db_detach("configdb"); |
| 875 | 891 | g.useAttach = 0; |
| 876 | 892 | g.zConfigDbName = 0; |
| 877 | 893 | }else if( g.dbConfig ){ |
| 878 | 894 | sqlite3_wal_checkpoint(g.dbConfig, 0); |
| 879 | - sqlite3_close(g.dbConfig); | |
| 895 | + db_close_with_checks(g.dbConfig, reportErrors); | |
| 880 | 896 | g.dbConfig = 0; |
| 881 | 897 | g.zConfigDbType = 0; |
| 882 | 898 | g.zConfigDbName = 0; |
| 883 | 899 | }else if( g.db && fossil_strcmp(g.zMainDbType, "configdb")==0 ){ |
| 884 | 900 | sqlite3_wal_checkpoint(g.db, 0); |
| 885 | - sqlite3_close(g.db); | |
| 901 | + db_close_with_checks(g.db, reportErrors); | |
| 886 | 902 | g.db = 0; |
| 887 | 903 | g.zMainDbType = 0; |
| 888 | 904 | g.zConfigDbName = 0; |
| 889 | 905 | } |
| 890 | 906 | } |
| @@ -904,11 +920,11 @@ | ||
| 904 | 920 | void db_open_config(int useAttach){ |
| 905 | 921 | char *zDbName; |
| 906 | 922 | char *zHome; |
| 907 | 923 | if( g.zConfigDbName ){ |
| 908 | 924 | if( useAttach==g.useAttach ) return; |
| 909 | - db_close_config(); | |
| 925 | + db_close_config(1); | |
| 910 | 926 | } |
| 911 | 927 | #if defined(_WIN32) || defined(__CYGWIN__) |
| 912 | 928 | zHome = fossil_getenv("LOCALAPPDATA"); |
| 913 | 929 | if( zHome==0 ){ |
| 914 | 930 | zHome = fossil_getenv("APPDATA"); |
| @@ -1295,11 +1311,10 @@ | ||
| 1295 | 1311 | ** |
| 1296 | 1312 | ** Check for unfinalized statements and report errors if the reportErrors |
| 1297 | 1313 | ** argument is true. Ignore unfinalized statements when false. |
| 1298 | 1314 | */ |
| 1299 | 1315 | void db_close(int reportErrors){ |
| 1300 | - sqlite3_stmt *pStmt; | |
| 1301 | 1316 | if( g.db==0 ) return; |
| 1302 | 1317 | if( g.fSqlStats ){ |
| 1303 | 1318 | int cur, hiwtr; |
| 1304 | 1319 | sqlite3_db_status(g.db, SQLITE_DBSTATUS_LOOKASIDE_USED, &cur, &hiwtr, 0); |
| 1305 | 1320 | fprintf(stderr, "-- LOOKASIDE_USED %10d %10d\n", cur, hiwtr); |
| @@ -1327,20 +1342,14 @@ | ||
| 1327 | 1342 | } |
| 1328 | 1343 | while( db.pAllStmt ){ |
| 1329 | 1344 | db_finalize(db.pAllStmt); |
| 1330 | 1345 | } |
| 1331 | 1346 | db_end_transaction(1); |
| 1332 | - pStmt = 0; | |
| 1333 | - if( reportErrors ){ | |
| 1334 | - while( (pStmt = sqlite3_next_stmt(g.db, pStmt))!=0 ){ | |
| 1335 | - fossil_warning("unfinalized SQL statement: [%s]", sqlite3_sql(pStmt)); | |
| 1336 | - } | |
| 1337 | - } | |
| 1338 | - db_close_config(); | |
| 1347 | + db_close_config(reportErrors); | |
| 1339 | 1348 | if( g.db ){ |
| 1340 | 1349 | sqlite3_wal_checkpoint(g.db, 0); |
| 1341 | - sqlite3_close(g.db); | |
| 1350 | + db_close_with_checks(g.db, reportErrors); | |
| 1342 | 1351 | g.db = 0; |
| 1343 | 1352 | g.zMainDbType = 0; |
| 1344 | 1353 | } |
| 1345 | 1354 | g.repositoryOpen = 0; |
| 1346 | 1355 | g.localOpen = 0; |
| 1347 | 1356 | |
| 1348 | 1357 | ADDED src/ftsearch.c |
| --- src/db.c | |
| +++ src/db.c | |
| @@ -688,10 +688,25 @@ | |
| 688 | z = 0; |
| 689 | } |
| 690 | db_finalize(&s); |
| 691 | return z; |
| 692 | } |
| 693 | |
| 694 | /* |
| 695 | ** Initialize a new database file with the given schema. If anything |
| 696 | ** goes wrong, call db_err() to exit. |
| 697 | */ |
| @@ -822,10 +837,11 @@ | |
| 822 | 0, 0 |
| 823 | ); |
| 824 | if( g.fSqlTrace ) sqlite3_trace(db, db_sql_trace, 0); |
| 825 | re_add_sql_func(db); |
| 826 | foci_register(db); |
| 827 | sqlite3_exec(db, "PRAGMA foreign_keys=OFF;", 0, 0, 0); |
| 828 | return db; |
| 829 | } |
| 830 | |
| 831 | |
| @@ -867,24 +883,24 @@ | |
| 867 | } |
| 868 | |
| 869 | /* |
| 870 | ** Close the user database. |
| 871 | */ |
| 872 | void db_close_config(){ |
| 873 | if( g.useAttach ){ |
| 874 | db_detach("configdb"); |
| 875 | g.useAttach = 0; |
| 876 | g.zConfigDbName = 0; |
| 877 | }else if( g.dbConfig ){ |
| 878 | sqlite3_wal_checkpoint(g.dbConfig, 0); |
| 879 | sqlite3_close(g.dbConfig); |
| 880 | g.dbConfig = 0; |
| 881 | g.zConfigDbType = 0; |
| 882 | g.zConfigDbName = 0; |
| 883 | }else if( g.db && fossil_strcmp(g.zMainDbType, "configdb")==0 ){ |
| 884 | sqlite3_wal_checkpoint(g.db, 0); |
| 885 | sqlite3_close(g.db); |
| 886 | g.db = 0; |
| 887 | g.zMainDbType = 0; |
| 888 | g.zConfigDbName = 0; |
| 889 | } |
| 890 | } |
| @@ -904,11 +920,11 @@ | |
| 904 | void db_open_config(int useAttach){ |
| 905 | char *zDbName; |
| 906 | char *zHome; |
| 907 | if( g.zConfigDbName ){ |
| 908 | if( useAttach==g.useAttach ) return; |
| 909 | db_close_config(); |
| 910 | } |
| 911 | #if defined(_WIN32) || defined(__CYGWIN__) |
| 912 | zHome = fossil_getenv("LOCALAPPDATA"); |
| 913 | if( zHome==0 ){ |
| 914 | zHome = fossil_getenv("APPDATA"); |
| @@ -1295,11 +1311,10 @@ | |
| 1295 | ** |
| 1296 | ** Check for unfinalized statements and report errors if the reportErrors |
| 1297 | ** argument is true. Ignore unfinalized statements when false. |
| 1298 | */ |
| 1299 | void db_close(int reportErrors){ |
| 1300 | sqlite3_stmt *pStmt; |
| 1301 | if( g.db==0 ) return; |
| 1302 | if( g.fSqlStats ){ |
| 1303 | int cur, hiwtr; |
| 1304 | sqlite3_db_status(g.db, SQLITE_DBSTATUS_LOOKASIDE_USED, &cur, &hiwtr, 0); |
| 1305 | fprintf(stderr, "-- LOOKASIDE_USED %10d %10d\n", cur, hiwtr); |
| @@ -1327,20 +1342,14 @@ | |
| 1327 | } |
| 1328 | while( db.pAllStmt ){ |
| 1329 | db_finalize(db.pAllStmt); |
| 1330 | } |
| 1331 | db_end_transaction(1); |
| 1332 | pStmt = 0; |
| 1333 | if( reportErrors ){ |
| 1334 | while( (pStmt = sqlite3_next_stmt(g.db, pStmt))!=0 ){ |
| 1335 | fossil_warning("unfinalized SQL statement: [%s]", sqlite3_sql(pStmt)); |
| 1336 | } |
| 1337 | } |
| 1338 | db_close_config(); |
| 1339 | if( g.db ){ |
| 1340 | sqlite3_wal_checkpoint(g.db, 0); |
| 1341 | sqlite3_close(g.db); |
| 1342 | g.db = 0; |
| 1343 | g.zMainDbType = 0; |
| 1344 | } |
| 1345 | g.repositoryOpen = 0; |
| 1346 | g.localOpen = 0; |
| 1347 | |
| 1348 | DDED src/ftsearch.c |
| --- src/db.c | |
| +++ src/db.c | |
| @@ -688,10 +688,25 @@ | |
| 688 | z = 0; |
| 689 | } |
| 690 | db_finalize(&s); |
| 691 | return z; |
| 692 | } |
| 693 | |
| 694 | /* |
| 695 | ** Invoke sqlite3_close() but also check its return code and if the |
| 696 | ** return code is SQLITE_BUSY, report errors. |
| 697 | */ |
| 698 | static void db_close_with_checks(sqlite3 *db, int reportErrors){ |
| 699 | int rc = sqlite3_close(db); |
| 700 | if( rc==SQLITE_BUSY && reportErrors ){ |
| 701 | sqlite3_stmt *pStmt; |
| 702 | while( (pStmt = sqlite3_next_stmt(g.db, pStmt))!=0 ){ |
| 703 | fossil_warning("unfinalized SQL statement: [%s]", sqlite3_sql(pStmt)); |
| 704 | } |
| 705 | } |
| 706 | } |
| 707 | |
| 708 | |
| 709 | /* |
| 710 | ** Initialize a new database file with the given schema. If anything |
| 711 | ** goes wrong, call db_err() to exit. |
| 712 | */ |
| @@ -822,10 +837,11 @@ | |
| 837 | 0, 0 |
| 838 | ); |
| 839 | if( g.fSqlTrace ) sqlite3_trace(db, db_sql_trace, 0); |
| 840 | re_add_sql_func(db); |
| 841 | foci_register(db); |
| 842 | ftsearch_add_sql_func(db); |
| 843 | sqlite3_exec(db, "PRAGMA foreign_keys=OFF;", 0, 0, 0); |
| 844 | return db; |
| 845 | } |
| 846 | |
| 847 | |
| @@ -867,24 +883,24 @@ | |
| 883 | } |
| 884 | |
| 885 | /* |
| 886 | ** Close the user database. |
| 887 | */ |
| 888 | void db_close_config(int reportErrors){ |
| 889 | if( g.useAttach ){ |
| 890 | db_detach("configdb"); |
| 891 | g.useAttach = 0; |
| 892 | g.zConfigDbName = 0; |
| 893 | }else if( g.dbConfig ){ |
| 894 | sqlite3_wal_checkpoint(g.dbConfig, 0); |
| 895 | db_close_with_checks(g.dbConfig, reportErrors); |
| 896 | g.dbConfig = 0; |
| 897 | g.zConfigDbType = 0; |
| 898 | g.zConfigDbName = 0; |
| 899 | }else if( g.db && fossil_strcmp(g.zMainDbType, "configdb")==0 ){ |
| 900 | sqlite3_wal_checkpoint(g.db, 0); |
| 901 | db_close_with_checks(g.db, reportErrors); |
| 902 | g.db = 0; |
| 903 | g.zMainDbType = 0; |
| 904 | g.zConfigDbName = 0; |
| 905 | } |
| 906 | } |
| @@ -904,11 +920,11 @@ | |
| 920 | void db_open_config(int useAttach){ |
| 921 | char *zDbName; |
| 922 | char *zHome; |
| 923 | if( g.zConfigDbName ){ |
| 924 | if( useAttach==g.useAttach ) return; |
| 925 | db_close_config(1); |
| 926 | } |
| 927 | #if defined(_WIN32) || defined(__CYGWIN__) |
| 928 | zHome = fossil_getenv("LOCALAPPDATA"); |
| 929 | if( zHome==0 ){ |
| 930 | zHome = fossil_getenv("APPDATA"); |
| @@ -1295,11 +1311,10 @@ | |
| 1311 | ** |
| 1312 | ** Check for unfinalized statements and report errors if the reportErrors |
| 1313 | ** argument is true. Ignore unfinalized statements when false. |
| 1314 | */ |
| 1315 | void db_close(int reportErrors){ |
| 1316 | if( g.db==0 ) return; |
| 1317 | if( g.fSqlStats ){ |
| 1318 | int cur, hiwtr; |
| 1319 | sqlite3_db_status(g.db, SQLITE_DBSTATUS_LOOKASIDE_USED, &cur, &hiwtr, 0); |
| 1320 | fprintf(stderr, "-- LOOKASIDE_USED %10d %10d\n", cur, hiwtr); |
| @@ -1327,20 +1342,14 @@ | |
| 1342 | } |
| 1343 | while( db.pAllStmt ){ |
| 1344 | db_finalize(db.pAllStmt); |
| 1345 | } |
| 1346 | db_end_transaction(1); |
| 1347 | db_close_config(reportErrors); |
| 1348 | if( g.db ){ |
| 1349 | sqlite3_wal_checkpoint(g.db, 0); |
| 1350 | db_close_with_checks(g.db, reportErrors); |
| 1351 | g.db = 0; |
| 1352 | g.zMainDbType = 0; |
| 1353 | } |
| 1354 | g.repositoryOpen = 0; |
| 1355 | g.localOpen = 0; |
| 1356 | |
| 1357 | DDED src/ftsearch.c |
+303
| --- a/src/ftsearch.c | ||
| +++ b/src/ftsearch.c | ||
| @@ -0,0 +1,303 @@ | ||
| 1 | +/* | |
| 2 | +** Copyright (c) 2014 D. Richard Hipp | |
| 3 | +** | |
| 4 | +** This program is free software; you can redistribute it and/or | |
| 5 | +** modify it under the terms of the Simplified BSD License (also | |
| 6 | +** known as the "2-Clause License" or "FreeBSD License".) | |
| 7 | + | |
| 8 | +** This program is distributed in the hope that it will be useful, | |
| 9 | +** but without any warranty; without even the implied warranty of | |
| 10 | +** merchantability or fitness for a particular purpose. | |
| 11 | +** | |
| 12 | +** Author contact information: | |
| 13 | +** [email protected] | |
| 14 | +** http://www.hwaci.com/drh/ | |
| 15 | +** | |
| 16 | +******************************************************************************* | |
| 17 | +** | |
| 18 | +** This file contains code to implement a full-text search function in | |
| 19 | +** Fossil using the FTS4 feature of SQLite. | |
| 20 | +*/ | |
| 21 | +#include "config.h" | |
| 22 | +#include "ftsearch.h" | |
| 23 | +#include <assert.h> | |
| 24 | + | |
| 25 | +/* | |
| 26 | +** Document Codes: | |
| 27 | +** | |
| 28 | +** A "document code" is a string that describes a particular document. | |
| 29 | +** The first letter is the document type. Second letter is '-' (for | |
| 30 | +** human readability. Subsequent letters are a unique identifier for | |
| 31 | +** the document. | |
| 32 | +** | |
| 33 | +** c-RID - Check-in comment | |
| 34 | +** d-MID-FID - Diff on filentent(mlink.fid)" | |
| 35 | + " code to iTKTID - Ticket text | |
| 36 | +** w-TAGID - Wiki page (most recent version) | |
| 37 | +** | |
| 38 | +** The FTSEARCHXREF table provides a mapping between document codes | |
| 39 | +** (i | |
| 40 | + id | |
| 41 | + /* | |
| 42 | +** Copyright (c) 2014 D014 D. Richard Hipp | |
| 43 | +** | |
| 44 | +** This program is free software; you can redistribute it and/or | |
| 45 | +** modify it under the terms of the Simplified BSD License (also | |
| 46 | +** known as the "2-Clause License" or "FreeBSD License".) | |
| 47 | + | |
| 48 | +** This program is distributed in the hope that it will be useful, | |
| 49 | +** but without any warranty; without even the implied warranty of | |
| 50 | +** merchantability or fitness for a particular purpose. | |
| 51 | +** | |
| 52 | +** Author contact information: | |
| 53 | +** [email protected] | |
| 54 | +** http://www.hwaci.com/drh/ | |
| 55 | +** | |
| 56 | +******************************************************************************* | |
| 57 | +** | |
| 58 | +** This file contains code to implement a full-text search function in | |
| 59 | +** Fossil using the FTS4 feature of SQLite. | |
| 60 | +*/ | |
| 61 | +#include "config.h" | |
| 62 | +#include "ftsearch.h" | |
| 63 | +#include <assert.h> | |
| 64 | + | |
| 65 | +/* | |
| 66 | +** Document Codes: | |
| 67 | +** | |
| 68 | +** A "document code" is a string that describes a particular document. | |
| 69 | +** The first letter is the document type. Second letter is '-' (for | |
| 70 | +** huUUan readability. Subsequent letters are a unique identifier for | |
| 71 | +** the document. | |
| 72 | +** | |
| 73 | +** c-RID - Check-in comment | |
| 74 | +** d-MID-FID - Diff on file FID from checkin MID | |
| 75 | +** e-TAGID - Event text | |
| 76 | +** f-FNID - File content (most recent version) | |
| 77 | +** t-TKTID - Ticket text | |
| 78 | +** w-TAGID - Wiki page (most recent version) | |
| 79 | +** | |
| 80 | +** The FTSEARCHXREF table provides a mapping between document codes | |
| 81 | +** (in the FTSID column) to the DOCID of the FTS4 tablam is free software; you can redistribute it and/or | |
| 82 | +** modify it under the terms of the Simplified BSD License (also | |
| 83 | +** known as the "2-Clause The returned text is in the Wiki format and contains | |
| 84 | +** links to the docureturn zRes; | |
| 85 | +} | |
| 86 | + | |
| 87 | +/* Return a human-readable description for the document described by | |
| 88 | +** the arguments. | |
| 89 | +** | |
| 90 | +** See ftsearch_content() for further information | |
| 91 | +*/ | |
| 92 | +char *ftsearch_description( | |
| 93 | + const char *zDocType, | |
| 94 | + const char *zDocId, | |
| 95 | + int bLink /* Provide hyperlink in text if true */ | |
| 96 | +){ | |
| 97 | + char *zRes = 0; /* The result to be returned */ | |
| 98 | + int id; | |
| 99 | + if( zDocId==0 ){ | |
| 100 | + if( zDocType[0]==0 || zDocType[1]==0 ) return 0; | |
| 101 | + zDocId = zDocType + 2; | |
| 102 | + } | |
| 103 | + id = atoi(zDocId); | |
| 104 | + switch( zDocType[0] ){ | |
| 105 | + case 'c': { /* A check-in comment. zDocId is the RID */ | |
| 106 | + char *zUuid = db_text("","SELECT uuid FROM blob WHERE rid=%d", id); | |
| 107 | + zRes = mprintf("Check-in [%S]", zUuid); | |
| 108 | + fossil_free(zUuid); | |
| 109 | + break; | |
| 110 | + } | |
| 111 | + case 'f': { /* A file. zDocId is the FNID */ | |
| 112 | + char *zName = db_text("","SELECT name FROM filename WHERE fnid=%d",id); | |
| 113 | + zRes = mprintf("File %s", zName); | |
| 114 | + fossil_free(zName); | |
| 115 | + break; | |
| 116 | + } | |
| 117 | + default: { | |
| 118 | + /* No-op */ | |
| 119 | + } | |
| 120 | + } | |
| 121 | + return zRes; | |
| 122 | +} | |
| 123 | + | |
| 124 | +/* | |
| 125 | +** COMMAND: test-ftsearch-content | |
| 126 | +** | |
| 127 | +** Usage: %fossil test-ftsearch-content DOCUMENTCODE | |
| 128 | +** | |
| 129 | +** Return the content for the given DOCUMENTCODE. This command is used | |
| 130 | +** for testing and debugging the ftsearch_content() method in the | |
| 131 | +** full-text search module. | |
| 132 | +*/ | |
| 133 | +void test_doc_content_cmd(void){ | |
| 134 | + char *zContent = 0; | |
| 135 | + char *zDesc = 0; | |
| 136 | + db_find_and_open_repository(0, 0); | |
| 137 | + verify_all_options(); | |
| 138 | + if( g.argc!=3 ) usage("DOCUMENTCODE"); | |
| 139 | + if( strlen(g.argv[2])>3 ){ | |
| 140 | + zContent = ftsearch_content(g.argv[2],0); | |
| 141 | + zDesc = ftsearch_description(g.argv[2],0,0); | |
| 142 | + } | |
| 143 | + if( zDesc ){ | |
| 144 | + fossil_print("Description: %s\n", zDesc); | |
| 145 | + fossil_free(zDesc); | |
| 146 | + } | |
| 147 | + if( zContent ){ | |
| 148 | + fossil_print( | |
| 149 | + "Content -------------------------------------------------------------\n" | |
| 150 | + "%s\n" | |
| 151 | + "---------------------------------------------------------------------\n", | |
| 152 | + zContent); | |
| 153 | + fossil_free(zContent); | |
| 154 | + } | |
| 155 | +} | |
| 156 | + | |
| 157 | +/* | |
| 158 | +** Implementation of the ftsearch_content() SQL function. | |
| 159 | +*/ | |
| 160 | +static void ftsearch_content_sql_func( | |
| 161 | + sqlite3_context *context, | |
| 162 | + int argc, | |
| 163 | + sqlite3_value **argv | |
| 164 | +){ | |
| 165 | + const char *zDocType; /* [cdeftw] */ | |
| 166 | + const char *zDocId; /* Identifier based on zDocType */ | |
| 167 | + char *zRes; /* Result */ | |
| 168 | + | |
| 169 | + zDocType = (const char*)sqlite3_value_text(argv[0]); | |
| 170 | + zDocId = argc>=2 ? (const char*)sqlite3_value_text(argv[1]) : 0; | |
| 171 | + zRes = ftsearch_content(zDocType, zDocId); | |
| 172 | + if( zRes ){ | |
| 173 | + sqlite3_result_text(context, zRes, -1, (void(*)(void*))fossil_free); | |
| 174 | + } | |
| 175 | +} | |
| 176 | + | |
| 177 | +/* | |
| 178 | +** Invoke this routine in order to install the ftsearch_content() SQL | |
| 179 | +** function on an SQLite database connection. | |
| 180 | +** | |
| 181 | +** sqlite3_auto_extension(ftsearch_add_sql_func); | |
| 182 | +** | |
| 183 | +** to cause this extension to be automatically loaded into each new | |
| 184 | +** database connection. | |
| 185 | +*/ | |
| 186 | +int ftsearch_add_sql_func(sqlite3 *db){ | |
| 187 | + int rc; | |
| 188 | + rc = sqlite3_create_function(db, "ftsearch_content", 1, SQLITE_UTF8, 0, | |
| 189 | + ftsearch_content_sql_func, 0, 0); | |
| 190 | + if( rc==SQLITE_OK ){ | |
| 191 | + rc = sqlite3_create_function(db, "ftsearch_content", 2, SQLITE_UTF8, 0, | |
| 192 | + ftsearch_content_sql_func, 0, 0); | |
| 193 | + } | |
| 194 | + return rc; | |
| 195 | +} | |
| 196 | + | |
| 197 | +/* | |
| 198 | +** Delete the ftsearch tables, views, and indexes | |
| 199 | +*/ | |
| 200 | +void ftsearch_disable_all(void){ | |
| 201 | + Stmt q; | |
| 202 | + Blob sql; | |
| 203 | + db_begin_transaction(); | |
| 204 | + db_prepare(&q, | |
| 205 | + "SELECT type, name FROM %s.sqlite_master" | |
| 206 | + " WHERE type IN ('table','view')" | |
| 207 | + " AND name GLOB 'ftsearch*'" | |
| 208 | + " AND name NOT GLOB 'ftsearch_*'", | |
| 209 | + db_name("repository") | |
| 210 | + ); | |
| 211 | + blob_init(&sql, 0, 0); | |
| 212 | + while( db_step(&q)==SQLITE_ROW ){ | |
| 213 | + blob_appendf(&sql, "DROP %s IF EXISTS \"%w\";\n", | |
| 214 | + db_column_text(&q,0), db_column_text(&q,1)); | |
| 215 | + } | |
| 216 | + db_finalize(&q); | |
| 217 | + db_multi_exec("%s", blob_str(&sql)/*safe-for-%s*/); | |
| 218 | + blob_reset(&sql); | |
| 219 | + db_end_transaction(0); | |
| 220 | +} | |
| 221 | + | |
| 222 | +/* | |
| 223 | +** Completely rebuild the ftsearch indexes from scratch | |
| 224 | +*/ | |
| 225 | +void ftsearch_rebuild_all(void){ | |
| 226 | + const char *zEnables; | |
| 227 | + db_begin_transaction(); | |
| 228 | + ftsearch_disable_all(); | |
| 229 | + zEnables = db_get("ftsearch-index-type", "cdeftw"); | |
| 230 | + | |
| 231 | + /* If none of the search categories are enabled, then do not | |
| 232 | + ** bother constructing the search tables | |
| 233 | + */ | |
| 234 | + if( sqlite3_strglob("*[cdeftw]*", zEnables) ) return; | |
| 235 | + | |
| 236 | + /* The FTSSEARCHXREF table provides a mapping between the integer | |
| 237 | + ** document-ids in FTS4 to the "document codes" that describe a | |
| 238 | + ** referenced object | |
| 239 | + */ | |
| 240 | + db_multi_exec( | |
| 241 | + "CREATE TABLE %s.ftsearchxref(\n" | |
| 242 | + " docid INTEGER PRIMARY KEY,\n" /* Link to ftsearch.docid */ | |
| 243 | + " ftsid TEXT UNIQUE,\n" /* The document code */ | |
| 244 | + " mtime DATE\n" /* Timestamp on this object */ | |
| 245 | + ");\n", | |
| 246 | + db_name("repository") | |
| 247 | + ); | |
| 248 | + | |
| 249 | + /* The FTSEARCHBODY view provides the content for the FTS4 table | |
| 250 | + */ | |
| 251 | + db_multi_exec( | |
| 252 | + "CREATE VIEW %s.ftsearchbody AS" | |
| 253 | + " SELECT docid AS rowid, ftsearch_content(ftsid) AS body" | |
| 254 | + " FROM ftsearchxref;\n", | |
| 255 | + db_name("repository") | |
| 256 | + ); | |
| 257 | + | |
| 258 | + /* This is the FT */ | |
| 259 | + db_multi_exec( | |
| 260 | + ; | |
| 261 | + db_multi_exec( | |
| 262 | + "CREAT" | |
| 263 | + " USING fts4(co/* | |
| 264 | +** Copyright (c) 2014 D. Richard Hipp | |
| 265 | +** | |
| 266 | +** This program is free software; you can redistribute it and/or | |
| 267 | +** modify it under the terms of the Simplified BSD License (also | |
| 268 | +** known as the "2-Clause License" or "FreeBSD License".) | |
| 269 | + | |
| 270 | +** This program is distributed in the hope that it will be useful, | |
| 271 | +** but without any warranty; without even the implied warranty of | |
| 272 | +** merchantability or fitness for a particular purpose. | |
| 273 | +** | |
| 274 | +** Author contact information: | |
| 275 | +** [email protected] | |
| 276 | +** http://www.hwaci.com/drh/ | |
| 277 | +** | |
| 278 | +******************************************************************************* | |
| 279 | +** | |
| 280 | +** This file contains code to implement a full-text search function in | |
| 281 | +** Fossil using the FTS4 feature of SQLite. | |
| 282 | +*/ | |
| 283 | +#include "config.h" | |
| 284 | +#include "ftsearch.h" | |
| 285 | +#include <assert.h> | |
| 286 | + | |
| 287 | +/* | |
| 288 | +** Document Codes: | |
| 289 | +** | |
| 290 | +** A "document code" is a string that describes a particular document. | |
| 291 | +** The first letter is the document type. Second letter is '-' (for | |
| 292 | +** human readability. Subsequent letters are a unique identifier for | |
| 293 | +** the document. | |
| 294 | +** | |
| 295 | +** c-RID - Check-in comment | |
| 296 | +** d-MID-FID - Diff on file FID from checkin MID | |
| 297 | +** e-TAGID - Event text | |
| 298 | +** f-FNID - File content (most recent version) | |
| 299 | +** t-TKTID - Ticket text | |
| 300 | +** w-TAGID - Wiki page (most recent version) | |
| 301 | +** | |
| 302 | +** The FTSEARCHXREF table provides a mapping between document codes | |
| 303 | +** (in the FTSID column) |
| --- a/src/ftsearch.c | |
| +++ b/src/ftsearch.c | |
| @@ -0,0 +1,303 @@ | |
| --- a/src/ftsearch.c | |
| +++ b/src/ftsearch.c | |
| @@ -0,0 +1,303 @@ | |
| 1 | /* |
| 2 | ** Copyright (c) 2014 D. Richard Hipp |
| 3 | ** |
| 4 | ** This program is free software; you can redistribute it and/or |
| 5 | ** modify it under the terms of the Simplified BSD License (also |
| 6 | ** known as the "2-Clause License" or "FreeBSD License".) |
| 7 | |
| 8 | ** This program is distributed in the hope that it will be useful, |
| 9 | ** but without any warranty; without even the implied warranty of |
| 10 | ** merchantability or fitness for a particular purpose. |
| 11 | ** |
| 12 | ** Author contact information: |
| 13 | ** [email protected] |
| 14 | ** http://www.hwaci.com/drh/ |
| 15 | ** |
| 16 | ******************************************************************************* |
| 17 | ** |
| 18 | ** This file contains code to implement a full-text search function in |
| 19 | ** Fossil using the FTS4 feature of SQLite. |
| 20 | */ |
| 21 | #include "config.h" |
| 22 | #include "ftsearch.h" |
| 23 | #include <assert.h> |
| 24 | |
| 25 | /* |
| 26 | ** Document Codes: |
| 27 | ** |
| 28 | ** A "document code" is a string that describes a particular document. |
| 29 | ** The first letter is the document type. Second letter is '-' (for |
| 30 | ** human readability. Subsequent letters are a unique identifier for |
| 31 | ** the document. |
| 32 | ** |
| 33 | ** c-RID - Check-in comment |
| 34 | ** d-MID-FID - Diff on filentent(mlink.fid)" |
| 35 | " code to iTKTID - Ticket text |
| 36 | ** w-TAGID - Wiki page (most recent version) |
| 37 | ** |
| 38 | ** The FTSEARCHXREF table provides a mapping between document codes |
| 39 | ** (i |
| 40 | id |
| 41 | /* |
| 42 | ** Copyright (c) 2014 D014 D. Richard Hipp |
| 43 | ** |
| 44 | ** This program is free software; you can redistribute it and/or |
| 45 | ** modify it under the terms of the Simplified BSD License (also |
| 46 | ** known as the "2-Clause License" or "FreeBSD License".) |
| 47 | |
| 48 | ** This program is distributed in the hope that it will be useful, |
| 49 | ** but without any warranty; without even the implied warranty of |
| 50 | ** merchantability or fitness for a particular purpose. |
| 51 | ** |
| 52 | ** Author contact information: |
| 53 | ** [email protected] |
| 54 | ** http://www.hwaci.com/drh/ |
| 55 | ** |
| 56 | ******************************************************************************* |
| 57 | ** |
| 58 | ** This file contains code to implement a full-text search function in |
| 59 | ** Fossil using the FTS4 feature of SQLite. |
| 60 | */ |
| 61 | #include "config.h" |
| 62 | #include "ftsearch.h" |
| 63 | #include <assert.h> |
| 64 | |
| 65 | /* |
| 66 | ** Document Codes: |
| 67 | ** |
| 68 | ** A "document code" is a string that describes a particular document. |
| 69 | ** The first letter is the document type. Second letter is '-' (for |
| 70 | ** huUUan readability. Subsequent letters are a unique identifier for |
| 71 | ** the document. |
| 72 | ** |
| 73 | ** c-RID - Check-in comment |
| 74 | ** d-MID-FID - Diff on file FID from checkin MID |
| 75 | ** e-TAGID - Event text |
| 76 | ** f-FNID - File content (most recent version) |
| 77 | ** t-TKTID - Ticket text |
| 78 | ** w-TAGID - Wiki page (most recent version) |
| 79 | ** |
| 80 | ** The FTSEARCHXREF table provides a mapping between document codes |
| 81 | ** (in the FTSID column) to the DOCID of the FTS4 tablam is free software; you can redistribute it and/or |
| 82 | ** modify it under the terms of the Simplified BSD License (also |
| 83 | ** known as the "2-Clause The returned text is in the Wiki format and contains |
| 84 | ** links to the docureturn zRes; |
| 85 | } |
| 86 | |
| 87 | /* Return a human-readable description for the document described by |
| 88 | ** the arguments. |
| 89 | ** |
| 90 | ** See ftsearch_content() for further information |
| 91 | */ |
| 92 | char *ftsearch_description( |
| 93 | const char *zDocType, |
| 94 | const char *zDocId, |
| 95 | int bLink /* Provide hyperlink in text if true */ |
| 96 | ){ |
| 97 | char *zRes = 0; /* The result to be returned */ |
| 98 | int id; |
| 99 | if( zDocId==0 ){ |
| 100 | if( zDocType[0]==0 || zDocType[1]==0 ) return 0; |
| 101 | zDocId = zDocType + 2; |
| 102 | } |
| 103 | id = atoi(zDocId); |
| 104 | switch( zDocType[0] ){ |
| 105 | case 'c': { /* A check-in comment. zDocId is the RID */ |
| 106 | char *zUuid = db_text("","SELECT uuid FROM blob WHERE rid=%d", id); |
| 107 | zRes = mprintf("Check-in [%S]", zUuid); |
| 108 | fossil_free(zUuid); |
| 109 | break; |
| 110 | } |
| 111 | case 'f': { /* A file. zDocId is the FNID */ |
| 112 | char *zName = db_text("","SELECT name FROM filename WHERE fnid=%d",id); |
| 113 | zRes = mprintf("File %s", zName); |
| 114 | fossil_free(zName); |
| 115 | break; |
| 116 | } |
| 117 | default: { |
| 118 | /* No-op */ |
| 119 | } |
| 120 | } |
| 121 | return zRes; |
| 122 | } |
| 123 | |
| 124 | /* |
| 125 | ** COMMAND: test-ftsearch-content |
| 126 | ** |
| 127 | ** Usage: %fossil test-ftsearch-content DOCUMENTCODE |
| 128 | ** |
| 129 | ** Return the content for the given DOCUMENTCODE. This command is used |
| 130 | ** for testing and debugging the ftsearch_content() method in the |
| 131 | ** full-text search module. |
| 132 | */ |
| 133 | void test_doc_content_cmd(void){ |
| 134 | char *zContent = 0; |
| 135 | char *zDesc = 0; |
| 136 | db_find_and_open_repository(0, 0); |
| 137 | verify_all_options(); |
| 138 | if( g.argc!=3 ) usage("DOCUMENTCODE"); |
| 139 | if( strlen(g.argv[2])>3 ){ |
| 140 | zContent = ftsearch_content(g.argv[2],0); |
| 141 | zDesc = ftsearch_description(g.argv[2],0,0); |
| 142 | } |
| 143 | if( zDesc ){ |
| 144 | fossil_print("Description: %s\n", zDesc); |
| 145 | fossil_free(zDesc); |
| 146 | } |
| 147 | if( zContent ){ |
| 148 | fossil_print( |
| 149 | "Content -------------------------------------------------------------\n" |
| 150 | "%s\n" |
| 151 | "---------------------------------------------------------------------\n", |
| 152 | zContent); |
| 153 | fossil_free(zContent); |
| 154 | } |
| 155 | } |
| 156 | |
| 157 | /* |
| 158 | ** Implementation of the ftsearch_content() SQL function. |
| 159 | */ |
| 160 | static void ftsearch_content_sql_func( |
| 161 | sqlite3_context *context, |
| 162 | int argc, |
| 163 | sqlite3_value **argv |
| 164 | ){ |
| 165 | const char *zDocType; /* [cdeftw] */ |
| 166 | const char *zDocId; /* Identifier based on zDocType */ |
| 167 | char *zRes; /* Result */ |
| 168 | |
| 169 | zDocType = (const char*)sqlite3_value_text(argv[0]); |
| 170 | zDocId = argc>=2 ? (const char*)sqlite3_value_text(argv[1]) : 0; |
| 171 | zRes = ftsearch_content(zDocType, zDocId); |
| 172 | if( zRes ){ |
| 173 | sqlite3_result_text(context, zRes, -1, (void(*)(void*))fossil_free); |
| 174 | } |
| 175 | } |
| 176 | |
| 177 | /* |
| 178 | ** Invoke this routine in order to install the ftsearch_content() SQL |
| 179 | ** function on an SQLite database connection. |
| 180 | ** |
| 181 | ** sqlite3_auto_extension(ftsearch_add_sql_func); |
| 182 | ** |
| 183 | ** to cause this extension to be automatically loaded into each new |
| 184 | ** database connection. |
| 185 | */ |
| 186 | int ftsearch_add_sql_func(sqlite3 *db){ |
| 187 | int rc; |
| 188 | rc = sqlite3_create_function(db, "ftsearch_content", 1, SQLITE_UTF8, 0, |
| 189 | ftsearch_content_sql_func, 0, 0); |
| 190 | if( rc==SQLITE_OK ){ |
| 191 | rc = sqlite3_create_function(db, "ftsearch_content", 2, SQLITE_UTF8, 0, |
| 192 | ftsearch_content_sql_func, 0, 0); |
| 193 | } |
| 194 | return rc; |
| 195 | } |
| 196 | |
| 197 | /* |
| 198 | ** Delete the ftsearch tables, views, and indexes |
| 199 | */ |
| 200 | void ftsearch_disable_all(void){ |
| 201 | Stmt q; |
| 202 | Blob sql; |
| 203 | db_begin_transaction(); |
| 204 | db_prepare(&q, |
| 205 | "SELECT type, name FROM %s.sqlite_master" |
| 206 | " WHERE type IN ('table','view')" |
| 207 | " AND name GLOB 'ftsearch*'" |
| 208 | " AND name NOT GLOB 'ftsearch_*'", |
| 209 | db_name("repository") |
| 210 | ); |
| 211 | blob_init(&sql, 0, 0); |
| 212 | while( db_step(&q)==SQLITE_ROW ){ |
| 213 | blob_appendf(&sql, "DROP %s IF EXISTS \"%w\";\n", |
| 214 | db_column_text(&q,0), db_column_text(&q,1)); |
| 215 | } |
| 216 | db_finalize(&q); |
| 217 | db_multi_exec("%s", blob_str(&sql)/*safe-for-%s*/); |
| 218 | blob_reset(&sql); |
| 219 | db_end_transaction(0); |
| 220 | } |
| 221 | |
| 222 | /* |
| 223 | ** Completely rebuild the ftsearch indexes from scratch |
| 224 | */ |
| 225 | void ftsearch_rebuild_all(void){ |
| 226 | const char *zEnables; |
| 227 | db_begin_transaction(); |
| 228 | ftsearch_disable_all(); |
| 229 | zEnables = db_get("ftsearch-index-type", "cdeftw"); |
| 230 | |
| 231 | /* If none of the search categories are enabled, then do not |
| 232 | ** bother constructing the search tables |
| 233 | */ |
| 234 | if( sqlite3_strglob("*[cdeftw]*", zEnables) ) return; |
| 235 | |
| 236 | /* The FTSSEARCHXREF table provides a mapping between the integer |
| 237 | ** document-ids in FTS4 to the "document codes" that describe a |
| 238 | ** referenced object |
| 239 | */ |
| 240 | db_multi_exec( |
| 241 | "CREATE TABLE %s.ftsearchxref(\n" |
| 242 | " docid INTEGER PRIMARY KEY,\n" /* Link to ftsearch.docid */ |
| 243 | " ftsid TEXT UNIQUE,\n" /* The document code */ |
| 244 | " mtime DATE\n" /* Timestamp on this object */ |
| 245 | ");\n", |
| 246 | db_name("repository") |
| 247 | ); |
| 248 | |
| 249 | /* The FTSEARCHBODY view provides the content for the FTS4 table |
| 250 | */ |
| 251 | db_multi_exec( |
| 252 | "CREATE VIEW %s.ftsearchbody AS" |
| 253 | " SELECT docid AS rowid, ftsearch_content(ftsid) AS body" |
| 254 | " FROM ftsearchxref;\n", |
| 255 | db_name("repository") |
| 256 | ); |
| 257 | |
| 258 | /* This is the FT */ |
| 259 | db_multi_exec( |
| 260 | ; |
| 261 | db_multi_exec( |
| 262 | "CREAT" |
| 263 | " USING fts4(co/* |
| 264 | ** Copyright (c) 2014 D. Richard Hipp |
| 265 | ** |
| 266 | ** This program is free software; you can redistribute it and/or |
| 267 | ** modify it under the terms of the Simplified BSD License (also |
| 268 | ** known as the "2-Clause License" or "FreeBSD License".) |
| 269 | |
| 270 | ** This program is distributed in the hope that it will be useful, |
| 271 | ** but without any warranty; without even the implied warranty of |
| 272 | ** merchantability or fitness for a particular purpose. |
| 273 | ** |
| 274 | ** Author contact information: |
| 275 | ** [email protected] |
| 276 | ** http://www.hwaci.com/drh/ |
| 277 | ** |
| 278 | ******************************************************************************* |
| 279 | ** |
| 280 | ** This file contains code to implement a full-text search function in |
| 281 | ** Fossil using the FTS4 feature of SQLite. |
| 282 | */ |
| 283 | #include "config.h" |
| 284 | #include "ftsearch.h" |
| 285 | #include <assert.h> |
| 286 | |
| 287 | /* |
| 288 | ** Document Codes: |
| 289 | ** |
| 290 | ** A "document code" is a string that describes a particular document. |
| 291 | ** The first letter is the document type. Second letter is '-' (for |
| 292 | ** human readability. Subsequent letters are a unique identifier for |
| 293 | ** the document. |
| 294 | ** |
| 295 | ** c-RID - Check-in comment |
| 296 | ** d-MID-FID - Diff on file FID from checkin MID |
| 297 | ** e-TAGID - Event text |
| 298 | ** f-FNID - File content (most recent version) |
| 299 | ** t-TKTID - Ticket text |
| 300 | ** w-TAGID - Wiki page (most recent version) |
| 301 | ** |
| 302 | ** The FTSEARCHXREF table provides a mapping between document codes |
| 303 | ** (in the FTSID column) |
+15
-3
| --- src/main.mk | ||
| +++ src/main.mk | ||
| @@ -45,10 +45,11 @@ | ||
| 45 | 45 | $(SRCDIR)/event.c \ |
| 46 | 46 | $(SRCDIR)/export.c \ |
| 47 | 47 | $(SRCDIR)/file.c \ |
| 48 | 48 | $(SRCDIR)/finfo.c \ |
| 49 | 49 | $(SRCDIR)/foci.c \ |
| 50 | + $(SRCDIR)/ftsearch.c \ | |
| 50 | 51 | $(SRCDIR)/fusefs.c \ |
| 51 | 52 | $(SRCDIR)/glob.c \ |
| 52 | 53 | $(SRCDIR)/graph.c \ |
| 53 | 54 | $(SRCDIR)/gzip.c \ |
| 54 | 55 | $(SRCDIR)/http.c \ |
| @@ -167,10 +168,11 @@ | ||
| 167 | 168 | $(OBJDIR)/event_.c \ |
| 168 | 169 | $(OBJDIR)/export_.c \ |
| 169 | 170 | $(OBJDIR)/file_.c \ |
| 170 | 171 | $(OBJDIR)/finfo_.c \ |
| 171 | 172 | $(OBJDIR)/foci_.c \ |
| 173 | + $(OBJDIR)/ftsearch_.c \ | |
| 172 | 174 | $(OBJDIR)/fusefs_.c \ |
| 173 | 175 | $(OBJDIR)/glob_.c \ |
| 174 | 176 | $(OBJDIR)/graph_.c \ |
| 175 | 177 | $(OBJDIR)/gzip_.c \ |
| 176 | 178 | $(OBJDIR)/http_.c \ |
| @@ -286,10 +288,11 @@ | ||
| 286 | 288 | $(OBJDIR)/event.o \ |
| 287 | 289 | $(OBJDIR)/export.o \ |
| 288 | 290 | $(OBJDIR)/file.o \ |
| 289 | 291 | $(OBJDIR)/finfo.o \ |
| 290 | 292 | $(OBJDIR)/foci.o \ |
| 293 | + $(OBJDIR)/ftsearch.o \ | |
| 291 | 294 | $(OBJDIR)/fusefs.o \ |
| 292 | 295 | $(OBJDIR)/glob.o \ |
| 293 | 296 | $(OBJDIR)/graph.o \ |
| 294 | 297 | $(OBJDIR)/gzip.o \ |
| 295 | 298 | $(OBJDIR)/http.o \ |
| @@ -415,17 +418,17 @@ | ||
| 415 | 418 | |
| 416 | 419 | $(OBJDIR)/VERSION.h: $(SRCDIR)/../manifest.uuid $(SRCDIR)/../manifest $(SRCDIR)/../VERSION $(OBJDIR)/mkversion |
| 417 | 420 | $(OBJDIR)/mkversion $(SRCDIR)/../manifest.uuid $(SRCDIR)/../manifest $(SRCDIR)/../VERSION >$(OBJDIR)/VERSION.h |
| 418 | 421 | |
| 419 | 422 | # Setup the options used to compile the included SQLite library. |
| 420 | -SQLITE_OPTIONS = -DNDEBUG=1 \ | |
| 421 | - -DSQLITE_OMIT_LOAD_EXTENSION=1 \ | |
| 423 | +SQLITE_OPTIONS = -DSQLITE_OMIT_LOAD_EXTENSION=1 \ | |
| 422 | 424 | -DSQLITE_ENABLE_LOCKING_STYLE=0 \ |
| 423 | 425 | -DSQLITE_THREADSAFE=0 \ |
| 424 | 426 | -DSQLITE_DEFAULT_FILE_FORMAT=4 \ |
| 425 | 427 | -DSQLITE_OMIT_DEPRECATED \ |
| 426 | - -DSQLITE_ENABLE_EXPLAIN_COMMENTS | |
| 428 | + -DSQLITE_ENABLE_EXPLAIN_COMMENTS \ | |
| 429 | + -DSQLITE_ENABLE_FTS4 | |
| 427 | 430 | |
| 428 | 431 | # Setup the options used to compile the included SQLite shell. |
| 429 | 432 | SHELL_OPTIONS = -Dmain=sqlite3_shell \ |
| 430 | 433 | -DSQLITE_OMIT_LOAD_EXTENSION=1 \ |
| 431 | 434 | -DUSE_SYSTEM_SQLITE=$(USE_SYSTEM_SQLITE) \ |
| @@ -514,10 +517,11 @@ | ||
| 514 | 517 | $(OBJDIR)/event_.c:$(OBJDIR)/event.h \ |
| 515 | 518 | $(OBJDIR)/export_.c:$(OBJDIR)/export.h \ |
| 516 | 519 | $(OBJDIR)/file_.c:$(OBJDIR)/file.h \ |
| 517 | 520 | $(OBJDIR)/finfo_.c:$(OBJDIR)/finfo.h \ |
| 518 | 521 | $(OBJDIR)/foci_.c:$(OBJDIR)/foci.h \ |
| 522 | + $(OBJDIR)/ftsearch_.c:$(OBJDIR)/ftsearch.h \ | |
| 519 | 523 | $(OBJDIR)/fusefs_.c:$(OBJDIR)/fusefs.h \ |
| 520 | 524 | $(OBJDIR)/glob_.c:$(OBJDIR)/glob.h \ |
| 521 | 525 | $(OBJDIR)/graph_.c:$(OBJDIR)/graph.h \ |
| 522 | 526 | $(OBJDIR)/gzip_.c:$(OBJDIR)/gzip.h \ |
| 523 | 527 | $(OBJDIR)/http_.c:$(OBJDIR)/http.h \ |
| @@ -868,10 +872,18 @@ | ||
| 868 | 872 | |
| 869 | 873 | $(OBJDIR)/foci.o: $(OBJDIR)/foci_.c $(OBJDIR)/foci.h $(SRCDIR)/config.h |
| 870 | 874 | $(XTCC) -o $(OBJDIR)/foci.o -c $(OBJDIR)/foci_.c |
| 871 | 875 | |
| 872 | 876 | $(OBJDIR)/foci.h: $(OBJDIR)/headers |
| 877 | + | |
| 878 | +$(OBJDIR)/ftsearch_.c: $(SRCDIR)/ftsearch.c $(OBJDIR)/translate | |
| 879 | + $(OBJDIR)/translate $(SRCDIR)/ftsearch.c >$@ | |
| 880 | + | |
| 881 | +$(OBJDIR)/ftsearch.o: $(OBJDIR)/ftsearch_.c $(OBJDIR)/ftsearch.h $(SRCDIR)/config.h | |
| 882 | + $(XTCC) -o $(OBJDIR)/ftsearch.o -c $(OBJDIR)/ftsearch_.c | |
| 883 | + | |
| 884 | +$(OBJDIR)/ftsearch.h: $(OBJDIR)/headers | |
| 873 | 885 | |
| 874 | 886 | $(OBJDIR)/fusefs_.c: $(SRCDIR)/fusefs.c $(OBJDIR)/translate |
| 875 | 887 | $(OBJDIR)/translate $(SRCDIR)/fusefs.c >$@ |
| 876 | 888 | |
| 877 | 889 | $(OBJDIR)/fusefs.o: $(OBJDIR)/fusefs_.c $(OBJDIR)/fusefs.h $(SRCDIR)/config.h |
| 878 | 890 |
| --- src/main.mk | |
| +++ src/main.mk | |
| @@ -45,10 +45,11 @@ | |
| 45 | $(SRCDIR)/event.c \ |
| 46 | $(SRCDIR)/export.c \ |
| 47 | $(SRCDIR)/file.c \ |
| 48 | $(SRCDIR)/finfo.c \ |
| 49 | $(SRCDIR)/foci.c \ |
| 50 | $(SRCDIR)/fusefs.c \ |
| 51 | $(SRCDIR)/glob.c \ |
| 52 | $(SRCDIR)/graph.c \ |
| 53 | $(SRCDIR)/gzip.c \ |
| 54 | $(SRCDIR)/http.c \ |
| @@ -167,10 +168,11 @@ | |
| 167 | $(OBJDIR)/event_.c \ |
| 168 | $(OBJDIR)/export_.c \ |
| 169 | $(OBJDIR)/file_.c \ |
| 170 | $(OBJDIR)/finfo_.c \ |
| 171 | $(OBJDIR)/foci_.c \ |
| 172 | $(OBJDIR)/fusefs_.c \ |
| 173 | $(OBJDIR)/glob_.c \ |
| 174 | $(OBJDIR)/graph_.c \ |
| 175 | $(OBJDIR)/gzip_.c \ |
| 176 | $(OBJDIR)/http_.c \ |
| @@ -286,10 +288,11 @@ | |
| 286 | $(OBJDIR)/event.o \ |
| 287 | $(OBJDIR)/export.o \ |
| 288 | $(OBJDIR)/file.o \ |
| 289 | $(OBJDIR)/finfo.o \ |
| 290 | $(OBJDIR)/foci.o \ |
| 291 | $(OBJDIR)/fusefs.o \ |
| 292 | $(OBJDIR)/glob.o \ |
| 293 | $(OBJDIR)/graph.o \ |
| 294 | $(OBJDIR)/gzip.o \ |
| 295 | $(OBJDIR)/http.o \ |
| @@ -415,17 +418,17 @@ | |
| 415 | |
| 416 | $(OBJDIR)/VERSION.h: $(SRCDIR)/../manifest.uuid $(SRCDIR)/../manifest $(SRCDIR)/../VERSION $(OBJDIR)/mkversion |
| 417 | $(OBJDIR)/mkversion $(SRCDIR)/../manifest.uuid $(SRCDIR)/../manifest $(SRCDIR)/../VERSION >$(OBJDIR)/VERSION.h |
| 418 | |
| 419 | # Setup the options used to compile the included SQLite library. |
| 420 | SQLITE_OPTIONS = -DNDEBUG=1 \ |
| 421 | -DSQLITE_OMIT_LOAD_EXTENSION=1 \ |
| 422 | -DSQLITE_ENABLE_LOCKING_STYLE=0 \ |
| 423 | -DSQLITE_THREADSAFE=0 \ |
| 424 | -DSQLITE_DEFAULT_FILE_FORMAT=4 \ |
| 425 | -DSQLITE_OMIT_DEPRECATED \ |
| 426 | -DSQLITE_ENABLE_EXPLAIN_COMMENTS |
| 427 | |
| 428 | # Setup the options used to compile the included SQLite shell. |
| 429 | SHELL_OPTIONS = -Dmain=sqlite3_shell \ |
| 430 | -DSQLITE_OMIT_LOAD_EXTENSION=1 \ |
| 431 | -DUSE_SYSTEM_SQLITE=$(USE_SYSTEM_SQLITE) \ |
| @@ -514,10 +517,11 @@ | |
| 514 | $(OBJDIR)/event_.c:$(OBJDIR)/event.h \ |
| 515 | $(OBJDIR)/export_.c:$(OBJDIR)/export.h \ |
| 516 | $(OBJDIR)/file_.c:$(OBJDIR)/file.h \ |
| 517 | $(OBJDIR)/finfo_.c:$(OBJDIR)/finfo.h \ |
| 518 | $(OBJDIR)/foci_.c:$(OBJDIR)/foci.h \ |
| 519 | $(OBJDIR)/fusefs_.c:$(OBJDIR)/fusefs.h \ |
| 520 | $(OBJDIR)/glob_.c:$(OBJDIR)/glob.h \ |
| 521 | $(OBJDIR)/graph_.c:$(OBJDIR)/graph.h \ |
| 522 | $(OBJDIR)/gzip_.c:$(OBJDIR)/gzip.h \ |
| 523 | $(OBJDIR)/http_.c:$(OBJDIR)/http.h \ |
| @@ -868,10 +872,18 @@ | |
| 868 | |
| 869 | $(OBJDIR)/foci.o: $(OBJDIR)/foci_.c $(OBJDIR)/foci.h $(SRCDIR)/config.h |
| 870 | $(XTCC) -o $(OBJDIR)/foci.o -c $(OBJDIR)/foci_.c |
| 871 | |
| 872 | $(OBJDIR)/foci.h: $(OBJDIR)/headers |
| 873 | |
| 874 | $(OBJDIR)/fusefs_.c: $(SRCDIR)/fusefs.c $(OBJDIR)/translate |
| 875 | $(OBJDIR)/translate $(SRCDIR)/fusefs.c >$@ |
| 876 | |
| 877 | $(OBJDIR)/fusefs.o: $(OBJDIR)/fusefs_.c $(OBJDIR)/fusefs.h $(SRCDIR)/config.h |
| 878 |
| --- src/main.mk | |
| +++ src/main.mk | |
| @@ -45,10 +45,11 @@ | |
| 45 | $(SRCDIR)/event.c \ |
| 46 | $(SRCDIR)/export.c \ |
| 47 | $(SRCDIR)/file.c \ |
| 48 | $(SRCDIR)/finfo.c \ |
| 49 | $(SRCDIR)/foci.c \ |
| 50 | $(SRCDIR)/ftsearch.c \ |
| 51 | $(SRCDIR)/fusefs.c \ |
| 52 | $(SRCDIR)/glob.c \ |
| 53 | $(SRCDIR)/graph.c \ |
| 54 | $(SRCDIR)/gzip.c \ |
| 55 | $(SRCDIR)/http.c \ |
| @@ -167,10 +168,11 @@ | |
| 168 | $(OBJDIR)/event_.c \ |
| 169 | $(OBJDIR)/export_.c \ |
| 170 | $(OBJDIR)/file_.c \ |
| 171 | $(OBJDIR)/finfo_.c \ |
| 172 | $(OBJDIR)/foci_.c \ |
| 173 | $(OBJDIR)/ftsearch_.c \ |
| 174 | $(OBJDIR)/fusefs_.c \ |
| 175 | $(OBJDIR)/glob_.c \ |
| 176 | $(OBJDIR)/graph_.c \ |
| 177 | $(OBJDIR)/gzip_.c \ |
| 178 | $(OBJDIR)/http_.c \ |
| @@ -286,10 +288,11 @@ | |
| 288 | $(OBJDIR)/event.o \ |
| 289 | $(OBJDIR)/export.o \ |
| 290 | $(OBJDIR)/file.o \ |
| 291 | $(OBJDIR)/finfo.o \ |
| 292 | $(OBJDIR)/foci.o \ |
| 293 | $(OBJDIR)/ftsearch.o \ |
| 294 | $(OBJDIR)/fusefs.o \ |
| 295 | $(OBJDIR)/glob.o \ |
| 296 | $(OBJDIR)/graph.o \ |
| 297 | $(OBJDIR)/gzip.o \ |
| 298 | $(OBJDIR)/http.o \ |
| @@ -415,17 +418,17 @@ | |
| 418 | |
| 419 | $(OBJDIR)/VERSION.h: $(SRCDIR)/../manifest.uuid $(SRCDIR)/../manifest $(SRCDIR)/../VERSION $(OBJDIR)/mkversion |
| 420 | $(OBJDIR)/mkversion $(SRCDIR)/../manifest.uuid $(SRCDIR)/../manifest $(SRCDIR)/../VERSION >$(OBJDIR)/VERSION.h |
| 421 | |
| 422 | # Setup the options used to compile the included SQLite library. |
| 423 | SQLITE_OPTIONS = -DSQLITE_OMIT_LOAD_EXTENSION=1 \ |
| 424 | -DSQLITE_ENABLE_LOCKING_STYLE=0 \ |
| 425 | -DSQLITE_THREADSAFE=0 \ |
| 426 | -DSQLITE_DEFAULT_FILE_FORMAT=4 \ |
| 427 | -DSQLITE_OMIT_DEPRECATED \ |
| 428 | -DSQLITE_ENABLE_EXPLAIN_COMMENTS \ |
| 429 | -DSQLITE_ENABLE_FTS4 |
| 430 | |
| 431 | # Setup the options used to compile the included SQLite shell. |
| 432 | SHELL_OPTIONS = -Dmain=sqlite3_shell \ |
| 433 | -DSQLITE_OMIT_LOAD_EXTENSION=1 \ |
| 434 | -DUSE_SYSTEM_SQLITE=$(USE_SYSTEM_SQLITE) \ |
| @@ -514,10 +517,11 @@ | |
| 517 | $(OBJDIR)/event_.c:$(OBJDIR)/event.h \ |
| 518 | $(OBJDIR)/export_.c:$(OBJDIR)/export.h \ |
| 519 | $(OBJDIR)/file_.c:$(OBJDIR)/file.h \ |
| 520 | $(OBJDIR)/finfo_.c:$(OBJDIR)/finfo.h \ |
| 521 | $(OBJDIR)/foci_.c:$(OBJDIR)/foci.h \ |
| 522 | $(OBJDIR)/ftsearch_.c:$(OBJDIR)/ftsearch.h \ |
| 523 | $(OBJDIR)/fusefs_.c:$(OBJDIR)/fusefs.h \ |
| 524 | $(OBJDIR)/glob_.c:$(OBJDIR)/glob.h \ |
| 525 | $(OBJDIR)/graph_.c:$(OBJDIR)/graph.h \ |
| 526 | $(OBJDIR)/gzip_.c:$(OBJDIR)/gzip.h \ |
| 527 | $(OBJDIR)/http_.c:$(OBJDIR)/http.h \ |
| @@ -868,10 +872,18 @@ | |
| 872 | |
| 873 | $(OBJDIR)/foci.o: $(OBJDIR)/foci_.c $(OBJDIR)/foci.h $(SRCDIR)/config.h |
| 874 | $(XTCC) -o $(OBJDIR)/foci.o -c $(OBJDIR)/foci_.c |
| 875 | |
| 876 | $(OBJDIR)/foci.h: $(OBJDIR)/headers |
| 877 | |
| 878 | $(OBJDIR)/ftsearch_.c: $(SRCDIR)/ftsearch.c $(OBJDIR)/translate |
| 879 | $(OBJDIR)/translate $(SRCDIR)/ftsearch.c >$@ |
| 880 | |
| 881 | $(OBJDIR)/ftsearch.o: $(OBJDIR)/ftsearch_.c $(OBJDIR)/ftsearch.h $(SRCDIR)/config.h |
| 882 | $(XTCC) -o $(OBJDIR)/ftsearch.o -c $(OBJDIR)/ftsearch_.c |
| 883 | |
| 884 | $(OBJDIR)/ftsearch.h: $(OBJDIR)/headers |
| 885 | |
| 886 | $(OBJDIR)/fusefs_.c: $(SRCDIR)/fusefs.c $(OBJDIR)/translate |
| 887 | $(OBJDIR)/translate $(SRCDIR)/fusefs.c >$@ |
| 888 | |
| 889 | $(OBJDIR)/fusefs.o: $(OBJDIR)/fusefs_.c $(OBJDIR)/fusefs.h $(SRCDIR)/config.h |
| 890 |
+2
-2
| --- src/makemake.tcl | ||
| +++ src/makemake.tcl | ||
| @@ -52,10 +52,11 @@ | ||
| 52 | 52 | event |
| 53 | 53 | export |
| 54 | 54 | file |
| 55 | 55 | finfo |
| 56 | 56 | foci |
| 57 | + ftsearch | |
| 57 | 58 | fusefs |
| 58 | 59 | glob |
| 59 | 60 | graph |
| 60 | 61 | gzip |
| 61 | 62 | http |
| @@ -147,19 +148,18 @@ | ||
| 147 | 148 | } |
| 148 | 149 | |
| 149 | 150 | # Options used to compile the included SQLite library. |
| 150 | 151 | # |
| 151 | 152 | set SQLITE_OPTIONS { |
| 152 | - -DNDEBUG=1 | |
| 153 | 153 | -DSQLITE_OMIT_LOAD_EXTENSION=1 |
| 154 | 154 | -DSQLITE_ENABLE_LOCKING_STYLE=0 |
| 155 | 155 | -DSQLITE_THREADSAFE=0 |
| 156 | 156 | -DSQLITE_DEFAULT_FILE_FORMAT=4 |
| 157 | 157 | -DSQLITE_OMIT_DEPRECATED |
| 158 | 158 | -DSQLITE_ENABLE_EXPLAIN_COMMENTS |
| 159 | + -DSQLITE_ENABLE_FTS4 | |
| 159 | 160 | } |
| 160 | -#lappend SQLITE_OPTIONS -DSQLITE_ENABLE_FTS3=1 | |
| 161 | 161 | #lappend SQLITE_OPTIONS -DSQLITE_ENABLE_STAT4 |
| 162 | 162 | #lappend SQLITE_OPTIONS -DSQLITE_WIN32_NO_ANSI |
| 163 | 163 | #lappend SQLITE_OPTIONS -DSQLITE_WINNT_MAX_PATH_CHARS=4096 |
| 164 | 164 | |
| 165 | 165 | # Options used to compile the included SQLite shell. |
| 166 | 166 |
| --- src/makemake.tcl | |
| +++ src/makemake.tcl | |
| @@ -52,10 +52,11 @@ | |
| 52 | event |
| 53 | export |
| 54 | file |
| 55 | finfo |
| 56 | foci |
| 57 | fusefs |
| 58 | glob |
| 59 | graph |
| 60 | gzip |
| 61 | http |
| @@ -147,19 +148,18 @@ | |
| 147 | } |
| 148 | |
| 149 | # Options used to compile the included SQLite library. |
| 150 | # |
| 151 | set SQLITE_OPTIONS { |
| 152 | -DNDEBUG=1 |
| 153 | -DSQLITE_OMIT_LOAD_EXTENSION=1 |
| 154 | -DSQLITE_ENABLE_LOCKING_STYLE=0 |
| 155 | -DSQLITE_THREADSAFE=0 |
| 156 | -DSQLITE_DEFAULT_FILE_FORMAT=4 |
| 157 | -DSQLITE_OMIT_DEPRECATED |
| 158 | -DSQLITE_ENABLE_EXPLAIN_COMMENTS |
| 159 | } |
| 160 | #lappend SQLITE_OPTIONS -DSQLITE_ENABLE_FTS3=1 |
| 161 | #lappend SQLITE_OPTIONS -DSQLITE_ENABLE_STAT4 |
| 162 | #lappend SQLITE_OPTIONS -DSQLITE_WIN32_NO_ANSI |
| 163 | #lappend SQLITE_OPTIONS -DSQLITE_WINNT_MAX_PATH_CHARS=4096 |
| 164 | |
| 165 | # Options used to compile the included SQLite shell. |
| 166 |
| --- src/makemake.tcl | |
| +++ src/makemake.tcl | |
| @@ -52,10 +52,11 @@ | |
| 52 | event |
| 53 | export |
| 54 | file |
| 55 | finfo |
| 56 | foci |
| 57 | ftsearch |
| 58 | fusefs |
| 59 | glob |
| 60 | graph |
| 61 | gzip |
| 62 | http |
| @@ -147,19 +148,18 @@ | |
| 148 | } |
| 149 | |
| 150 | # Options used to compile the included SQLite library. |
| 151 | # |
| 152 | set SQLITE_OPTIONS { |
| 153 | -DSQLITE_OMIT_LOAD_EXTENSION=1 |
| 154 | -DSQLITE_ENABLE_LOCKING_STYLE=0 |
| 155 | -DSQLITE_THREADSAFE=0 |
| 156 | -DSQLITE_DEFAULT_FILE_FORMAT=4 |
| 157 | -DSQLITE_OMIT_DEPRECATED |
| 158 | -DSQLITE_ENABLE_EXPLAIN_COMMENTS |
| 159 | -DSQLITE_ENABLE_FTS4 |
| 160 | } |
| 161 | #lappend SQLITE_OPTIONS -DSQLITE_ENABLE_STAT4 |
| 162 | #lappend SQLITE_OPTIONS -DSQLITE_WIN32_NO_ANSI |
| 163 | #lappend SQLITE_OPTIONS -DSQLITE_WINNT_MAX_PATH_CHARS=4096 |
| 164 | |
| 165 | # Options used to compile the included SQLite shell. |
| 166 |
+1
-1
| --- src/regexp.c | ||
| +++ src/regexp.c | ||
| @@ -725,11 +725,11 @@ | ||
| 725 | 725 | ** Invoke this routine in order to install the REGEXP function in an |
| 726 | 726 | ** SQLite database connection. |
| 727 | 727 | ** |
| 728 | 728 | ** Use: |
| 729 | 729 | ** |
| 730 | -** sqlite3_auto_extension(sqlite3_add_regexp_func); | |
| 730 | +** sqlite3_auto_extension(re_add_regexp_func); | |
| 731 | 731 | ** |
| 732 | 732 | ** to cause this extension to be automatically loaded into each new |
| 733 | 733 | ** database connection. |
| 734 | 734 | */ |
| 735 | 735 | int re_add_sql_func(sqlite3 *db){ |
| 736 | 736 |
| --- src/regexp.c | |
| +++ src/regexp.c | |
| @@ -725,11 +725,11 @@ | |
| 725 | ** Invoke this routine in order to install the REGEXP function in an |
| 726 | ** SQLite database connection. |
| 727 | ** |
| 728 | ** Use: |
| 729 | ** |
| 730 | ** sqlite3_auto_extension(sqlite3_add_regexp_func); |
| 731 | ** |
| 732 | ** to cause this extension to be automatically loaded into each new |
| 733 | ** database connection. |
| 734 | */ |
| 735 | int re_add_sql_func(sqlite3 *db){ |
| 736 |
| --- src/regexp.c | |
| +++ src/regexp.c | |
| @@ -725,11 +725,11 @@ | |
| 725 | ** Invoke this routine in order to install the REGEXP function in an |
| 726 | ** SQLite database connection. |
| 727 | ** |
| 728 | ** Use: |
| 729 | ** |
| 730 | ** sqlite3_auto_extension(re_add_regexp_func); |
| 731 | ** |
| 732 | ** to cause this extension to be automatically loaded into each new |
| 733 | ** database connection. |
| 734 | */ |
| 735 | int re_add_sql_func(sqlite3 *db){ |
| 736 |
+2
-2
| --- src/search.c | ||
| +++ src/search.c | ||
| @@ -182,12 +182,12 @@ | ||
| 182 | 182 | } |
| 183 | 183 | |
| 184 | 184 | /* |
| 185 | 185 | ** Testing the search function. |
| 186 | 186 | ** |
| 187 | -** COMMAND: search* | |
| 188 | -** %fossil search [-all|-a] [-limit|-n #] [-width|-W #] pattern... | |
| 187 | +** COMMAND: test-search* | |
| 188 | +** %fossil test-search [-all|-a] [-limit|-n #] [-width|-W #] pattern... | |
| 189 | 189 | ** |
| 190 | 190 | ** Search for timeline entries matching all words |
| 191 | 191 | ** provided on the command line. Whole-word matches |
| 192 | 192 | ** scope more highly than partial matches. |
| 193 | 193 | ** |
| 194 | 194 |
| --- src/search.c | |
| +++ src/search.c | |
| @@ -182,12 +182,12 @@ | |
| 182 | } |
| 183 | |
| 184 | /* |
| 185 | ** Testing the search function. |
| 186 | ** |
| 187 | ** COMMAND: search* |
| 188 | ** %fossil search [-all|-a] [-limit|-n #] [-width|-W #] pattern... |
| 189 | ** |
| 190 | ** Search for timeline entries matching all words |
| 191 | ** provided on the command line. Whole-word matches |
| 192 | ** scope more highly than partial matches. |
| 193 | ** |
| 194 |
| --- src/search.c | |
| +++ src/search.c | |
| @@ -182,12 +182,12 @@ | |
| 182 | } |
| 183 | |
| 184 | /* |
| 185 | ** Testing the search function. |
| 186 | ** |
| 187 | ** COMMAND: test-search* |
| 188 | ** %fossil test-search [-all|-a] [-limit|-n #] [-width|-W #] pattern... |
| 189 | ** |
| 190 | ** Search for timeline entries matching all words |
| 191 | ** provided on the command line. Whole-word matches |
| 192 | ** scope more highly than partial matches. |
| 193 | ** |
| 194 |
+1
| --- src/sqlcmd.c | ||
| +++ src/sqlcmd.c | ||
| @@ -135,10 +135,11 @@ | ||
| 135 | 135 | ){ |
| 136 | 136 | add_content_sql_commands(db); |
| 137 | 137 | re_add_sql_func(db); |
| 138 | 138 | g.zMainDbType = "repository"; |
| 139 | 139 | foci_register(db); |
| 140 | + ftsearch_add_sql_func(db); | |
| 140 | 141 | g.repositoryOpen = 1; |
| 141 | 142 | g.db = db; |
| 142 | 143 | return SQLITE_OK; |
| 143 | 144 | } |
| 144 | 145 | |
| 145 | 146 |
| --- src/sqlcmd.c | |
| +++ src/sqlcmd.c | |
| @@ -135,10 +135,11 @@ | |
| 135 | ){ |
| 136 | add_content_sql_commands(db); |
| 137 | re_add_sql_func(db); |
| 138 | g.zMainDbType = "repository"; |
| 139 | foci_register(db); |
| 140 | g.repositoryOpen = 1; |
| 141 | g.db = db; |
| 142 | return SQLITE_OK; |
| 143 | } |
| 144 | |
| 145 |
| --- src/sqlcmd.c | |
| +++ src/sqlcmd.c | |
| @@ -135,10 +135,11 @@ | |
| 135 | ){ |
| 136 | add_content_sql_commands(db); |
| 137 | re_add_sql_func(db); |
| 138 | g.zMainDbType = "repository"; |
| 139 | foci_register(db); |
| 140 | ftsearch_add_sql_func(db); |
| 141 | g.repositoryOpen = 1; |
| 142 | g.db = db; |
| 143 | return SQLITE_OK; |
| 144 | } |
| 145 | |
| 146 |
+1
-1
| --- src/th_main.c | ||
| +++ src/th_main.c | ||
| @@ -1369,11 +1369,11 @@ | ||
| 1369 | 1369 | */ |
| 1370 | 1370 | void Th_CloseConfig( |
| 1371 | 1371 | int closeRepository |
| 1372 | 1372 | ){ |
| 1373 | 1373 | if( g.th1Flags & TH_STATE_CONFIG ){ |
| 1374 | - db_close_config(); | |
| 1374 | + db_close_config(1); | |
| 1375 | 1375 | g.th1Flags &= ~TH_STATE_CONFIG; |
| 1376 | 1376 | } |
| 1377 | 1377 | if( closeRepository && (g.th1Flags & TH_STATE_REPOSITORY) ){ |
| 1378 | 1378 | db_close(1); |
| 1379 | 1379 | g.th1Flags &= ~TH_STATE_REPOSITORY; |
| 1380 | 1380 |
| --- src/th_main.c | |
| +++ src/th_main.c | |
| @@ -1369,11 +1369,11 @@ | |
| 1369 | */ |
| 1370 | void Th_CloseConfig( |
| 1371 | int closeRepository |
| 1372 | ){ |
| 1373 | if( g.th1Flags & TH_STATE_CONFIG ){ |
| 1374 | db_close_config(); |
| 1375 | g.th1Flags &= ~TH_STATE_CONFIG; |
| 1376 | } |
| 1377 | if( closeRepository && (g.th1Flags & TH_STATE_REPOSITORY) ){ |
| 1378 | db_close(1); |
| 1379 | g.th1Flags &= ~TH_STATE_REPOSITORY; |
| 1380 |
| --- src/th_main.c | |
| +++ src/th_main.c | |
| @@ -1369,11 +1369,11 @@ | |
| 1369 | */ |
| 1370 | void Th_CloseConfig( |
| 1371 | int closeRepository |
| 1372 | ){ |
| 1373 | if( g.th1Flags & TH_STATE_CONFIG ){ |
| 1374 | db_close_config(1); |
| 1375 | g.th1Flags &= ~TH_STATE_CONFIG; |
| 1376 | } |
| 1377 | if( closeRepository && (g.th1Flags & TH_STATE_REPOSITORY) ){ |
| 1378 | db_close(1); |
| 1379 | g.th1Flags &= ~TH_STATE_REPOSITORY; |
| 1380 |
+1
-1
| --- win/Makefile.PellesCGMake | ||
| +++ win/Makefile.PellesCGMake | ||
| @@ -83,11 +83,11 @@ | ||
| 83 | 83 | |
| 84 | 84 | # define the SQLite files, which need special flags on compile |
| 85 | 85 | SQLITESRC=sqlite3.c |
| 86 | 86 | ORIGSQLITESRC=$(foreach sf,$(SQLITESRC),$(SRCDIR)$(sf)) |
| 87 | 87 | SQLITEOBJ=$(foreach sf,$(SQLITESRC),$(sf:.c=.obj)) |
| 88 | -SQLITEDEFINES=-DNDEBUG=1 -DSQLITE_OMIT_LOAD_EXTENSION=1 -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_THREADSAFE=0 -DSQLITE_DEFAULT_FILE_FORMAT=4 -DSQLITE_OMIT_DEPRECATED -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_WIN32_NO_ANSI | |
| 88 | +SQLITEDEFINES=-DSQLITE_OMIT_LOAD_EXTENSION=1 -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_THREADSAFE=0 -DSQLITE_DEFAULT_FILE_FORMAT=4 -DSQLITE_OMIT_DEPRECATED -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_FTS4 -DSQLITE_WIN32_NO_ANSI | |
| 89 | 89 | |
| 90 | 90 | # define the SQLite shell files, which need special flags on compile |
| 91 | 91 | SQLITESHELLSRC=shell.c |
| 92 | 92 | ORIGSQLITESHELLSRC=$(foreach sf,$(SQLITESHELLSRC),$(SRCDIR)$(sf)) |
| 93 | 93 | SQLITESHELLOBJ=$(foreach sf,$(SQLITESHELLSRC),$(sf:.c=.obj)) |
| 94 | 94 |
| --- win/Makefile.PellesCGMake | |
| +++ win/Makefile.PellesCGMake | |
| @@ -83,11 +83,11 @@ | |
| 83 | |
| 84 | # define the SQLite files, which need special flags on compile |
| 85 | SQLITESRC=sqlite3.c |
| 86 | ORIGSQLITESRC=$(foreach sf,$(SQLITESRC),$(SRCDIR)$(sf)) |
| 87 | SQLITEOBJ=$(foreach sf,$(SQLITESRC),$(sf:.c=.obj)) |
| 88 | SQLITEDEFINES=-DNDEBUG=1 -DSQLITE_OMIT_LOAD_EXTENSION=1 -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_THREADSAFE=0 -DSQLITE_DEFAULT_FILE_FORMAT=4 -DSQLITE_OMIT_DEPRECATED -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_WIN32_NO_ANSI |
| 89 | |
| 90 | # define the SQLite shell files, which need special flags on compile |
| 91 | SQLITESHELLSRC=shell.c |
| 92 | ORIGSQLITESHELLSRC=$(foreach sf,$(SQLITESHELLSRC),$(SRCDIR)$(sf)) |
| 93 | SQLITESHELLOBJ=$(foreach sf,$(SQLITESHELLSRC),$(sf:.c=.obj)) |
| 94 |
| --- win/Makefile.PellesCGMake | |
| +++ win/Makefile.PellesCGMake | |
| @@ -83,11 +83,11 @@ | |
| 83 | |
| 84 | # define the SQLite files, which need special flags on compile |
| 85 | SQLITESRC=sqlite3.c |
| 86 | ORIGSQLITESRC=$(foreach sf,$(SQLITESRC),$(SRCDIR)$(sf)) |
| 87 | SQLITEOBJ=$(foreach sf,$(SQLITESRC),$(sf:.c=.obj)) |
| 88 | SQLITEDEFINES=-DSQLITE_OMIT_LOAD_EXTENSION=1 -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_THREADSAFE=0 -DSQLITE_DEFAULT_FILE_FORMAT=4 -DSQLITE_OMIT_DEPRECATED -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_FTS4 -DSQLITE_WIN32_NO_ANSI |
| 89 | |
| 90 | # define the SQLite shell files, which need special flags on compile |
| 91 | SQLITESHELLSRC=shell.c |
| 92 | ORIGSQLITESHELLSRC=$(foreach sf,$(SQLITESHELLSRC),$(SRCDIR)$(sf)) |
| 93 | SQLITESHELLOBJ=$(foreach sf,$(SQLITESHELLSRC),$(sf:.c=.obj)) |
| 94 |
+11
-5
| --- win/Makefile.dmc | ||
| +++ win/Makefile.dmc | ||
| @@ -24,17 +24,17 @@ | ||
| 24 | 24 | CFLAGS = -o |
| 25 | 25 | BCC = $(DMDIR)\bin\dmc $(CFLAGS) |
| 26 | 26 | TCC = $(DMDIR)\bin\dmc $(CFLAGS) $(DMCDEF) $(SSL) $(INCL) |
| 27 | 27 | LIBS = $(DMDIR)\extra\lib\ zlib wsock32 advapi32 |
| 28 | 28 | |
| 29 | -SQLITE_OPTIONS = -DNDEBUG=1 -DSQLITE_OMIT_LOAD_EXTENSION=1 -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_THREADSAFE=0 -DSQLITE_DEFAULT_FILE_FORMAT=4 -DSQLITE_OMIT_DEPRECATED -DSQLITE_ENABLE_EXPLAIN_COMMENTS | |
| 29 | +SQLITE_OPTIONS = -DSQLITE_OMIT_LOAD_EXTENSION=1 -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_THREADSAFE=0 -DSQLITE_DEFAULT_FILE_FORMAT=4 -DSQLITE_OMIT_DEPRECATED -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_FTS4 | |
| 30 | 30 | |
| 31 | 31 | SHELL_OPTIONS = -Dmain=sqlite3_shell -DSQLITE_OMIT_LOAD_EXTENSION=1 -DUSE_SYSTEM_SQLITE=$(USE_SYSTEM_SQLITE) -DSQLITE_SHELL_DBNAME_PROC=fossil_open -Daccess=file_access -Dsystem=fossil_system -Dgetenv=fossil_getenv -Dfopen=fossil_fopen |
| 32 | 32 | |
| 33 | -SRC = add_.c allrepo_.c attach_.c bag_.c bisect_.c blob_.c branch_.c browse_.c builtin_.c bundle_.c cache_.c captcha_.c cgi_.c checkin_.c checkout_.c clearsign_.c clone_.c comformat_.c configure_.c content_.c db_.c delta_.c deltacmd_.c descendants_.c diff_.c diffcmd_.c doc_.c encode_.c event_.c export_.c file_.c finfo_.c foci_.c fusefs_.c glob_.c graph_.c gzip_.c http_.c http_socket_.c http_ssl_.c http_transport_.c import_.c info_.c json_.c json_artifact_.c json_branch_.c json_config_.c json_diff_.c json_dir_.c json_finfo_.c json_login_.c json_query_.c json_report_.c json_status_.c json_tag_.c json_timeline_.c json_user_.c json_wiki_.c leaf_.c loadctrl_.c login_.c lookslike_.c main_.c manifest_.c markdown_.c markdown_html_.c md5_.c merge_.c merge3_.c moderate_.c name_.c path_.c pivot_.c popen_.c pqueue_.c printf_.c publish_.c purge_.c rebuild_.c regexp_.c report_.c rss_.c schema_.c search_.c setup_.c sha1_.c shun_.c sitemap_.c skins_.c sqlcmd_.c stash_.c stat_.c style_.c sync_.c tag_.c tar_.c th_main_.c timeline_.c tkt_.c tktsetup_.c undo_.c unicode_.c update_.c url_.c user_.c utf8_.c util_.c verify_.c vfile_.c wiki_.c wikiformat_.c winfile_.c winhttp_.c wysiwyg_.c xfer_.c xfersetup_.c zip_.c | |
| 33 | +SRC = add_.c allrepo_.c attach_.c bag_.c bisect_.c blob_.c branch_.c browse_.c builtin_.c bundle_.c cache_.c captcha_.c cgi_.c checkin_.c checkout_.c clearsign_.c clone_.c comformat_.c configure_.c content_.c db_.c delta_.c deltacmd_.c descendants_.c diff_.c diffcmd_.c doc_.c encode_.c event_.c export_.c file_.c finfo_.c foci_.c ftsearch_.c fusefs_.c glob_.c graph_.c gzip_.c http_.c http_socket_.c http_ssl_.c http_transport_.c import_.c info_.c json_.c json_artifact_.c json_branch_.c json_config_.c json_diff_.c json_dir_.c json_finfo_.c json_login_.c json_query_.c json_report_.c json_status_.c json_tag_.c json_timeline_.c json_user_.c json_wiki_.c leaf_.c loadctrl_.c login_.c lookslike_.c main_.c manifest_.c markdown_.c markdown_html_.c md5_.c merge_.c merge3_.c moderate_.c name_.c path_.c pivot_.c popen_.c pqueue_.c printf_.c publish_.c purge_.c rebuild_.c regexp_.c report_.c rss_.c schema_.c search_.c setup_.c sha1_.c shun_.c sitemap_.c skins_.c sqlcmd_.c stash_.c stat_.c style_.c sync_.c tag_.c tar_.c th_main_.c timeline_.c tkt_.c tktsetup_.c undo_.c unicode_.c update_.c url_.c user_.c utf8_.c util_.c verify_.c vfile_.c wiki_.c wikiformat_.c winfile_.c winhttp_.c wysiwyg_.c xfer_.c xfersetup_.c zip_.c | |
| 34 | 34 | |
| 35 | -OBJ = $(OBJDIR)\add$O $(OBJDIR)\allrepo$O $(OBJDIR)\attach$O $(OBJDIR)\bag$O $(OBJDIR)\bisect$O $(OBJDIR)\blob$O $(OBJDIR)\branch$O $(OBJDIR)\browse$O $(OBJDIR)\builtin$O $(OBJDIR)\bundle$O $(OBJDIR)\cache$O $(OBJDIR)\captcha$O $(OBJDIR)\cgi$O $(OBJDIR)\checkin$O $(OBJDIR)\checkout$O $(OBJDIR)\clearsign$O $(OBJDIR)\clone$O $(OBJDIR)\comformat$O $(OBJDIR)\configure$O $(OBJDIR)\content$O $(OBJDIR)\db$O $(OBJDIR)\delta$O $(OBJDIR)\deltacmd$O $(OBJDIR)\descendants$O $(OBJDIR)\diff$O $(OBJDIR)\diffcmd$O $(OBJDIR)\doc$O $(OBJDIR)\encode$O $(OBJDIR)\event$O $(OBJDIR)\export$O $(OBJDIR)\file$O $(OBJDIR)\finfo$O $(OBJDIR)\foci$O $(OBJDIR)\fusefs$O $(OBJDIR)\glob$O $(OBJDIR)\graph$O $(OBJDIR)\gzip$O $(OBJDIR)\http$O $(OBJDIR)\http_socket$O $(OBJDIR)\http_ssl$O $(OBJDIR)\http_transport$O $(OBJDIR)\import$O $(OBJDIR)\info$O $(OBJDIR)\json$O $(OBJDIR)\json_artifact$O $(OBJDIR)\json_branch$O $(OBJDIR)\json_config$O $(OBJDIR)\json_diff$O $(OBJDIR)\json_dir$O $(OBJDIR)\json_finfo$O $(OBJDIR)\json_login$O $(OBJDIR)\json_query$O $(OBJDIR)\json_report$O $(OBJDIR)\json_status$O $(OBJDIR)\json_tag$O $(OBJDIR)\json_timeline$O $(OBJDIR)\json_user$O $(OBJDIR)\json_wiki$O $(OBJDIR)\leaf$O $(OBJDIR)\loadctrl$O $(OBJDIR)\login$O $(OBJDIR)\lookslike$O $(OBJDIR)\main$O $(OBJDIR)\manifest$O $(OBJDIR)\markdown$O $(OBJDIR)\markdown_html$O $(OBJDIR)\md5$O $(OBJDIR)\merge$O $(OBJDIR)\merge3$O $(OBJDIR)\moderate$O $(OBJDIR)\name$O $(OBJDIR)\path$O $(OBJDIR)\pivot$O $(OBJDIR)\popen$O $(OBJDIR)\pqueue$O $(OBJDIR)\printf$O $(OBJDIR)\publish$O $(OBJDIR)\purge$O $(OBJDIR)\rebuild$O $(OBJDIR)\regexp$O $(OBJDIR)\report$O $(OBJDIR)\rss$O $(OBJDIR)\schema$O $(OBJDIR)\search$O $(OBJDIR)\setup$O $(OBJDIR)\sha1$O $(OBJDIR)\shun$O $(OBJDIR)\sitemap$O $(OBJDIR)\skins$O $(OBJDIR)\sqlcmd$O $(OBJDIR)\stash$O $(OBJDIR)\stat$O $(OBJDIR)\style$O $(OBJDIR)\sync$O $(OBJDIR)\tag$O $(OBJDIR)\tar$O $(OBJDIR)\th_main$O $(OBJDIR)\timeline$O $(OBJDIR)\tkt$O $(OBJDIR)\tktsetup$O $(OBJDIR)\undo$O $(OBJDIR)\unicode$O $(OBJDIR)\update$O $(OBJDIR)\url$O $(OBJDIR)\user$O $(OBJDIR)\utf8$O $(OBJDIR)\util$O $(OBJDIR)\verify$O $(OBJDIR)\vfile$O $(OBJDIR)\wiki$O $(OBJDIR)\wikiformat$O $(OBJDIR)\winfile$O $(OBJDIR)\winhttp$O $(OBJDIR)\wysiwyg$O $(OBJDIR)\xfer$O $(OBJDIR)\xfersetup$O $(OBJDIR)\zip$O $(OBJDIR)\shell$O $(OBJDIR)\sqlite3$O $(OBJDIR)\th$O $(OBJDIR)\th_lang$O | |
| 35 | +OBJ = $(OBJDIR)\add$O $(OBJDIR)\allrepo$O $(OBJDIR)\attach$O $(OBJDIR)\bag$O $(OBJDIR)\bisect$O $(OBJDIR)\blob$O $(OBJDIR)\branch$O $(OBJDIR)\browse$O $(OBJDIR)\builtin$O $(OBJDIR)\bundle$O $(OBJDIR)\cache$O $(OBJDIR)\captcha$O $(OBJDIR)\cgi$O $(OBJDIR)\checkin$O $(OBJDIR)\checkout$O $(OBJDIR)\clearsign$O $(OBJDIR)\clone$O $(OBJDIR)\comformat$O $(OBJDIR)\configure$O $(OBJDIR)\content$O $(OBJDIR)\db$O $(OBJDIR)\delta$O $(OBJDIR)\deltacmd$O $(OBJDIR)\descendants$O $(OBJDIR)\diff$O $(OBJDIR)\diffcmd$O $(OBJDIR)\doc$O $(OBJDIR)\encode$O $(OBJDIR)\event$O $(OBJDIR)\export$O $(OBJDIR)\file$O $(OBJDIR)\finfo$O $(OBJDIR)\foci$O $(OBJDIR)\ftsearch$O $(OBJDIR)\fusefs$O $(OBJDIR)\glob$O $(OBJDIR)\graph$O $(OBJDIR)\gzip$O $(OBJDIR)\http$O $(OBJDIR)\http_socket$O $(OBJDIR)\http_ssl$O $(OBJDIR)\http_transport$O $(OBJDIR)\import$O $(OBJDIR)\info$O $(OBJDIR)\json$O $(OBJDIR)\json_artifact$O $(OBJDIR)\json_branch$O $(OBJDIR)\json_config$O $(OBJDIR)\json_diff$O $(OBJDIR)\json_dir$O $(OBJDIR)\json_finfo$O $(OBJDIR)\json_login$O $(OBJDIR)\json_query$O $(OBJDIR)\json_report$O $(OBJDIR)\json_status$O $(OBJDIR)\json_tag$O $(OBJDIR)\json_timeline$O $(OBJDIR)\json_user$O $(OBJDIR)\json_wiki$O $(OBJDIR)\leaf$O $(OBJDIR)\loadctrl$O $(OBJDIR)\login$O $(OBJDIR)\lookslike$O $(OBJDIR)\main$O $(OBJDIR)\manifest$O $(OBJDIR)\markdown$O $(OBJDIR)\markdown_html$O $(OBJDIR)\md5$O $(OBJDIR)\merge$O $(OBJDIR)\merge3$O $(OBJDIR)\moderate$O $(OBJDIR)\name$O $(OBJDIR)\path$O $(OBJDIR)\pivot$O $(OBJDIR)\popen$O $(OBJDIR)\pqueue$O $(OBJDIR)\printf$O $(OBJDIR)\publish$O $(OBJDIR)\purge$O $(OBJDIR)\rebuild$O $(OBJDIR)\regexp$O $(OBJDIR)\report$O $(OBJDIR)\rss$O $(OBJDIR)\schema$O $(OBJDIR)\search$O $(OBJDIR)\setup$O $(OBJDIR)\sha1$O $(OBJDIR)\shun$O $(OBJDIR)\sitemap$O $(OBJDIR)\skins$O $(OBJDIR)\sqlcmd$O $(OBJDIR)\stash$O $(OBJDIR)\stat$O $(OBJDIR)\style$O $(OBJDIR)\sync$O $(OBJDIR)\tag$O $(OBJDIR)\tar$O $(OBJDIR)\th_main$O $(OBJDIR)\timeline$O $(OBJDIR)\tkt$O $(OBJDIR)\tktsetup$O $(OBJDIR)\undo$O $(OBJDIR)\unicode$O $(OBJDIR)\update$O $(OBJDIR)\url$O $(OBJDIR)\user$O $(OBJDIR)\utf8$O $(OBJDIR)\util$O $(OBJDIR)\verify$O $(OBJDIR)\vfile$O $(OBJDIR)\wiki$O $(OBJDIR)\wikiformat$O $(OBJDIR)\winfile$O $(OBJDIR)\winhttp$O $(OBJDIR)\wysiwyg$O $(OBJDIR)\xfer$O $(OBJDIR)\xfersetup$O $(OBJDIR)\zip$O $(OBJDIR)\shell$O $(OBJDIR)\sqlite3$O $(OBJDIR)\th$O $(OBJDIR)\th_lang$O | |
| 36 | 36 | |
| 37 | 37 | |
| 38 | 38 | RC=$(DMDIR)\bin\rcc |
| 39 | 39 | RCFLAGS=-32 -w1 -I$(SRCDIR) /D__DMC__ |
| 40 | 40 | |
| @@ -49,11 +49,11 @@ | ||
| 49 | 49 | |
| 50 | 50 | $(OBJDIR)\fossil.res: $B\win\fossil.rc |
| 51 | 51 | $(RC) $(RCFLAGS) -o$@ $** |
| 52 | 52 | |
| 53 | 53 | $(OBJDIR)\link: $B\win\Makefile.dmc $(OBJDIR)\fossil.res |
| 54 | - +echo add allrepo attach bag bisect blob branch browse builtin bundle cache captcha cgi checkin checkout clearsign clone comformat configure content db delta deltacmd descendants diff diffcmd doc encode event export file finfo foci fusefs glob graph gzip http http_socket http_ssl http_transport import info json json_artifact json_branch json_config json_diff json_dir json_finfo json_login json_query json_report json_status json_tag json_timeline json_user json_wiki leaf loadctrl login lookslike main manifest markdown markdown_html md5 merge merge3 moderate name path pivot popen pqueue printf publish purge rebuild regexp report rss schema search setup sha1 shun sitemap skins sqlcmd stash stat style sync tag tar th_main timeline tkt tktsetup undo unicode update url user utf8 util verify vfile wiki wikiformat winfile winhttp wysiwyg xfer xfersetup zip shell sqlite3 th th_lang > $@ | |
| 54 | + +echo add allrepo attach bag bisect blob branch browse builtin bundle cache captcha cgi checkin checkout clearsign clone comformat configure content db delta deltacmd descendants diff diffcmd doc encode event export file finfo foci ftsearch fusefs glob graph gzip http http_socket http_ssl http_transport import info json json_artifact json_branch json_config json_diff json_dir json_finfo json_login json_query json_report json_status json_tag json_timeline json_user json_wiki leaf loadctrl login lookslike main manifest markdown markdown_html md5 merge merge3 moderate name path pivot popen pqueue printf publish purge rebuild regexp report rss schema search setup sha1 shun sitemap skins sqlcmd stash stat style sync tag tar th_main timeline tkt tktsetup undo unicode update url user utf8 util verify vfile wiki wikiformat winfile winhttp wysiwyg xfer xfersetup zip shell sqlite3 th th_lang > $@ | |
| 55 | 55 | +echo fossil >> $@ |
| 56 | 56 | +echo fossil >> $@ |
| 57 | 57 | +echo $(LIBS) >> $@ |
| 58 | 58 | +echo. >> $@ |
| 59 | 59 | +echo fossil >> $@ |
| @@ -320,10 +320,16 @@ | ||
| 320 | 320 | $(OBJDIR)\foci$O : foci_.c foci.h |
| 321 | 321 | $(TCC) -o$@ -c foci_.c |
| 322 | 322 | |
| 323 | 323 | foci_.c : $(SRCDIR)\foci.c |
| 324 | 324 | +translate$E $** > $@ |
| 325 | + | |
| 326 | +$(OBJDIR)\ftsearch$O : ftsearch_.c ftsearch.h | |
| 327 | + $(TCC) -o$@ -c ftsearch_.c | |
| 328 | + | |
| 329 | +ftsearch_.c : $(SRCDIR)\ftsearch.c | |
| 330 | + +translate$E $** > $@ | |
| 325 | 331 | |
| 326 | 332 | $(OBJDIR)\fusefs$O : fusefs_.c fusefs.h |
| 327 | 333 | $(TCC) -o$@ -c fusefs_.c |
| 328 | 334 | |
| 329 | 335 | fusefs_.c : $(SRCDIR)\fusefs.c |
| @@ -826,7 +832,7 @@ | ||
| 826 | 832 | |
| 827 | 833 | zip_.c : $(SRCDIR)\zip.c |
| 828 | 834 | +translate$E $** > $@ |
| 829 | 835 | |
| 830 | 836 | headers: makeheaders$E page_index.h builtin_data.h VERSION.h |
| 831 | - +makeheaders$E add_.c:add.h allrepo_.c:allrepo.h attach_.c:attach.h bag_.c:bag.h bisect_.c:bisect.h blob_.c:blob.h branch_.c:branch.h browse_.c:browse.h builtin_.c:builtin.h bundle_.c:bundle.h cache_.c:cache.h captcha_.c:captcha.h cgi_.c:cgi.h checkin_.c:checkin.h checkout_.c:checkout.h clearsign_.c:clearsign.h clone_.c:clone.h comformat_.c:comformat.h configure_.c:configure.h content_.c:content.h db_.c:db.h delta_.c:delta.h deltacmd_.c:deltacmd.h descendants_.c:descendants.h diff_.c:diff.h diffcmd_.c:diffcmd.h doc_.c:doc.h encode_.c:encode.h event_.c:event.h export_.c:export.h file_.c:file.h finfo_.c:finfo.h foci_.c:foci.h fusefs_.c:fusefs.h glob_.c:glob.h graph_.c:graph.h gzip_.c:gzip.h http_.c:http.h http_socket_.c:http_socket.h http_ssl_.c:http_ssl.h http_transport_.c:http_transport.h import_.c:import.h info_.c:info.h json_.c:json.h json_artifact_.c:json_artifact.h json_branch_.c:json_branch.h json_config_.c:json_config.h json_diff_.c:json_diff.h json_dir_.c:json_dir.h json_finfo_.c:json_finfo.h json_login_.c:json_login.h json_query_.c:json_query.h json_report_.c:json_report.h json_status_.c:json_status.h json_tag_.c:json_tag.h json_timeline_.c:json_timeline.h json_user_.c:json_user.h json_wiki_.c:json_wiki.h leaf_.c:leaf.h loadctrl_.c:loadctrl.h login_.c:login.h lookslike_.c:lookslike.h main_.c:main.h manifest_.c:manifest.h markdown_.c:markdown.h markdown_html_.c:markdown_html.h md5_.c:md5.h merge_.c:merge.h merge3_.c:merge3.h moderate_.c:moderate.h name_.c:name.h path_.c:path.h pivot_.c:pivot.h popen_.c:popen.h pqueue_.c:pqueue.h printf_.c:printf.h publish_.c:publish.h purge_.c:purge.h rebuild_.c:rebuild.h regexp_.c:regexp.h report_.c:report.h rss_.c:rss.h schema_.c:schema.h search_.c:search.h setup_.c:setup.h sha1_.c:sha1.h shun_.c:shun.h sitemap_.c:sitemap.h skins_.c:skins.h sqlcmd_.c:sqlcmd.h stash_.c:stash.h stat_.c:stat.h style_.c:style.h sync_.c:sync.h tag_.c:tag.h tar_.c:tar.h th_main_.c:th_main.h timeline_.c:timeline.h tkt_.c:tkt.h tktsetup_.c:tktsetup.h undo_.c:undo.h unicode_.c:unicode.h update_.c:update.h url_.c:url.h user_.c:user.h utf8_.c:utf8.h util_.c:util.h verify_.c:verify.h vfile_.c:vfile.h wiki_.c:wiki.h wikiformat_.c:wikiformat.h winfile_.c:winfile.h winhttp_.c:winhttp.h wysiwyg_.c:wysiwyg.h xfer_.c:xfer.h xfersetup_.c:xfersetup.h zip_.c:zip.h $(SRCDIR)\sqlite3.h $(SRCDIR)\th.h VERSION.h $(SRCDIR)\cson_amalgamation.h | |
| 837 | + +makeheaders$E add_.c:add.h allrepo_.c:allrepo.h attach_.c:attach.h bag_.c:bag.h bisect_.c:bisect.h blob_.c:blob.h branch_.c:branch.h browse_.c:browse.h builtin_.c:builtin.h bundle_.c:bundle.h cache_.c:cache.h captcha_.c:captcha.h cgi_.c:cgi.h checkin_.c:checkin.h checkout_.c:checkout.h clearsign_.c:clearsign.h clone_.c:clone.h comformat_.c:comformat.h configure_.c:configure.h content_.c:content.h db_.c:db.h delta_.c:delta.h deltacmd_.c:deltacmd.h descendants_.c:descendants.h diff_.c:diff.h diffcmd_.c:diffcmd.h doc_.c:doc.h encode_.c:encode.h event_.c:event.h export_.c:export.h file_.c:file.h finfo_.c:finfo.h foci_.c:foci.h ftsearch_.c:ftsearch.h fusefs_.c:fusefs.h glob_.c:glob.h graph_.c:graph.h gzip_.c:gzip.h http_.c:http.h http_socket_.c:http_socket.h http_ssl_.c:http_ssl.h http_transport_.c:http_transport.h import_.c:import.h info_.c:info.h json_.c:json.h json_artifact_.c:json_artifact.h json_branch_.c:json_branch.h json_config_.c:json_config.h json_diff_.c:json_diff.h json_dir_.c:json_dir.h json_finfo_.c:json_finfo.h json_login_.c:json_login.h json_query_.c:json_query.h json_report_.c:json_report.h json_status_.c:json_status.h json_tag_.c:json_tag.h json_timeline_.c:json_timeline.h json_user_.c:json_user.h json_wiki_.c:json_wiki.h leaf_.c:leaf.h loadctrl_.c:loadctrl.h login_.c:login.h lookslike_.c:lookslike.h main_.c:main.h manifest_.c:manifest.h markdown_.c:markdown.h markdown_html_.c:markdown_html.h md5_.c:md5.h merge_.c:merge.h merge3_.c:merge3.h moderate_.c:moderate.h name_.c:name.h path_.c:path.h pivot_.c:pivot.h popen_.c:popen.h pqueue_.c:pqueue.h printf_.c:printf.h publish_.c:publish.h purge_.c:purge.h rebuild_.c:rebuild.h regexp_.c:regexp.h report_.c:report.h rss_.c:rss.h schema_.c:schema.h search_.c:search.h setup_.c:setup.h sha1_.c:sha1.h shun_.c:shun.h sitemap_.c:sitemap.h skins_.c:skins.h sqlcmd_.c:sqlcmd.h stash_.c:stash.h stat_.c:stat.h style_.c:style.h sync_.c:sync.h tag_.c:tag.h tar_.c:tar.h th_main_.c:th_main.h timeline_.c:timeline.h tkt_.c:tkt.h tktsetup_.c:tktsetup.h undo_.c:undo.h unicode_.c:unicode.h update_.c:update.h url_.c:url.h user_.c:user.h utf8_.c:utf8.h util_.c:util.h verify_.c:verify.h vfile_.c:vfile.h wiki_.c:wiki.h wikiformat_.c:wikiformat.h winfile_.c:winfile.h winhttp_.c:winhttp.h wysiwyg_.c:wysiwyg.h xfer_.c:xfer.h xfersetup_.c:xfersetup.h zip_.c:zip.h $(SRCDIR)\sqlite3.h $(SRCDIR)\th.h VERSION.h $(SRCDIR)\cson_amalgamation.h | |
| 832 | 838 | @copy /Y nul: headers |
| 833 | 839 |
| --- win/Makefile.dmc | |
| +++ win/Makefile.dmc | |
| @@ -24,17 +24,17 @@ | |
| 24 | CFLAGS = -o |
| 25 | BCC = $(DMDIR)\bin\dmc $(CFLAGS) |
| 26 | TCC = $(DMDIR)\bin\dmc $(CFLAGS) $(DMCDEF) $(SSL) $(INCL) |
| 27 | LIBS = $(DMDIR)\extra\lib\ zlib wsock32 advapi32 |
| 28 | |
| 29 | SQLITE_OPTIONS = -DNDEBUG=1 -DSQLITE_OMIT_LOAD_EXTENSION=1 -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_THREADSAFE=0 -DSQLITE_DEFAULT_FILE_FORMAT=4 -DSQLITE_OMIT_DEPRECATED -DSQLITE_ENABLE_EXPLAIN_COMMENTS |
| 30 | |
| 31 | SHELL_OPTIONS = -Dmain=sqlite3_shell -DSQLITE_OMIT_LOAD_EXTENSION=1 -DUSE_SYSTEM_SQLITE=$(USE_SYSTEM_SQLITE) -DSQLITE_SHELL_DBNAME_PROC=fossil_open -Daccess=file_access -Dsystem=fossil_system -Dgetenv=fossil_getenv -Dfopen=fossil_fopen |
| 32 | |
| 33 | SRC = add_.c allrepo_.c attach_.c bag_.c bisect_.c blob_.c branch_.c browse_.c builtin_.c bundle_.c cache_.c captcha_.c cgi_.c checkin_.c checkout_.c clearsign_.c clone_.c comformat_.c configure_.c content_.c db_.c delta_.c deltacmd_.c descendants_.c diff_.c diffcmd_.c doc_.c encode_.c event_.c export_.c file_.c finfo_.c foci_.c fusefs_.c glob_.c graph_.c gzip_.c http_.c http_socket_.c http_ssl_.c http_transport_.c import_.c info_.c json_.c json_artifact_.c json_branch_.c json_config_.c json_diff_.c json_dir_.c json_finfo_.c json_login_.c json_query_.c json_report_.c json_status_.c json_tag_.c json_timeline_.c json_user_.c json_wiki_.c leaf_.c loadctrl_.c login_.c lookslike_.c main_.c manifest_.c markdown_.c markdown_html_.c md5_.c merge_.c merge3_.c moderate_.c name_.c path_.c pivot_.c popen_.c pqueue_.c printf_.c publish_.c purge_.c rebuild_.c regexp_.c report_.c rss_.c schema_.c search_.c setup_.c sha1_.c shun_.c sitemap_.c skins_.c sqlcmd_.c stash_.c stat_.c style_.c sync_.c tag_.c tar_.c th_main_.c timeline_.c tkt_.c tktsetup_.c undo_.c unicode_.c update_.c url_.c user_.c utf8_.c util_.c verify_.c vfile_.c wiki_.c wikiformat_.c winfile_.c winhttp_.c wysiwyg_.c xfer_.c xfersetup_.c zip_.c |
| 34 | |
| 35 | OBJ = $(OBJDIR)\add$O $(OBJDIR)\allrepo$O $(OBJDIR)\attach$O $(OBJDIR)\bag$O $(OBJDIR)\bisect$O $(OBJDIR)\blob$O $(OBJDIR)\branch$O $(OBJDIR)\browse$O $(OBJDIR)\builtin$O $(OBJDIR)\bundle$O $(OBJDIR)\cache$O $(OBJDIR)\captcha$O $(OBJDIR)\cgi$O $(OBJDIR)\checkin$O $(OBJDIR)\checkout$O $(OBJDIR)\clearsign$O $(OBJDIR)\clone$O $(OBJDIR)\comformat$O $(OBJDIR)\configure$O $(OBJDIR)\content$O $(OBJDIR)\db$O $(OBJDIR)\delta$O $(OBJDIR)\deltacmd$O $(OBJDIR)\descendants$O $(OBJDIR)\diff$O $(OBJDIR)\diffcmd$O $(OBJDIR)\doc$O $(OBJDIR)\encode$O $(OBJDIR)\event$O $(OBJDIR)\export$O $(OBJDIR)\file$O $(OBJDIR)\finfo$O $(OBJDIR)\foci$O $(OBJDIR)\fusefs$O $(OBJDIR)\glob$O $(OBJDIR)\graph$O $(OBJDIR)\gzip$O $(OBJDIR)\http$O $(OBJDIR)\http_socket$O $(OBJDIR)\http_ssl$O $(OBJDIR)\http_transport$O $(OBJDIR)\import$O $(OBJDIR)\info$O $(OBJDIR)\json$O $(OBJDIR)\json_artifact$O $(OBJDIR)\json_branch$O $(OBJDIR)\json_config$O $(OBJDIR)\json_diff$O $(OBJDIR)\json_dir$O $(OBJDIR)\json_finfo$O $(OBJDIR)\json_login$O $(OBJDIR)\json_query$O $(OBJDIR)\json_report$O $(OBJDIR)\json_status$O $(OBJDIR)\json_tag$O $(OBJDIR)\json_timeline$O $(OBJDIR)\json_user$O $(OBJDIR)\json_wiki$O $(OBJDIR)\leaf$O $(OBJDIR)\loadctrl$O $(OBJDIR)\login$O $(OBJDIR)\lookslike$O $(OBJDIR)\main$O $(OBJDIR)\manifest$O $(OBJDIR)\markdown$O $(OBJDIR)\markdown_html$O $(OBJDIR)\md5$O $(OBJDIR)\merge$O $(OBJDIR)\merge3$O $(OBJDIR)\moderate$O $(OBJDIR)\name$O $(OBJDIR)\path$O $(OBJDIR)\pivot$O $(OBJDIR)\popen$O $(OBJDIR)\pqueue$O $(OBJDIR)\printf$O $(OBJDIR)\publish$O $(OBJDIR)\purge$O $(OBJDIR)\rebuild$O $(OBJDIR)\regexp$O $(OBJDIR)\report$O $(OBJDIR)\rss$O $(OBJDIR)\schema$O $(OBJDIR)\search$O $(OBJDIR)\setup$O $(OBJDIR)\sha1$O $(OBJDIR)\shun$O $(OBJDIR)\sitemap$O $(OBJDIR)\skins$O $(OBJDIR)\sqlcmd$O $(OBJDIR)\stash$O $(OBJDIR)\stat$O $(OBJDIR)\style$O $(OBJDIR)\sync$O $(OBJDIR)\tag$O $(OBJDIR)\tar$O $(OBJDIR)\th_main$O $(OBJDIR)\timeline$O $(OBJDIR)\tkt$O $(OBJDIR)\tktsetup$O $(OBJDIR)\undo$O $(OBJDIR)\unicode$O $(OBJDIR)\update$O $(OBJDIR)\url$O $(OBJDIR)\user$O $(OBJDIR)\utf8$O $(OBJDIR)\util$O $(OBJDIR)\verify$O $(OBJDIR)\vfile$O $(OBJDIR)\wiki$O $(OBJDIR)\wikiformat$O $(OBJDIR)\winfile$O $(OBJDIR)\winhttp$O $(OBJDIR)\wysiwyg$O $(OBJDIR)\xfer$O $(OBJDIR)\xfersetup$O $(OBJDIR)\zip$O $(OBJDIR)\shell$O $(OBJDIR)\sqlite3$O $(OBJDIR)\th$O $(OBJDIR)\th_lang$O |
| 36 | |
| 37 | |
| 38 | RC=$(DMDIR)\bin\rcc |
| 39 | RCFLAGS=-32 -w1 -I$(SRCDIR) /D__DMC__ |
| 40 | |
| @@ -49,11 +49,11 @@ | |
| 49 | |
| 50 | $(OBJDIR)\fossil.res: $B\win\fossil.rc |
| 51 | $(RC) $(RCFLAGS) -o$@ $** |
| 52 | |
| 53 | $(OBJDIR)\link: $B\win\Makefile.dmc $(OBJDIR)\fossil.res |
| 54 | +echo add allrepo attach bag bisect blob branch browse builtin bundle cache captcha cgi checkin checkout clearsign clone comformat configure content db delta deltacmd descendants diff diffcmd doc encode event export file finfo foci fusefs glob graph gzip http http_socket http_ssl http_transport import info json json_artifact json_branch json_config json_diff json_dir json_finfo json_login json_query json_report json_status json_tag json_timeline json_user json_wiki leaf loadctrl login lookslike main manifest markdown markdown_html md5 merge merge3 moderate name path pivot popen pqueue printf publish purge rebuild regexp report rss schema search setup sha1 shun sitemap skins sqlcmd stash stat style sync tag tar th_main timeline tkt tktsetup undo unicode update url user utf8 util verify vfile wiki wikiformat winfile winhttp wysiwyg xfer xfersetup zip shell sqlite3 th th_lang > $@ |
| 55 | +echo fossil >> $@ |
| 56 | +echo fossil >> $@ |
| 57 | +echo $(LIBS) >> $@ |
| 58 | +echo. >> $@ |
| 59 | +echo fossil >> $@ |
| @@ -320,10 +320,16 @@ | |
| 320 | $(OBJDIR)\foci$O : foci_.c foci.h |
| 321 | $(TCC) -o$@ -c foci_.c |
| 322 | |
| 323 | foci_.c : $(SRCDIR)\foci.c |
| 324 | +translate$E $** > $@ |
| 325 | |
| 326 | $(OBJDIR)\fusefs$O : fusefs_.c fusefs.h |
| 327 | $(TCC) -o$@ -c fusefs_.c |
| 328 | |
| 329 | fusefs_.c : $(SRCDIR)\fusefs.c |
| @@ -826,7 +832,7 @@ | |
| 826 | |
| 827 | zip_.c : $(SRCDIR)\zip.c |
| 828 | +translate$E $** > $@ |
| 829 | |
| 830 | headers: makeheaders$E page_index.h builtin_data.h VERSION.h |
| 831 | +makeheaders$E add_.c:add.h allrepo_.c:allrepo.h attach_.c:attach.h bag_.c:bag.h bisect_.c:bisect.h blob_.c:blob.h branch_.c:branch.h browse_.c:browse.h builtin_.c:builtin.h bundle_.c:bundle.h cache_.c:cache.h captcha_.c:captcha.h cgi_.c:cgi.h checkin_.c:checkin.h checkout_.c:checkout.h clearsign_.c:clearsign.h clone_.c:clone.h comformat_.c:comformat.h configure_.c:configure.h content_.c:content.h db_.c:db.h delta_.c:delta.h deltacmd_.c:deltacmd.h descendants_.c:descendants.h diff_.c:diff.h diffcmd_.c:diffcmd.h doc_.c:doc.h encode_.c:encode.h event_.c:event.h export_.c:export.h file_.c:file.h finfo_.c:finfo.h foci_.c:foci.h fusefs_.c:fusefs.h glob_.c:glob.h graph_.c:graph.h gzip_.c:gzip.h http_.c:http.h http_socket_.c:http_socket.h http_ssl_.c:http_ssl.h http_transport_.c:http_transport.h import_.c:import.h info_.c:info.h json_.c:json.h json_artifact_.c:json_artifact.h json_branch_.c:json_branch.h json_config_.c:json_config.h json_diff_.c:json_diff.h json_dir_.c:json_dir.h json_finfo_.c:json_finfo.h json_login_.c:json_login.h json_query_.c:json_query.h json_report_.c:json_report.h json_status_.c:json_status.h json_tag_.c:json_tag.h json_timeline_.c:json_timeline.h json_user_.c:json_user.h json_wiki_.c:json_wiki.h leaf_.c:leaf.h loadctrl_.c:loadctrl.h login_.c:login.h lookslike_.c:lookslike.h main_.c:main.h manifest_.c:manifest.h markdown_.c:markdown.h markdown_html_.c:markdown_html.h md5_.c:md5.h merge_.c:merge.h merge3_.c:merge3.h moderate_.c:moderate.h name_.c:name.h path_.c:path.h pivot_.c:pivot.h popen_.c:popen.h pqueue_.c:pqueue.h printf_.c:printf.h publish_.c:publish.h purge_.c:purge.h rebuild_.c:rebuild.h regexp_.c:regexp.h report_.c:report.h rss_.c:rss.h schema_.c:schema.h search_.c:search.h setup_.c:setup.h sha1_.c:sha1.h shun_.c:shun.h sitemap_.c:sitemap.h skins_.c:skins.h sqlcmd_.c:sqlcmd.h stash_.c:stash.h stat_.c:stat.h style_.c:style.h sync_.c:sync.h tag_.c:tag.h tar_.c:tar.h th_main_.c:th_main.h timeline_.c:timeline.h tkt_.c:tkt.h tktsetup_.c:tktsetup.h undo_.c:undo.h unicode_.c:unicode.h update_.c:update.h url_.c:url.h user_.c:user.h utf8_.c:utf8.h util_.c:util.h verify_.c:verify.h vfile_.c:vfile.h wiki_.c:wiki.h wikiformat_.c:wikiformat.h winfile_.c:winfile.h winhttp_.c:winhttp.h wysiwyg_.c:wysiwyg.h xfer_.c:xfer.h xfersetup_.c:xfersetup.h zip_.c:zip.h $(SRCDIR)\sqlite3.h $(SRCDIR)\th.h VERSION.h $(SRCDIR)\cson_amalgamation.h |
| 832 | @copy /Y nul: headers |
| 833 |
| --- win/Makefile.dmc | |
| +++ win/Makefile.dmc | |
| @@ -24,17 +24,17 @@ | |
| 24 | CFLAGS = -o |
| 25 | BCC = $(DMDIR)\bin\dmc $(CFLAGS) |
| 26 | TCC = $(DMDIR)\bin\dmc $(CFLAGS) $(DMCDEF) $(SSL) $(INCL) |
| 27 | LIBS = $(DMDIR)\extra\lib\ zlib wsock32 advapi32 |
| 28 | |
| 29 | SQLITE_OPTIONS = -DSQLITE_OMIT_LOAD_EXTENSION=1 -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_THREADSAFE=0 -DSQLITE_DEFAULT_FILE_FORMAT=4 -DSQLITE_OMIT_DEPRECATED -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_FTS4 |
| 30 | |
| 31 | SHELL_OPTIONS = -Dmain=sqlite3_shell -DSQLITE_OMIT_LOAD_EXTENSION=1 -DUSE_SYSTEM_SQLITE=$(USE_SYSTEM_SQLITE) -DSQLITE_SHELL_DBNAME_PROC=fossil_open -Daccess=file_access -Dsystem=fossil_system -Dgetenv=fossil_getenv -Dfopen=fossil_fopen |
| 32 | |
| 33 | SRC = add_.c allrepo_.c attach_.c bag_.c bisect_.c blob_.c branch_.c browse_.c builtin_.c bundle_.c cache_.c captcha_.c cgi_.c checkin_.c checkout_.c clearsign_.c clone_.c comformat_.c configure_.c content_.c db_.c delta_.c deltacmd_.c descendants_.c diff_.c diffcmd_.c doc_.c encode_.c event_.c export_.c file_.c finfo_.c foci_.c ftsearch_.c fusefs_.c glob_.c graph_.c gzip_.c http_.c http_socket_.c http_ssl_.c http_transport_.c import_.c info_.c json_.c json_artifact_.c json_branch_.c json_config_.c json_diff_.c json_dir_.c json_finfo_.c json_login_.c json_query_.c json_report_.c json_status_.c json_tag_.c json_timeline_.c json_user_.c json_wiki_.c leaf_.c loadctrl_.c login_.c lookslike_.c main_.c manifest_.c markdown_.c markdown_html_.c md5_.c merge_.c merge3_.c moderate_.c name_.c path_.c pivot_.c popen_.c pqueue_.c printf_.c publish_.c purge_.c rebuild_.c regexp_.c report_.c rss_.c schema_.c search_.c setup_.c sha1_.c shun_.c sitemap_.c skins_.c sqlcmd_.c stash_.c stat_.c style_.c sync_.c tag_.c tar_.c th_main_.c timeline_.c tkt_.c tktsetup_.c undo_.c unicode_.c update_.c url_.c user_.c utf8_.c util_.c verify_.c vfile_.c wiki_.c wikiformat_.c winfile_.c winhttp_.c wysiwyg_.c xfer_.c xfersetup_.c zip_.c |
| 34 | |
| 35 | OBJ = $(OBJDIR)\add$O $(OBJDIR)\allrepo$O $(OBJDIR)\attach$O $(OBJDIR)\bag$O $(OBJDIR)\bisect$O $(OBJDIR)\blob$O $(OBJDIR)\branch$O $(OBJDIR)\browse$O $(OBJDIR)\builtin$O $(OBJDIR)\bundle$O $(OBJDIR)\cache$O $(OBJDIR)\captcha$O $(OBJDIR)\cgi$O $(OBJDIR)\checkin$O $(OBJDIR)\checkout$O $(OBJDIR)\clearsign$O $(OBJDIR)\clone$O $(OBJDIR)\comformat$O $(OBJDIR)\configure$O $(OBJDIR)\content$O $(OBJDIR)\db$O $(OBJDIR)\delta$O $(OBJDIR)\deltacmd$O $(OBJDIR)\descendants$O $(OBJDIR)\diff$O $(OBJDIR)\diffcmd$O $(OBJDIR)\doc$O $(OBJDIR)\encode$O $(OBJDIR)\event$O $(OBJDIR)\export$O $(OBJDIR)\file$O $(OBJDIR)\finfo$O $(OBJDIR)\foci$O $(OBJDIR)\ftsearch$O $(OBJDIR)\fusefs$O $(OBJDIR)\glob$O $(OBJDIR)\graph$O $(OBJDIR)\gzip$O $(OBJDIR)\http$O $(OBJDIR)\http_socket$O $(OBJDIR)\http_ssl$O $(OBJDIR)\http_transport$O $(OBJDIR)\import$O $(OBJDIR)\info$O $(OBJDIR)\json$O $(OBJDIR)\json_artifact$O $(OBJDIR)\json_branch$O $(OBJDIR)\json_config$O $(OBJDIR)\json_diff$O $(OBJDIR)\json_dir$O $(OBJDIR)\json_finfo$O $(OBJDIR)\json_login$O $(OBJDIR)\json_query$O $(OBJDIR)\json_report$O $(OBJDIR)\json_status$O $(OBJDIR)\json_tag$O $(OBJDIR)\json_timeline$O $(OBJDIR)\json_user$O $(OBJDIR)\json_wiki$O $(OBJDIR)\leaf$O $(OBJDIR)\loadctrl$O $(OBJDIR)\login$O $(OBJDIR)\lookslike$O $(OBJDIR)\main$O $(OBJDIR)\manifest$O $(OBJDIR)\markdown$O $(OBJDIR)\markdown_html$O $(OBJDIR)\md5$O $(OBJDIR)\merge$O $(OBJDIR)\merge3$O $(OBJDIR)\moderate$O $(OBJDIR)\name$O $(OBJDIR)\path$O $(OBJDIR)\pivot$O $(OBJDIR)\popen$O $(OBJDIR)\pqueue$O $(OBJDIR)\printf$O $(OBJDIR)\publish$O $(OBJDIR)\purge$O $(OBJDIR)\rebuild$O $(OBJDIR)\regexp$O $(OBJDIR)\report$O $(OBJDIR)\rss$O $(OBJDIR)\schema$O $(OBJDIR)\search$O $(OBJDIR)\setup$O $(OBJDIR)\sha1$O $(OBJDIR)\shun$O $(OBJDIR)\sitemap$O $(OBJDIR)\skins$O $(OBJDIR)\sqlcmd$O $(OBJDIR)\stash$O $(OBJDIR)\stat$O $(OBJDIR)\style$O $(OBJDIR)\sync$O $(OBJDIR)\tag$O $(OBJDIR)\tar$O $(OBJDIR)\th_main$O $(OBJDIR)\timeline$O $(OBJDIR)\tkt$O $(OBJDIR)\tktsetup$O $(OBJDIR)\undo$O $(OBJDIR)\unicode$O $(OBJDIR)\update$O $(OBJDIR)\url$O $(OBJDIR)\user$O $(OBJDIR)\utf8$O $(OBJDIR)\util$O $(OBJDIR)\verify$O $(OBJDIR)\vfile$O $(OBJDIR)\wiki$O $(OBJDIR)\wikiformat$O $(OBJDIR)\winfile$O $(OBJDIR)\winhttp$O $(OBJDIR)\wysiwyg$O $(OBJDIR)\xfer$O $(OBJDIR)\xfersetup$O $(OBJDIR)\zip$O $(OBJDIR)\shell$O $(OBJDIR)\sqlite3$O $(OBJDIR)\th$O $(OBJDIR)\th_lang$O |
| 36 | |
| 37 | |
| 38 | RC=$(DMDIR)\bin\rcc |
| 39 | RCFLAGS=-32 -w1 -I$(SRCDIR) /D__DMC__ |
| 40 | |
| @@ -49,11 +49,11 @@ | |
| 49 | |
| 50 | $(OBJDIR)\fossil.res: $B\win\fossil.rc |
| 51 | $(RC) $(RCFLAGS) -o$@ $** |
| 52 | |
| 53 | $(OBJDIR)\link: $B\win\Makefile.dmc $(OBJDIR)\fossil.res |
| 54 | +echo add allrepo attach bag bisect blob branch browse builtin bundle cache captcha cgi checkin checkout clearsign clone comformat configure content db delta deltacmd descendants diff diffcmd doc encode event export file finfo foci ftsearch fusefs glob graph gzip http http_socket http_ssl http_transport import info json json_artifact json_branch json_config json_diff json_dir json_finfo json_login json_query json_report json_status json_tag json_timeline json_user json_wiki leaf loadctrl login lookslike main manifest markdown markdown_html md5 merge merge3 moderate name path pivot popen pqueue printf publish purge rebuild regexp report rss schema search setup sha1 shun sitemap skins sqlcmd stash stat style sync tag tar th_main timeline tkt tktsetup undo unicode update url user utf8 util verify vfile wiki wikiformat winfile winhttp wysiwyg xfer xfersetup zip shell sqlite3 th th_lang > $@ |
| 55 | +echo fossil >> $@ |
| 56 | +echo fossil >> $@ |
| 57 | +echo $(LIBS) >> $@ |
| 58 | +echo. >> $@ |
| 59 | +echo fossil >> $@ |
| @@ -320,10 +320,16 @@ | |
| 320 | $(OBJDIR)\foci$O : foci_.c foci.h |
| 321 | $(TCC) -o$@ -c foci_.c |
| 322 | |
| 323 | foci_.c : $(SRCDIR)\foci.c |
| 324 | +translate$E $** > $@ |
| 325 | |
| 326 | $(OBJDIR)\ftsearch$O : ftsearch_.c ftsearch.h |
| 327 | $(TCC) -o$@ -c ftsearch_.c |
| 328 | |
| 329 | ftsearch_.c : $(SRCDIR)\ftsearch.c |
| 330 | +translate$E $** > $@ |
| 331 | |
| 332 | $(OBJDIR)\fusefs$O : fusefs_.c fusefs.h |
| 333 | $(TCC) -o$@ -c fusefs_.c |
| 334 | |
| 335 | fusefs_.c : $(SRCDIR)\fusefs.c |
| @@ -826,7 +832,7 @@ | |
| 832 | |
| 833 | zip_.c : $(SRCDIR)\zip.c |
| 834 | +translate$E $** > $@ |
| 835 | |
| 836 | headers: makeheaders$E page_index.h builtin_data.h VERSION.h |
| 837 | +makeheaders$E add_.c:add.h allrepo_.c:allrepo.h attach_.c:attach.h bag_.c:bag.h bisect_.c:bisect.h blob_.c:blob.h branch_.c:branch.h browse_.c:browse.h builtin_.c:builtin.h bundle_.c:bundle.h cache_.c:cache.h captcha_.c:captcha.h cgi_.c:cgi.h checkin_.c:checkin.h checkout_.c:checkout.h clearsign_.c:clearsign.h clone_.c:clone.h comformat_.c:comformat.h configure_.c:configure.h content_.c:content.h db_.c:db.h delta_.c:delta.h deltacmd_.c:deltacmd.h descendants_.c:descendants.h diff_.c:diff.h diffcmd_.c:diffcmd.h doc_.c:doc.h encode_.c:encode.h event_.c:event.h export_.c:export.h file_.c:file.h finfo_.c:finfo.h foci_.c:foci.h ftsearch_.c:ftsearch.h fusefs_.c:fusefs.h glob_.c:glob.h graph_.c:graph.h gzip_.c:gzip.h http_.c:http.h http_socket_.c:http_socket.h http_ssl_.c:http_ssl.h http_transport_.c:http_transport.h import_.c:import.h info_.c:info.h json_.c:json.h json_artifact_.c:json_artifact.h json_branch_.c:json_branch.h json_config_.c:json_config.h json_diff_.c:json_diff.h json_dir_.c:json_dir.h json_finfo_.c:json_finfo.h json_login_.c:json_login.h json_query_.c:json_query.h json_report_.c:json_report.h json_status_.c:json_status.h json_tag_.c:json_tag.h json_timeline_.c:json_timeline.h json_user_.c:json_user.h json_wiki_.c:json_wiki.h leaf_.c:leaf.h loadctrl_.c:loadctrl.h login_.c:login.h lookslike_.c:lookslike.h main_.c:main.h manifest_.c:manifest.h markdown_.c:markdown.h markdown_html_.c:markdown_html.h md5_.c:md5.h merge_.c:merge.h merge3_.c:merge3.h moderate_.c:moderate.h name_.c:name.h path_.c:path.h pivot_.c:pivot.h popen_.c:popen.h pqueue_.c:pqueue.h printf_.c:printf.h publish_.c:publish.h purge_.c:purge.h rebuild_.c:rebuild.h regexp_.c:regexp.h report_.c:report.h rss_.c:rss.h schema_.c:schema.h search_.c:search.h setup_.c:setup.h sha1_.c:sha1.h shun_.c:shun.h sitemap_.c:sitemap.h skins_.c:skins.h sqlcmd_.c:sqlcmd.h stash_.c:stash.h stat_.c:stat.h style_.c:style.h sync_.c:sync.h tag_.c:tag.h tar_.c:tar.h th_main_.c:th_main.h timeline_.c:timeline.h tkt_.c:tkt.h tktsetup_.c:tktsetup.h undo_.c:undo.h unicode_.c:unicode.h update_.c:update.h url_.c:url.h user_.c:user.h utf8_.c:utf8.h util_.c:util.h verify_.c:verify.h vfile_.c:vfile.h wiki_.c:wiki.h wikiformat_.c:wikiformat.h winfile_.c:winfile.h winhttp_.c:winhttp.h wysiwyg_.c:wysiwyg.h xfer_.c:xfer.h xfersetup_.c:xfersetup.h zip_.c:zip.h $(SRCDIR)\sqlite3.h $(SRCDIR)\th.h VERSION.h $(SRCDIR)\cson_amalgamation.h |
| 838 | @copy /Y nul: headers |
| 839 |
+14
-2
| --- win/Makefile.mingw | ||
| +++ win/Makefile.mingw | ||
| @@ -381,10 +381,11 @@ | ||
| 381 | 381 | $(SRCDIR)/event.c \ |
| 382 | 382 | $(SRCDIR)/export.c \ |
| 383 | 383 | $(SRCDIR)/file.c \ |
| 384 | 384 | $(SRCDIR)/finfo.c \ |
| 385 | 385 | $(SRCDIR)/foci.c \ |
| 386 | + $(SRCDIR)/ftsearch.c \ | |
| 386 | 387 | $(SRCDIR)/fusefs.c \ |
| 387 | 388 | $(SRCDIR)/glob.c \ |
| 388 | 389 | $(SRCDIR)/graph.c \ |
| 389 | 390 | $(SRCDIR)/gzip.c \ |
| 390 | 391 | $(SRCDIR)/http.c \ |
| @@ -503,10 +504,11 @@ | ||
| 503 | 504 | $(OBJDIR)/event_.c \ |
| 504 | 505 | $(OBJDIR)/export_.c \ |
| 505 | 506 | $(OBJDIR)/file_.c \ |
| 506 | 507 | $(OBJDIR)/finfo_.c \ |
| 507 | 508 | $(OBJDIR)/foci_.c \ |
| 509 | + $(OBJDIR)/ftsearch_.c \ | |
| 508 | 510 | $(OBJDIR)/fusefs_.c \ |
| 509 | 511 | $(OBJDIR)/glob_.c \ |
| 510 | 512 | $(OBJDIR)/graph_.c \ |
| 511 | 513 | $(OBJDIR)/gzip_.c \ |
| 512 | 514 | $(OBJDIR)/http_.c \ |
| @@ -622,10 +624,11 @@ | ||
| 622 | 624 | $(OBJDIR)/event.o \ |
| 623 | 625 | $(OBJDIR)/export.o \ |
| 624 | 626 | $(OBJDIR)/file.o \ |
| 625 | 627 | $(OBJDIR)/finfo.o \ |
| 626 | 628 | $(OBJDIR)/foci.o \ |
| 629 | + $(OBJDIR)/ftsearch.o \ | |
| 627 | 630 | $(OBJDIR)/fusefs.o \ |
| 628 | 631 | $(OBJDIR)/glob.o \ |
| 629 | 632 | $(OBJDIR)/graph.o \ |
| 630 | 633 | $(OBJDIR)/gzip.o \ |
| 631 | 634 | $(OBJDIR)/http.o \ |
| @@ -934,10 +937,11 @@ | ||
| 934 | 937 | $(OBJDIR)/event_.c:$(OBJDIR)/event.h \ |
| 935 | 938 | $(OBJDIR)/export_.c:$(OBJDIR)/export.h \ |
| 936 | 939 | $(OBJDIR)/file_.c:$(OBJDIR)/file.h \ |
| 937 | 940 | $(OBJDIR)/finfo_.c:$(OBJDIR)/finfo.h \ |
| 938 | 941 | $(OBJDIR)/foci_.c:$(OBJDIR)/foci.h \ |
| 942 | + $(OBJDIR)/ftsearch_.c:$(OBJDIR)/ftsearch.h \ | |
| 939 | 943 | $(OBJDIR)/fusefs_.c:$(OBJDIR)/fusefs.h \ |
| 940 | 944 | $(OBJDIR)/glob_.c:$(OBJDIR)/glob.h \ |
| 941 | 945 | $(OBJDIR)/graph_.c:$(OBJDIR)/graph.h \ |
| 942 | 946 | $(OBJDIR)/gzip_.c:$(OBJDIR)/gzip.h \ |
| 943 | 947 | $(OBJDIR)/http_.c:$(OBJDIR)/http.h \ |
| @@ -1290,10 +1294,18 @@ | ||
| 1290 | 1294 | |
| 1291 | 1295 | $(OBJDIR)/foci.o: $(OBJDIR)/foci_.c $(OBJDIR)/foci.h $(SRCDIR)/config.h |
| 1292 | 1296 | $(XTCC) -o $(OBJDIR)/foci.o -c $(OBJDIR)/foci_.c |
| 1293 | 1297 | |
| 1294 | 1298 | $(OBJDIR)/foci.h: $(OBJDIR)/headers |
| 1299 | + | |
| 1300 | +$(OBJDIR)/ftsearch_.c: $(SRCDIR)/ftsearch.c $(TRANSLATE) | |
| 1301 | + $(TRANSLATE) $(SRCDIR)/ftsearch.c >$@ | |
| 1302 | + | |
| 1303 | +$(OBJDIR)/ftsearch.o: $(OBJDIR)/ftsearch_.c $(OBJDIR)/ftsearch.h $(SRCDIR)/config.h | |
| 1304 | + $(XTCC) -o $(OBJDIR)/ftsearch.o -c $(OBJDIR)/ftsearch_.c | |
| 1305 | + | |
| 1306 | +$(OBJDIR)/ftsearch.h: $(OBJDIR)/headers | |
| 1295 | 1307 | |
| 1296 | 1308 | $(OBJDIR)/fusefs_.c: $(SRCDIR)/fusefs.c $(TRANSLATE) |
| 1297 | 1309 | $(TRANSLATE) $(SRCDIR)/fusefs.c >$@ |
| 1298 | 1310 | |
| 1299 | 1311 | $(OBJDIR)/fusefs.o: $(OBJDIR)/fusefs_.c $(OBJDIR)/fusefs.h $(SRCDIR)/config.h |
| @@ -1963,17 +1975,17 @@ | ||
| 1963 | 1975 | $(OBJDIR)/zip.o: $(OBJDIR)/zip_.c $(OBJDIR)/zip.h $(SRCDIR)/config.h |
| 1964 | 1976 | $(XTCC) -o $(OBJDIR)/zip.o -c $(OBJDIR)/zip_.c |
| 1965 | 1977 | |
| 1966 | 1978 | $(OBJDIR)/zip.h: $(OBJDIR)/headers |
| 1967 | 1979 | |
| 1968 | -SQLITE_OPTIONS = -DNDEBUG=1 \ | |
| 1969 | - -DSQLITE_OMIT_LOAD_EXTENSION=1 \ | |
| 1980 | +SQLITE_OPTIONS = -DSQLITE_OMIT_LOAD_EXTENSION=1 \ | |
| 1970 | 1981 | -DSQLITE_ENABLE_LOCKING_STYLE=0 \ |
| 1971 | 1982 | -DSQLITE_THREADSAFE=0 \ |
| 1972 | 1983 | -DSQLITE_DEFAULT_FILE_FORMAT=4 \ |
| 1973 | 1984 | -DSQLITE_OMIT_DEPRECATED \ |
| 1974 | 1985 | -DSQLITE_ENABLE_EXPLAIN_COMMENTS \ |
| 1986 | + -DSQLITE_ENABLE_FTS4 \ | |
| 1975 | 1987 | -DSQLITE_WIN32_NO_ANSI \ |
| 1976 | 1988 | -D_HAVE__MINGW_H \ |
| 1977 | 1989 | -DSQLITE_USE_MALLOC_H \ |
| 1978 | 1990 | -DSQLITE_USE_MSIZE |
| 1979 | 1991 | |
| 1980 | 1992 |
| --- win/Makefile.mingw | |
| +++ win/Makefile.mingw | |
| @@ -381,10 +381,11 @@ | |
| 381 | $(SRCDIR)/event.c \ |
| 382 | $(SRCDIR)/export.c \ |
| 383 | $(SRCDIR)/file.c \ |
| 384 | $(SRCDIR)/finfo.c \ |
| 385 | $(SRCDIR)/foci.c \ |
| 386 | $(SRCDIR)/fusefs.c \ |
| 387 | $(SRCDIR)/glob.c \ |
| 388 | $(SRCDIR)/graph.c \ |
| 389 | $(SRCDIR)/gzip.c \ |
| 390 | $(SRCDIR)/http.c \ |
| @@ -503,10 +504,11 @@ | |
| 503 | $(OBJDIR)/event_.c \ |
| 504 | $(OBJDIR)/export_.c \ |
| 505 | $(OBJDIR)/file_.c \ |
| 506 | $(OBJDIR)/finfo_.c \ |
| 507 | $(OBJDIR)/foci_.c \ |
| 508 | $(OBJDIR)/fusefs_.c \ |
| 509 | $(OBJDIR)/glob_.c \ |
| 510 | $(OBJDIR)/graph_.c \ |
| 511 | $(OBJDIR)/gzip_.c \ |
| 512 | $(OBJDIR)/http_.c \ |
| @@ -622,10 +624,11 @@ | |
| 622 | $(OBJDIR)/event.o \ |
| 623 | $(OBJDIR)/export.o \ |
| 624 | $(OBJDIR)/file.o \ |
| 625 | $(OBJDIR)/finfo.o \ |
| 626 | $(OBJDIR)/foci.o \ |
| 627 | $(OBJDIR)/fusefs.o \ |
| 628 | $(OBJDIR)/glob.o \ |
| 629 | $(OBJDIR)/graph.o \ |
| 630 | $(OBJDIR)/gzip.o \ |
| 631 | $(OBJDIR)/http.o \ |
| @@ -934,10 +937,11 @@ | |
| 934 | $(OBJDIR)/event_.c:$(OBJDIR)/event.h \ |
| 935 | $(OBJDIR)/export_.c:$(OBJDIR)/export.h \ |
| 936 | $(OBJDIR)/file_.c:$(OBJDIR)/file.h \ |
| 937 | $(OBJDIR)/finfo_.c:$(OBJDIR)/finfo.h \ |
| 938 | $(OBJDIR)/foci_.c:$(OBJDIR)/foci.h \ |
| 939 | $(OBJDIR)/fusefs_.c:$(OBJDIR)/fusefs.h \ |
| 940 | $(OBJDIR)/glob_.c:$(OBJDIR)/glob.h \ |
| 941 | $(OBJDIR)/graph_.c:$(OBJDIR)/graph.h \ |
| 942 | $(OBJDIR)/gzip_.c:$(OBJDIR)/gzip.h \ |
| 943 | $(OBJDIR)/http_.c:$(OBJDIR)/http.h \ |
| @@ -1290,10 +1294,18 @@ | |
| 1290 | |
| 1291 | $(OBJDIR)/foci.o: $(OBJDIR)/foci_.c $(OBJDIR)/foci.h $(SRCDIR)/config.h |
| 1292 | $(XTCC) -o $(OBJDIR)/foci.o -c $(OBJDIR)/foci_.c |
| 1293 | |
| 1294 | $(OBJDIR)/foci.h: $(OBJDIR)/headers |
| 1295 | |
| 1296 | $(OBJDIR)/fusefs_.c: $(SRCDIR)/fusefs.c $(TRANSLATE) |
| 1297 | $(TRANSLATE) $(SRCDIR)/fusefs.c >$@ |
| 1298 | |
| 1299 | $(OBJDIR)/fusefs.o: $(OBJDIR)/fusefs_.c $(OBJDIR)/fusefs.h $(SRCDIR)/config.h |
| @@ -1963,17 +1975,17 @@ | |
| 1963 | $(OBJDIR)/zip.o: $(OBJDIR)/zip_.c $(OBJDIR)/zip.h $(SRCDIR)/config.h |
| 1964 | $(XTCC) -o $(OBJDIR)/zip.o -c $(OBJDIR)/zip_.c |
| 1965 | |
| 1966 | $(OBJDIR)/zip.h: $(OBJDIR)/headers |
| 1967 | |
| 1968 | SQLITE_OPTIONS = -DNDEBUG=1 \ |
| 1969 | -DSQLITE_OMIT_LOAD_EXTENSION=1 \ |
| 1970 | -DSQLITE_ENABLE_LOCKING_STYLE=0 \ |
| 1971 | -DSQLITE_THREADSAFE=0 \ |
| 1972 | -DSQLITE_DEFAULT_FILE_FORMAT=4 \ |
| 1973 | -DSQLITE_OMIT_DEPRECATED \ |
| 1974 | -DSQLITE_ENABLE_EXPLAIN_COMMENTS \ |
| 1975 | -DSQLITE_WIN32_NO_ANSI \ |
| 1976 | -D_HAVE__MINGW_H \ |
| 1977 | -DSQLITE_USE_MALLOC_H \ |
| 1978 | -DSQLITE_USE_MSIZE |
| 1979 | |
| 1980 |
| --- win/Makefile.mingw | |
| +++ win/Makefile.mingw | |
| @@ -381,10 +381,11 @@ | |
| 381 | $(SRCDIR)/event.c \ |
| 382 | $(SRCDIR)/export.c \ |
| 383 | $(SRCDIR)/file.c \ |
| 384 | $(SRCDIR)/finfo.c \ |
| 385 | $(SRCDIR)/foci.c \ |
| 386 | $(SRCDIR)/ftsearch.c \ |
| 387 | $(SRCDIR)/fusefs.c \ |
| 388 | $(SRCDIR)/glob.c \ |
| 389 | $(SRCDIR)/graph.c \ |
| 390 | $(SRCDIR)/gzip.c \ |
| 391 | $(SRCDIR)/http.c \ |
| @@ -503,10 +504,11 @@ | |
| 504 | $(OBJDIR)/event_.c \ |
| 505 | $(OBJDIR)/export_.c \ |
| 506 | $(OBJDIR)/file_.c \ |
| 507 | $(OBJDIR)/finfo_.c \ |
| 508 | $(OBJDIR)/foci_.c \ |
| 509 | $(OBJDIR)/ftsearch_.c \ |
| 510 | $(OBJDIR)/fusefs_.c \ |
| 511 | $(OBJDIR)/glob_.c \ |
| 512 | $(OBJDIR)/graph_.c \ |
| 513 | $(OBJDIR)/gzip_.c \ |
| 514 | $(OBJDIR)/http_.c \ |
| @@ -622,10 +624,11 @@ | |
| 624 | $(OBJDIR)/event.o \ |
| 625 | $(OBJDIR)/export.o \ |
| 626 | $(OBJDIR)/file.o \ |
| 627 | $(OBJDIR)/finfo.o \ |
| 628 | $(OBJDIR)/foci.o \ |
| 629 | $(OBJDIR)/ftsearch.o \ |
| 630 | $(OBJDIR)/fusefs.o \ |
| 631 | $(OBJDIR)/glob.o \ |
| 632 | $(OBJDIR)/graph.o \ |
| 633 | $(OBJDIR)/gzip.o \ |
| 634 | $(OBJDIR)/http.o \ |
| @@ -934,10 +937,11 @@ | |
| 937 | $(OBJDIR)/event_.c:$(OBJDIR)/event.h \ |
| 938 | $(OBJDIR)/export_.c:$(OBJDIR)/export.h \ |
| 939 | $(OBJDIR)/file_.c:$(OBJDIR)/file.h \ |
| 940 | $(OBJDIR)/finfo_.c:$(OBJDIR)/finfo.h \ |
| 941 | $(OBJDIR)/foci_.c:$(OBJDIR)/foci.h \ |
| 942 | $(OBJDIR)/ftsearch_.c:$(OBJDIR)/ftsearch.h \ |
| 943 | $(OBJDIR)/fusefs_.c:$(OBJDIR)/fusefs.h \ |
| 944 | $(OBJDIR)/glob_.c:$(OBJDIR)/glob.h \ |
| 945 | $(OBJDIR)/graph_.c:$(OBJDIR)/graph.h \ |
| 946 | $(OBJDIR)/gzip_.c:$(OBJDIR)/gzip.h \ |
| 947 | $(OBJDIR)/http_.c:$(OBJDIR)/http.h \ |
| @@ -1290,10 +1294,18 @@ | |
| 1294 | |
| 1295 | $(OBJDIR)/foci.o: $(OBJDIR)/foci_.c $(OBJDIR)/foci.h $(SRCDIR)/config.h |
| 1296 | $(XTCC) -o $(OBJDIR)/foci.o -c $(OBJDIR)/foci_.c |
| 1297 | |
| 1298 | $(OBJDIR)/foci.h: $(OBJDIR)/headers |
| 1299 | |
| 1300 | $(OBJDIR)/ftsearch_.c: $(SRCDIR)/ftsearch.c $(TRANSLATE) |
| 1301 | $(TRANSLATE) $(SRCDIR)/ftsearch.c >$@ |
| 1302 | |
| 1303 | $(OBJDIR)/ftsearch.o: $(OBJDIR)/ftsearch_.c $(OBJDIR)/ftsearch.h $(SRCDIR)/config.h |
| 1304 | $(XTCC) -o $(OBJDIR)/ftsearch.o -c $(OBJDIR)/ftsearch_.c |
| 1305 | |
| 1306 | $(OBJDIR)/ftsearch.h: $(OBJDIR)/headers |
| 1307 | |
| 1308 | $(OBJDIR)/fusefs_.c: $(SRCDIR)/fusefs.c $(TRANSLATE) |
| 1309 | $(TRANSLATE) $(SRCDIR)/fusefs.c >$@ |
| 1310 | |
| 1311 | $(OBJDIR)/fusefs.o: $(OBJDIR)/fusefs_.c $(OBJDIR)/fusefs.h $(SRCDIR)/config.h |
| @@ -1963,17 +1975,17 @@ | |
| 1975 | $(OBJDIR)/zip.o: $(OBJDIR)/zip_.c $(OBJDIR)/zip.h $(SRCDIR)/config.h |
| 1976 | $(XTCC) -o $(OBJDIR)/zip.o -c $(OBJDIR)/zip_.c |
| 1977 | |
| 1978 | $(OBJDIR)/zip.h: $(OBJDIR)/headers |
| 1979 | |
| 1980 | SQLITE_OPTIONS = -DSQLITE_OMIT_LOAD_EXTENSION=1 \ |
| 1981 | -DSQLITE_ENABLE_LOCKING_STYLE=0 \ |
| 1982 | -DSQLITE_THREADSAFE=0 \ |
| 1983 | -DSQLITE_DEFAULT_FILE_FORMAT=4 \ |
| 1984 | -DSQLITE_OMIT_DEPRECATED \ |
| 1985 | -DSQLITE_ENABLE_EXPLAIN_COMMENTS \ |
| 1986 | -DSQLITE_ENABLE_FTS4 \ |
| 1987 | -DSQLITE_WIN32_NO_ANSI \ |
| 1988 | -D_HAVE__MINGW_H \ |
| 1989 | -DSQLITE_USE_MALLOC_H \ |
| 1990 | -DSQLITE_USE_MSIZE |
| 1991 | |
| 1992 |
+12
-2
| --- win/Makefile.msc | ||
| +++ win/Makefile.msc | ||
| @@ -173,17 +173,17 @@ | ||
| 173 | 173 | RCC = $(RCC) /DFOSSIL_ENABLE_TCL_PRIVATE_STUBS=1 |
| 174 | 174 | TCC = $(TCC) /DUSE_TCL_STUBS=1 |
| 175 | 175 | RCC = $(RCC) /DUSE_TCL_STUBS=1 |
| 176 | 176 | !endif |
| 177 | 177 | |
| 178 | -SQLITE_OPTIONS = /DNDEBUG=1 \ | |
| 179 | - /DSQLITE_OMIT_LOAD_EXTENSION=1 \ | |
| 178 | +SQLITE_OPTIONS = /DSQLITE_OMIT_LOAD_EXTENSION=1 \ | |
| 180 | 179 | /DSQLITE_ENABLE_LOCKING_STYLE=0 \ |
| 181 | 180 | /DSQLITE_THREADSAFE=0 \ |
| 182 | 181 | /DSQLITE_DEFAULT_FILE_FORMAT=4 \ |
| 183 | 182 | /DSQLITE_OMIT_DEPRECATED \ |
| 184 | 183 | /DSQLITE_ENABLE_EXPLAIN_COMMENTS \ |
| 184 | + /DSQLITE_ENABLE_FTS4 \ | |
| 185 | 185 | /DSQLITE_WIN32_NO_ANSI |
| 186 | 186 | |
| 187 | 187 | SHELL_OPTIONS = /Dmain=sqlite3_shell \ |
| 188 | 188 | /DSQLITE_OMIT_LOAD_EXTENSION=1 \ |
| 189 | 189 | /DUSE_SYSTEM_SQLITE=$(USE_SYSTEM_SQLITE) \ |
| @@ -228,10 +228,11 @@ | ||
| 228 | 228 | event_.c \ |
| 229 | 229 | export_.c \ |
| 230 | 230 | file_.c \ |
| 231 | 231 | finfo_.c \ |
| 232 | 232 | foci_.c \ |
| 233 | + ftsearch_.c \ | |
| 233 | 234 | fusefs_.c \ |
| 234 | 235 | glob_.c \ |
| 235 | 236 | graph_.c \ |
| 236 | 237 | gzip_.c \ |
| 237 | 238 | http_.c \ |
| @@ -349,10 +350,11 @@ | ||
| 349 | 350 | $(OX)\event$O \ |
| 350 | 351 | $(OX)\export$O \ |
| 351 | 352 | $(OX)\file$O \ |
| 352 | 353 | $(OX)\finfo$O \ |
| 353 | 354 | $(OX)\foci$O \ |
| 355 | + $(OX)\ftsearch$O \ | |
| 354 | 356 | $(OX)\fusefs$O \ |
| 355 | 357 | $(OX)\glob$O \ |
| 356 | 358 | $(OX)\graph$O \ |
| 357 | 359 | $(OX)\gzip$O \ |
| 358 | 360 | $(OX)\http$O \ |
| @@ -523,10 +525,11 @@ | ||
| 523 | 525 | echo $(OX)\event.obj >> $@ |
| 524 | 526 | echo $(OX)\export.obj >> $@ |
| 525 | 527 | echo $(OX)\file.obj >> $@ |
| 526 | 528 | echo $(OX)\finfo.obj >> $@ |
| 527 | 529 | echo $(OX)\foci.obj >> $@ |
| 530 | + echo $(OX)\ftsearch.obj >> $@ | |
| 528 | 531 | echo $(OX)\fusefs.obj >> $@ |
| 529 | 532 | echo $(OX)\glob.obj >> $@ |
| 530 | 533 | echo $(OX)\graph.obj >> $@ |
| 531 | 534 | echo $(OX)\gzip.obj >> $@ |
| 532 | 535 | echo $(OX)\http.obj >> $@ |
| @@ -908,10 +911,16 @@ | ||
| 908 | 911 | $(OX)\foci$O : foci_.c foci.h |
| 909 | 912 | $(TCC) /Fo$@ -c foci_.c |
| 910 | 913 | |
| 911 | 914 | foci_.c : $(SRCDIR)\foci.c |
| 912 | 915 | translate$E $** > $@ |
| 916 | + | |
| 917 | +$(OX)\ftsearch$O : ftsearch_.c ftsearch.h | |
| 918 | + $(TCC) /Fo$@ -c ftsearch_.c | |
| 919 | + | |
| 920 | +ftsearch_.c : $(SRCDIR)\ftsearch.c | |
| 921 | + translate$E $** > $@ | |
| 913 | 922 | |
| 914 | 923 | $(OX)\fusefs$O : fusefs_.c fusefs.h |
| 915 | 924 | $(TCC) /Fo$@ -c fusefs_.c |
| 916 | 925 | |
| 917 | 926 | fusefs_.c : $(SRCDIR)\fusefs.c |
| @@ -1450,10 +1459,11 @@ | ||
| 1450 | 1459 | event_.c:event.h \ |
| 1451 | 1460 | export_.c:export.h \ |
| 1452 | 1461 | file_.c:file.h \ |
| 1453 | 1462 | finfo_.c:finfo.h \ |
| 1454 | 1463 | foci_.c:foci.h \ |
| 1464 | + ftsearch_.c:ftsearch.h \ | |
| 1455 | 1465 | fusefs_.c:fusefs.h \ |
| 1456 | 1466 | glob_.c:glob.h \ |
| 1457 | 1467 | graph_.c:graph.h \ |
| 1458 | 1468 | gzip_.c:gzip.h \ |
| 1459 | 1469 | http_.c:http.h \ |
| 1460 | 1470 |
| --- win/Makefile.msc | |
| +++ win/Makefile.msc | |
| @@ -173,17 +173,17 @@ | |
| 173 | RCC = $(RCC) /DFOSSIL_ENABLE_TCL_PRIVATE_STUBS=1 |
| 174 | TCC = $(TCC) /DUSE_TCL_STUBS=1 |
| 175 | RCC = $(RCC) /DUSE_TCL_STUBS=1 |
| 176 | !endif |
| 177 | |
| 178 | SQLITE_OPTIONS = /DNDEBUG=1 \ |
| 179 | /DSQLITE_OMIT_LOAD_EXTENSION=1 \ |
| 180 | /DSQLITE_ENABLE_LOCKING_STYLE=0 \ |
| 181 | /DSQLITE_THREADSAFE=0 \ |
| 182 | /DSQLITE_DEFAULT_FILE_FORMAT=4 \ |
| 183 | /DSQLITE_OMIT_DEPRECATED \ |
| 184 | /DSQLITE_ENABLE_EXPLAIN_COMMENTS \ |
| 185 | /DSQLITE_WIN32_NO_ANSI |
| 186 | |
| 187 | SHELL_OPTIONS = /Dmain=sqlite3_shell \ |
| 188 | /DSQLITE_OMIT_LOAD_EXTENSION=1 \ |
| 189 | /DUSE_SYSTEM_SQLITE=$(USE_SYSTEM_SQLITE) \ |
| @@ -228,10 +228,11 @@ | |
| 228 | event_.c \ |
| 229 | export_.c \ |
| 230 | file_.c \ |
| 231 | finfo_.c \ |
| 232 | foci_.c \ |
| 233 | fusefs_.c \ |
| 234 | glob_.c \ |
| 235 | graph_.c \ |
| 236 | gzip_.c \ |
| 237 | http_.c \ |
| @@ -349,10 +350,11 @@ | |
| 349 | $(OX)\event$O \ |
| 350 | $(OX)\export$O \ |
| 351 | $(OX)\file$O \ |
| 352 | $(OX)\finfo$O \ |
| 353 | $(OX)\foci$O \ |
| 354 | $(OX)\fusefs$O \ |
| 355 | $(OX)\glob$O \ |
| 356 | $(OX)\graph$O \ |
| 357 | $(OX)\gzip$O \ |
| 358 | $(OX)\http$O \ |
| @@ -523,10 +525,11 @@ | |
| 523 | echo $(OX)\event.obj >> $@ |
| 524 | echo $(OX)\export.obj >> $@ |
| 525 | echo $(OX)\file.obj >> $@ |
| 526 | echo $(OX)\finfo.obj >> $@ |
| 527 | echo $(OX)\foci.obj >> $@ |
| 528 | echo $(OX)\fusefs.obj >> $@ |
| 529 | echo $(OX)\glob.obj >> $@ |
| 530 | echo $(OX)\graph.obj >> $@ |
| 531 | echo $(OX)\gzip.obj >> $@ |
| 532 | echo $(OX)\http.obj >> $@ |
| @@ -908,10 +911,16 @@ | |
| 908 | $(OX)\foci$O : foci_.c foci.h |
| 909 | $(TCC) /Fo$@ -c foci_.c |
| 910 | |
| 911 | foci_.c : $(SRCDIR)\foci.c |
| 912 | translate$E $** > $@ |
| 913 | |
| 914 | $(OX)\fusefs$O : fusefs_.c fusefs.h |
| 915 | $(TCC) /Fo$@ -c fusefs_.c |
| 916 | |
| 917 | fusefs_.c : $(SRCDIR)\fusefs.c |
| @@ -1450,10 +1459,11 @@ | |
| 1450 | event_.c:event.h \ |
| 1451 | export_.c:export.h \ |
| 1452 | file_.c:file.h \ |
| 1453 | finfo_.c:finfo.h \ |
| 1454 | foci_.c:foci.h \ |
| 1455 | fusefs_.c:fusefs.h \ |
| 1456 | glob_.c:glob.h \ |
| 1457 | graph_.c:graph.h \ |
| 1458 | gzip_.c:gzip.h \ |
| 1459 | http_.c:http.h \ |
| 1460 |
| --- win/Makefile.msc | |
| +++ win/Makefile.msc | |
| @@ -173,17 +173,17 @@ | |
| 173 | RCC = $(RCC) /DFOSSIL_ENABLE_TCL_PRIVATE_STUBS=1 |
| 174 | TCC = $(TCC) /DUSE_TCL_STUBS=1 |
| 175 | RCC = $(RCC) /DUSE_TCL_STUBS=1 |
| 176 | !endif |
| 177 | |
| 178 | SQLITE_OPTIONS = /DSQLITE_OMIT_LOAD_EXTENSION=1 \ |
| 179 | /DSQLITE_ENABLE_LOCKING_STYLE=0 \ |
| 180 | /DSQLITE_THREADSAFE=0 \ |
| 181 | /DSQLITE_DEFAULT_FILE_FORMAT=4 \ |
| 182 | /DSQLITE_OMIT_DEPRECATED \ |
| 183 | /DSQLITE_ENABLE_EXPLAIN_COMMENTS \ |
| 184 | /DSQLITE_ENABLE_FTS4 \ |
| 185 | /DSQLITE_WIN32_NO_ANSI |
| 186 | |
| 187 | SHELL_OPTIONS = /Dmain=sqlite3_shell \ |
| 188 | /DSQLITE_OMIT_LOAD_EXTENSION=1 \ |
| 189 | /DUSE_SYSTEM_SQLITE=$(USE_SYSTEM_SQLITE) \ |
| @@ -228,10 +228,11 @@ | |
| 228 | event_.c \ |
| 229 | export_.c \ |
| 230 | file_.c \ |
| 231 | finfo_.c \ |
| 232 | foci_.c \ |
| 233 | ftsearch_.c \ |
| 234 | fusefs_.c \ |
| 235 | glob_.c \ |
| 236 | graph_.c \ |
| 237 | gzip_.c \ |
| 238 | http_.c \ |
| @@ -349,10 +350,11 @@ | |
| 350 | $(OX)\event$O \ |
| 351 | $(OX)\export$O \ |
| 352 | $(OX)\file$O \ |
| 353 | $(OX)\finfo$O \ |
| 354 | $(OX)\foci$O \ |
| 355 | $(OX)\ftsearch$O \ |
| 356 | $(OX)\fusefs$O \ |
| 357 | $(OX)\glob$O \ |
| 358 | $(OX)\graph$O \ |
| 359 | $(OX)\gzip$O \ |
| 360 | $(OX)\http$O \ |
| @@ -523,10 +525,11 @@ | |
| 525 | echo $(OX)\event.obj >> $@ |
| 526 | echo $(OX)\export.obj >> $@ |
| 527 | echo $(OX)\file.obj >> $@ |
| 528 | echo $(OX)\finfo.obj >> $@ |
| 529 | echo $(OX)\foci.obj >> $@ |
| 530 | echo $(OX)\ftsearch.obj >> $@ |
| 531 | echo $(OX)\fusefs.obj >> $@ |
| 532 | echo $(OX)\glob.obj >> $@ |
| 533 | echo $(OX)\graph.obj >> $@ |
| 534 | echo $(OX)\gzip.obj >> $@ |
| 535 | echo $(OX)\http.obj >> $@ |
| @@ -908,10 +911,16 @@ | |
| 911 | $(OX)\foci$O : foci_.c foci.h |
| 912 | $(TCC) /Fo$@ -c foci_.c |
| 913 | |
| 914 | foci_.c : $(SRCDIR)\foci.c |
| 915 | translate$E $** > $@ |
| 916 | |
| 917 | $(OX)\ftsearch$O : ftsearch_.c ftsearch.h |
| 918 | $(TCC) /Fo$@ -c ftsearch_.c |
| 919 | |
| 920 | ftsearch_.c : $(SRCDIR)\ftsearch.c |
| 921 | translate$E $** > $@ |
| 922 | |
| 923 | $(OX)\fusefs$O : fusefs_.c fusefs.h |
| 924 | $(TCC) /Fo$@ -c fusefs_.c |
| 925 | |
| 926 | fusefs_.c : $(SRCDIR)\fusefs.c |
| @@ -1450,10 +1459,11 @@ | |
| 1459 | event_.c:event.h \ |
| 1460 | export_.c:export.h \ |
| 1461 | file_.c:file.h \ |
| 1462 | finfo_.c:finfo.h \ |
| 1463 | foci_.c:foci.h \ |
| 1464 | ftsearch_.c:ftsearch.h \ |
| 1465 | fusefs_.c:fusefs.h \ |
| 1466 | glob_.c:glob.h \ |
| 1467 | graph_.c:graph.h \ |
| 1468 | gzip_.c:gzip.h \ |
| 1469 | http_.c:http.h \ |
| 1470 |