Login
Check-in [574b521a2b]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Minor build reorgs as part of integrating (fossil diff -tk)-ish feature.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 574b521a2b8a70494a678f2b8b83d3af556f367f
User & Date: stephan 2022-01-03 16:39:27.838
Context
2022-01-03
17:21
Ported in fossil's diff -tk script bits and implemented (f-vdiff --format tk) but the output currently goes to stdout instead of launching tclsh. The TCL dibu can optionally include the TK bits or not, depending on its flags. check-in: 82bf08414f user: stephan tags: trunk
16:39
Minor build reorgs as part of integrating (fossil diff -tk)-ish feature. check-in: 574b521a2b user: stephan tags: trunk
2022-01-02
16:10
Minor doc updates and code reformatting. check-in: 707fecabb9 user: stephan tags: trunk
Changes
Unified Diff Ignore Whitespace Patch
Changes to GNUmakefile.in.
9
10
11
12
13
14
15
16
17
18
19
20
21


22
23
24
25
26
27
28

#ShakeNMake.CISH_SOURCES := $(wildcard *.c) $(wildcard $(SRC.DIR)/*.c)

########################################################################
# Some common vars used by shakenmake.make and/or the sub-makes
# (make-*.make).
DIR.top := @srcdir@
DIR.src := @srcdir@/src
DIR.client := @srcdir@/client
DIR.tools := @srcdir@/tools
DIR.include := @srcdir@/include
DIR.bindings := @srcdir@/bindings
DIR.f-apps := @srcdir@/f-apps


