Fossil SCM

Merge updates from trunk.

mistachkin 2014-08-28 00:00 UTC reqdFor130 merge
Commit 937d2f479d878b8060d12389f7e703fab4230670
--- Makefile.classic
+++ Makefile.classic
@@ -25,11 +25,11 @@
2525
#### The suffix to add to final executable file. When cross-compiling
2626
# to windows, make this ".exe". Otherwise leave it blank.
2727
#
2828
E =
2929
30
-#### C Compile and options for use in building executables that
30
+#### C Compile and options for use in building executables that
3131
# will run on the target platform. This is usually the same
3232
# as BCC, unless you are cross-compiling. This C compiler builds
3333
# the finished binary for fossil. The BCC compiler above is used
3434
# for building intermediate code-generator tools.
3535
#
3636
--- Makefile.classic
+++ Makefile.classic
@@ -25,11 +25,11 @@
25 #### The suffix to add to final executable file. When cross-compiling
26 # to windows, make this ".exe". Otherwise leave it blank.
27 #
28 E =
29
30 #### C Compile and options for use in building executables that
31 # will run on the target platform. This is usually the same
32 # as BCC, unless you are cross-compiling. This C compiler builds
33 # the finished binary for fossil. The BCC compiler above is used
34 # for building intermediate code-generator tools.
35 #
36
--- Makefile.classic
+++ Makefile.classic
@@ -25,11 +25,11 @@
25 #### The suffix to add to final executable file. When cross-compiling
26 # to windows, make this ".exe". Otherwise leave it blank.
27 #
28 E =
29
30 #### C Compile and options for use in building executables that
31 # will run on the target platform. This is usually the same
32 # as BCC, unless you are cross-compiling. This C compiler builds
33 # the finished binary for fossil. The BCC compiler above is used
34 # for building intermediate code-generator tools.
35 #
36
+2 -2
--- auto.def
+++ auto.def
@@ -2,11 +2,11 @@
22
33
use cc cc-lib
44
55
options {
66
with-openssl:path|auto|none
7
- => {Look for openssl in the given path, or auto or none}
7
+ => {Look for OpenSSL in the given path, or auto or none}
88
with-zlib:path => {Look for zlib in the given path}
99
with-th1-hooks=0 => {Enable TH1 hooks for commands and web pages}
1010
with-tcl:path => {Enable Tcl integration, with Tcl in the specified path}
1111
with-tcl-stubs=0 => {Enable Tcl integration via stubs library mechanism}
1212
with-tcl-private-stubs=0
@@ -161,11 +161,11 @@
161161
define-append EXTRA_CFLAGS $cflags
162162
define-append EXTRA_LDFLAGS $tclconfig(TCL_LD_FLAGS)
163163
define FOSSIL_ENABLE_TCL
164164
}
165165
166
-# Helper for openssl checking
166
+# Helper for OpenSSL checking
167167
proc check-for-openssl {msg {cflags {}}} {
168168
msg-checking "Checking for $msg..."
169169
set rc 0
170170
msg-quiet cc-with [list -cflags $cflags -libs {-lssl -lcrypto}] {
171171
if {[cc-check-includes openssl/ssl.h] && [cc-check-functions SSL_new]} {
172172
--- auto.def
+++ auto.def
@@ -2,11 +2,11 @@
2
3 use cc cc-lib
4
5 options {
6 with-openssl:path|auto|none
7 => {Look for openssl in the given path, or auto or none}
8 with-zlib:path => {Look for zlib in the given path}
9 with-th1-hooks=0 => {Enable TH1 hooks for commands and web pages}
10 with-tcl:path => {Enable Tcl integration, with Tcl in the specified path}
11 with-tcl-stubs=0 => {Enable Tcl integration via stubs library mechanism}
12 with-tcl-private-stubs=0
@@ -161,11 +161,11 @@
161 define-append EXTRA_CFLAGS $cflags
162 define-append EXTRA_LDFLAGS $tclconfig(TCL_LD_FLAGS)
163 define FOSSIL_ENABLE_TCL
164 }
165
166 # Helper for openssl checking
167 proc check-for-openssl {msg {cflags {}}} {
168 msg-checking "Checking for $msg..."
169 set rc 0
170 msg-quiet cc-with [list -cflags $cflags -libs {-lssl -lcrypto}] {
171 if {[cc-check-includes openssl/ssl.h] && [cc-check-functions SSL_new]} {
172
--- auto.def
+++ auto.def
@@ -2,11 +2,11 @@
2
3 use cc cc-lib
4
5 options {
6 with-openssl:path|auto|none
7 => {Look for OpenSSL in the given path, or auto or none}
8 with-zlib:path => {Look for zlib in the given path}
9 with-th1-hooks=0 => {Enable TH1 hooks for commands and web pages}
10 with-tcl:path => {Enable Tcl integration, with Tcl in the specified path}
11 with-tcl-stubs=0 => {Enable Tcl integration via stubs library mechanism}
12 with-tcl-private-stubs=0
@@ -161,11 +161,11 @@
161 define-append EXTRA_CFLAGS $cflags
162 define-append EXTRA_LDFLAGS $tclconfig(TCL_LD_FLAGS)
163 define FOSSIL_ENABLE_TCL
164 }
165
166 # Helper for OpenSSL checking
167 proc check-for-openssl {msg {cflags {}}} {
168 msg-checking "Checking for $msg..."
169 set rc 0
170 msg-quiet cc-with [list -cflags $cflags -libs {-lssl -lcrypto}] {
171 if {[cc-check-includes openssl/ssl.h] && [cc-check-functions SSL_new]} {
172
+10 -3
--- src/attach.c
+++ src/attach.c
@@ -365,10 +365,12 @@
365365
int modPending; /* True if awaiting moderation */
366366
const char *zModAction; /* Moderation action or NULL */
367367
int isModerator; /* TRUE if user is the moderator */
368368
const char *zMime; /* MIME Type */
369369
Blob attach; /* Content of the attachment */
370
+ int fShowContent = 0;
371
+ const char *zLn = P("ln");
370372
371373
login_check_credentials();
372374
if( !g.perm.RdTkt && !g.perm.RdWiki ){ login_needed(); return; }
373375
rid = name_to_rid_www("name");
374376
if( rid==0 ){ fossil_redirect_home(); }
@@ -391,10 +393,12 @@
391393
zTarget = pAttach->zAttachTarget;
392394
zSrc = pAttach->zAttachSrc;
393395
ridSrc = db_int(0,"SELECT rid FROM blob WHERE uuid='%s'", zSrc);
394396
zName = pAttach->zAttachName;
395397
zDesc = pAttach->zComment;
398
+ zMime = mimetype_from_name(zName);
399
+ fShowContent = zMime ? strncmp(zMime,"text/", 5)==0 : 0;
396400
if( validate16(zTarget, strlen(zTarget))
397401
&& db_exists("SELECT 1 FROM ticket WHERE tkt_uuid='%s'", zTarget)
398402
){
399403
zTktUuid = zTarget;
400404
if( !g.perm.RdTkt ){ login_needed(); return; }
@@ -464,10 +468,15 @@
464468
moderation_approve(rid);
465469
}
466470
}
467471
style_header("Attachment Details");
468472
style_submenu_element("Raw", "Raw", "%R/artifact/%s", zUuid);
473
+ if(fShowContent){
474
+ style_submenu_element("Line Numbers", "Line Numbers",
475
+ "%R/ainfo/%s%s",zUuid,
476
+ ((zLn&&*zLn) ? "" : "?ln=0"));
477
+ }
469478
470479
@ <div class="section">Overview</div>
471480
@ <p><table class="label-value">
472481
@ <tr><th>Artifact&nbsp;ID:</th>
473482
@ <td>%z(href("%R/artifact/%s",zUuid))%s(zUuid)</a>
@@ -494,11 +503,10 @@
494503
@ <td>%z(href("%R/artifact/%s",zSrc))%s(zSrc)</a>
495504
if( g.perm.Setup ){
496505
@ (%d(ridSrc))
497506
}
498507
@ <tr><th>Filename:</th><td>%h(zName)</td></tr>
499
- zMime = mimetype_from_name(zName);
500508
if( g.perm.Setup ){
501509
@ <tr><th>MIME-Type:</th><td>%h(zMime)</td></tr>
502510
}
503511
@ <tr><th valign="top">Description:</th><td valign="top">%h(zDesc)</td></tr>
504512
@ </table>
@@ -517,13 +525,12 @@
517525
}
518526
519527
@ <div class="section">Content Appended</div>
520528
@ <blockquote>
521529
blob_zero(&attach);
522
- if( zMime==0 || strncmp(zMime,"text/", 5)==0 ){
530
+ if( fShowContent ){
523531
const char *z;
524
- const char *zLn = P("ln");
525532
content_get(ridSrc, &attach);
526533
blob_to_utf8_no_bom(&attach, 0);
527534
z = blob_str(&attach);
528535
if( zLn ){
529536
output_text_with_line_numbers(z, zLn);
530537
--- src/attach.c
+++ src/attach.c
@@ -365,10 +365,12 @@
365 int modPending; /* True if awaiting moderation */
366 const char *zModAction; /* Moderation action or NULL */
367 int isModerator; /* TRUE if user is the moderator */
368 const char *zMime; /* MIME Type */
369 Blob attach; /* Content of the attachment */
 
 
370
371 login_check_credentials();
372 if( !g.perm.RdTkt && !g.perm.RdWiki ){ login_needed(); return; }
373 rid = name_to_rid_www("name");
374 if( rid==0 ){ fossil_redirect_home(); }
@@ -391,10 +393,12 @@
391 zTarget = pAttach->zAttachTarget;
392 zSrc = pAttach->zAttachSrc;
393 ridSrc = db_int(0,"SELECT rid FROM blob WHERE uuid='%s'", zSrc);
394 zName = pAttach->zAttachName;
395 zDesc = pAttach->zComment;
 
 
396 if( validate16(zTarget, strlen(zTarget))
397 && db_exists("SELECT 1 FROM ticket WHERE tkt_uuid='%s'", zTarget)
398 ){
399 zTktUuid = zTarget;
400 if( !g.perm.RdTkt ){ login_needed(); return; }
@@ -464,10 +468,15 @@
464 moderation_approve(rid);
465 }
466 }
467 style_header("Attachment Details");
468 style_submenu_element("Raw", "Raw", "%R/artifact/%s", zUuid);
 
 
 
 
 
469
470 @ <div class="section">Overview</div>
471 @ <p><table class="label-value">
472 @ <tr><th>Artifact&nbsp;ID:</th>
473 @ <td>%z(href("%R/artifact/%s",zUuid))%s(zUuid)</a>
@@ -494,11 +503,10 @@
494 @ <td>%z(href("%R/artifact/%s",zSrc))%s(zSrc)</a>
495 if( g.perm.Setup ){
496 @ (%d(ridSrc))
497 }
498 @ <tr><th>Filename:</th><td>%h(zName)</td></tr>
499 zMime = mimetype_from_name(zName);
500 if( g.perm.Setup ){
501 @ <tr><th>MIME-Type:</th><td>%h(zMime)</td></tr>
502 }
503 @ <tr><th valign="top">Description:</th><td valign="top">%h(zDesc)</td></tr>
504 @ </table>
@@ -517,13 +525,12 @@
517 }
518
519 @ <div class="section">Content Appended</div>
520 @ <blockquote>
521 blob_zero(&attach);
522 if( zMime==0 || strncmp(zMime,"text/", 5)==0 ){
523 const char *z;
524 const char *zLn = P("ln");
525 content_get(ridSrc, &attach);
526 blob_to_utf8_no_bom(&attach, 0);
527 z = blob_str(&attach);
528 if( zLn ){
529 output_text_with_line_numbers(z, zLn);
530
--- src/attach.c
+++ src/attach.c
@@ -365,10 +365,12 @@
365 int modPending; /* True if awaiting moderation */
366 const char *zModAction; /* Moderation action or NULL */
367 int isModerator; /* TRUE if user is the moderator */
368 const char *zMime; /* MIME Type */
369 Blob attach; /* Content of the attachment */
370 int fShowContent = 0;
371 const char *zLn = P("ln");
372
373 login_check_credentials();
374 if( !g.perm.RdTkt && !g.perm.RdWiki ){ login_needed(); return; }
375 rid = name_to_rid_www("name");
376 if( rid==0 ){ fossil_redirect_home(); }
@@ -391,10 +393,12 @@
393 zTarget = pAttach->zAttachTarget;
394 zSrc = pAttach->zAttachSrc;
395 ridSrc = db_int(0,"SELECT rid FROM blob WHERE uuid='%s'", zSrc);
396 zName = pAttach->zAttachName;
397 zDesc = pAttach->zComment;
398 zMime = mimetype_from_name(zName);
399 fShowContent = zMime ? strncmp(zMime,"text/", 5)==0 : 0;
400 if( validate16(zTarget, strlen(zTarget))
401 && db_exists("SELECT 1 FROM ticket WHERE tkt_uuid='%s'", zTarget)
402 ){
403 zTktUuid = zTarget;
404 if( !g.perm.RdTkt ){ login_needed(); return; }
@@ -464,10 +468,15 @@
468 moderation_approve(rid);
469 }
470 }
471 style_header("Attachment Details");
472 style_submenu_element("Raw", "Raw", "%R/artifact/%s", zUuid);
473 if(fShowContent){
474 style_submenu_element("Line Numbers", "Line Numbers",
475 "%R/ainfo/%s%s",zUuid,
476 ((zLn&&*zLn) ? "" : "?ln=0"));
477 }
478
479 @ <div class="section">Overview</div>
480 @ <p><table class="label-value">
481 @ <tr><th>Artifact&nbsp;ID:</th>
482 @ <td>%z(href("%R/artifact/%s",zUuid))%s(zUuid)</a>
@@ -494,11 +503,10 @@
503 @ <td>%z(href("%R/artifact/%s",zSrc))%s(zSrc)</a>
504 if( g.perm.Setup ){
505 @ (%d(ridSrc))
506 }
507 @ <tr><th>Filename:</th><td>%h(zName)</td></tr>
 
508 if( g.perm.Setup ){
509 @ <tr><th>MIME-Type:</th><td>%h(zMime)</td></tr>
510 }
511 @ <tr><th valign="top">Description:</th><td valign="top">%h(zDesc)</td></tr>
512 @ </table>
@@ -517,13 +525,12 @@
525 }
526
527 @ <div class="section">Content Appended</div>
528 @ <blockquote>
529 blob_zero(&attach);
530 if( fShowContent ){
531 const char *z;
 
532 content_get(ridSrc, &attach);
533 blob_to_utf8_no_bom(&attach, 0);
534 z = blob_str(&attach);
535 if( zLn ){
536 output_text_with_line_numbers(z, zLn);
537
+9 -6
--- src/info.c
+++ src/info.c
@@ -197,11 +197,11 @@
197197
i64 fsize;
198198
int verboseFlag = find_option("verbose","v",0)!=0;
199199
if( !verboseFlag ){
200200
verboseFlag = find_option("detail","l",0)!=0; /* deprecated */
201201
}
202
-
202
+
203203
/* We should be done with options.. */
204204
verify_all_options();
205205
206206
if( g.argc==3 && (fsize = file_size(g.argv[2]))>0 && (fsize&0x1ff)==0 ){
207207
db_open_config(0);
@@ -1065,28 +1065,28 @@
10651065
cmp = -1;
10661066
}else{
10671067
cmp = fossil_strcmp(pFileFrom->zName, pFileTo->zName);
10681068
}
10691069
if( cmp<0 ){
1070
- if(!zGlob || strglob(zGlob, pFileFrom->zName)){
1070
+ if( !zGlob || sqlite3_strglob(zGlob, pFileFrom->zName)==0 ){
10711071
append_file_change_line(pFileFrom->zName,
10721072
pFileFrom->zUuid, 0, 0, diffFlags, pRe, 0);
10731073
}
10741074
pFileFrom = manifest_file_next(pFrom, 0);
10751075
}else if( cmp>0 ){
1076
- if(!zGlob || strglob(zGlob, pFileTo->zName)){
1076
+ if( !zGlob || sqlite3_strglob(zGlob, pFileTo->zName)==0 ){
10771077
append_file_change_line(pFileTo->zName,
10781078
0, pFileTo->zUuid, 0, diffFlags, pRe,
10791079
manifest_file_mperm(pFileTo));
10801080
}
10811081
pFileTo = manifest_file_next(pTo, 0);
10821082
}else if( fossil_strcmp(pFileFrom->zUuid, pFileTo->zUuid)==0 ){
10831083
pFileFrom = manifest_file_next(pFrom, 0);
10841084
pFileTo = manifest_file_next(pTo, 0);
10851085
}else{
1086
- if(!zGlob || (strglob(zGlob, pFileFrom->zName)
1087
- || strglob(zGlob, pFileTo->zName))){
1086
+ if(!zGlob || (sqlite3_strglob(zGlob, pFileFrom->zName)==0
1087
+ || sqlite3_strglob(zGlob, pFileTo->zName)==0) ){
10881088
append_file_change_line(pFileFrom->zName,
10891089
pFileFrom->zUuid,
10901090
pFileTo->zUuid, 0, diffFlags, pRe,
10911091
manifest_file_mperm(pFileTo));
10921092
}
@@ -1744,10 +1744,11 @@
17441744
int objType;
17451745
int asText;
17461746
const char *zUuid;
17471747
u32 objdescFlags = 0;
17481748
int descOnly = fossil_strcmp(g.zPath,"whatis")==0;
1749
+ const char *zLn = P("ln");
17491750
17501751
if( P("ci") && P("filename") ){
17511752
rid = artifact_from_ci_and_filename_www();
17521753
}
17531754
if( rid==0 ){
@@ -1811,10 +1812,13 @@
18111812
style_submenu_element("Parsed", "Parsed", "%R/info/%s", zUuid);
18121813
}
18131814
if( descOnly ){
18141815
style_submenu_element("Content", "Content", "%R/artifact/%s", zUuid);
18151816
}else{
1817
+ style_submenu_element("Line Numbers", "Line Numbers",
1818
+ "%R/info/%s%s",zUuid,
1819
+ ((zLn&&*zLn) ? "" : "?ln=0"));
18161820
@ <hr />
18171821
content_get(rid, &content);
18181822
if( renderAsWiki ){
18191823
wiki_render_by_mimetype(&content, zMime);
18201824
}else if( renderAsHtml ){
@@ -1827,11 +1831,10 @@
18271831
style_submenu_element("Hex","Hex", "%s/hexdump?name=%s", g.zTop, zUuid);
18281832
blob_to_utf8_no_bom(&content, 0);
18291833
zMime = mimetype_from_content(&content);
18301834
@ <blockquote>
18311835
if( zMime==0 ){
1832
- const char *zLn = P("ln");
18331836
const char *z;
18341837
z = blob_str(&content);
18351838
if( zLn ){
18361839
output_text_with_line_numbers(z, zLn);
18371840
}else{
18381841
--- src/info.c
+++ src/info.c
@@ -197,11 +197,11 @@
197 i64 fsize;
198 int verboseFlag = find_option("verbose","v",0)!=0;
199 if( !verboseFlag ){
200 verboseFlag = find_option("detail","l",0)!=0; /* deprecated */
201 }
202
203 /* We should be done with options.. */
204 verify_all_options();
205
206 if( g.argc==3 && (fsize = file_size(g.argv[2]))>0 && (fsize&0x1ff)==0 ){
207 db_open_config(0);
@@ -1065,28 +1065,28 @@
1065 cmp = -1;
1066 }else{
1067 cmp = fossil_strcmp(pFileFrom->zName, pFileTo->zName);
1068 }
1069 if( cmp<0 ){
1070 if(!zGlob || strglob(zGlob, pFileFrom->zName)){
1071 append_file_change_line(pFileFrom->zName,
1072 pFileFrom->zUuid, 0, 0, diffFlags, pRe, 0);
1073 }
1074 pFileFrom = manifest_file_next(pFrom, 0);
1075 }else if( cmp>0 ){
1076 if(!zGlob || strglob(zGlob, pFileTo->zName)){
1077 append_file_change_line(pFileTo->zName,
1078 0, pFileTo->zUuid, 0, diffFlags, pRe,
1079 manifest_file_mperm(pFileTo));
1080 }
1081 pFileTo = manifest_file_next(pTo, 0);
1082 }else if( fossil_strcmp(pFileFrom->zUuid, pFileTo->zUuid)==0 ){
1083 pFileFrom = manifest_file_next(pFrom, 0);
1084 pFileTo = manifest_file_next(pTo, 0);
1085 }else{
1086 if(!zGlob || (strglob(zGlob, pFileFrom->zName)
1087 || strglob(zGlob, pFileTo->zName))){
1088 append_file_change_line(pFileFrom->zName,
1089 pFileFrom->zUuid,
1090 pFileTo->zUuid, 0, diffFlags, pRe,
1091 manifest_file_mperm(pFileTo));
1092 }
@@ -1744,10 +1744,11 @@
1744 int objType;
1745 int asText;
1746 const char *zUuid;
1747 u32 objdescFlags = 0;
1748 int descOnly = fossil_strcmp(g.zPath,"whatis")==0;
 
1749
1750 if( P("ci") && P("filename") ){
1751 rid = artifact_from_ci_and_filename_www();
1752 }
1753 if( rid==0 ){
@@ -1811,10 +1812,13 @@
1811 style_submenu_element("Parsed", "Parsed", "%R/info/%s", zUuid);
1812 }
1813 if( descOnly ){
1814 style_submenu_element("Content", "Content", "%R/artifact/%s", zUuid);
1815 }else{
 
 
 
1816 @ <hr />
1817 content_get(rid, &content);
1818 if( renderAsWiki ){
1819 wiki_render_by_mimetype(&content, zMime);
1820 }else if( renderAsHtml ){
@@ -1827,11 +1831,10 @@
1827 style_submenu_element("Hex","Hex", "%s/hexdump?name=%s", g.zTop, zUuid);
1828 blob_to_utf8_no_bom(&content, 0);
1829 zMime = mimetype_from_content(&content);
1830 @ <blockquote>
1831 if( zMime==0 ){
1832 const char *zLn = P("ln");
1833 const char *z;
1834 z = blob_str(&content);
1835 if( zLn ){
1836 output_text_with_line_numbers(z, zLn);
1837 }else{
1838
--- src/info.c
+++ src/info.c
@@ -197,11 +197,11 @@
197 i64 fsize;
198 int verboseFlag = find_option("verbose","v",0)!=0;
199 if( !verboseFlag ){
200 verboseFlag = find_option("detail","l",0)!=0; /* deprecated */
201 }
202
203 /* We should be done with options.. */
204 verify_all_options();
205
206 if( g.argc==3 && (fsize = file_size(g.argv[2]))>0 && (fsize&0x1ff)==0 ){
207 db_open_config(0);
@@ -1065,28 +1065,28 @@
1065 cmp = -1;
1066 }else{
1067 cmp = fossil_strcmp(pFileFrom->zName, pFileTo->zName);
1068 }
1069 if( cmp<0 ){
1070 if( !zGlob || sqlite3_strglob(zGlob, pFileFrom->zName)==0 ){
1071 append_file_change_line(pFileFrom->zName,
1072 pFileFrom->zUuid, 0, 0, diffFlags, pRe, 0);
1073 }
1074 pFileFrom = manifest_file_next(pFrom, 0);
1075 }else if( cmp>0 ){
1076 if( !zGlob || sqlite3_strglob(zGlob, pFileTo->zName)==0 ){
1077 append_file_change_line(pFileTo->zName,
1078 0, pFileTo->zUuid, 0, diffFlags, pRe,
1079 manifest_file_mperm(pFileTo));
1080 }
1081 pFileTo = manifest_file_next(pTo, 0);
1082 }else if( fossil_strcmp(pFileFrom->zUuid, pFileTo->zUuid)==0 ){
1083 pFileFrom = manifest_file_next(pFrom, 0);
1084 pFileTo = manifest_file_next(pTo, 0);
1085 }else{
1086 if(!zGlob || (sqlite3_strglob(zGlob, pFileFrom->zName)==0
1087 || sqlite3_strglob(zGlob, pFileTo->zName)==0) ){
1088 append_file_change_line(pFileFrom->zName,
1089 pFileFrom->zUuid,
1090 pFileTo->zUuid, 0, diffFlags, pRe,
1091 manifest_file_mperm(pFileTo));
1092 }
@@ -1744,10 +1744,11 @@
1744 int objType;
1745 int asText;
1746 const char *zUuid;
1747 u32 objdescFlags = 0;
1748 int descOnly = fossil_strcmp(g.zPath,"whatis")==0;
1749 const char *zLn = P("ln");
1750
1751 if( P("ci") && P("filename") ){
1752 rid = artifact_from_ci_and_filename_www();
1753 }
1754 if( rid==0 ){
@@ -1811,10 +1812,13 @@
1812 style_submenu_element("Parsed", "Parsed", "%R/info/%s", zUuid);
1813 }
1814 if( descOnly ){
1815 style_submenu_element("Content", "Content", "%R/artifact/%s", zUuid);
1816 }else{
1817 style_submenu_element("Line Numbers", "Line Numbers",
1818 "%R/info/%s%s",zUuid,
1819 ((zLn&&*zLn) ? "" : "?ln=0"));
1820 @ <hr />
1821 content_get(rid, &content);
1822 if( renderAsWiki ){
1823 wiki_render_by_mimetype(&content, zMime);
1824 }else if( renderAsHtml ){
@@ -1827,11 +1831,10 @@
1831 style_submenu_element("Hex","Hex", "%s/hexdump?name=%s", g.zTop, zUuid);
1832 blob_to_utf8_no_bom(&content, 0);
1833 zMime = mimetype_from_content(&content);
1834 @ <blockquote>
1835 if( zMime==0 ){
 
1836 const char *z;
1837 z = blob_str(&content);
1838 if( zLn ){
1839 output_text_with_line_numbers(z, zLn);
1840 }else{
1841
+4 -4
--- src/main.c
+++ src/main.c
@@ -940,11 +940,11 @@
940940
void version_cmd(void){
941941
int verboseFlag = 0;
942942
943943
fossil_print("This is fossil version %s\n", get_version());
944944
verboseFlag = find_option("verbose","v",0)!=0;
945
-
945
+
946946
/* We should be done with options.. */
947947
verify_all_options();
948948
949949
if(!verboseFlag){
950950
return;
@@ -1429,11 +1429,11 @@
14291429
continue;
14301430
}
14311431
if( pFileGlob!=0
14321432
&& file_isfile(zRepo)
14331433
&& glob_match(pFileGlob, zRepo)
1434
- && strglob("*.fossil*",zRepo)==0
1434
+ && sqlite3_strglob("*.fossil*",zRepo)!=0
14351435
&& (zMimetype = mimetype_from_name(zRepo))!=0
14361436
&& strcmp(zMimetype, "application/x-fossil-artifact")!=0
14371437
){
14381438
Blob content;
14391439
blob_read_from_file(&content, zRepo);
@@ -1935,11 +1935,11 @@
19351935
if( zAltBase ) set_base_url(zAltBase);
19361936
if( find_option("https",0,0)!=0 ) cgi_replace_parameter("HTTPS","on");
19371937
zHost = find_option("host", 0, 1);
19381938
if( zHost ) cgi_replace_parameter("HTTP_HOST",zHost);
19391939
g.cgiOutput = 1;
1940
-
1940
+
19411941
/* We should be done with options.. */
19421942
verify_all_options();
19431943
19441944
if( g.argc!=2 && g.argc!=3 && g.argc!=6 ){
19451945
fossil_fatal("no repository specified");
@@ -2125,11 +2125,11 @@
21252125
set_base_url(zAltBase);
21262126
}
21272127
if( find_option("localhost", 0, 0)!=0 ){
21282128
flags |= HTTP_SERVER_LOCALHOST;
21292129
}
2130
-
2130
+
21312131
/* We should be done with options.. */
21322132
verify_all_options();
21332133
21342134
if( g.argc!=2 && g.argc!=3 ) usage("?REPOSITORY?");
21352135
isUiCmd = g.argv[1][0]=='u';
21362136
--- src/main.c
+++ src/main.c
@@ -940,11 +940,11 @@
940 void version_cmd(void){
941 int verboseFlag = 0;
942
943 fossil_print("This is fossil version %s\n", get_version());
944 verboseFlag = find_option("verbose","v",0)!=0;
945
946 /* We should be done with options.. */
947 verify_all_options();
948
949 if(!verboseFlag){
950 return;
@@ -1429,11 +1429,11 @@
1429 continue;
1430 }
1431 if( pFileGlob!=0
1432 && file_isfile(zRepo)
1433 && glob_match(pFileGlob, zRepo)
1434 && strglob("*.fossil*",zRepo)==0
1435 && (zMimetype = mimetype_from_name(zRepo))!=0
1436 && strcmp(zMimetype, "application/x-fossil-artifact")!=0
1437 ){
1438 Blob content;
1439 blob_read_from_file(&content, zRepo);
@@ -1935,11 +1935,11 @@
1935 if( zAltBase ) set_base_url(zAltBase);
1936 if( find_option("https",0,0)!=0 ) cgi_replace_parameter("HTTPS","on");
1937 zHost = find_option("host", 0, 1);
1938 if( zHost ) cgi_replace_parameter("HTTP_HOST",zHost);
1939 g.cgiOutput = 1;
1940
1941 /* We should be done with options.. */
1942 verify_all_options();
1943
1944 if( g.argc!=2 && g.argc!=3 && g.argc!=6 ){
1945 fossil_fatal("no repository specified");
@@ -2125,11 +2125,11 @@
2125 set_base_url(zAltBase);
2126 }
2127 if( find_option("localhost", 0, 0)!=0 ){
2128 flags |= HTTP_SERVER_LOCALHOST;
2129 }
2130
2131 /* We should be done with options.. */
2132 verify_all_options();
2133
2134 if( g.argc!=2 && g.argc!=3 ) usage("?REPOSITORY?");
2135 isUiCmd = g.argv[1][0]=='u';
2136
--- src/main.c
+++ src/main.c
@@ -940,11 +940,11 @@
940 void version_cmd(void){
941 int verboseFlag = 0;
942
943 fossil_print("This is fossil version %s\n", get_version());
944 verboseFlag = find_option("verbose","v",0)!=0;
945
946 /* We should be done with options.. */
947 verify_all_options();
948
949 if(!verboseFlag){
950 return;
@@ -1429,11 +1429,11 @@
1429 continue;
1430 }
1431 if( pFileGlob!=0
1432 && file_isfile(zRepo)
1433 && glob_match(pFileGlob, zRepo)
1434 && sqlite3_strglob("*.fossil*",zRepo)!=0
1435 && (zMimetype = mimetype_from_name(zRepo))!=0
1436 && strcmp(zMimetype, "application/x-fossil-artifact")!=0
1437 ){
1438 Blob content;
1439 blob_read_from_file(&content, zRepo);
@@ -1935,11 +1935,11 @@
1935 if( zAltBase ) set_base_url(zAltBase);
1936 if( find_option("https",0,0)!=0 ) cgi_replace_parameter("HTTPS","on");
1937 zHost = find_option("host", 0, 1);
1938 if( zHost ) cgi_replace_parameter("HTTP_HOST",zHost);
1939 g.cgiOutput = 1;
1940
1941 /* We should be done with options.. */
1942 verify_all_options();
1943
1944 if( g.argc!=2 && g.argc!=3 && g.argc!=6 ){
1945 fossil_fatal("no repository specified");
@@ -2125,11 +2125,11 @@
2125 set_base_url(zAltBase);
2126 }
2127 if( find_option("localhost", 0, 0)!=0 ){
2128 flags |= HTTP_SERVER_LOCALHOST;
2129 }
2130
2131 /* We should be done with options.. */
2132 verify_all_options();
2133
2134 if( g.argc!=2 && g.argc!=3 ) usage("?REPOSITORY?");
2135 isUiCmd = g.argv[1][0]=='u';
2136
+3 -3
--- src/main.mk
+++ src/main.mk
@@ -403,11 +403,11 @@
403403
404404
# The USE_SYSTEM_SQLITE variable may be undefined, set to 0, or set
405405
# to 1. If it is set to 1, then there is no need to build or link
406406
# the sqlite3.o object. Instead, the system sqlite will be linked
407407
# using -lsqlite3.
408
-SQLITE3_OBJ.1 =
408
+SQLITE3_OBJ.1 =
409409
SQLITE3_OBJ.0 = $(OBJDIR)/sqlite3.o
410410
SQLITE3_OBJ. = $(SQLITE3_OBJ.0)
411411
412412
EXTRAOBJ = $(SQLITE3_OBJ.$(USE_SYSTEM_SQLITE)) $(OBJDIR)/shell.o $(OBJDIR)/th.o $(OBJDIR)/th_lang.o $(OBJDIR)/th_tcl.o $(OBJDIR)/cson_amalgamation.o
413413
@@ -415,14 +415,14 @@
415415
$(TCC) -o $(APPNAME) $(OBJ) $(EXTRAOBJ) $(LIB)
416416
417417
# This rule prevents make from using its default rules to try build
418418
# an executable named "manifest" out of the file named "manifest.c"
419419
#
420
-$(SRCDIR)/../manifest:
420
+$(SRCDIR)/../manifest:
421421
# noop
422422
423
-clean:
423
+clean:
424424
rm -rf $(OBJDIR)/* $(APPNAME)
425425
426426
427427
$(OBJDIR)/page_index.h: $(TRANS_SRC) $(OBJDIR)/mkindex
428428
$(OBJDIR)/mkindex $(TRANS_SRC) >$@
429429
--- src/main.mk
+++ src/main.mk
@@ -403,11 +403,11 @@
403
404 # The USE_SYSTEM_SQLITE variable may be undefined, set to 0, or set
405 # to 1. If it is set to 1, then there is no need to build or link
406 # the sqlite3.o object. Instead, the system sqlite will be linked
407 # using -lsqlite3.
408 SQLITE3_OBJ.1 =
409 SQLITE3_OBJ.0 = $(OBJDIR)/sqlite3.o
410 SQLITE3_OBJ. = $(SQLITE3_OBJ.0)
411
412 EXTRAOBJ = $(SQLITE3_OBJ.$(USE_SYSTEM_SQLITE)) $(OBJDIR)/shell.o $(OBJDIR)/th.o $(OBJDIR)/th_lang.o $(OBJDIR)/th_tcl.o $(OBJDIR)/cson_amalgamation.o
413
@@ -415,14 +415,14 @@
415 $(TCC) -o $(APPNAME) $(OBJ) $(EXTRAOBJ) $(LIB)
416
417 # This rule prevents make from using its default rules to try build
418 # an executable named "manifest" out of the file named "manifest.c"
419 #
420 $(SRCDIR)/../manifest:
421 # noop
422
423 clean:
424 rm -rf $(OBJDIR)/* $(APPNAME)
425
426
427 $(OBJDIR)/page_index.h: $(TRANS_SRC) $(OBJDIR)/mkindex
428 $(OBJDIR)/mkindex $(TRANS_SRC) >$@
429
--- src/main.mk
+++ src/main.mk
@@ -403,11 +403,11 @@
403
404 # The USE_SYSTEM_SQLITE variable may be undefined, set to 0, or set
405 # to 1. If it is set to 1, then there is no need to build or link
406 # the sqlite3.o object. Instead, the system sqlite will be linked
407 # using -lsqlite3.
408 SQLITE3_OBJ.1 =
409 SQLITE3_OBJ.0 = $(OBJDIR)/sqlite3.o
410 SQLITE3_OBJ. = $(SQLITE3_OBJ.0)
411
412 EXTRAOBJ = $(SQLITE3_OBJ.$(USE_SYSTEM_SQLITE)) $(OBJDIR)/shell.o $(OBJDIR)/th.o $(OBJDIR)/th_lang.o $(OBJDIR)/th_tcl.o $(OBJDIR)/cson_amalgamation.o
413
@@ -415,14 +415,14 @@
415 $(TCC) -o $(APPNAME) $(OBJ) $(EXTRAOBJ) $(LIB)
416
417 # This rule prevents make from using its default rules to try build
418 # an executable named "manifest" out of the file named "manifest.c"
419 #
420 $(SRCDIR)/../manifest:
421 # noop
422
423 clean:
424 rm -rf $(OBJDIR)/* $(APPNAME)
425
426
427 $(OBJDIR)/page_index.h: $(TRANS_SRC) $(OBJDIR)/mkindex
428 $(OBJDIR)/mkindex $(TRANS_SRC) >$@
429
+51 -25
--- src/makemake.tcl
+++ src/makemake.tcl
@@ -268,11 +268,11 @@
268268
269269
# The USE_SYSTEM_SQLITE variable may be undefined, set to 0, or set
270270
# to 1. If it is set to 1, then there is no need to build or link
271271
# the sqlite3.o object. Instead, the system sqlite will be linked
272272
# using -lsqlite3.
273
-SQLITE3_OBJ.1 =
273
+SQLITE3_OBJ.1 =
274274
SQLITE3_OBJ.0 = $(OBJDIR)/sqlite3.o
275275
SQLITE3_OBJ. = $(SQLITE3_OBJ.0)
276276
277277
EXTRAOBJ = \
278278
$(SQLITE3_OBJ.$(USE_SYSTEM_SQLITE)) \
@@ -286,14 +286,14 @@
286286
$(TCC) -o $(APPNAME) $(OBJ) $(EXTRAOBJ) $(LIB)
287287
288288
# This rule prevents make from using its default rules to try build
289289
# an executable named "manifest" out of the file named "manifest.c"
290290
#
291
-$(SRCDIR)/../manifest:
291
+$(SRCDIR)/../manifest:
292292
# noop
293293
294
-clean:
294
+clean:
295295
rm -rf $(OBJDIR)/* $(APPNAME)
296296
297297
}]
298298
299299
set mhargs {}
@@ -580,25 +580,30 @@
580580
#### We add the -static option here so that we can build a static
581581
# executable that will run in a chroot jail.
582582
#
583583
LIB = -static
584584
585
-# MinGW: If available, use the Unicode capable runtime startup code.
585
+#### MinGW: If available, use the Unicode capable runtime startup code.
586
+#
586587
ifndef MINGW_IS_32BIT_ONLY
587588
LIB += -municode
588589
endif
589590
591
+#### SQLite: If enabled, use the system SQLite library.
592
+#
590593
ifdef USE_SYSTEM_SQLITE
591594
LIB += -lsqlite3
592595
endif
593596
594
-# OpenSSL: Add the necessary libraries required, if enabled.
597
+#### OpenSSL: Add the necessary libraries required, if enabled.
598
+#
595599
ifdef FOSSIL_ENABLE_SSL
596600
LIB += -lssl -lcrypto -lgdi32
597601
endif
598602
599
-# Tcl: Add the necessary libraries required, if enabled.
603
+#### Tcl: Add the necessary libraries required, if enabled.
604
+#
600605
ifdef FOSSIL_ENABLE_TCL
601606
LIB += $(LIBTCL)
602607
endif
603608
604609
#### Extra arguments for linking the finished binary. Fossil needs
@@ -921,11 +926,11 @@
921926
APPNAME = $(OBJDIR)\fossil$(E)
922927
923928
all: $(APPNAME)
924929
925930
$(APPNAME) : translate$E mkindex$E headers $(OBJ) $(OBJDIR)\link
926
- cd $(OBJDIR)
931
+ cd $(OBJDIR)
927932
$(DMDIR)\bin\link @link
928933
929934
$(OBJDIR)\fossil.res: $B\win\fossil.rc
930935
$(RC) $(RCFLAGS) -o$@ $**
931936
@@ -970,11 +975,11 @@
970975
cp $@ $@
971976
972977
VERSION.h : version$E $B\manifest.uuid $B\manifest $B\VERSION
973978
+$** > $@
974979
975
-page_index.h: mkindex$E $(SRC)
980
+page_index.h: mkindex$E $(SRC)
976981
+$** > $@
977982
978983
clean:
979984
-del $(OBJDIR)\*.obj
980985
-del *.obj *_.c *.h *.map
@@ -1033,17 +1038,19 @@
10331038
#
10341039
# This file is automatically generated. Instead of editing this
10351040
# file, edit "makemake.tcl" then run "tclsh makemake.tcl"
10361041
# to regenerate this file.
10371042
#
1038
-B = ..
1039
-SRCDIR = $B\src
1040
-OBJDIR = .
1041
-OX = .
1042
-O = .obj
1043
-E = .exe
1044
-P = .pdb
1043
+B = ..
1044
+SRCDIR = $B\src
1045
+OBJDIR = .
1046
+OX = .
1047
+O = .obj
1048
+E = .exe
1049
+P = .pdb
1050
+PERLDIR =
1051
+PERL = perl.exe
10451052
10461053
# Uncomment to enable debug symbols
10471054
# DEBUG = 1
10481055
10491056
# Uncomment to enable JSON API
@@ -1057,12 +1064,13 @@
10571064
10581065
# Uncomment to enable Tcl support
10591066
# FOSSIL_ENABLE_TCL = 1
10601067
10611068
!ifdef FOSSIL_ENABLE_SSL
1062
-SSLINCDIR = $(B)\compat\openssl-1.0.1i\include
1063
-SSLLIBDIR = $(B)\compat\openssl-1.0.1i\out32
1069
+SSLDIR = $(B)\compat\openssl-1.0.1i
1070
+SSLINCDIR = $(SSLDIR)\include
1071
+SSLLIBDIR = $(SSLDIR)\out32
10641072
SSLLIB = ssleay32.lib libeay32.lib user32.lib gdi32.lib
10651073
!endif
10661074
10671075
!ifdef FOSSIL_ENABLE_TCL
10681076
TCLDIR = $(B)\compat\tcl-8.6
@@ -1158,21 +1166,39 @@
11581166
writeln -nonewline "\$(OX)\\$s\$O"; incr i
11591167
}
11601168
writeln " \\"
11611169
writeln -nonewline " \$(OX)\\fossil.res\n\n"
11621170
writeln {
1163
-APPNAME = $(OX)\fossil$(E)
1164
-PDBNAME = $(OX)\fossil$(P)
1171
+APPNAME = $(OX)\fossil$(E)
1172
+PDBNAME = $(OX)\fossil$(P)
1173
+APPTARGETS =
11651174
11661175
all: $(OX) $(APPNAME)
11671176
11681177
zlib:
11691178
@echo Building zlib from "$(ZLIBDIR)"...
1170
- @pushd "$(ZLIBDIR)" && nmake /f win32\Makefile.msc $(ZLIB) && popd
1179
+ @pushd "$(ZLIBDIR)" && $(MAKE) /f win32\Makefile.msc $(ZLIB) && popd
1180
+
1181
+!ifdef FOSSIL_ENABLE_SSL
1182
+openssl:
1183
+ @echo Building OpenSSL from "$(SSLDIR)"...
1184
+!if "$(PERLDIR)" != ""
1185
+ @set PATH=$(PERLDIR);$(PATH)
1186
+!endif
1187
+ @pushd "$(SSLDIR)" && $(PERL) Configure VC-WIN32 no-asm && popd
1188
+ @pushd "$(SSLDIR)" && call ms\do_ms.bat && popd
1189
+ @pushd "$(SSLDIR)" && $(MAKE) /f ms\nt.mak all && popd
1190
+!endif
1191
+
1192
+APPTARGETS = $(APPTARGETS) zlib
1193
+
1194
+!ifdef FOSSIL_ENABLE_SSL
1195
+APPTARGETS = $(APPTARGETS) openssl
1196
+!endif
11711197
1172
-$(APPNAME) : translate$E mkindex$E headers $(OBJ) $(OX)\linkopts zlib
1173
- cd $(OX)
1198
+$(APPNAME) : translate$E mkindex$E headers $(OBJ) $(OX)\linkopts $(APPTARGETS)
1199
+ cd $(OX)
11741200
link $(LDFLAGS) /OUT:$@ $(LIBDIR) Wsetargv.obj fossil.res @linkopts
11751201
11761202
$(OX)\linkopts: $B\win\Makefile.msc}
11771203
set redir {>}
11781204
foreach s [lsort [concat $src $AdditionalObj]] {
@@ -1215,11 +1241,11 @@
12151241
VERSION.h : mkversion$E $B\manifest.uuid $B\manifest $B\VERSION
12161242
$** > $@
12171243
$(OX)\cson_amalgamation$O : $(SRCDIR)\cson_amalgamation.c
12181244
$(TCC) /Fo$@ /c $**
12191245
1220
-page_index.h: mkindex$E $(SRC)
1246
+page_index.h: mkindex$E $(SRC)
12211247
$** > $@
12221248
12231249
clean:
12241250
-del $(OX)\*.obj
12251251
-del *.obj
@@ -1333,13 +1359,13 @@
13331359
# and
13341360
# PellesC 6.00.4
13351361
# gmake 3.80
13361362
# zlib sources 1.2.5
13371363
# Windows 7 Home Premium
1338
-#
1364
+#
13391365
1340
-#
1366
+#
13411367
PellesCDir=c:\Programme\PellesC
13421368
13431369
# Select between 32/64 bit code, default is 32 bit
13441370
#TARGETVERSION=64
13451371
13461372
--- src/makemake.tcl
+++ src/makemake.tcl
@@ -268,11 +268,11 @@
268
269 # The USE_SYSTEM_SQLITE variable may be undefined, set to 0, or set
270 # to 1. If it is set to 1, then there is no need to build or link
271 # the sqlite3.o object. Instead, the system sqlite will be linked
272 # using -lsqlite3.
273 SQLITE3_OBJ.1 =
274 SQLITE3_OBJ.0 = $(OBJDIR)/sqlite3.o
275 SQLITE3_OBJ. = $(SQLITE3_OBJ.0)
276
277 EXTRAOBJ = \
278 $(SQLITE3_OBJ.$(USE_SYSTEM_SQLITE)) \
@@ -286,14 +286,14 @@
286 $(TCC) -o $(APPNAME) $(OBJ) $(EXTRAOBJ) $(LIB)
287
288 # This rule prevents make from using its default rules to try build
289 # an executable named "manifest" out of the file named "manifest.c"
290 #
291 $(SRCDIR)/../manifest:
292 # noop
293
294 clean:
295 rm -rf $(OBJDIR)/* $(APPNAME)
296
297 }]
298
299 set mhargs {}
@@ -580,25 +580,30 @@
580 #### We add the -static option here so that we can build a static
581 # executable that will run in a chroot jail.
582 #
583 LIB = -static
584
585 # MinGW: If available, use the Unicode capable runtime startup code.
 
586 ifndef MINGW_IS_32BIT_ONLY
587 LIB += -municode
588 endif
589
 
 
590 ifdef USE_SYSTEM_SQLITE
591 LIB += -lsqlite3
592 endif
593
594 # OpenSSL: Add the necessary libraries required, if enabled.
 
595 ifdef FOSSIL_ENABLE_SSL
596 LIB += -lssl -lcrypto -lgdi32
597 endif
598
599 # Tcl: Add the necessary libraries required, if enabled.
 
600 ifdef FOSSIL_ENABLE_TCL
601 LIB += $(LIBTCL)
602 endif
603
604 #### Extra arguments for linking the finished binary. Fossil needs
@@ -921,11 +926,11 @@
921 APPNAME = $(OBJDIR)\fossil$(E)
922
923 all: $(APPNAME)
924
925 $(APPNAME) : translate$E mkindex$E headers $(OBJ) $(OBJDIR)\link
926 cd $(OBJDIR)
927 $(DMDIR)\bin\link @link
928
929 $(OBJDIR)\fossil.res: $B\win\fossil.rc
930 $(RC) $(RCFLAGS) -o$@ $**
931
@@ -970,11 +975,11 @@
970 cp $@ $@
971
972 VERSION.h : version$E $B\manifest.uuid $B\manifest $B\VERSION
973 +$** > $@
974
975 page_index.h: mkindex$E $(SRC)
976 +$** > $@
977
978 clean:
979 -del $(OBJDIR)\*.obj
980 -del *.obj *_.c *.h *.map
@@ -1033,17 +1038,19 @@
1033 #
1034 # This file is automatically generated. Instead of editing this
1035 # file, edit "makemake.tcl" then run "tclsh makemake.tcl"
1036 # to regenerate this file.
1037 #
1038 B = ..
1039 SRCDIR = $B\src
1040 OBJDIR = .
1041 OX = .
1042 O = .obj
1043 E = .exe
1044 P = .pdb
 
 
1045
1046 # Uncomment to enable debug symbols
1047 # DEBUG = 1
1048
1049 # Uncomment to enable JSON API
@@ -1057,12 +1064,13 @@
1057
1058 # Uncomment to enable Tcl support
1059 # FOSSIL_ENABLE_TCL = 1
1060
1061 !ifdef FOSSIL_ENABLE_SSL
1062 SSLINCDIR = $(B)\compat\openssl-1.0.1i\include
1063 SSLLIBDIR = $(B)\compat\openssl-1.0.1i\out32
 
1064 SSLLIB = ssleay32.lib libeay32.lib user32.lib gdi32.lib
1065 !endif
1066
1067 !ifdef FOSSIL_ENABLE_TCL
1068 TCLDIR = $(B)\compat\tcl-8.6
@@ -1158,21 +1166,39 @@
1158 writeln -nonewline "\$(OX)\\$s\$O"; incr i
1159 }
1160 writeln " \\"
1161 writeln -nonewline " \$(OX)\\fossil.res\n\n"
1162 writeln {
1163 APPNAME = $(OX)\fossil$(E)
1164 PDBNAME = $(OX)\fossil$(P)
 
1165
1166 all: $(OX) $(APPNAME)
1167
1168 zlib:
1169 @echo Building zlib from "$(ZLIBDIR)"...
1170 @pushd "$(ZLIBDIR)" && nmake /f win32\Makefile.msc $(ZLIB) && popd
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1171
1172 $(APPNAME) : translate$E mkindex$E headers $(OBJ) $(OX)\linkopts zlib
1173 cd $(OX)
1174 link $(LDFLAGS) /OUT:$@ $(LIBDIR) Wsetargv.obj fossil.res @linkopts
1175
1176 $(OX)\linkopts: $B\win\Makefile.msc}
1177 set redir {>}
1178 foreach s [lsort [concat $src $AdditionalObj]] {
@@ -1215,11 +1241,11 @@
1215 VERSION.h : mkversion$E $B\manifest.uuid $B\manifest $B\VERSION
1216 $** > $@
1217 $(OX)\cson_amalgamation$O : $(SRCDIR)\cson_amalgamation.c
1218 $(TCC) /Fo$@ /c $**
1219
1220 page_index.h: mkindex$E $(SRC)
1221 $** > $@
1222
1223 clean:
1224 -del $(OX)\*.obj
1225 -del *.obj
@@ -1333,13 +1359,13 @@
1333 # and
1334 # PellesC 6.00.4
1335 # gmake 3.80
1336 # zlib sources 1.2.5
1337 # Windows 7 Home Premium
1338 #
1339
1340 #
1341 PellesCDir=c:\Programme\PellesC
1342
1343 # Select between 32/64 bit code, default is 32 bit
1344 #TARGETVERSION=64
1345
1346
--- src/makemake.tcl
+++ src/makemake.tcl
@@ -268,11 +268,11 @@
268
269 # The USE_SYSTEM_SQLITE variable may be undefined, set to 0, or set
270 # to 1. If it is set to 1, then there is no need to build or link
271 # the sqlite3.o object. Instead, the system sqlite will be linked
272 # using -lsqlite3.
273 SQLITE3_OBJ.1 =
274 SQLITE3_OBJ.0 = $(OBJDIR)/sqlite3.o
275 SQLITE3_OBJ. = $(SQLITE3_OBJ.0)
276
277 EXTRAOBJ = \
278 $(SQLITE3_OBJ.$(USE_SYSTEM_SQLITE)) \
@@ -286,14 +286,14 @@
286 $(TCC) -o $(APPNAME) $(OBJ) $(EXTRAOBJ) $(LIB)
287
288 # This rule prevents make from using its default rules to try build
289 # an executable named "manifest" out of the file named "manifest.c"
290 #
291 $(SRCDIR)/../manifest:
292 # noop
293
294 clean:
295 rm -rf $(OBJDIR)/* $(APPNAME)
296
297 }]
298
299 set mhargs {}
@@ -580,25 +580,30 @@
580 #### We add the -static option here so that we can build a static
581 # executable that will run in a chroot jail.
582 #
583 LIB = -static
584
585 #### MinGW: If available, use the Unicode capable runtime startup code.
586 #
587 ifndef MINGW_IS_32BIT_ONLY
588 LIB += -municode
589 endif
590
591 #### SQLite: If enabled, use the system SQLite library.
592 #
593 ifdef USE_SYSTEM_SQLITE
594 LIB += -lsqlite3
595 endif
596
597 #### OpenSSL: Add the necessary libraries required, if enabled.
598 #
599 ifdef FOSSIL_ENABLE_SSL
600 LIB += -lssl -lcrypto -lgdi32
601 endif
602
603 #### Tcl: Add the necessary libraries required, if enabled.
604 #
605 ifdef FOSSIL_ENABLE_TCL
606 LIB += $(LIBTCL)
607 endif
608
609 #### Extra arguments for linking the finished binary. Fossil needs
@@ -921,11 +926,11 @@
926 APPNAME = $(OBJDIR)\fossil$(E)
927
928 all: $(APPNAME)
929
930 $(APPNAME) : translate$E mkindex$E headers $(OBJ) $(OBJDIR)\link
931 cd $(OBJDIR)
932 $(DMDIR)\bin\link @link
933
934 $(OBJDIR)\fossil.res: $B\win\fossil.rc
935 $(RC) $(RCFLAGS) -o$@ $**
936
@@ -970,11 +975,11 @@
975 cp $@ $@
976
977 VERSION.h : version$E $B\manifest.uuid $B\manifest $B\VERSION
978 +$** > $@
979
980 page_index.h: mkindex$E $(SRC)
981 +$** > $@
982
983 clean:
984 -del $(OBJDIR)\*.obj
985 -del *.obj *_.c *.h *.map
@@ -1033,17 +1038,19 @@
1038 #
1039 # This file is automatically generated. Instead of editing this
1040 # file, edit "makemake.tcl" then run "tclsh makemake.tcl"
1041 # to regenerate this file.
1042 #
1043 B = ..
1044 SRCDIR = $B\src
1045 OBJDIR = .
1046 OX = .
1047 O = .obj
1048 E = .exe
1049 P = .pdb
1050 PERLDIR =
1051 PERL = perl.exe
1052
1053 # Uncomment to enable debug symbols
1054 # DEBUG = 1
1055
1056 # Uncomment to enable JSON API
@@ -1057,12 +1064,13 @@
1064
1065 # Uncomment to enable Tcl support
1066 # FOSSIL_ENABLE_TCL = 1
1067
1068 !ifdef FOSSIL_ENABLE_SSL
1069 SSLDIR = $(B)\compat\openssl-1.0.1i
1070 SSLINCDIR = $(SSLDIR)\include
1071 SSLLIBDIR = $(SSLDIR)\out32
1072 SSLLIB = ssleay32.lib libeay32.lib user32.lib gdi32.lib
1073 !endif
1074
1075 !ifdef FOSSIL_ENABLE_TCL
1076 TCLDIR = $(B)\compat\tcl-8.6
@@ -1158,21 +1166,39 @@
1166 writeln -nonewline "\$(OX)\\$s\$O"; incr i
1167 }
1168 writeln " \\"
1169 writeln -nonewline " \$(OX)\\fossil.res\n\n"
1170 writeln {
1171 APPNAME = $(OX)\fossil$(E)
1172 PDBNAME = $(OX)\fossil$(P)
1173 APPTARGETS =
1174
1175 all: $(OX) $(APPNAME)
1176
1177 zlib:
1178 @echo Building zlib from "$(ZLIBDIR)"...
1179 @pushd "$(ZLIBDIR)" && $(MAKE) /f win32\Makefile.msc $(ZLIB) && popd
1180
1181 !ifdef FOSSIL_ENABLE_SSL
1182 openssl:
1183 @echo Building OpenSSL from "$(SSLDIR)"...
1184 !if "$(PERLDIR)" != ""
1185 @set PATH=$(PERLDIR);$(PATH)
1186 !endif
1187 @pushd "$(SSLDIR)" && $(PERL) Configure VC-WIN32 no-asm && popd
1188 @pushd "$(SSLDIR)" && call ms\do_ms.bat && popd
1189 @pushd "$(SSLDIR)" && $(MAKE) /f ms\nt.mak all && popd
1190 !endif
1191
1192 APPTARGETS = $(APPTARGETS) zlib
1193
1194 !ifdef FOSSIL_ENABLE_SSL
1195 APPTARGETS = $(APPTARGETS) openssl
1196 !endif
1197
1198 $(APPNAME) : translate$E mkindex$E headers $(OBJ) $(OX)\linkopts $(APPTARGETS)
1199 cd $(OX)
1200 link $(LDFLAGS) /OUT:$@ $(LIBDIR) Wsetargv.obj fossil.res @linkopts
1201
1202 $(OX)\linkopts: $B\win\Makefile.msc}
1203 set redir {>}
1204 foreach s [lsort [concat $src $AdditionalObj]] {
@@ -1215,11 +1241,11 @@
1241 VERSION.h : mkversion$E $B\manifest.uuid $B\manifest $B\VERSION
1242 $** > $@
1243 $(OX)\cson_amalgamation$O : $(SRCDIR)\cson_amalgamation.c
1244 $(TCC) /Fo$@ /c $**
1245
1246 page_index.h: mkindex$E $(SRC)
1247 $** > $@
1248
1249 clean:
1250 -del $(OX)\*.obj
1251 -del *.obj
@@ -1333,13 +1359,13 @@
1359 # and
1360 # PellesC 6.00.4
1361 # gmake 3.80
1362 # zlib sources 1.2.5
1363 # Windows 7 Home Premium
1364 #
1365
1366 #
1367 PellesCDir=c:\Programme\PellesC
1368
1369 # Select between 32/64 bit code, default is 32 bit
1370 #TARGETVERSION=64
1371
1372
+2 -2
--- src/tag.c
+++ src/tag.c
@@ -354,11 +354,11 @@
354354
**
355355
** List all objects that use TAGNAME. TYPE can be "ci" for
356356
** checkins or "e" for events. The limit option limits the number
357357
** of results to the given value.
358358
**
359
-** %fossil tag list ?--raw? ?CHECK-IN?
359
+** %fossil tag list|ls ?--raw? ?CHECK-IN?
360360
**
361361
** List all tags, or if CHECK-IN is supplied, list
362362
** all tags and their values for CHECK-IN.
363363
**
364364
** The option --raw allows the manipulation of all types of tags
@@ -475,11 +475,11 @@
475475
db_finalize(&q);
476476
}
477477
}
478478
}else
479479
480
- if( strncmp(g.argv[2],"list",n)==0 ){
480
+ if(( strncmp(g.argv[2],"list",n)==0 )||( strncmp(g.argv[2],"ls",n)==0 )){
481481
Stmt q;
482482
if( g.argc==3 ){
483483
db_prepare(&q,
484484
"SELECT tagname FROM tag"
485485
" WHERE EXISTS(SELECT 1 FROM tagxref"
486486
487487
ADDED test/merge6.test
--- src/tag.c
+++ src/tag.c
@@ -354,11 +354,11 @@
354 **
355 ** List all objects that use TAGNAME. TYPE can be "ci" for
356 ** checkins or "e" for events. The limit option limits the number
357 ** of results to the given value.
358 **
359 ** %fossil tag list ?--raw? ?CHECK-IN?
360 **
361 ** List all tags, or if CHECK-IN is supplied, list
362 ** all tags and their values for CHECK-IN.
363 **
364 ** The option --raw allows the manipulation of all types of tags
@@ -475,11 +475,11 @@
475 db_finalize(&q);
476 }
477 }
478 }else
479
480 if( strncmp(g.argv[2],"list",n)==0 ){
481 Stmt q;
482 if( g.argc==3 ){
483 db_prepare(&q,
484 "SELECT tagname FROM tag"
485 " WHERE EXISTS(SELECT 1 FROM tagxref"
486
487 DDED test/merge6.test
--- src/tag.c
+++ src/tag.c
@@ -354,11 +354,11 @@
354 **
355 ** List all objects that use TAGNAME. TYPE can be "ci" for
356 ** checkins or "e" for events. The limit option limits the number
357 ** of results to the given value.
358 **
359 ** %fossil tag list|ls ?--raw? ?CHECK-IN?
360 **
361 ** List all tags, or if CHECK-IN is supplied, list
362 ** all tags and their values for CHECK-IN.
363 **
364 ** The option --raw allows the manipulation of all types of tags
@@ -475,11 +475,11 @@
475 db_finalize(&q);
476 }
477 }
478 }else
479
480 if(( strncmp(g.argv[2],"list",n)==0 )||( strncmp(g.argv[2],"ls",n)==0 )){
481 Stmt q;
482 if( g.argc==3 ){
483 db_prepare(&q,
484 "SELECT tagname FROM tag"
485 " WHERE EXISTS(SELECT 1 FROM tagxref"
486
487 DDED test/merge6.test
--- a/test/merge6.test
+++ b/test/merge6.test
@@ -0,0 +1,59 @@
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
+# Tests of the "merge" command
19
+#
20
+
21
+####################################################################
22
+# TEST 1: Handle multiple merges each with one or more ADDED files #
23
+###########################################repo_init###############
24
+
25
+test_setup
26
+fossil ls
27
+
28
+test merge_multi-0 {[string map [list \r\_multi-0 {[normalize_result] eq {}}
29
+
30
+write_file f1 "f1 line"
31
+fossil add f1
32
+fossil string map [list \r\_multi-1 {[normalize_result] eq {f1}}
33
+
34
+fossil update trunk
35
+write_file f2 "f2 line"
36
+fossil add f2
37
+fossil commit -m "branch for file f2" -b branch_for_f2
38
+fossistring map [list \r\] eq {f1
39
+f2}}
40
+
41
+fossil update trunk
42
+write_file f3 "f3 line"
43
+write_file f4 "f4 line"
44
+fossil add f3
45
+fossil add f4
46
+fossil commit -m "branch for files f3 and f4" -b branch_for_f3_f4
47
+fossil ls
48
+
49
+test merge_multi-3 {[string map [list \r\_multi-3 {[normalize_result] eq {f1
50
+f3
51
+f4}}
52
+
53
+fossil update trunk
54
+fossil merge branch_for_f2
55
+fossil merge branch_for_f3_f4
56
+fossil commit -m "new trunk files f2, string map [list \r\n \n] [string trim $RESULT]] eq {f1
57
+f2
58
+f3
59
+f4}}
--- a/test/merge6.test
+++ b/test/merge6.test
@@ -0,0 +1,59 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
--- a/test/merge6.test
+++ b/test/merge6.test
@@ -0,0 +1,59 @@
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 # Tests of the "merge" command
19 #
20
21 ####################################################################
22 # TEST 1: Handle multiple merges each with one or more ADDED files #
23 ###########################################repo_init###############
24
25 test_setup
26 fossil ls
27
28 test merge_multi-0 {[string map [list \r\_multi-0 {[normalize_result] eq {}}
29
30 write_file f1 "f1 line"
31 fossil add f1
32 fossil string map [list \r\_multi-1 {[normalize_result] eq {f1}}
33
34 fossil update trunk
35 write_file f2 "f2 line"
36 fossil add f2
37 fossil commit -m "branch for file f2" -b branch_for_f2
38 fossistring map [list \r\] eq {f1
39 f2}}
40
41 fossil update trunk
42 write_file f3 "f3 line"
43 write_file f4 "f4 line"
44 fossil add f3
45 fossil add f4
46 fossil commit -m "branch for files f3 and f4" -b branch_for_f3_f4
47 fossil ls
48
49 test merge_multi-3 {[string map [list \r\_multi-3 {[normalize_result] eq {f1
50 f3
51 f4}}
52
53 fossil update trunk
54 fossil merge branch_for_f2
55 fossil merge branch_for_f3_f4
56 fossil commit -m "new trunk files f2, string map [list \r\n \n] [string trim $RESULT]] eq {f1
57 f2
58 f3
59 f4}}
--- win/Makefile.PellesCGMake
+++ win/Makefile.PellesCGMake
@@ -30,13 +30,13 @@
3030
# and
3131
# PellesC 6.00.4
3232
# gmake 3.80
3333
# zlib sources 1.2.5
3434
# Windows 7 Home Premium
35
-#
35
+#
3636
37
-#
37
+#
3838
PellesCDir=c:\Programme\PellesC
3939
4040
# Select between 32/64 bit code, default is 32 bit
4141
#TARGETVERSION=64
4242
4343
--- win/Makefile.PellesCGMake
+++ win/Makefile.PellesCGMake
@@ -30,13 +30,13 @@
30 # and
31 # PellesC 6.00.4
32 # gmake 3.80
33 # zlib sources 1.2.5
34 # Windows 7 Home Premium
35 #
36
37 #
38 PellesCDir=c:\Programme\PellesC
39
40 # Select between 32/64 bit code, default is 32 bit
41 #TARGETVERSION=64
42
43
--- win/Makefile.PellesCGMake
+++ win/Makefile.PellesCGMake
@@ -30,13 +30,13 @@
30 # and
31 # PellesC 6.00.4
32 # gmake 3.80
33 # zlib sources 1.2.5
34 # Windows 7 Home Premium
35 #
36
37 #
38 PellesCDir=c:\Programme\PellesC
39
40 # Select between 32/64 bit code, default is 32 bit
41 #TARGETVERSION=64
42
43
--- win/Makefile.dmc
+++ win/Makefile.dmc
@@ -41,11 +41,11 @@
4141
APPNAME = $(OBJDIR)\fossil$(E)
4242
4343
all: $(APPNAME)
4444
4545
$(APPNAME) : translate$E mkindex$E headers $(OBJ) $(OBJDIR)\link
46
- cd $(OBJDIR)
46
+ cd $(OBJDIR)
4747
$(DMDIR)\bin\link @link
4848
4949
$(OBJDIR)\fossil.res: $B\win\fossil.rc
5050
$(RC) $(RCFLAGS) -o$@ $**
5151
@@ -85,11 +85,11 @@
8585
cp $@ $@
8686
8787
VERSION.h : version$E $B\manifest.uuid $B\manifest $B\VERSION
8888
+$** > $@
8989
90
-page_index.h: mkindex$E $(SRC)
90
+page_index.h: mkindex$E $(SRC)
9191
+$** > $@
9292
9393
clean:
9494
-del $(OBJDIR)\*.obj
9595
-del *.obj *_.c *.h *.map
9696
--- win/Makefile.dmc
+++ win/Makefile.dmc
@@ -41,11 +41,11 @@
41 APPNAME = $(OBJDIR)\fossil$(E)
42
43 all: $(APPNAME)
44
45 $(APPNAME) : translate$E mkindex$E headers $(OBJ) $(OBJDIR)\link
46 cd $(OBJDIR)
47 $(DMDIR)\bin\link @link
48
49 $(OBJDIR)\fossil.res: $B\win\fossil.rc
50 $(RC) $(RCFLAGS) -o$@ $**
51
@@ -85,11 +85,11 @@
85 cp $@ $@
86
87 VERSION.h : version$E $B\manifest.uuid $B\manifest $B\VERSION
88 +$** > $@
89
90 page_index.h: mkindex$E $(SRC)
91 +$** > $@
92
93 clean:
94 -del $(OBJDIR)\*.obj
95 -del *.obj *_.c *.h *.map
96
--- win/Makefile.dmc
+++ win/Makefile.dmc
@@ -41,11 +41,11 @@
41 APPNAME = $(OBJDIR)\fossil$(E)
42
43 all: $(APPNAME)
44
45 $(APPNAME) : translate$E mkindex$E headers $(OBJ) $(OBJDIR)\link
46 cd $(OBJDIR)
47 $(DMDIR)\bin\link @link
48
49 $(OBJDIR)\fossil.res: $B\win\fossil.rc
50 $(RC) $(RCFLAGS) -o$@ $**
51
@@ -85,11 +85,11 @@
85 cp $@ $@
86
87 VERSION.h : version$E $B\manifest.uuid $B\manifest $B\VERSION
88 +$** > $@
89
90 page_index.h: mkindex$E $(SRC)
91 +$** > $@
92
93 clean:
94 -del $(OBJDIR)\*.obj
95 -del *.obj *_.c *.h *.map
96
--- win/Makefile.mingw
+++ win/Makefile.mingw
@@ -216,25 +216,30 @@
216216
#### We add the -static option here so that we can build a static
217217
# executable that will run in a chroot jail.
218218
#
219219
LIB = -static
220220
221
-# MinGW: If available, use the Unicode capable runtime startup code.
221
+#### MinGW: If available, use the Unicode capable runtime startup code.
222
+#
222223
ifndef MINGW_IS_32BIT_ONLY
223224
LIB += -municode
224225
endif
225226
227
+#### SQLite: If enabled, use the system SQLite library.
228
+#
226229
ifdef USE_SYSTEM_SQLITE
227230
LIB += -lsqlite3
228231
endif
229232
230
-# OpenSSL: Add the necessary libraries required, if enabled.
233
+#### OpenSSL: Add the necessary libraries required, if enabled.
234
+#
231235
ifdef FOSSIL_ENABLE_SSL
232236
LIB += -lssl -lcrypto -lgdi32
233237
endif
234238
235
-# Tcl: Add the necessary libraries required, if enabled.
239
+#### Tcl: Add the necessary libraries required, if enabled.
240
+#
236241
ifdef FOSSIL_ENABLE_TCL
237242
LIB += $(LIBTCL)
238243
endif
239244
240245
#### Extra arguments for linking the finished binary. Fossil needs
241246
--- win/Makefile.mingw
+++ win/Makefile.mingw
@@ -216,25 +216,30 @@
216 #### We add the -static option here so that we can build a static
217 # executable that will run in a chroot jail.
218 #
219 LIB = -static
220
221 # MinGW: If available, use the Unicode capable runtime startup code.
 
222 ifndef MINGW_IS_32BIT_ONLY
223 LIB += -municode
224 endif
225
 
 
226 ifdef USE_SYSTEM_SQLITE
227 LIB += -lsqlite3
228 endif
229
230 # OpenSSL: Add the necessary libraries required, if enabled.
 
231 ifdef FOSSIL_ENABLE_SSL
232 LIB += -lssl -lcrypto -lgdi32
233 endif
234
235 # Tcl: Add the necessary libraries required, if enabled.
 
236 ifdef FOSSIL_ENABLE_TCL
237 LIB += $(LIBTCL)
238 endif
239
240 #### Extra arguments for linking the finished binary. Fossil needs
241
--- win/Makefile.mingw
+++ win/Makefile.mingw
@@ -216,25 +216,30 @@
216 #### We add the -static option here so that we can build a static
217 # executable that will run in a chroot jail.
218 #
219 LIB = -static
220
221 #### MinGW: If available, use the Unicode capable runtime startup code.
222 #
223 ifndef MINGW_IS_32BIT_ONLY
224 LIB += -municode
225 endif
226
227 #### SQLite: If enabled, use the system SQLite library.
228 #
229 ifdef USE_SYSTEM_SQLITE
230 LIB += -lsqlite3
231 endif
232
233 #### OpenSSL: Add the necessary libraries required, if enabled.
234 #
235 ifdef FOSSIL_ENABLE_SSL
236 LIB += -lssl -lcrypto -lgdi32
237 endif
238
239 #### Tcl: Add the necessary libraries required, if enabled.
240 #
241 ifdef FOSSIL_ENABLE_TCL
242 LIB += $(LIBTCL)
243 endif
244
245 #### Extra arguments for linking the finished binary. Fossil needs
246
--- win/Makefile.mingw.mistachkin
+++ win/Makefile.mingw.mistachkin
@@ -216,25 +216,30 @@
216216
#### We add the -static option here so that we can build a static
217217
# executable that will run in a chroot jail.
218218
#
219219
LIB = -static
220220
221
-# MinGW: If available, use the Unicode capable runtime startup code.
221
+#### MinGW: If available, use the Unicode capable runtime startup code.
222
+#
222223
ifndef MINGW_IS_32BIT_ONLY
223224
LIB += -municode
224225
endif
225226
227
+#### SQLite: If enabled, use the system SQLite library.
228
+#
226229
ifdef USE_SYSTEM_SQLITE
227230
LIB += -lsqlite3
228231
endif
229232
230
-# OpenSSL: Add the necessary libraries required, if enabled.
233
+#### OpenSSL: Add the necessary libraries required, if enabled.
234
+#
231235
ifdef FOSSIL_ENABLE_SSL
232236
LIB += -lssl -lcrypto -lgdi32
233237
endif
234238
235
-# Tcl: Add the necessary libraries required, if enabled.
239
+#### Tcl: Add the necessary libraries required, if enabled.
240
+#
236241
ifdef FOSSIL_ENABLE_TCL
237242
LIB += $(LIBTCL)
238243
endif
239244
240245
#### Extra arguments for linking the finished binary. Fossil needs
241246
--- win/Makefile.mingw.mistachkin
+++ win/Makefile.mingw.mistachkin
@@ -216,25 +216,30 @@
216 #### We add the -static option here so that we can build a static
217 # executable that will run in a chroot jail.
218 #
219 LIB = -static
220
221 # MinGW: If available, use the Unicode capable runtime startup code.
 
222 ifndef MINGW_IS_32BIT_ONLY
223 LIB += -municode
224 endif
225
 
 
226 ifdef USE_SYSTEM_SQLITE
227 LIB += -lsqlite3
228 endif
229
230 # OpenSSL: Add the necessary libraries required, if enabled.
 
231 ifdef FOSSIL_ENABLE_SSL
232 LIB += -lssl -lcrypto -lgdi32
233 endif
234
235 # Tcl: Add the necessary libraries required, if enabled.
 
236 ifdef FOSSIL_ENABLE_TCL
237 LIB += $(LIBTCL)
238 endif
239
240 #### Extra arguments for linking the finished binary. Fossil needs
241
--- win/Makefile.mingw.mistachkin
+++ win/Makefile.mingw.mistachkin
@@ -216,25 +216,30 @@
216 #### We add the -static option here so that we can build a static
217 # executable that will run in a chroot jail.
218 #
219 LIB = -static
220
221 #### MinGW: If available, use the Unicode capable runtime startup code.
222 #
223 ifndef MINGW_IS_32BIT_ONLY
224 LIB += -municode
225 endif
226
227 #### SQLite: If enabled, use the system SQLite library.
228 #
229 ifdef USE_SYSTEM_SQLITE
230 LIB += -lsqlite3
231 endif
232
233 #### OpenSSL: Add the necessary libraries required, if enabled.
234 #
235 ifdef FOSSIL_ENABLE_SSL
236 LIB += -lssl -lcrypto -lgdi32
237 endif
238
239 #### Tcl: Add the necessary libraries required, if enabled.
240 #
241 ifdef FOSSIL_ENABLE_TCL
242 LIB += $(LIBTCL)
243 endif
244
245 #### Extra arguments for linking the finished binary. Fossil needs
246
+36 -15
--- win/Makefile.msc
+++ win/Makefile.msc
@@ -5,17 +5,19 @@
55
#
66
# This file is automatically generated. Instead of editing this
77
# file, edit "makemake.tcl" then run "tclsh makemake.tcl"
88
# to regenerate this file.
99
#
10
-B = ..
11
-SRCDIR = $B\src
12
-OBJDIR = .
13
-OX = .
14
-O = .obj
15
-E = .exe
16
-P = .pdb
10
+B = ..
11
+SRCDIR = $B\src
12
+OBJDIR = .
13
+OX = .
14
+O = .obj
15
+E = .exe
16
+P = .pdb
17
+PERLDIR =
18
+PERL = perl.exe
1719
1820
# Uncomment to enable debug symbols
1921
# DEBUG = 1
2022
2123
# Uncomment to enable JSON API
@@ -29,12 +31,13 @@
2931
3032
# Uncomment to enable Tcl support
3133
# FOSSIL_ENABLE_TCL = 1
3234
3335
!ifdef FOSSIL_ENABLE_SSL
34
-SSLINCDIR = $(B)\compat\openssl-1.0.1i\include
35
-SSLLIBDIR = $(B)\compat\openssl-1.0.1i\out32
36
+SSLDIR = $(B)\compat\openssl-1.0.1i
37
+SSLINCDIR = $(SSLDIR)\include
38
+SSLLIBDIR = $(SSLDIR)\out32
3639
SSLLIB = ssleay32.lib libeay32.lib user32.lib gdi32.lib
3740
!endif
3841
3942
!ifdef FOSSIL_ENABLE_TCL
4043
TCLDIR = $(B)\compat\tcl-8.6
@@ -349,21 +352,39 @@
349352
$(OX)\xfersetup$O \
350353
$(OX)\zip$O \
351354
$(OX)\fossil.res
352355
353356
354
-APPNAME = $(OX)\fossil$(E)
355
-PDBNAME = $(OX)\fossil$(P)
357
+APPNAME = $(OX)\fossil$(E)
358
+PDBNAME = $(OX)\fossil$(P)
359
+APPTARGETS =
356360
357361
all: $(OX) $(APPNAME)
358362
359363
zlib:
360364
@echo Building zlib from "$(ZLIBDIR)"...
361
- @pushd "$(ZLIBDIR)" && nmake /f win32\Makefile.msc $(ZLIB) && popd
365
+ @pushd "$(ZLIBDIR)" && $(MAKE) /f win32\Makefile.msc $(ZLIB) && popd
362366
363
-$(APPNAME) : translate$E mkindex$E headers $(OBJ) $(OX)\linkopts zlib
364
- cd $(OX)
367
+!ifdef FOSSIL_ENABLE_SSL
368
+openssl:
369
+ @echo Building OpenSSL from "$(SSLDIR)"...
370
+!if "$(PERLDIR)" != ""
371
+ @set PATH=$(PERLDIR);$(PATH)
372
+!endif
373
+ @pushd "$(SSLDIR)" && $(PERL) Configure VC-WIN32 no-asm && popd
374
+ @pushd "$(SSLDIR)" && call ms\do_ms.bat && popd
375
+ @pushd "$(SSLDIR)" && $(MAKE) /f ms\nt.mak all && popd
376
+!endif
377
+
378
+APPTARGETS = $(APPTARGETS) zlib
379
+
380
+!ifdef FOSSIL_ENABLE_SSL
381
+APPTARGETS = $(APPTARGETS) openssl
382
+!endif
383
+
384
+$(APPNAME) : translate$E mkindex$E headers $(OBJ) $(OX)\linkopts $(APPTARGETS)
385
+ cd $(OX)
365386
link $(LDFLAGS) /OUT:$@ $(LIBDIR) Wsetargv.obj fossil.res @linkopts
366387
367388
$(OX)\linkopts: $B\win\Makefile.msc
368389
echo $(OX)\add.obj > $@
369390
echo $(OX)\allrepo.obj >> $@
@@ -517,11 +538,11 @@
517538
VERSION.h : mkversion$E $B\manifest.uuid $B\manifest $B\VERSION
518539
$** > $@
519540
$(OX)\cson_amalgamation$O : $(SRCDIR)\cson_amalgamation.c
520541
$(TCC) /Fo$@ /c $**
521542
522
-page_index.h: mkindex$E $(SRC)
543
+page_index.h: mkindex$E $(SRC)
523544
$** > $@
524545
525546
clean:
526547
-del $(OX)\*.obj
527548
-del *.obj
528549
--- win/Makefile.msc
+++ win/Makefile.msc
@@ -5,17 +5,19 @@
5 #
6 # This file is automatically generated. Instead of editing this
7 # file, edit "makemake.tcl" then run "tclsh makemake.tcl"
8 # to regenerate this file.
9 #
10 B = ..
11 SRCDIR = $B\src
12 OBJDIR = .
13 OX = .
14 O = .obj
15 E = .exe
16 P = .pdb
 
 
17
18 # Uncomment to enable debug symbols
19 # DEBUG = 1
20
21 # Uncomment to enable JSON API
@@ -29,12 +31,13 @@
29
30 # Uncomment to enable Tcl support
31 # FOSSIL_ENABLE_TCL = 1
32
33 !ifdef FOSSIL_ENABLE_SSL
34 SSLINCDIR = $(B)\compat\openssl-1.0.1i\include
35 SSLLIBDIR = $(B)\compat\openssl-1.0.1i\out32
 
36 SSLLIB = ssleay32.lib libeay32.lib user32.lib gdi32.lib
37 !endif
38
39 !ifdef FOSSIL_ENABLE_TCL
40 TCLDIR = $(B)\compat\tcl-8.6
@@ -349,21 +352,39 @@
349 $(OX)\xfersetup$O \
350 $(OX)\zip$O \
351 $(OX)\fossil.res
352
353
354 APPNAME = $(OX)\fossil$(E)
355 PDBNAME = $(OX)\fossil$(P)
 
356
357 all: $(OX) $(APPNAME)
358
359 zlib:
360 @echo Building zlib from "$(ZLIBDIR)"...
361 @pushd "$(ZLIBDIR)" && nmake /f win32\Makefile.msc $(ZLIB) && popd
362
363 $(APPNAME) : translate$E mkindex$E headers $(OBJ) $(OX)\linkopts zlib
364 cd $(OX)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
365 link $(LDFLAGS) /OUT:$@ $(LIBDIR) Wsetargv.obj fossil.res @linkopts
366
367 $(OX)\linkopts: $B\win\Makefile.msc
368 echo $(OX)\add.obj > $@
369 echo $(OX)\allrepo.obj >> $@
@@ -517,11 +538,11 @@
517 VERSION.h : mkversion$E $B\manifest.uuid $B\manifest $B\VERSION
518 $** > $@
519 $(OX)\cson_amalgamation$O : $(SRCDIR)\cson_amalgamation.c
520 $(TCC) /Fo$@ /c $**
521
522 page_index.h: mkindex$E $(SRC)
523 $** > $@
524
525 clean:
526 -del $(OX)\*.obj
527 -del *.obj
528
--- win/Makefile.msc
+++ win/Makefile.msc
@@ -5,17 +5,19 @@
5 #
6 # This file is automatically generated. Instead of editing this
7 # file, edit "makemake.tcl" then run "tclsh makemake.tcl"
8 # to regenerate this file.
9 #
10 B = ..
11 SRCDIR = $B\src
12 OBJDIR = .
13 OX = .
14 O = .obj
15 E = .exe
16 P = .pdb
17 PERLDIR =
18 PERL = perl.exe
19
20 # Uncomment to enable debug symbols
21 # DEBUG = 1
22
23 # Uncomment to enable JSON API
@@ -29,12 +31,13 @@
31
32 # Uncomment to enable Tcl support
33 # FOSSIL_ENABLE_TCL = 1
34
35 !ifdef FOSSIL_ENABLE_SSL
36 SSLDIR = $(B)\compat\openssl-1.0.1i
37 SSLINCDIR = $(SSLDIR)\include
38 SSLLIBDIR = $(SSLDIR)\out32
39 SSLLIB = ssleay32.lib libeay32.lib user32.lib gdi32.lib
40 !endif
41
42 !ifdef FOSSIL_ENABLE_TCL
43 TCLDIR = $(B)\compat\tcl-8.6
@@ -349,21 +352,39 @@
352 $(OX)\xfersetup$O \
353 $(OX)\zip$O \
354 $(OX)\fossil.res
355
356
357 APPNAME = $(OX)\fossil$(E)
358 PDBNAME = $(OX)\fossil$(P)
359 APPTARGETS =
360
361 all: $(OX) $(APPNAME)
362
363 zlib:
364 @echo Building zlib from "$(ZLIBDIR)"...
365 @pushd "$(ZLIBDIR)" && $(MAKE) /f win32\Makefile.msc $(ZLIB) && popd
366
367 !ifdef FOSSIL_ENABLE_SSL
368 openssl:
369 @echo Building OpenSSL from "$(SSLDIR)"...
370 !if "$(PERLDIR)" != ""
371 @set PATH=$(PERLDIR);$(PATH)
372 !endif
373 @pushd "$(SSLDIR)" && $(PERL) Configure VC-WIN32 no-asm && popd
374 @pushd "$(SSLDIR)" && call ms\do_ms.bat && popd
375 @pushd "$(SSLDIR)" && $(MAKE) /f ms\nt.mak all && popd
376 !endif
377
378 APPTARGETS = $(APPTARGETS) zlib
379
380 !ifdef FOSSIL_ENABLE_SSL
381 APPTARGETS = $(APPTARGETS) openssl
382 !endif
383
384 $(APPNAME) : translate$E mkindex$E headers $(OBJ) $(OX)\linkopts $(APPTARGETS)
385 cd $(OX)
386 link $(LDFLAGS) /OUT:$@ $(LIBDIR) Wsetargv.obj fossil.res @linkopts
387
388 $(OX)\linkopts: $B\win\Makefile.msc
389 echo $(OX)\add.obj > $@
390 echo $(OX)\allrepo.obj >> $@
@@ -517,11 +538,11 @@
538 VERSION.h : mkversion$E $B\manifest.uuid $B\manifest $B\VERSION
539 $** > $@
540 $(OX)\cson_amalgamation$O : $(SRCDIR)\cson_amalgamation.c
541 $(TCC) /Fo$@ /c $**
542
543 page_index.h: mkindex$E $(SRC)
544 $** > $@
545
546 clean:
547 -del $(OX)\*.obj
548 -del *.obj
549
+3 -3
--- win/fossil.rc
+++ win/fossil.rc
@@ -105,11 +105,11 @@
105105
#endif /* defined(FOSSIL_ENABLE_SSL) */
106106
#if defined(FOSSIL_ENABLE_TH1_HOOKS)
107107
VALUE "Th1Hooks", "Yes\0"
108108
#else
109109
VALUE "Th1Hooks", "No\0"
110
-#endif
110
+#endif /* defined(FOSSIL_ENABLE_TH1_HOOKS) */
111111
#if defined(FOSSIL_ENABLE_TCL)
112112
VALUE "TclEnabled", "Yes, Tcl " TCL_PATCH_LEVEL "\0"
113113
#if defined(USE_TCL_STUBS)
114114
VALUE "UseTclStubsEnabled", "Yes\0"
115115
#else
@@ -142,12 +142,12 @@
142142
* This embedded manifest is needed for Windows 8.1.
143143
*/
144144
145145
#ifndef RT_MANIFEST
146146
#define RT_MANIFEST 24
147
-#endif
147
+#endif /* RT_MANIFEST */
148148
149149
#ifndef CREATEPROCESS_MANIFEST_RESOURCE_ID
150150
#define CREATEPROCESS_MANIFEST_RESOURCE_ID 1
151
-#endif
151
+#endif /* CREATEPROCESS_MANIFEST_RESOURCE_ID */
152152
153153
CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST "fossil.exe.manifest"
154154
--- win/fossil.rc
+++ win/fossil.rc
@@ -105,11 +105,11 @@
105 #endif /* defined(FOSSIL_ENABLE_SSL) */
106 #if defined(FOSSIL_ENABLE_TH1_HOOKS)
107 VALUE "Th1Hooks", "Yes\0"
108 #else
109 VALUE "Th1Hooks", "No\0"
110 #endif
111 #if defined(FOSSIL_ENABLE_TCL)
112 VALUE "TclEnabled", "Yes, Tcl " TCL_PATCH_LEVEL "\0"
113 #if defined(USE_TCL_STUBS)
114 VALUE "UseTclStubsEnabled", "Yes\0"
115 #else
@@ -142,12 +142,12 @@
142 * This embedded manifest is needed for Windows 8.1.
143 */
144
145 #ifndef RT_MANIFEST
146 #define RT_MANIFEST 24
147 #endif
148
149 #ifndef CREATEPROCESS_MANIFEST_RESOURCE_ID
150 #define CREATEPROCESS_MANIFEST_RESOURCE_ID 1
151 #endif
152
153 CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST "fossil.exe.manifest"
154
--- win/fossil.rc
+++ win/fossil.rc
@@ -105,11 +105,11 @@
105 #endif /* defined(FOSSIL_ENABLE_SSL) */
106 #if defined(FOSSIL_ENABLE_TH1_HOOKS)
107 VALUE "Th1Hooks", "Yes\0"
108 #else
109 VALUE "Th1Hooks", "No\0"
110 #endif /* defined(FOSSIL_ENABLE_TH1_HOOKS) */
111 #if defined(FOSSIL_ENABLE_TCL)
112 VALUE "TclEnabled", "Yes, Tcl " TCL_PATCH_LEVEL "\0"
113 #if defined(USE_TCL_STUBS)
114 VALUE "UseTclStubsEnabled", "Yes\0"
115 #else
@@ -142,12 +142,12 @@
142 * This embedded manifest is needed for Windows 8.1.
143 */
144
145 #ifndef RT_MANIFEST
146 #define RT_MANIFEST 24
147 #endif /* RT_MANIFEST */
148
149 #ifndef CREATEPROCESS_MANIFEST_RESOURCE_ID
150 #define CREATEPROCESS_MANIFEST_RESOURCE_ID 1
151 #endif /* CREATEPROCESS_MANIFEST_RESOURCE_ID */
152
153 CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST "fossil.exe.manifest"
154
+18 -4
--- www/build.wiki
+++ www/build.wiki
@@ -112,15 +112,29 @@
112112
"<b>make -f win/Makefile.mingw</b>". On a Windows box you will
113113
need either Cygwin or Msys as build environment. On Cygwin, Linux
114114
or Darwin you may want to make minor edits to win/Makefile.mingw
115115
to configure the cross-compile environment.
116116
117
-<li><p><i>MSVC</i> → Use the msc makefile. First
117
+<li><p><i>MSVC</i> → Use the MSVC makefile. First
118118
change to the "win/" subdirectory ("<b>cd win</b>") then run
119
-"<b>nmake /f Makefile.msc</b>". Alternatively, the batch file
120
-"<b>win\buildmsvc.bat</b>" may be used and it will attempt to
121
-detect and use the latest installed version of MSVC.
119
+"<b>nmake /f Makefile.msc</b>".<br><br>Alternatively, the batch
120
+file "<b>win\buildmsvc.bat</b>" may be used and it will attempt to
121
+detect and use the latest installed version of MSVC.<br><br>To enable
122
+the optional <a href="https://www.openssl.org/">OpenSSL</a> support,
123
+first <a href="https://www.openssl.org/source/">download the official
124
+source code for OpenSSL</a> and extract it to an appropriately named
125
+"<b>openssl-X.Y.ZA</b>" subdirectory within the local
126
+[/tree?ci=trunk&name=compat | compat] directory (e.g.
127
+"<b>compat/openssl-1.0.1i</b>"), then make sure that some recent
128
+<a href="http://www.perl.org/">Perl</a> binaries are installed locally,
129
+and finally run one of the following commands:
130
+<blockquote><pre>
131
+nmake /f Makefile.msc FOSSIL_ENABLE_SSL=1 PERLDIR=C:\full\path\to\Perl\bin
132
+</pre></blockquote>
133
+<blockquote><pre>
134
+buildmsvc.bat FOSSIL_ENABLE_SSL=1 PERLDIR=C:\full\path\to\Perl\bin
135
+</pre></blockquote>
122136
123137
<li><p><i>Cygwin</i> → The same as other unix-like systems. It is
124138
recommended to configure using: "<b>configure --disable-internal-sqlite</b>",
125139
making sure you have the "libsqlite3-devel" , "zlib-devel" and
126140
"openssl-devel" packages installed first.
127141
--- www/build.wiki
+++ www/build.wiki
@@ -112,15 +112,29 @@
112 "<b>make -f win/Makefile.mingw</b>". On a Windows box you will
113 need either Cygwin or Msys as build environment. On Cygwin, Linux
114 or Darwin you may want to make minor edits to win/Makefile.mingw
115 to configure the cross-compile environment.
116
117 <li><p><i>MSVC</i> → Use the msc makefile. First
118 change to the "win/" subdirectory ("<b>cd win</b>") then run
119 "<b>nmake /f Makefile.msc</b>". Alternatively, the batch file
120 "<b>win\buildmsvc.bat</b>" may be used and it will attempt to
121 detect and use the latest installed version of MSVC.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
122
123 <li><p><i>Cygwin</i> → The same as other unix-like systems. It is
124 recommended to configure using: "<b>configure --disable-internal-sqlite</b>",
125 making sure you have the "libsqlite3-devel" , "zlib-devel" and
126 "openssl-devel" packages installed first.
127
--- www/build.wiki
+++ www/build.wiki
@@ -112,15 +112,29 @@
112 "<b>make -f win/Makefile.mingw</b>". On a Windows box you will
113 need either Cygwin or Msys as build environment. On Cygwin, Linux
114 or Darwin you may want to make minor edits to win/Makefile.mingw
115 to configure the cross-compile environment.
116
117 <li><p><i>MSVC</i> → Use the MSVC makefile. First
118 change to the "win/" subdirectory ("<b>cd win</b>") then run
119 "<b>nmake /f Makefile.msc</b>".<br><br>Alternatively, the batch
120 file "<b>win\buildmsvc.bat</b>" may be used and it will attempt to
121 detect and use the latest installed version of MSVC.<br><br>To enable
122 the optional <a href="https://www.openssl.org/">OpenSSL</a> support,
123 first <a href="https://www.openssl.org/source/">download the official
124 source code for OpenSSL</a> and extract it to an appropriately named
125 "<b>openssl-X.Y.ZA</b>" subdirectory within the local
126 [/tree?ci=trunk&name=compat | compat] directory (e.g.
127 "<b>compat/openssl-1.0.1i</b>"), then make sure that some recent
128 <a href="http://www.perl.org/">Perl</a> binaries are installed locally,
129 and finally run one of the following commands:
130 <blockquote><pre>
131 nmake /f Makefile.msc FOSSIL_ENABLE_SSL=1 PERLDIR=C:\full\path\to\Perl\bin
132 </pre></blockquote>
133 <blockquote><pre>
134 buildmsvc.bat FOSSIL_ENABLE_SSL=1 PERLDIR=C:\full\path\to\Perl\bin
135 </pre></blockquote>
136
137 <li><p><i>Cygwin</i> → The same as other unix-like systems. It is
138 recommended to configure using: "<b>configure --disable-internal-sqlite</b>",
139 making sure you have the "libsqlite3-devel" , "zlib-devel" and
140 "openssl-devel" packages installed first.
141
--- www/changes.wiki
+++ www/changes.wiki
@@ -20,10 +20,12 @@
2020
* Let [/help?cmd=new|fossil new] no longer create an initial empty commit
2121
by default. The first commit after checking out an empty repository will
2222
become the initial commit. (NOT PLANNED FOR 1.30, BUT DONE TO EXPOSE
2323
[/help?cmd=new|fossil new --empty] TO MORE FIELD TESTING BEFORE
2424
MAKING ANY DECISION ON IT!)
25
+ * Added a line-number toggle option to the [/help?cmd=/info|/info]
26
+ and [/help?cmd=/artifact|/artifact] pages.
2527
2628
<h2>Changes For Version 1.29 (2014-06-12)</h2>
2729
* Add the ability to display content, diffs and annotations for UTF16
2830
text files in the web interface.
2931
* Add the "SaveAs..." and "Invert" buttons
3032
--- www/changes.wiki
+++ www/changes.wiki
@@ -20,10 +20,12 @@
20 * Let [/help?cmd=new|fossil new] no longer create an initial empty commit
21 by default. The first commit after checking out an empty repository will
22 become the initial commit. (NOT PLANNED FOR 1.30, BUT DONE TO EXPOSE
23 [/help?cmd=new|fossil new --empty] TO MORE FIELD TESTING BEFORE
24 MAKING ANY DECISION ON IT!)
 
 
25
26 <h2>Changes For Version 1.29 (2014-06-12)</h2>
27 * Add the ability to display content, diffs and annotations for UTF16
28 text files in the web interface.
29 * Add the "SaveAs..." and "Invert" buttons
30
--- www/changes.wiki
+++ www/changes.wiki
@@ -20,10 +20,12 @@
20 * Let [/help?cmd=new|fossil new] no longer create an initial empty commit
21 by default. The first commit after checking out an empty repository will
22 become the initial commit. (NOT PLANNED FOR 1.30, BUT DONE TO EXPOSE
23 [/help?cmd=new|fossil new --empty] TO MORE FIELD TESTING BEFORE
24 MAKING ANY DECISION ON IT!)
25 * Added a line-number toggle option to the [/help?cmd=/info|/info]
26 and [/help?cmd=/artifact|/artifact] pages.
27
28 <h2>Changes For Version 1.29 (2014-06-12)</h2>
29 * Add the ability to display content, diffs and annotations for UTF16
30 text files in the web interface.
31 * Add the "SaveAs..." and "Invert" buttons
32

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button