LIB_CURSES := @LIB_CURSES@
CFLAGS_CURSES := @CFLAGS_CURSES@
ShakeNMake.CISH_SOURCES := $(patsubst %~,%,$(wildcard \
  $(DIR.src)/*.[ch] \
  $(DIR.f-apps)/*.[ch] \
  $(DIR.client)/fnc/*.[ch] \
  $(DIR.bindings)/cpp/*.[ch]pp \







|
|
|
|
|
|
>
>







9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30

#ShakeNMake.CISH_SOURCES := $(wildcard *.c) $(wildcard $(SRC.DIR)/*.c)

########################################################################
# Some common vars used by shakenmake.make and/or the sub-makes
# (make-*.make).
DIR.top := @srcdir@
DIR.src := $(DIR.top)/src
DIR.client := $(DIR.top)/client
DIR.tools := $(DIR.top)/tools
DIR.include := $(DIR.top)/include
DIR.bindings := $(DIR.top)/bindings
DIR.f-apps := $(DIR.top)/f-apps
DIR.sql := $(DIR.top)/sql

LIB_CURSES := @LIB_CURSES@
CFLAGS_CURSES := @CFLAGS_CURSES@
ShakeNMake.CISH_SOURCES := $(patsubst %~,%,$(wildcard \
  $(DIR.src)/*.[ch] \
  $(DIR.f-apps)/*.[ch] \
  $(DIR.client)/fnc/*.[ch] \
  $(DIR.bindings)/cpp/*.[ch]pp \
38
39
40
41
42
43
44





























45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
# dependencies makefile, as that file, in turn, depends on the files
# it scans for dependencies.
ifneq (,$(ShakeNMake.CISH_DEPS_FILE))
  PACKAGE.C_DEPS.MAKEFILES := $(subst $(ShakeNMake.CISH_DEPS_FILE),,$(MAKEFILE_LIST))
else
  PACKAGE.C_DEPS.MAKEFILES :=
endif





























########################################################################
# Subdir/module builds...
#
# Maintenance reminders: all relevant symbols in the sub-makefiles
# (make-XXX.make) MUST be unique across the whole global
# namespace. Similarly, all relevant paths must point to that
# subdir. That is particularly of interest with the BIN/DLL/LIB and
# CLEAN.xxx rules, which may require another level of $(var)
# indirection for that purpose. It's also important when using
# CPPFLAGS and such, to keep subdir-specific flags from leaking across
# makefiles. Similarly, when using ShakeNMake.install.XXX, the vars
# must appended to instead of overwritten.
########################################################################
# INCLUDE_SINGLE_SUBMAKE includes file make-$(1).make if it exists,
# else this is a no-op. It protects against multiple inclusion.
INCLUDED_SUBMAKES :=
define INCLUDE_SINGLE_SUBMAKE
  SINGLE.$(1) := $$(wildcard make-$(1).make)
  ifneq (,$$(SINGLE.$(1)))







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>










|
|







40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
# dependencies makefile, as that file, in turn, depends on the files
# it scans for dependencies.
ifneq (,$(ShakeNMake.CISH_DEPS_FILE))
  PACKAGE.C_DEPS.MAKEFILES := $(subst $(ShakeNMake.CISH_DEPS_FILE),,$(MAKEFILE_LIST))
else
  PACKAGE.C_DEPS.MAKEFILES :=
endif

########################################################################
# Transform schema SQL files into source form. We don't use fossil(1)'s
# approach because it relies on unspecified length limits on C string
# literals. Yeah, it works, but i'm funny about the C Standard.
#include $(TOP_SRCDIR_REL)/tools.make
BIN.TEXT2C := $(DIR.tools)/text2c
$(BIN.TEXT2C): $(DIR.tools)/text2c.c
	cc $< -o $@
DISTCLEAN.root += $(BIN.TEXT2C)

########################################################################
# Transforms file $(2) to $(1).c in the form of a byte array and
# accessor function.
define FILE2C
$(2):
$(1).c: $(2) $$(BIN.TEXT2C) $(PACKAGE.C_DEPS.MAKEFILES)
ifneq (1,$(MAKING_CLEAN))
	@echo "Creating $$@ from $(2)..."; \
	{ \
		echo '/** @page page_$$(notdir $1) $$(notdir $(2))'; echo; \
    echo 'Binary form of file $(2).'; echo; \
		echo '*/'; \
		$$(BIN.TEXT2C) fsl_$$(notdir $1) < $(2); \
		echo '/* end of $(2) */'; \
	} > $$@;
endif
endef

########################################################################
# Subdir/module builds...
#
# Maintenance reminders: all relevant symbols in the sub-makefiles
# (make-XXX.make) MUST be unique across the whole global
# namespace. Similarly, all relevant paths must point to that
# subdir. That is particularly of interest with the BIN/DLL/LIB and
# CLEAN.xxx rules, which may require another level of $(var)
# indirection for that purpose. It's also important when using
# CPPFLAGS and such, to keep subdir-specific flags from leaking across
# makefiles. Similarly, when using ShakeNMake.install.XXX, the install
# vars must appended to instead of overwritten.
########################################################################
# INCLUDE_SINGLE_SUBMAKE includes file make-$(1).make if it exists,
# else this is a no-op. It protects against multiple inclusion.
INCLUDED_SUBMAKES :=
define INCLUDE_SINGLE_SUBMAKE
  SINGLE.$(1) := $$(wildcard make-$(1).make)
  ifneq (,$$(SINGLE.$(1)))
Changes to make-libf.make.in.
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110

111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
  FSL.SRC += $(SQLITE3.C)
endif

FSL.OBJ := $(patsubst %.c,%.o,$(FSL.SRC))
$(FSL.OBJ): $(LIBF.MAKEFILE)
CLEAN.libf += $(FSL.OBJ)

########################################################################
# Transform schema SQL files into source form. We don't use fossil(1)'s
# approach because it relies on unspecified length limits on C string
# literals. Yeah, it works, but i'm funny about the C Standard.
#include $(TOP_SRCDIR_REL)/tools.make
BIN.TEXT2C := $(DIR.tools)/text2c
$(BIN.TEXT2C): $(DIR.tools)/text2c.c
	cc $< -o $@
DISTCLEAN.libf += $(BIN.TEXT2C)


define SQL2C
$(2):
$(1).c: $(2) $$(BIN.TEXT2C)
ifneq (1,$(MAKING_CLEAN))
	@echo "Creating $$@ from $(2)..."; \
	{ \
		echo '/* Binary form of file $(2) */'; \
		echo '/** @page page_$$(notdir $1) Schema: $$(notdir $(2))'; \
		echo '@code'; \
		cat "$(2)"; \
		echo ' @endcode'; \
		echo ' @see $$(subst _cstr,,$$(notdir $1))()'; \
		echo '*/'; \
		$$(BIN.TEXT2C) fsl_$$(notdir $1) < $(2); \
		echo '/* end of $(2) */'; \
	} > $$@;
endif
FSL.SRC += $(1).c
FSL.SRC.BASE += $(1).c
FSL.OBJ += $(1).o
DISTCLEAN.libf += $(1).c
sql: $(1).c
endef

$(FSL.OBJ): CPPFLAGS+=$(LIBF.CPPFLAGS)

SQL.DIR := @srcdir@/sql
$(eval $(call SQL2C,$(DIR.src)/schema_config_cstr,$(SQL.DIR)/config.sql))
$(eval $(call SQL2C,$(DIR.src)/schema_repo1_cstr,$(SQL.DIR)/repo-static.sql))
$(eval $(call SQL2C,$(DIR.src)/schema_repo2_cstr,$(SQL.DIR)/repo-transient.sql))
$(eval $(call SQL2C,$(DIR.src)/schema_ckout_cstr,$(SQL.DIR)/checkout.sql))
$(eval $(call SQL2C,$(DIR.src)/schema_ticket_cstr,$(SQL.DIR)/ticket.sql))
$(eval $(call SQL2C,$(DIR.src)/schema_ticket_reports_cstr,$(SQL.DIR)/ticket-reports.sql))
$(eval $(call SQL2C,$(DIR.src)/schema_forum_cstr,$(SQL.DIR)/forum.sql))
# end SQL transformation bits
########################################################################

# These are the flags used by fossil's embedded sqlite3:
$(SQLITE3.OBJ): CPPFLAGS+=-DNDEBUG=1 \
                 -DSQLITE_DQS=0 \
                 -DSQLITE_THREADSAFE=0 \







<
<
<
<
<
<
<
<
<
>


|
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<







<
<
<
|
|
|
|
|
|
|







95
96
97
98
99
100
101









102
103
104
105















106
107
108
109
110
111
112



113
114
115
116
117
118
119
120
121
122
123
124
125
126
  FSL.SRC += $(SQLITE3.C)
endif

FSL.OBJ := $(patsubst %.c,%.o,$(FSL.SRC))
$(FSL.OBJ): $(LIBF.MAKEFILE)
CLEAN.libf += $(FSL.OBJ)










$(FSL.OBJ): CPPFLAGS+=$(LIBF.CPPFLAGS)

define SQL2C
$(call FILE2C,$(1),$(2))















FSL.SRC += $(1).c
FSL.SRC.BASE += $(1).c
FSL.OBJ += $(1).o
DISTCLEAN.libf += $(1).c
sql: $(1).c
endef




$(eval $(call SQL2C,$(DIR.src)/schema_config_cstr,$(DIR.sql)/config.sql))
$(eval $(call SQL2C,$(DIR.src)/schema_repo1_cstr,$(DIR.sql)/repo-static.sql))
$(eval $(call SQL2C,$(DIR.src)/schema_repo2_cstr,$(DIR.sql)/repo-transient.sql))
$(eval $(call SQL2C,$(DIR.src)/schema_ckout_cstr,$(DIR.sql)/checkout.sql))
$(eval $(call SQL2C,$(DIR.src)/schema_ticket_cstr,$(DIR.sql)/ticket.sql))
$(eval $(call SQL2C,$(DIR.src)/schema_ticket_reports_cstr,$(DIR.sql)/ticket-reports.sql))
$(eval $(call SQL2C,$(DIR.src)/schema_forum_cstr,$(DIR.sql)/forum.sql))
# end SQL transformation bits
########################################################################

# These are the flags used by fossil's embedded sqlite3:
$(SQLITE3.OBJ): CPPFLAGS+=-DNDEBUG=1 \
                 -DSQLITE_DQS=0 \
                 -DSQLITE_THREADSAFE=0 \
Changes to src/schema_ckout_cstr.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
/* Binary form of file ./sql/checkout.sql */
/** @page page_schema_ckout_cstr Schema: checkout.sql
@code
-- The VVAR table holds miscellanous information about the local database
-- in the form of name-value pairs.  This is similar to the VAR table
-- table in the repository except that this table holds information that
-- is specific to the local checkout.
--
-- Important Variables:
--
--     repository        Full pathname of the repository database
--     user-id           Userid to use
--
CREATE TABLE ckout.vvar(
  name TEXT PRIMARY KEY NOT NULL,  -- Primary name of the entry
  value CLOB,                      -- Content of the named parameter
  CHECK( typeof(name)='text' AND length(name)>=1 )
);

-- Each entry in the vfile table represents a single file in the
-- current checkout.
--
-- The file.rid field is 0 for files or folders that have been
-- added but not yet committed.
--
-- Vfile.chnged is 0 for unmodified files, 1 for files that have
-- been edited or which have been subjected to a 3-way merge.
-- Vfile.chnged is 2 if the file has been replaced from a different
-- version by the merge and 3 if the file has been added by a merge.
-- Vfile.chnged is 4|5 is the same as 2|3, but the operation has been
-- done by an --integrate merge.  The difference between vfile.chnged==2|4
-- and a regular add is that with vfile.chnged==2|4 we know that the
-- current version of the file is already in the repository.
--
CREATE TABLE ckout.vfile(
  id INTEGER PRIMARY KEY,           -- ID of the checked out file
  vid INTEGER REFERENCES blob,      -- The baseline this file is part of.
  chnged INT DEFAULT 0,             -- 0:unchnged 1:edited 2:m-chng 3:m-add 4:i-chng 5:i-add
  deleted BOOLEAN DEFAULT 0,        -- True if deleted
  isexe BOOLEAN,                    -- True if file should be executable
  islink BOOLEAN,                   -- True if file should be symlink
  rid INTEGER,                      -- Originally from this repository record
  mrid INTEGER,                     -- Based on this record due to a merge
  mtime INTEGER,                    -- Mtime of file on disk. sec since 1970
  pathname TEXT,                    -- Full pathname relative to root
  origname TEXT,                    -- Original pathname. NULL if unchanged
  mhash TEXT,                       -- Hash of mrid iff mrid!=rid. Added 2019-01-19.
  UNIQUE(pathname,vid)
);

-- This table holds a record of uncommitted merges in the local
-- file tree.  If a VFILE entry with id has merged with another
-- record, there is an entry in this table with (id,merge) where
-- merge is the RECORD table entry that the file merged against.
-- An id of 0 or <-3 here means the version record itself.  When
-- id==(-1) that is a cherrypick merge, id==(-2) that is a
-- backout merge and id==(-4) is a integrate merge.

CREATE TABLE ckout.vmerge(
  id INTEGER REFERENCES vfile,      -- VFILE entry that has been merged
  merge INTEGER,                    -- Merged with this record
  mhash TEXT                        -- SHA1/SHA3 hash for merge object
);
CREATE UNIQUE INDEX ckout.vmergex1 ON vmerge(id,mhash);

-- The following trigger will prevent older versions of Fossil that
-- do not know about the new vmerge.mhash column from updating the
-- vmerge table.  This must be done with a trigger, since legacy Fossil
-- uses INSERT OR IGNORE to update vmerge, and the OR IGNORE will cause
-- a NOT NULL constraint to be silently ignored.
CREATE TRIGGER ckout.vmerge_ck1 AFTER INSERT ON vmerge
WHEN new.mhash IS NULL BEGIN
  SELECT raise(FAIL,
  'trying to update a newer checkout with an older version of Fossil');
END;

-- Identifier for this file type.
-- The integer is the same as 'FSLC'.
PRAGMA ckout.application_id=252006674;
 @endcode
 @see schema_ckout()
*/
/* auto-generated code - edit at your own risk! (Good luck with that!) */
static char const fsl_schema_ckout_cstr_a[] = {
45, 45, 32, 84, 104, 101, 32, 86, 86, 65, 82, 32, 116, 97, 98, 108, 101, 32, 104, 111, 
108, 100, 115, 32, 109, 105, 115, 99, 101, 108, 108, 97, 110, 111, 117, 115, 32, 105, 110, 102, 
111, 114, 109, 97, 116, 105, 111, 110, 32, 97, 98, 111, 117, 116, 32, 116, 104, 101, 32, 108, 
111, 99, 97, 108, 32, 100, 97, 116, 97, 98, 97, 115, 101, 10, 45, 45, 32, 105, 110, 32, 
<
|
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<

<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
|
<
<
<
<
<
<
<

<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<








1
















2






























3







4























5
6
7
8
9
10
11

/** @page page_schema_ckout_cstr checkout.sql















































Binary form of file ./sql/checkout.sql.































*/
/* auto-generated code - edit at your own risk! (Good luck with that!) */
static char const fsl_schema_ckout_cstr_a[] = {
45, 45, 32, 84, 104, 101, 32, 86, 86, 65, 82, 32, 116, 97, 98, 108, 101, 32, 104, 111, 
108, 100, 115, 32, 109, 105, 115, 99, 101, 108, 108, 97, 110, 111, 117, 115, 32, 105, 110, 102, 
111, 114, 109, 97, 116, 105, 111, 110, 32, 97, 98, 111, 117, 116, 32, 116, 104, 101, 32, 108, 
111, 99, 97, 108, 32, 100, 97, 116, 97, 98, 97, 115, 101, 10, 45, 45, 32, 105, 110, 32, 
Changes to src/schema_config_cstr.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
/* Binary form of file ./sql/config.sql */
/** @page page_schema_config_cstr Schema: config.sql
@code
-- This file contains the schema for the database that is kept in the
-- ~/.fossil file and that stores information about the users setup.
--
CREATE TABLE cfg.global_config(
  name TEXT PRIMARY KEY,
  value TEXT
);

-- Identifier for this file type.
-- The integer is the same as 'FSLG'.
PRAGMA cfg.application_id=252006675;
 @endcode
 @see schema_config()
*/
/* auto-generated code - edit at your own risk! (Good luck with that!) */
static char const fsl_schema_config_cstr_a[] = {
45, 45, 32, 84, 104, 105, 115, 32, 102, 105, 108, 101, 32, 99, 111, 110, 116, 97, 105, 110, 
115, 32, 116, 104, 101, 32, 115, 99, 104, 101, 109, 97, 32, 102, 111, 114, 32, 116, 104, 101, 
32, 100, 97, 116, 97, 98, 97, 115, 101, 32, 116, 104, 97, 116, 32, 105, 115, 32, 107, 101, 
112, 116, 32, 105, 110, 32, 116, 104, 101, 10, 45, 45, 32, 126, 47, 46, 102, 111, 115, 115, 
<
|
|
<
<
<
|
<
<
<

<
<
<
<
<








1
2



3



4





5
6
7
8
9
10
11

/** @page page_schema_config_cstr config.sql




Binary form of file ./sql/config.sql.









*/
/* auto-generated code - edit at your own risk! (Good luck with that!) */
static char const fsl_schema_config_cstr_a[] = {
45, 45, 32, 84, 104, 105, 115, 32, 102, 105, 108, 101, 32, 99, 111, 110, 116, 97, 105, 110, 
115, 32, 116, 104, 101, 32, 115, 99, 104, 101, 109, 97, 32, 102, 111, 114, 32, 116, 104, 101, 
32, 100, 97, 116, 97, 98, 97, 115, 101, 32, 116, 104, 97, 116, 32, 105, 115, 32, 107, 101, 
112, 116, 32, 105, 110, 32, 116, 104, 101, 10, 45, 45, 32, 126, 47, 46, 102, 111, 115, 115, 
Changes to src/schema_forum_cstr.c.
1
2
3

4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/* Binary form of file ./sql/forum.sql */
/** @page page_schema_forum_cstr Schema: forum.sql
@code

CREATE TABLE repo.forumpost(
  fpid INTEGER PRIMARY KEY,  -- BLOB.rid for the artifact
  froot INT,                 -- fpid of the thread root
  fprev INT,                 -- Previous version of this same post
  firt INT,                  -- This post is in-reply-to
  fmtime REAL                -- When posted.  Julian day
);
CREATE INDEX repo.forumthread ON forumpost(froot,fmtime);
 @endcode
 @see schema_forum()
*/
/* auto-generated code - edit at your own risk! (Good luck with that!) */
static char const fsl_schema_forum_cstr_a[] = {
67, 82, 69, 65, 84, 69, 32, 84, 65, 66, 76, 69, 32, 114, 101, 112, 111, 46, 102, 111, 
114, 117, 109, 112, 111, 115, 116, 40, 10, 32, 32, 102, 112, 105, 100, 32, 73, 78, 84, 69, 
71, 69, 82, 32, 80, 82, 73, 77, 65, 82, 89, 32, 75, 69, 89, 44, 32, 32, 45, 45, 
32, 66, 76, 79, 66, 46, 114, 105, 100, 32, 102, 111, 114, 32, 116, 104, 101, 32, 97, 114, 
<
|
|
>
|
<
<
<
<
<
<
<
<
<








1
2
3
4









5
6
7
8
9
10
11

/** @page page_schema_forum_cstr forum.sql

Binary form of file ./sql/forum.sql.










*/
/* auto-generated code - edit at your own risk! (Good luck with that!) */
static char const fsl_schema_forum_cstr_a[] = {
67, 82, 69, 65, 84, 69, 32, 84, 65, 66, 76, 69, 32, 114, 101, 112, 111, 46, 102, 111, 
114, 117, 109, 112, 111, 115, 116, 40, 10, 32, 32, 102, 112, 105, 100, 32, 73, 78, 84, 69, 
71, 69, 82, 32, 80, 82, 73, 77, 65, 82, 89, 32, 75, 69, 89, 44, 32, 32, 45, 45, 
32, 66, 76, 79, 66, 46, 114, 105, 100, 32, 102, 111, 114, 32, 116, 104, 101, 32, 97, 114, 
Changes to src/schema_repo1_cstr.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
/* Binary form of file ./sql/repo-static.sql */
/** @page page_schema_repo1_cstr Schema: repo-static.sql
@code
-- This file contains parts of the schema that are fixed and
-- unchanging across Fossil versions.


-- The BLOB and DELTA tables contain all records held in the repository.
--
-- The BLOB.CONTENT column is always compressed using zlib.  This
-- column might hold the full text of the record or it might hold
-- a delta that is able to reconstruct the record from some other
-- record.  If BLOB.CONTENT holds a delta, then a DELTA table entry
-- will exist for the record and that entry will point to another
-- entry that holds the source of the delta.  Deltas can be chained.
--
-- The blob and delta tables collectively hold the "global state" of
-- a Fossil repository.  
--
CREATE TABLE repo.blob(
  rid INTEGER PRIMARY KEY,        -- Record ID
  rcvid INTEGER,                  -- Origin of this record
  size INTEGER,                   -- Size of content. -1 for a phantom.
  uuid TEXT UNIQUE NOT NULL,      -- SHA1 hash of the content
  content BLOB,                   -- Compressed content of this record
  CHECK( length(uuid)>=40 AND rid>0 )
);
CREATE TABLE repo.delta(
  rid INTEGER PRIMARY KEY,                 -- Record ID
  srcid INTEGER NOT NULL REFERENCES blob   -- Record holding source document
);
CREATE INDEX repo.delta_i1 ON delta(srcid);

-------------------------------------------------------------------------
-- The BLOB and DELTA tables above hold the "global state" of a Fossil
-- project; the stuff that is normally exchanged during "sync".  The
-- "local state" of a repository is contained in the remaining tables of
-- the zRepositorySchema1 string.  
-------------------------------------------------------------------------

-- Whenever new blobs are received into the repository, an entry
-- in this table records the source of the blob.
--
CREATE TABLE repo.rcvfrom(
  rcvid INTEGER PRIMARY KEY,      -- Received-From ID
  uid INTEGER REFERENCES user,    -- User login
  mtime DATETIME,                 -- Time of receipt.  Julian day.
  nonce TEXT UNIQUE,              -- Nonce used for login
  ipaddr TEXT                     -- Remote IP address.  NULL for direct.
);
INSERT INTO repo.rcvfrom(rcvid,uid,mtime,nonce,ipaddr)
VALUES (1, 1, julianday('now'), NULL, NULL);

-- Information about users
--
-- The user.pw field can be either cleartext of the password, or
-- a SHA1 hash of the password.  If the user.pw field is exactly 40
-- characters long we assume it is a SHA1 hash.  Otherwise, it is
-- cleartext.  The sha1_shared_secret() routine computes the password
-- hash based on the project-code, the user login, and the cleartext
-- password.
--
CREATE TABLE repo.user(
  uid INTEGER PRIMARY KEY,        -- User ID
  login TEXT UNIQUE,              -- login name of the user
  pw TEXT,                        -- password
  cap TEXT,                       -- Capabilities of this user
  cookie TEXT,                    -- WWW login cookie
  ipaddr TEXT,                    -- IP address for which cookie is valid
  cexpire DATETIME,               -- Time when cookie expires
  info TEXT,                      -- contact information
  mtime DATE,                     -- last change.  seconds since 1970
  photo BLOB                      -- JPEG image of this user
);

-- The VAR table holds miscellanous information about the repository.
-- in the form of name-value pairs.
--
CREATE TABLE repo.config(
  name TEXT PRIMARY KEY NOT NULL,  -- Primary name of the entry
  value CLOB,                      -- Content of the named parameter
  mtime DATE,                      -- last modified.  seconds since 1970
  CHECK( typeof(name)='text' AND length(name)>=1 )
);

-- Artifacts that should not be processed are identified in the
-- "shun" table.  Artifacts that are control-file forgeries or
-- spam or artifacts whose contents violate administrative policy
-- can be shunned in order to prevent them from contaminating
-- the repository.
--
-- Shunned artifacts do not exist in the blob table.  Hence they
-- have not artifact ID (rid) and we thus must store their full
-- UUID.
--
CREATE TABLE repo.shun(
  uuid UNIQUE,          -- UUID of artifact to be shunned. Canonical form
  mtime DATE,           -- When added.  seconds since 1970
  scom TEXT             -- Optional text explaining why the shun occurred
);

-- Artifacts that should not be pushed are stored in the "private"
-- table.  Private artifacts are omitted from the "unclustered" and
-- "unsent" tables.
--
CREATE TABLE repo.private(rid INTEGER PRIMARY KEY);

-- An entry in this table describes a database query that generates a
-- table of tickets.
--
CREATE TABLE repo.reportfmt(
   rn INTEGER PRIMARY KEY,  -- Report number
   owner TEXT,              -- Owner of this report format (not used)
   title TEXT UNIQUE,       -- Title of this report
   mtime DATE,              -- Last modified.  seconds since 1970
   cols TEXT,               -- A color-key specification
   sqlcode TEXT             -- An SQL SELECT statement for this report
);

-- Some ticket content (such as the originators email address or contact
-- information) needs to be obscured to protect privacy.  This is achieved
-- by storing an SHA1 hash of the content.  For display, the hash is
-- mapped back into the original text using this table.  
--
-- This table contains sensitive information and should not be shared
-- with unauthorized users.
--
CREATE TABLE repo.concealed(
  hash TEXT PRIMARY KEY,    -- The SHA1 hash of content
  mtime DATE,               -- Time created.  Seconds since 1970
  content TEXT              -- Content intended to be concealed
);

-- The application ID helps the unix "file" command to identify the
-- database as a fossil repository.
PRAGMA repo.application_id=252006673;
 @endcode
 @see schema_repo1()
*/
/* auto-generated code - edit at your own risk! (Good luck with that!) */
static char const fsl_schema_repo1_cstr_a[] = {
45, 45, 32, 84, 104, 105, 115, 32, 102, 105, 108, 101, 32, 99, 111, 110, 116, 97, 105, 110, 
115, 32, 112, 97, 114, 116, 115, 32, 111, 102, 32, 116, 104, 101, 32, 115, 99, 104, 101, 109, 
97, 32, 116, 104, 97, 116, 32, 97, 114, 101, 32, 102, 105, 120, 101, 100, 32, 97, 110, 100, 
10, 45, 45, 32, 117, 110, 99, 104, 97, 110, 103, 105, 110, 103, 32, 97, 99, 114, 111, 115, 
<
|
<
<
<

|
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<

<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<








1



2
3

























4









































































































5
6
7
8
9
10
11

/** @page page_schema_repo1_cstr repo-static.sql




Binary form of file ./sql/repo-static.sql.



































































































































*/
/* auto-generated code - edit at your own risk! (Good luck with that!) */
static char const fsl_schema_repo1_cstr_a[] = {
45, 45, 32, 84, 104, 105, 115, 32, 102, 105, 108, 101, 32, 99, 111, 110, 116, 97, 105, 110, 
115, 32, 112, 97, 114, 116, 115, 32, 111, 102, 32, 116, 104, 101, 32, 115, 99, 104, 101, 109, 
97, 32, 116, 104, 97, 116, 32, 97, 114, 101, 32, 102, 105, 120, 101, 100, 32, 97, 110, 100, 
10, 45, 45, 32, 117, 110, 99, 104, 97, 110, 103, 105, 110, 103, 32, 97, 99, 114, 111, 115, 
Changes to src/schema_repo2_cstr.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
/* Binary form of file ./sql/repo-transient.sql */
/** @page page_schema_repo2_cstr Schema: repo-transient.sql
@code
-- This file contains parts of the schema that can change from one
-- version to the next. The data stored in these tables is
-- reconstructed from the information in the main repo schema by the
-- "rebuild" operation.

-- Filenames
--
CREATE TABLE repo.filename(
  fnid INTEGER PRIMARY KEY,    -- Filename ID
  name TEXT UNIQUE             -- Name of file page
);

-- Linkages between check-ins, files created by each check-in, and
-- the names of those files.
--
-- Each entry represents a file that changed content from pid to fid
-- due to the check-in that goes from pmid to mid.  fnid is the name
-- of the file in the mid check-in.  If the file was renamed as part
-- of the mid check-in, then pfnid is the previous filename.
--
-- There can be multiple entries for (mid,fid) if the mid check-in was
-- a merge.  Entries with isaux==0 are from the primary parent.  Merge
-- parents have isaux set to true.
--
-- Field name mnemonics:
--    mid = Manifest ID.  (Each check-in is stored as a "Manifest")
--    fid = File ID.
--    pmid = Parent Manifest ID.
--    pid = Parent file ID.
--    fnid = File Name ID.
--    pfnid = Parent File Name ID.
--    isaux = pmid IS AUXiliary parent, not primary parent
--
-- pid==0    if the file is added by check-in mid.
-- pid==(-1) if the file exists in a merge parents but not in the primary
--           parent.  In other words, if the file file was added by merge.
--           (TODO: confirm if/where this is used in fossil and then make sure
--           libfossil does so, too.)
-- fid==0    if the file is removed by check-in mid.
--
CREATE TABLE repo.mlink(
  mid INTEGER,        -- Check-in that contains fid
  fid INTEGER,        -- New file content RID. 0 if deleted
  pmid INTEGER,       -- Check-in RID that contains pid
  pid INTEGER,        -- Prev file content RID. 0 if new. -1 if from a merge
  fnid INTEGER REFERENCES filename,   -- Name of the file
  pfnid INTEGER,      -- Previous name. 0 if unchanged
  mperm INTEGER,                      -- File permissions.  1==exec
  isaux BOOLEAN DEFAULT 0             -- TRUE if pmid is the primary
);
CREATE INDEX repo.mlink_i1 ON mlink(mid);
CREATE INDEX repo.mlink_i2 ON mlink(fnid);
CREATE INDEX repo.mlink_i3 ON mlink(fid);
CREATE INDEX repo.mlink_i4 ON mlink(pid);

-- Parent/child linkages between checkins
--
CREATE TABLE repo.plink(
  pid INTEGER REFERENCES blob,    -- Parent manifest
  cid INTEGER REFERENCES blob,    -- Child manifest
  isprim BOOLEAN,                 -- pid is the primary parent of cid
  mtime DATETIME,                 -- the date/time stamp on cid.  Julian day.
  baseid INTEGER REFERENCES blob, -- Baseline if cid is a delta manifest.
  UNIQUE(pid, cid)
);
CREATE INDEX repo.plink_i2 ON plink(cid,pid);

-- A "leaf" checkin is a checkin that has no children in the same
-- branch.  The set of all leaves is easily computed with a join,
-- between the plink and tagxref tables, but it is a slower join for
-- very large repositories (repositories with 100,000 or more checkins)
-- and so it makes sense to precompute the set of leaves.  There is
-- one entry in the following table for each leaf.
--
CREATE TABLE repo.leaf(rid INTEGER PRIMARY KEY);

-- Events used to generate a timeline
--
CREATE TABLE repo.event(
  type TEXT,                      -- Type of event: 'ci', 'w', 'e', 't', 'g'
  mtime DATETIME,                 -- Time of occurrence. Julian day.
  objid INTEGER PRIMARY KEY,      -- Associated record ID
  tagid INTEGER,                  -- Associated ticket or wiki name tag
  uid INTEGER REFERENCES user,    -- User who caused the event
  bgcolor TEXT,                   -- Color set by 'bgcolor' property
  euser TEXT,                     -- User set by 'user' property
  user TEXT,                      -- Name of the user
  ecomment TEXT,                  -- Comment set by 'comment' property
  comment TEXT,                   -- Comment describing the event
  brief TEXT,                     -- Short comment when tagid already seen
  omtime DATETIME                 -- Original unchanged date+time, or NULL
);
CREATE INDEX repo.event_i1 ON event(mtime);

-- A record of phantoms.  A phantom is a record for which we know the
-- UUID but we do not (yet) know the file content.
--
CREATE TABLE repo.phantom(
  rid INTEGER PRIMARY KEY         -- Record ID of the phantom
);

-- A record of orphaned delta-manifests.  An orphan is a delta-manifest
-- for which we have content, but its baseline-manifest is a phantom.
-- We have to track all orphan manifests so that when the baseline arrives,
-- we know to process the orphaned deltas.
CREATE TABLE repo.orphan(
  rid INTEGER PRIMARY KEY,        -- Delta manifest with a phantom baseline
  baseline INTEGER                -- Phantom baseline of this orphan
);
CREATE INDEX repo.orphan_baseline ON orphan(baseline);

-- Unclustered records.  An unclustered record is a record (including
-- a cluster records themselves) that is not mentioned by some other
-- cluster.
--
-- Phantoms are usually included in the unclustered table.  A new cluster
-- will never be created that contains a phantom.  But another repository
-- might send us a cluster that contains entries that are phantoms to
-- us.
--
CREATE TABLE repo.unclustered(
  rid INTEGER PRIMARY KEY         -- Record ID of the unclustered file
);

-- Records which have never been pushed to another server.  This is
-- used to reduce push operations to a single HTTP request in the
-- common case when one repository only talks to a single server.
--
CREATE TABLE repo.unsent(
  rid INTEGER PRIMARY KEY         -- Record ID of the phantom
);

-- Each baseline or manifest can have one or more tags.  A tag
-- is defined by a row in the next table.
-- 
-- Wiki pages are tagged with "wiki-NAME" where NAME is the name of
-- the wiki page.  Tickets changes are tagged with "ticket-UUID" where 
-- UUID is the indentifier of the ticket.  Tags used to assign symbolic
-- names to baselines are branches are of the form "sym-NAME" where
-- NAME is the symbolic name.
--
CREATE TABLE repo.tag(
  tagid INTEGER PRIMARY KEY,       -- Numeric tag ID
  tagname TEXT UNIQUE              -- Tag name.
);
INSERT INTO repo.tag VALUES(1, 'bgcolor');         -- FSL_TAGID_BGCOLOR
INSERT INTO repo.tag VALUES(2, 'comment');         -- FSL_TAGID_COMMENT
INSERT INTO repo.tag VALUES(3, 'user');            -- FSL_TAGID_USER
INSERT INTO repo.tag VALUES(4, 'date');            -- FSL_TAGID_DATE
INSERT INTO repo.tag VALUES(5, 'hidden');          -- FSL_TAGID_HIDDEN
INSERT INTO repo.tag VALUES(6, 'private');         -- FSL_TAGID_PRIVATE
INSERT INTO repo.tag VALUES(7, 'cluster');         -- FSL_TAGID_CLUSTER
INSERT INTO repo.tag VALUES(8, 'branch');          -- FSL_TAGID_BRANCH
INSERT INTO repo.tag VALUES(9, 'closed');          -- FSL_TAGID_CLOSED
INSERT INTO repo.tag VALUES(10,'parent');          -- FSL_TAGID_PARENT
INSERT INTO repo.tag VALUES(11,'note');            -- FSL_TAG_NOTE
-- arguable, to force auto-increment to start at 100:
-- INSERT INTO tag VALUES(99,'FSL_TAGID_MAX_INTERNAL');

-- Assignments of tags to baselines.  Note that we allow tags to
-- have values assigned to them.  So we are not really dealing with
-- tags here.  These are really properties.  But we are going to
-- keep calling them tags because in many cases the value is ignored.
--
CREATE TABLE repo.tagxref(
  tagid INTEGER REFERENCES tag,   -- The tag that was added or removed
  tagtype INTEGER,                -- 0:-,cancel  1:+,single  2:*,propagate
  srcid INTEGER REFERENCES blob,  -- Artifact of tag. 0 for propagated tags
  origid INTEGER REFERENCES blob, -- check-in holding propagated tag
  value TEXT,                     -- Value of the tag.  Might be NULL.
  mtime TIMESTAMP,                -- Time of addition or removal. Julian day
  rid INTEGER REFERENCE blob,     -- Artifact tag is applied to
  UNIQUE(rid, tagid)
);
CREATE INDEX repo.tagxref_i1 ON tagxref(tagid, mtime);

-- When a hyperlink occurs from one artifact to another (for example
-- when a check-in comment refers to a ticket) an entry is made in
-- the following table for that hyperlink.  This table is used to
-- facilitate the display of "back links".
--
CREATE TABLE repo.backlink(
  target TEXT,           -- Where the hyperlink points to
  srctype INT,           -- 0: check-in  1: ticket  2: wiki
  srcid INT,             -- rid for checkin or wiki.  tkt_id for ticket.
  mtime TIMESTAMP,       -- time that the hyperlink was added. Julian day.
  UNIQUE(target, srctype, srcid)
);
CREATE INDEX repo.backlink_src ON backlink(srcid, srctype);

-- Each attachment is an entry in the following table.  Only
-- the most recent attachment (identified by the D card) is saved.
--
CREATE TABLE repo.attachment(
  attachid INTEGER PRIMARY KEY,   -- Local id for this attachment
  isLatest BOOLEAN DEFAULT 0,     -- True if this is the one to use
  mtime TIMESTAMP,                -- Last changed.  Julian day.
  src TEXT,                       -- UUID of the attachment.  NULL to delete
  target TEXT,                    -- Object attached to. Wikiname or Tkt UUID
  filename TEXT,                  -- Filename for the attachment
  comment TEXT,                   -- Comment associated with this attachment
  user TEXT                       -- Name of user adding attachment
);
CREATE INDEX repo.attachment_idx1 ON attachment(target, filename, mtime);
CREATE INDEX repo.attachment_idx2 ON attachment(src);

-- For tracking cherrypick merges
CREATE TABLE repo.cherrypick(
  parentid INT,
  childid INT,
  isExclude BOOLEAN DEFAULT false,
  PRIMARY KEY(parentid, childid)
) WITHOUT ROWID;
CREATE INDEX repo.cherrypick_cid ON cherrypick(childid);
 @endcode
 @see schema_repo2()
*/
/* auto-generated code - edit at your own risk! (Good luck with that!) */
static char const fsl_schema_repo2_cstr_a[] = {
45, 45, 32, 84, 104, 105, 115, 32, 102, 105, 108, 101, 32, 99, 111, 110, 116, 97, 105, 110, 
115, 32, 112, 97, 114, 116, 115, 32, 111, 102, 32, 116, 104, 101, 32, 115, 99, 104, 101, 109, 
97, 32, 116, 104, 97, 116, 32, 99, 97, 110, 32, 99, 104, 97, 110, 103, 101, 32, 102, 114, 
111, 109, 32, 111, 110, 101, 10, 45, 45, 32, 118, 101, 114, 115, 105, 111, 110, 32, 116, 111, 
<
|
<
<
<
<
<

<
<
<
<
<
<
|
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<

<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<








1





2






3










































4

































































































































































5
6
7
8
9
10
11

/** @page page_schema_repo2_cstr repo-transient.sql












Binary form of file ./sql/repo-transient.sql.












































































































































































































*/
/* auto-generated code - edit at your own risk! (Good luck with that!) */
static char const fsl_schema_repo2_cstr_a[] = {
45, 45, 32, 84, 104, 105, 115, 32, 102, 105, 108, 101, 32, 99, 111, 110, 116, 97, 105, 110, 
115, 32, 112, 97, 114, 116, 115, 32, 111, 102, 32, 116, 104, 101, 32, 115, 99, 104, 101, 109, 
97, 32, 116, 104, 97, 116, 32, 99, 97, 110, 32, 99, 104, 97, 110, 103, 101, 32, 102, 114, 
111, 109, 32, 111, 110, 101, 10, 45, 45, 32, 118, 101, 114, 115, 105, 111, 110, 32, 116, 111, 
Changes to src/schema_ticket_cstr.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/* Binary form of file ./sql/ticket.sql */
/** @page page_schema_ticket_cstr Schema: ticket.sql
@code
-- Template for the TICKET table
CREATE TABLE repo.ticket(
  -- Do not change any column that begins with tkt_
  tkt_id INTEGER PRIMARY KEY,
  tkt_uuid TEXT UNIQUE,
  tkt_mtime DATE,
  tkt_ctime DATE,
  -- Add as many field as required below this line
  type TEXT,
  status TEXT,
  subsystem TEXT,
  priority TEXT,
  severity TEXT,
  foundin TEXT,
  private_contact TEXT,
  resolution TEXT,
  title TEXT,
  comment TEXT
);
CREATE TABLE repo.ticketchng(
  -- Do not change any column that begins with tkt_
  tkt_id INTEGER REFERENCES ticket,
  tkt_rid INTEGER REFERENCES blob,
  tkt_mtime DATE,
  -- Add as many fields as required below this line
  login TEXT,
  username TEXT,
  mimetype TEXT,
  icomment TEXT
);
CREATE INDEX repo.ticketchng_idx1 ON ticketchng(tkt_id, tkt_mtime);
 @endcode
 @see schema_ticket()
*/
/* auto-generated code - edit at your own risk! (Good luck with that!) */
static char const fsl_schema_ticket_cstr_a[] = {
45, 45, 32, 84, 101, 109, 112, 108, 97, 116, 101, 32, 102, 111, 114, 32, 116, 104, 101, 32, 
84, 73, 67, 75, 69, 84, 32, 116, 97, 98, 108, 101, 10, 67, 82, 69, 65, 84, 69, 32, 
84, 65, 66, 76, 69, 32, 114, 101, 112, 111, 46, 116, 105, 99, 107, 101, 116, 40, 10, 32, 
32, 45, 45, 32, 68, 111, 32, 110, 111, 116, 32, 99, 104, 97, 110, 103, 101, 32, 97, 110, 
<
|
|
<
|
|
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<








1
2

3
4






























5
6
7
8
9
10
11

/** @page page_schema_ticket_cstr ticket.sql


Binary form of file ./sql/ticket.sql.































*/
/* auto-generated code - edit at your own risk! (Good luck with that!) */
static char const fsl_schema_ticket_cstr_a[] = {
45, 45, 32, 84, 101, 109, 112, 108, 97, 116, 101, 32, 102, 111, 114, 32, 116, 104, 101, 32, 
84, 73, 67, 75, 69, 84, 32, 116, 97, 98, 108, 101, 10, 67, 82, 69, 65, 84, 69, 32, 
84, 65, 66, 76, 69, 32, 114, 101, 112, 111, 46, 116, 105, 99, 107, 101, 116, 40, 10, 32, 
32, 45, 45, 32, 68, 111, 32, 110, 111, 116, 32, 99, 104, 97, 110, 103, 101, 32, 97, 110, 
Changes to src/schema_ticket_reports_cstr.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
/* Binary form of file ./sql/ticket-reports.sql */
/** @page page_schema_ticket_reports_cstr Schema: ticket-reports.sql
@code
INSERT INTO reportfmt(title,mtime,cols,sqlcode) 
VALUES('All Tickets',julianday('1970-01-01'),'#ffffff Key:
#f2dcdc Active
#e8e8e8 Review
#cfe8bd Fixed
#bde5d6 Tested
#cacae5 Deferred
#c8c8c8 Closed','SELECT
  CASE WHEN status IN (''Open'',''Verified'') THEN ''#f2dcdc''
       WHEN status=''Review'' THEN ''#e8e8e8''
       WHEN status=''Fixed'' THEN ''#cfe8bd''
       WHEN status=''Tested'' THEN ''#bde5d6''
       WHEN status=''Deferred'' THEN ''#cacae5''
       ELSE ''#c8c8c8'' END AS ''bgcolor'',
  substr(tkt_uuid,1,10) AS ''#'',
  datetime(tkt_mtime) AS ''mtime'',
  type,
  status,
  subsystem,
  title
FROM ticket');
 @endcode
 @see schema_ticket_reports()
*/
/* auto-generated code - edit at your own risk! (Good luck with that!) */
static char const fsl_schema_ticket_reports_cstr_a[] = {
73, 78, 83, 69, 82, 84, 32, 73, 78, 84, 79, 32, 114, 101, 112, 111, 114, 116, 102, 109, 
116, 40, 116, 105, 116, 108, 101, 44, 109, 116, 105, 109, 101, 44, 99, 111, 108, 115, 44, 115, 
113, 108, 99, 111, 100, 101, 41, 32, 10, 86, 65, 76, 85, 69, 83, 40, 39, 65, 108, 108, 
32, 84, 105, 99, 107, 101, 116, 115, 39, 44, 106, 117, 108, 105, 97, 110, 100, 97, 121, 40, 
<
|
|
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
|
|
<








1
2




















3
4

5
6
7
8
9
10
11

/** @page page_schema_ticket_reports_cstr ticket-reports.sql





















Binary form of file ./sql/ticket-reports.sql.


*/
/* auto-generated code - edit at your own risk! (Good luck with that!) */
static char const fsl_schema_ticket_reports_cstr_a[] = {
73, 78, 83, 69, 82, 84, 32, 73, 78, 84, 79, 32, 114, 101, 112, 111, 114, 116, 102, 109, 
116, 40, 116, 105, 116, 108, 101, 44, 109, 116, 105, 109, 101, 44, 99, 111, 108, 115, 44, 115, 
113, 108, 99, 111, 100, 101, 41, 32, 10, 86, 65, 76, 85, 69, 83, 40, 39, 65, 108, 108, 
32, 84, 105, 99, 107, 101, 116, 115, 39, 44, 106, 117, 108, 105, 97, 110, 100, 97, 121, 40, 
Deleted subdir-inc.make.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/do/not/make # to help out emacs
# To be included from subdir GNU Makefiles.
TOP_DIR := $(patsubst %/,%,$(dir $(word $(words $(MAKEFILE_LIST)),$(MAKEFILE_LIST))))
#$(error TOP_DIR=$(TOP_DIR))
include $(TOP_DIR)/config.make
include $(TOP_DIR)/shakenmake.make

########################################################################
# These amalgamation-related targets are used by client binaries which
# link to libfossil.o (amalgamation) instead of libfossil.so/a.
ifeq (,$(wildcard fsl.c))
# ^^^^ don't include these rules in the main lib dir
LIBF_O := $(TOP_DIR)/libfossil.o
SQLITE3_O := $(TOP_DIR)/src/sqlite3.o
$(TOP_DIR)/libfossil.h: $(TOP_DIR)/libfossil-config.h $(wildcard $(TOP_DIR)/include/fossil-scm/*.h)
$(TOP_DIR)/libfossil.c: $(TOP_DIR)/libfossil.h $(wildcard $(TOP_DIR)/src/*.c)
$(LIBF_O): $(TOP_DIR)/libfossil.c
$(LIBF_O) $(TOP_DIR)/libfossil.h $(TOP_DIR)/libfossil-config.h:
	$(MAKE) -C $(TOP_DIR) amal
$(SQLITE3_O):
	$(MAKE) -C $(TOP_DIR)/src $@
# Client .o files should have these as deps:
LIBF_STATIC_CLIENT_OBJ_DEPS := $(LIBF_O) $(SQLITE3_O)
# Client .o files should link with:
LIBF_STATIC_CLIENT_LDFLAGS := $(LIBF_O) $(SQLITE3_O) -lz -lm
endif
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<