Index: Makefile.in ================================================================== --- Makefile.in +++ Makefile.in @@ -34,11 +34,11 @@ TCC = @CC@ #### Tcl shell for use in running the fossil testsuite. If you do not # care about testing the end result, this can be blank. # -TCLSH = tclsh +TCLSH = @TCLSH@ CFLAGS = @CFLAGS@ LIB = @LDFLAGS@ @EXTRA_LDFLAGS@ @LIBS@ BCCFLAGS = @CPPFLAGS@ $(CFLAGS) TCCFLAGS = @EXTRA_CFLAGS@ @CPPFLAGS@ $(CFLAGS) -DHAVE_AUTOCONFIG_H -D_HAVE_SQLITE_CONFIG_H Index: auto.def ================================================================== --- auto.def +++ auto.def @@ -33,12 +33,47 @@ } # Use pread/pwrite system calls in place of seek + read/write if possible define USE_PREAD [cc-check-functions pread] -# Find tclsh for the test suite. Can't yet use jimsh for this. +# Find tclsh for the test suite. +# +# We can't use jimsh for this: the test suite uses features of Tcl that +# Jim doesn't support, either statically or due to the way it's built by +# autosetup. For example, Jim supports `file normalize`, but only if +# you build it with HAVE_REALPATH, which won't ever be defined in this +# context because autosetup doesn't try to discover platform-specific +# details like that before it decides to build jimsh0. Besides which, +# autosetup won't build jimsh0 at all if it can find tclsh itself. +# Ironically, this means we may right now be running under either jimsh0 +# or a version of tclsh that we find unsuitable below! cc-check-progs tclsh +set hbtd /usr/local/Cellar/tcl-tk +if {[string equal false [get-define TCLSH]]} { + msg-result "WARNING: 'make test' will not run here." +} else { + set v [exec /bin/sh -c "echo 'puts \$tcl_version' | tclsh"] + if {[expr $v >= 8.6]} { + msg-result "Found Tclsh version $v in the PATH." + define TCLSH tclsh + } elseif {[file isdirectory $hbtd]} { + # This is a macOS system with the Homebrew version of Tcl/Tk + # installed. Select the newest version. It won't normally be + # in the PATH to avoid shadowing /usr/bin/tclsh, and even if it + # were in the PATH, it's bad practice to put /usr/local/bin (the + # Homebrew default) ahead of /usr/bin, especially given that + # it's user-writeable by default with Homebrew. Thus, we can be + # pretty sure the only way to call it is with an absolute path. + set v [exec ls -tr $hbtd | tail -1] + set path "$hbtd/$v/bin/tclsh" + define TCLSH $path + msg-result "Using Homebrew Tcl/Tk version $path." + } else { + msg-result "WARNING: tclsh $v found; need >= 8.6 for 'make test'." + define TCLSH false ;# force "make test" failure via /usr/bin/false + } +} define EXTRA_CFLAGS "-Wall" define EXTRA_LDFLAGS "" define USE_SYSTEM_SQLITE 0 define USE_LINENOISE 0 Index: skins/ardoise/header.txt ================================================================== --- skins/ardoise/header.txt +++ skins/ardoise/header.txt @@ -41,10 +41,13 @@ menulink /dir?ci=tip Files } if {[hascap o]} { menulink /brlist Branches menulink /taglist Tags +} +if {[anycap 23456] || [anoncap 2] || [anoncap 3]} { + menulink /forum Forum } if {[hascap r]} { menulink /ticket Tickets } if {[hascap j]} { Index: skins/black_and_white/header.txt ================================================================== --- skins/black_and_white/header.txt +++ skins/black_and_white/header.txt @@ -22,10 +22,13 @@ html "Files\n" } if {[anoncap o]} { html "Branches\n" html "Tags\n" +} +if {[anycap 23456] || [anoncap 2] || [anoncap 3]} { + html "Forum\n" } if {[anoncap r]} { html "Tickets\n" } if {[anoncap j]} { Index: skins/blitz/header.txt ================================================================== --- skins/blitz/header.txt +++ skins/blitz/header.txt @@ -45,10 +45,13 @@ menulink /dir?ci=tip Files } if {[hascap o]} { menulink /brlist Branches menulink /taglist Tags +} +if {[anycap 23456] || [anoncap 2] || [anoncap 3]} { + menulink /forum Forum } if {[hascap r]} { menulink /ticket Tickets } if {[hascap j]} { Index: skins/blitz_no_logo/header.txt ================================================================== --- skins/blitz_no_logo/header.txt +++ skins/blitz_no_logo/header.txt @@ -42,10 +42,13 @@ menulink /dir?ci=tip Files } if {[hascap o]} { menulink /brlist Branches menulink /taglist Tags +} +if {[anycap 23456] || [anoncap 2] || [anoncap 3]} { + menulink /forum Forum } if {[hascap r]} { menulink /ticket Tickets } if {[hascap j]} { Index: skins/bootstrap/header.txt ================================================================== --- skins/bootstrap/header.txt +++ skins/bootstrap/header.txt @@ -77,10 +77,17 @@ if {[string compare $current_page "taglist"] == 0} { html "
  • Tags
  • \n" } else { html "
  • Tags
  • \n" } + } + if {[anycap 23456] || [anoncap 2] || [anoncap 3]} { + if {[string compare $current_page "forum"] == 0} { + html "
  • Forum
  • \n" + } else { + html "
  • Forum
  • \n" + } } if {[hascap r]} { if {[string compare $current_page "reportlist"] == 0} { html "
  • Tickets
  • \n" } else { Index: skins/default/css.txt ================================================================== --- skins/default/css.txt +++ skins/default/css.txt @@ -1,8 +1,7 @@ body { margin: 0 auto; - padding: 0px 20px; background-color: white; font-family: sans-serif; font-size:14pt; -moz-text-size-adjust: none; -webkit-text-size-adjust: none; @@ -15,20 +14,21 @@ } a:hover { color: #4183C4; text-decoration: underline; } +div.forumPosts a:visited { + color: #6A7F94; +} hr { color: #eee; } .title { color: #4183C4; float:left; - padding-top: 30px; - padding-bottom: 10px; } .title h1 { display:inline; } .title h1:after { @@ -72,39 +72,51 @@ } .status { float:right; font-size:.7em; - padding-top:50px; } .mainmenu { font-size:.8em; clear:both; - padding:10px; background:#eaeaea linear-gradient(#fafafa, #eaeaea) repeat-x; border:1px solid #eaeaea; border-radius:5px; overflow-x: auto; + overflow-y: hidden; white-space: nowrap; + z-index: 21; /* just above hbdrop */ } .mainmenu a { - padding: 10px 20px; text-decoration:none; color: #777; border-right:1px solid #eaeaea; } .mainmenu a.active, .mainmenu a:hover { color: #000; border-bottom:2px solid #D26911; } + +div#hbdrop { + background-color: white; + border: 1px solid black; + border-top: white; + border-radius: 0 0 0.5em 0.5em; + display: none; + font-size: 80%; + left: 2em; + width: 90%; + padding-right: 1em; + position: absolute; + z-index: 20; /* just below mainmenu, but above timeline bubbles */ +} .submenu { font-size: .7em; - margin-top: 10px; padding: 10px; border-bottom: 1px solid #ccc; } .submenu a, .submenu label { @@ -207,5 +219,51 @@ white-space: nowrap; } div.submenu label { white-space: nowrap; } + +@media screen and (max-width: 600px) { + /* Spacing for mobile */ + body { + padding-left: 4px; + padding-right: 4px; + } + .title { + padding-top: 0px; + padding-bottom: 0px; + } + .status {padding-top: 0px;} + .mainmenu a { + padding: 10px 10px; + } + .mainmenu { + padding: 10px; + } + .desktoponly { + display: none; + } +} +@media screen and (min-width: 600px) { + /* Spacing for desktop */ + body { + padding-left: 20px; + padding-right: 20px; + } + .title { + padding-top: 10px; + padding-bottom: 10px; + } + .status {padding-top: 30px;} + .mainmenu a { + padding: 10px 20px; + } + .mainmenu { + padding: 10px; + } +} +@media screen and (max-width: 1200px) { + /* Special declarations for narrow desktop or wide mobile */ + .wideonly { + display: none; + } +} Index: skins/default/footer.txt ================================================================== --- skins/default/footer.txt +++ skins/default/footer.txt @@ -1,5 +1,8 @@ + Index: skins/default/header.txt ================================================================== --- skins/default/header.txt +++ skins/default/header.txt @@ -8,37 +8,42 @@ } +
    ADDED skins/default/js.txt Index: skins/default/js.txt ================================================================== --- /dev/null +++ skins/default/js.txt @@ -0,0 +1,122 @@ +(function() { + var home='$home'; + var panel = document.getElementById("hbdrop"); + if (!panel) return; // site admin might've nuked it + var panelBorder = panel.style.border; + var animate = panel.style.hasOwnProperty('transition'); + var animMS = 400; + + // Calculate panel height despite its being hidden at call time. + // Based on https://stackoverflow.com/a/29047447/142454 + var panelHeight; // computed on sitemap load + function calculatePanelHeight() { + // Get initial panel styles so we can restore them below. + var es = window.getComputedStyle(panel), + edis = es.display, + epos = es.position, + evis = es.visibility; + + // Restyle the panel so we can measure its height while invisible. + panel.style.visibility = 'hidden'; + panel.style.position = 'absolute'; + panel.style.display = 'block'; + panelHeight = panel.offsetHeight + 'px'; + + // Revert styles now that job is done. + panel.style.display = edis; + panel.style.position = epos; + panel.style.visibility = evis; + } + + // Show the panel by changing the panel height, which kicks off the + // slide-open/closed transition set up in the XHR onload handler. + // + // Schedule the change for a near-future time in case this is the + // first call, where the div was initially invisible. That causes + // the browser to consider the height change as part of the same + // state change as the visibility change, so it doesn't see a state + // *transition*, hence never kicks off the *CSS* transition: + // + // https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Transitions/Using_CSS_transitions#JavaScript_examples + function showPanel() { + if (animate) { + setTimeout(function() { + panel.style.maxHeight = panelHeight; + panel.style.border = panelBorder; + }, 40); // 25ms is insufficient with Firefox 62 + } + else { + panel.style.display = 'block'; + } + } + + // Return true if the panel is showing. + function panelShowing() { + if (animate) { + return panel.style.maxHeight == panelHeight; + } + else { + return panel.style.display == 'block'; + } + } + + // Click handler for the hamburger button. + var needSitemapHTML = true; + document.querySelector("div.mainmenu > a").onclick = function() { + if (panelShowing()) { + // Transition back to hidden state. + if (animate) { + panel.style.maxHeight = '0'; + setTimeout(function() { + // Browsers show a 1px high border line when maxHeight == 0, + // our "hidden" state, so hide the borders in that state, too. + panel.style.border = 'none'; + }, animMS); + } + else { + panel.style.display = 'none'; + } + } + else if (needSitemapHTML) { + // Only get it once per page load: it isn't likely to + // change on us. + var xhr = new XMLHttpRequest(); + xhr.onload = function() { + var doc = xhr.responseXML; + if (doc) { + var sm = doc.querySelector("ul#sitemap"); + if (sm && xhr.status == 200) { + // Got sitemap. Insert it into the drop-down panel. + needSitemapHTML = false; + panel.innerHTML = sm.outerHTML; + if (window.setAllHrefs) { + setAllHrefs(); // don't need anti-robot defense here + } + + // Display the panel + if (animate) { + // Set up a CSS transition to animate the panel open and + // closed. Only needs to be done once per page load. + // Based on https://stackoverflow.com/a/29047447/142454 + calculatePanelHeight(); + panel.style.transition = 'max-height ' + + (animMS / 1000) + 's ease-in-out'; + panel.style.overflowY = 'hidden'; + panel.style.maxHeight = '0'; + showPanel(); + } + panel.style.display = 'block'; + } + } + // else, can't parse response as HTML or XML + } + xhr.open("POST", home + "/sitemap"); + xhr.responseType = "document"; + xhr.send("popup=1"); + } + else { + showPanel(); // just show what we built above + } + return false; // prevent browser from acting on click + } +})(); Index: skins/eagle/header.txt ================================================================== --- skins/eagle/header.txt +++ skins/eagle/header.txt @@ -71,11 +71,11 @@ } else { puts "Not logged in" }
    - - style_load_one_js_file("href.js"); + } + @ +} + +/* +** Extra JS to run after all content is loaded. +*/ +void style_js_onload(const char *zFormat, ...){ + va_list ap; + va_start(ap, zFormat); + blob_vappendf(&blobOnLoad, zFormat, ap); + va_end(ap); } /* ** Draw the footer at the bottom of the page. */ @@ -807,10 +855,29 @@ zSelector = g.argv[3]; found = containsSelector(blob_str(&css), zSelector); fossil_print("%s %s\n", zSelector, found ? "found" : "not found"); blob_reset(&css); } + +/* +** WEBPAGE: script.js +** +** Return the "Javascript" content for the current skin (if there is any) +*/ +void page_script_js(void){ + const char *zScript = skin_get("js"); + if( P("test") ){ + /* Render the script as plain-text for testing purposes, if the "test" + ** query parameter is present */ + cgi_set_content_type("text/plain"); + }else{ + /* Default behavior is to return javascript */ + cgi_set_content_type("application/javascript"); + } + style_init_th1_vars(0); + Th_Render(zScript?zScript:""); +} /* ** WEBPAGE: style.css ** Index: src/th_main.c ================================================================== --- src/th_main.c +++ src/th_main.c @@ -1300,10 +1300,38 @@ }else{ Th_SetResult(interp, "repository unavailable", -1); return TH_ERROR; } } + +/* +** TH1 command: styleScript +** +** Render the configured javascript for the selected skin +*/ +static int styleScriptCmd( + Th_Interp *interp, + void *p, + int argc, + const char **argv, + int *argl +){ + if( argc!=1 ){ + return Th_WrongNumArgs(interp, "styleScript"); + } + if( Th_IsRepositoryOpen() ){ + const char *zScript = skin_get("js"); + if( zScript==0 ) zScript = ""; + Th_Render(zScript); + Th_SetResult(interp, 0, 0); + return TH_OK; + }else{ + Th_SetResult(interp, "repository unavailable", -1); + return TH_ERROR; + } +} + /* ** TH1 command: artifact ID ?FILENAME? ** ** Attempts to locate the specified artifact and return its contents. An @@ -1984,12 +2012,13 @@ {"render", renderCmd, 0}, {"repository", repositoryCmd, 0}, {"searchable", searchableCmd, 0}, {"setParameter", setParameterCmd, 0}, {"setting", settingCmd, 0}, - {"styleHeader", styleHeaderCmd, 0}, {"styleFooter", styleFooterCmd, 0}, + {"styleHeader", styleHeaderCmd, 0}, + {"styleScript", styleScriptCmd, 0}, {"tclReady", tclReadyCmd, 0}, {"trace", traceCmd, 0}, {"stime", stimeCmd, 0}, {"unversioned", unversionedCmd, 0}, {"utime", utimeCmd, 0}, Index: test/commit-warning.test ================================================================== --- test/commit-warning.test +++ test/commit-warning.test @@ -161,146 +161,146 @@ # be fragile as development progresses. # # Unless the real goal of this test is to document a collection # of source files that MUST NEVER BE TEXT. # -run_in_checkout { +test_block_in_checkout pre-commit-warnings-fossil-1 { fossil test-commit-warning --no-settings -} - -test pre-commit-warnings-fossil-1 {[normalize_result] eq \ - [subst -nocommands -novariables [string trim { -1\tart/branching.odp\tbinary data -1\tart/concept1.dia\tbinary data -1\tart/concept2.dia\tbinary data -1\tcompat/zlib/contrib/blast/test.pk\tbinary data -1\tcompat/zlib/contrib/dotzlib/DotZLib.build\tCR/LF line endings -1\tcompat/zlib/contrib/dotzlib/DotZLib.chm\tbinary data -1\tcompat/zlib/contrib/dotzlib/DotZLib.sln\tCR/LF line endings -1\tcompat/zlib/contrib/dotzlib/DotZLib/AssemblyInfo.cs\tCR/LF line endings -1\tcompat/zlib/contrib/dotzlib/DotZLib/ChecksumImpl.cs\tinvalid UTF-8 -1\tcompat/zlib/contrib/dotzlib/DotZLib/CircularBuffer.cs\tinvalid UTF-8 -1\tcompat/zlib/contrib/dotzlib/DotZLib/CodecBase.cs\tinvalid UTF-8 -1\tcompat/zlib/contrib/dotzlib/DotZLib/Deflater.cs\tinvalid UTF-8 -1\tcompat/zlib/contrib/dotzlib/DotZLib/DotZLib.cs\tinvalid UTF-8 -1\tcompat/zlib/contrib/dotzlib/DotZLib/DotZLib.csproj\tCR/LF line endings -1\tcompat/zlib/contrib/dotzlib/DotZLib/GZipStream.cs\tinvalid UTF-8 -1\tcompat/zlib/contrib/dotzlib/DotZLib/Inflater.cs\tinvalid UTF-8 -1\tcompat/zlib/contrib/dotzlib/DotZLib/UnitTests.cs\tCR/LF line endings -1\tcompat/zlib/contrib/dotzlib/LICENSE_1_0.txt\tCR/LF line endings -1\tcompat/zlib/contrib/dotzlib/readme.txt\tCR/LF line endings -1\tcompat/zlib/contrib/gcc_gvmat64/gvmat64.S\tCR/LF line endings -1\tcompat/zlib/contrib/masmx64/bld_ml64.bat\tCR/LF line endings -1\tcompat/zlib/contrib/masmx64/gvmat64.asm\tCR/LF line endings -1\tcompat/zlib/contrib/masmx64/inffas8664.c\tCR/LF line endings -1\tcompat/zlib/contrib/masmx64/inffasx64.asm\tCR/LF line endings -1\tcompat/zlib/contrib/masmx64/readme.txt\tCR/LF line endings -1\tcompat/zlib/contrib/masmx86/bld_ml32.bat\tCR/LF line endings -1\tcompat/zlib/contrib/masmx86/inffas32.asm\tCR/LF line endings -1\tcompat/zlib/contrib/masmx86/match686.asm\tCR/LF line endings -1\tcompat/zlib/contrib/masmx86/readme.txt\tCR/LF line endings -1\tcompat/zlib/contrib/puff/zeros.raw\tbinary data -1\tcompat/zlib/contrib/testzlib/testzlib.c\tCR/LF line endings -1\tcompat/zlib/contrib/testzlib/testzlib.txt\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/readme.txt\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc10/miniunz.vcxproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc10/miniunz.vcxproj.filters\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc10/minizip.vcxproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc10/minizip.vcxproj.filters\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc10/testzlib.vcxproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc10/testzlib.vcxproj.filters\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc10/testzlibdll.vcxproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc10/testzlibdll.vcxproj.filters\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc10/zlib.rc\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc10/zlibstat.vcxproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc10/zlibstat.vcxproj.filters\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc10/zlibvc.def\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc10/zlibvc.sln\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc10/zlibvc.vcxproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc10/zlibvc.vcxproj.filters\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc11/miniunz.vcxproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc11/minizip.vcxproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc11/testzlib.vcxproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc11/testzlibdll.vcxproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc11/zlib.rc\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc11/zlibstat.vcxproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc11/zlibvc.def\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc11/zlibvc.sln\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc11/zlibvc.vcxproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc12/zlibvc.def\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc14/zlibvc.def\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc9/miniunz.vcproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc9/minizip.vcproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc9/testzlib.vcproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc9/testzlibdll.vcproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc9/zlib.rc\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc9/zlibstat.vcproj\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc9/zlibvc.def\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc9/zlibvc.sln\tCR/LF line endings -1\tcompat/zlib/contrib/vstudio/vc9/zlibvc.vcproj\tCR/LF line endings -1\tcompat/zlib/win32/zlib.def\tCR/LF line endings -1\tcompat/zlib/zlib.3.pdf\tbinary data -1\tcompat/zlib/zlib.map\tCR/LF line endings -1\tsetup/fossil.iss\tCR/LF line endings -1\tskins/blitz/arrow_project.png\tbinary data -1\tskins/blitz/dir.png\tbinary data -1\tskins/blitz/file.png\tbinary data -1\tskins/blitz/fossil_100.png\tbinary data -1\tskins/blitz/fossil_80_reversed_darkcyan.png\tbinary data -1\tskins/blitz/fossil_80_reversed_darkcyan_text.png\tbinary data -1\tskins/blitz/rss_20.png\tbinary data -1\tskins/bootstrap/css.txt\tlong lines -1\ttest/th1-docs-input.txt\tCR/LF line endings -1\ttest/th1-hooks-input.txt\tCR/LF line endings -1\ttest/utf16be.txt\tUnicode -1\ttest/utf16le.txt\tUnicode -1\twin/buildmsvc.bat\tCR/LF line endings -1\twin/fossil.ico\tbinary data -1\twin/fossil.rc\tinvalid UTF-8 -1\twww/CollRev1.gif\tbinary data -1\twww/CollRev2.gif\tbinary data -1\twww/CollRev3.gif\tbinary data -1\twww/CollRev4.gif\tbinary data -1\twww/apple-touch-icon.png\tbinary data -1\twww/background.jpg\tbinary data -1\twww/branch01.gif\tbinary data -1\twww/branch02.gif\tbinary data -1\twww/branch03.gif\tbinary data -1\twww/branch04.gif\tbinary data -1\twww/branch05.gif\tbinary data -1\twww/build-icons/linux.gif\tbinary data -1\twww/build-icons/linux64.gif\tbinary data -1\twww/build-icons/mac.gif\tbinary data -1\twww/build-icons/openbsd.gif\tbinary data -1\twww/build-icons/src.gif\tbinary data -1\twww/build-icons/win32.gif\tbinary data -1\twww/concept1.gif\tbinary data -1\twww/concept2.gif\tbinary data -1\twww/copyright-release.pdf\tbinary data -1\twww/delta1.gif\tbinary data -1\twww/delta2.gif\tbinary data -1\twww/delta3.gif\tbinary data -1\twww/delta4.gif\tbinary data -1\twww/delta5.gif\tbinary data -1\twww/delta6.gif\tbinary data -1\twww/encode1.gif\tbinary data -1\twww/encode10.gif\tbinary data -1\twww/encode2.gif\tbinary data -1\twww/encode3.gif\tbinary data -1\twww/encode4.gif\tbinary data -1\twww/encode5.gif\tbinary data -1\twww/encode6.gif\tbinary data -1\twww/encode7.gif\tbinary data -1\twww/encode8.gif\tbinary data -1\twww/encode9.gif\tbinary data -1\twww/fossil.gif\tbinary data -1\twww/fossil2.gif\tbinary data -1\twww/fossil3.gif\tbinary data -1\twww/fossil_logo_small.gif\tbinary data -1\twww/fossil_logo_small2.gif\tbinary data -1\twww/fossil_logo_small3.gif\tbinary data -1\twww/xkcd-git.gif\tbinary data -1}]]} +} { + test pre-commit-warnings-fossil-1 {[normalize_result] eq \ + [subst -nocommands -novariables [string trim { + 1\tart/branching.odp\tbinary data + 1\tart/concept1.dia\tbinary data + 1\tart/concept2.dia\tbinary data + 1\tcompat/zlib/contrib/blast/test.pk\tbinary data + 1\tcompat/zlib/contrib/dotzlib/DotZLib.build\tCR/LF line endings + 1\tcompat/zlib/contrib/dotzlib/DotZLib.chm\tbinary data + 1\tcompat/zlib/contrib/dotzlib/DotZLib.sln\tCR/LF line endings + 1\tcompat/zlib/contrib/dotzlib/DotZLib/AssemblyInfo.cs\tCR/LF line endings + 1\tcompat/zlib/contrib/dotzlib/DotZLib/ChecksumImpl.cs\tinvalid UTF-8 + 1\tcompat/zlib/contrib/dotzlib/DotZLib/CircularBuffer.cs\tinvalid UTF-8 + 1\tcompat/zlib/contrib/dotzlib/DotZLib/CodecBase.cs\tinvalid UTF-8 + 1\tcompat/zlib/contrib/dotzlib/DotZLib/Deflater.cs\tinvalid UTF-8 + 1\tcompat/zlib/contrib/dotzlib/DotZLib/DotZLib.cs\tinvalid UTF-8 + 1\tcompat/zlib/contrib/dotzlib/DotZLib/DotZLib.csproj\tCR/LF line endings + 1\tcompat/zlib/contrib/dotzlib/DotZLib/GZipStream.cs\tinvalid UTF-8 + 1\tcompat/zlib/contrib/dotzlib/DotZLib/Inflater.cs\tinvalid UTF-8 + 1\tcompat/zlib/contrib/dotzlib/DotZLib/UnitTests.cs\tCR/LF line endings + 1\tcompat/zlib/contrib/dotzlib/LICENSE_1_0.txt\tCR/LF line endings + 1\tcompat/zlib/contrib/dotzlib/readme.txt\tCR/LF line endings + 1\tcompat/zlib/contrib/gcc_gvmat64/gvmat64.S\tCR/LF line endings + 1\tcompat/zlib/contrib/masmx64/bld_ml64.bat\tCR/LF line endings + 1\tcompat/zlib/contrib/masmx64/gvmat64.asm\tCR/LF line endings + 1\tcompat/zlib/contrib/masmx64/inffas8664.c\tCR/LF line endings + 1\tcompat/zlib/contrib/masmx64/inffasx64.asm\tCR/LF line endings + 1\tcompat/zlib/contrib/masmx64/readme.txt\tCR/LF line endings + 1\tcompat/zlib/contrib/masmx86/bld_ml32.bat\tCR/LF line endings + 1\tcompat/zlib/contrib/masmx86/inffas32.asm\tCR/LF line endings + 1\tcompat/zlib/contrib/masmx86/match686.asm\tCR/LF line endings + 1\tcompat/zlib/contrib/masmx86/readme.txt\tCR/LF line endings + 1\tcompat/zlib/contrib/puff/zeros.raw\tbinary data + 1\tcompat/zlib/contrib/testzlib/testzlib.c\tCR/LF line endings + 1\tcompat/zlib/contrib/testzlib/testzlib.txt\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/readme.txt\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc10/miniunz.vcxproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc10/miniunz.vcxproj.filters\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc10/minizip.vcxproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc10/minizip.vcxproj.filters\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc10/testzlib.vcxproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc10/testzlib.vcxproj.filters\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc10/testzlibdll.vcxproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc10/testzlibdll.vcxproj.filters\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc10/zlib.rc\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc10/zlibstat.vcxproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc10/zlibstat.vcxproj.filters\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc10/zlibvc.def\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc10/zlibvc.sln\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc10/zlibvc.vcxproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc10/zlibvc.vcxproj.filters\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc11/miniunz.vcxproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc11/minizip.vcxproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc11/testzlib.vcxproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc11/testzlibdll.vcxproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc11/zlib.rc\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc11/zlibstat.vcxproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc11/zlibvc.def\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc11/zlibvc.sln\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc11/zlibvc.vcxproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc12/zlibvc.def\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc14/zlibvc.def\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc9/miniunz.vcproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc9/minizip.vcproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc9/testzlib.vcproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc9/testzlibdll.vcproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc9/zlib.rc\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc9/zlibstat.vcproj\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc9/zlibvc.def\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc9/zlibvc.sln\tCR/LF line endings + 1\tcompat/zlib/contrib/vstudio/vc9/zlibvc.vcproj\tCR/LF line endings + 1\tcompat/zlib/win32/zlib.def\tCR/LF line endings + 1\tcompat/zlib/zlib.3.pdf\tbinary data + 1\tcompat/zlib/zlib.map\tCR/LF line endings + 1\tsetup/fossil.iss\tCR/LF line endings + 1\tskins/blitz/arrow_project.png\tbinary data + 1\tskins/blitz/dir.png\tbinary data + 1\tskins/blitz/file.png\tbinary data + 1\tskins/blitz/fossil_100.png\tbinary data + 1\tskins/blitz/fossil_80_reversed_darkcyan.png\tbinary data + 1\tskins/blitz/fossil_80_reversed_darkcyan_text.png\tbinary data + 1\tskins/blitz/rss_20.png\tbinary data + 1\tskins/bootstrap/css.txt\tlong lines + 1\ttest/th1-docs-input.txt\tCR/LF line endings + 1\ttest/th1-hooks-input.txt\tCR/LF line endings + 1\ttest/utf16be.txt\tUnicode + 1\ttest/utf16le.txt\tUnicode + 1\twin/buildmsvc.bat\tCR/LF line endings + 1\twin/fossil.ico\tbinary data + 1\twin/fossil.rc\tinvalid UTF-8 + 1\twww/CollRev1.gif\tbinary data + 1\twww/CollRev2.gif\tbinary data + 1\twww/CollRev3.gif\tbinary data + 1\twww/CollRev4.gif\tbinary data + 1\twww/apple-touch-icon.png\tbinary data + 1\twww/background.jpg\tbinary data + 1\twww/branch01.gif\tbinary data + 1\twww/branch02.gif\tbinary data + 1\twww/branch03.gif\tbinary data + 1\twww/branch04.gif\tbinary data + 1\twww/branch05.gif\tbinary data + 1\twww/build-icons/linux.gif\tbinary data + 1\twww/build-icons/linux64.gif\tbinary data + 1\twww/build-icons/mac.gif\tbinary data + 1\twww/build-icons/openbsd.gif\tbinary data + 1\twww/build-icons/src.gif\tbinary data + 1\twww/build-icons/win32.gif\tbinary data + 1\twww/concept1.gif\tbinary data + 1\twww/concept2.gif\tbinary data + 1\twww/copyright-release.pdf\tbinary data + 1\twww/delta1.gif\tbinary data + 1\twww/delta2.gif\tbinary data + 1\twww/delta3.gif\tbinary data + 1\twww/delta4.gif\tbinary data + 1\twww/delta5.gif\tbinary data + 1\twww/delta6.gif\tbinary data + 1\twww/encode1.gif\tbinary data + 1\twww/encode10.gif\tbinary data + 1\twww/encode2.gif\tbinary data + 1\twww/encode3.gif\tbinary data + 1\twww/encode4.gif\tbinary data + 1\twww/encode5.gif\tbinary data + 1\twww/encode6.gif\tbinary data + 1\twww/encode7.gif\tbinary data + 1\twww/encode8.gif\tbinary data + 1\twww/encode9.gif\tbinary data + 1\twww/fossil.gif\tbinary data + 1\twww/fossil2.gif\tbinary data + 1\twww/fossil3.gif\tbinary data + 1\twww/fossil_logo_small.gif\tbinary data + 1\twww/fossil_logo_small2.gif\tbinary data + 1\twww/fossil_logo_small3.gif\tbinary data + 1\twww/xkcd-git.gif\tbinary data + 1}]]} +} ############################################################################### test_cleanup Index: test/tester.tcl ================================================================== --- test/tester.tcl +++ test/tester.tcl @@ -20,20 +20,32 @@ # tclsh ../test/tester.tcl ../bld/fossil # # Where ../test/tester.tcl is the name of this file and ../bld/fossil # is the name of the executable to be tested. # + +# We use some things introduced in 8.6 such as lmap. auto.def should +# have found us a suitable Tcl installation. +package require Tcl 8.6 set testfiledir [file normalize [file dirname [info script]]] set testrundir [pwd] set testdir [file normalize [file dirname $argv0]] set fossilexe [file normalize [lindex $argv 0]] +set is_windows [expr {$::tcl_platform(platform) eq "windows"}] -if {$tcl_platform(platform) eq "windows" && \ - [string length [file extension $fossilexe]] == 0} { - append fossilexe .exe +if {$::is_windows} { + if {[string length [file extension $fossilexe]] == 0} { + append fossilexe .exe + } + set outside_fossil_repo [expr ![file exists "$::testfiledir\\..\\_FOSSIL_"]] +} else { + set outside_fossil_repo [expr ![file exists "$::testfiledir/../.fslckout"]] } + +catch {exec $::fossilexe changes --changed} res +set dirty_ckout [string length $res] set argv [lrange $argv 1 end] set i [lsearch $argv -keep] if {$i>=0} { @@ -439,11 +451,11 @@ if {![info exists ::tempKeepHome]} {delete_temporary_home} } proc delete_temporary_home {} { if {$::KEEP} {return}; # All cleanup disabled? - if {$::tcl_platform(platform) eq "windows"} { + if {$::is_windows} { robust_delete [file join $::tempHomePath _fossil] } else { robust_delete [file join $::tempHomePath .fossil] } robust_delete $::tempHomePath @@ -512,26 +524,66 @@ fossil test-th-eval --open-config "setting th1-hooks" if {[normalize_result] eq "1"} {return 1} return [info exists ::env(TH1_ENABLE_HOOKS)] } -# This (rarely used) procedure is designed to run a test within the Fossil -# source checkout (e.g. one that does NOT modify any state), while saving -# and restoring the current directory (e.g. one used when running a test -# file outside of the Fossil source checkout). Please do NOT use this -# procedure unless you are absolutely sure it does not modify the state of -# the repository or source checkout in any way. +# Run the given command script inside the Fossil source repo checkout. +# +# Callers of this function must ensure two things: +# +# 1. This test run is in fact being done from within a Fossil repo +# checkout directory. If you are unsure, test $::outside_fossil_repo +# or call one of the test_* wrappers below which do that for you. +# +# As a rule, you should not be calling this function directly! +# +# 2. This test run is being done from a repo checkout directory that +# doesn't have any uncommitted changes. If it does, that affects the +# output of any test based on the output of "fossil status", +# "... diff", etc., which is likely to make the test appear to fail. +# If you must call this function directly, test $::dirty_ckout and +# skip the call if it's true. The test_* wrappers do this for you. # +# 3. The test does NOT modify the Fossil checkout tree in any way. proc run_in_checkout { script {dir ""} } { if {[string length $dir] == 0} {set dir $::testfiledir} set savedPwd [pwd]; cd $dir set code [catch { uplevel 1 $script } result] cd $savedPwd; unset savedPwd return -code $code $result } + +# Wrapper for the above function pair. The tscript parameter is an +# optional post-run test script. Some callers choose instead to put +# the tests inline with the rscript commands. +# +# Be sure to adhere to the requirements of run_in_checkout! +proc test_block_in_checkout { name rscript {tscript ""} } { + if {$::outside_fossil_repo || $::dirty_ckout} { + set $::CODE 0 + set $::RESULT "" + } else { + run_in_checkout $rscript + if {[string length $tscript] == 0} { + return "" + } else { + set code [catch { + uplevel 1 $tscript + } result] + return -code $code $result + } + } +} + +# Single-test wrapper for the above. +proc test_in_checkout { name rscript tscript } { + return test_block_in_checkout name rscript { + test $name $tscript + } +} # Normalize file status lists (like those returned by 'fossil changes') # so they can be compared using simple string comparison # proc normalize_status_list {list} { @@ -624,11 +676,11 @@ } # # NOTE: On non-Windows systems, fallback to /tmp if it is usable. # - if {$::tcl_platform(platform) ne "windows"} { + if {!$::is_windows} { set value /tmp if {[file exists $value] && [file isdirectory $value]} { return $value } @@ -796,21 +848,21 @@ global fossilexe tempPath set command [list exec $fossilexe server --localhost] if {[string length $varName] > 0} { upvar 1 $varName stopArg } - if {$::tcl_platform(platform) eq "windows"} { + if {$::is_windows} { set stopArg [file join [getTemporaryPath] [appendArgs \ [string trim [clock seconds] -] _ [getSeqNo] .stopper]] lappend command --stopper $stopArg } set outFileName [file join $tempPath [appendArgs \ fossil_server_ [string trim [clock seconds] -] _ \ [getSeqNo]]].out lappend command $repository >&$outFileName & set pid [eval $command] - if {$::tcl_platform(platform) ne "windows"} { + if {!$::is_windows} { set stopArg $pid } after 1000; # output might not be there yet set output [read_file $outFileName] if {![regexp {Listening.*TCP port (\d+)} $output dummy port]} { @@ -823,11 +875,11 @@ # This procedure stops a Fossil server instance that was previously started # by the [test_start_server] procedure. The value of the "stop argument" # will vary by platform as will the exact method used to stop the server. # The fileName argument is the name of a temporary output file to delete. proc test_stop_server { stopArg pid fileName } { - if {$::tcl_platform(platform) eq "windows"} { + if {$::is_windows} { # # NOTE: On Windows, the "stop argument" must be the name of a file # that does NOT already exist. # if {[string length $stopArg] > 0 && \ @@ -950,11 +1002,11 @@ return [lindex [split [normalize_result] \n] end-2] } set tempPath [getTemporaryPath] -if {$tcl_platform(platform) eq "windows"} { +if {$is_windows} { set tempPath [string map [list \\ /] $tempPath] } if {[catch { set tempFile [file join $tempPath temporary.txt] Index: test/th1-docs.test ================================================================== --- test/th1-docs.test +++ test/th1-docs.test @@ -29,10 +29,18 @@ if {[normalize_result] ne "1"} { puts "Fossil was not compiled with Tcl support." test_cleanup_then_return } + +if {$::outside_fossil_repo} { + puts "Skipping th1-docs-* tests: not in Fossil repo checkout." + test_cleanup_then_return +} elseif ($::dirty_ckout) { + puts "Skipping th1-docs-* tests: uncommitted changes in Fossil checkout." + test_cleanup_then_return +} ############################################################################### test_setup "" Index: test/th1.test ================================================================== --- test/th1.test +++ test/th1.test @@ -553,10 +553,19 @@ fossil test-th-eval "lindex list -0x" test th1-expr-49 {$RESULT eq {TH_ERROR: expected integer, got: "-0x"}} ############################################################################### + +set skip_anycap 1 +if {$::outside_fossil_repo} { + puts "Skipping th1-anycap-*-1 perm tests: not in Fossil repo checkout." +} elseif ($::dirty_ckout) { + puts "Skipping th1-anycap-*-1 perm tests: uncommitted changes in Fossil checkout." +} else { + set skip_anycap 0 +} foreach perm [list a b c d e f g h i j k l m n o p q r s t u v w x y z] { if {$perm eq "u"} continue; # NOTE: Skip "reader" meta-permission. if {$perm eq "v"} continue; # NOTE: Skip "developer" meta-permission. @@ -566,10 +575,12 @@ fossil test-th-eval "hascap $perm" test th1-hascap-no-$perm-1 {$RESULT eq {0}} fossil test-th-eval "anoncap $perm" test th1-anoncap-no-$perm-1 {$RESULT eq {0}} + + if {$skip_anycap} { continue } run_in_checkout { fossil test-th-eval --set-user-caps "anycap $perm" test th1-anycap-yes-$perm-1 {$RESULT eq {1}} @@ -621,11 +632,11 @@ fossil test-th-eval "anoncap o h" test th1-anoncap-no-multiple-2 {$RESULT eq {0}} ############################################################################### -run_in_checkout { +test_block_in_checkout "test-anoncap-*" { fossil test-th-eval --set-user-caps "anycap oh" test th1-anycap-yes-multiple-1 {$RESULT eq {1}} set ::env(TH1_TEST_USER_CAPS) o fossil test-th-eval --set-user-caps "anycap oh" @@ -665,29 +676,25 @@ unset ::env(TH1_TEST_ANON_CAPS) } ############################################################################### -run_in_checkout { +test_in_checkout th1-checkout-1 { # NOTE: The "1" here forces the checkout to be opened. fossil test-th-eval "checkout 1" -} - -test th1-checkout-1 {[string length $RESULT] > 0} +} {[string length $RESULT] > 0} ############################################################################### -run_in_checkout { +test_in_checkout th1-checkout-2 { if {$th1Hooks} { fossil test-th-eval "checkout" } else { # NOTE: No TH1 hooks, force checkout to be populated. fossil test-th-eval --open-config "checkout" } -} - -test th1-checkout-2 {[string length $RESULT] > 0} +} {[string length $RESULT] > 0} ############################################################################### set savedPwd [pwd]; cd / fossil test-th-eval "checkout 1" @@ -762,15 +769,13 @@ fossil test-th-eval "styleHeader {Page Title Here}" test th1-header-1 {$RESULT eq {TH_ERROR: repository unavailable}} ############################################################################### -run_in_checkout { +test_in_checkout th1-header-2 { fossil test-th-eval --open-config "styleHeader {Page Title Here}" -} - -test th1-header-2 {[regexp -- {Fossil: Page Title Here} $RESULT]} +} {[regexp -- {Fossil: Page Title Here} $RESULT]} ############################################################################### fossil test-th-eval "styleFooter" test th1-footer-1 {$RESULT eq {TH_ERROR: repository unavailable}} @@ -848,15 +853,13 @@ fossil test-th-eval "artifact tip" test th1-artifact-2 {$RESULT eq {TH_ERROR: repository unavailable}} ############################################################################### -run_in_checkout { +test_in_checkout th1-artifact-3 { fossil test-th-eval --open-config "artifact tip" -} - -test th1-artifact-3 {[regexp -- {F test/th1\.test [0-9a-f]{40,64}} $RESULT]} +} {[regexp -- {F test/th1\.test [0-9a-f]{40,64}} $RESULT]} ############################################################################### fossil test-th-eval "artifact 0000000000" test th1-artifact-4 {$RESULT eq {TH_ERROR: repository unavailable}} @@ -871,15 +874,13 @@ fossil test-th-eval "artifact tip test/th1.test" test th1-artifact-6 {$RESULT eq {TH_ERROR: repository unavailable}} ############################################################################### -run_in_checkout { +test_in_checkout th1-artifact-7 { fossil test-th-eval --open-config "artifact tip test/th1.test" -} - -test th1-artifact-7 {[regexp -- {th1-artifact-7} $RESULT]} +} {[regexp -- {th1-artifact-7} $RESULT]} ############################################################################### fossil test-th-eval "artifact 0000000000 test/th1.test" test th1-artifact-8 {$RESULT eq {TH_ERROR: repository unavailable}} @@ -889,24 +890,22 @@ fossil test-th-eval --open-config "artifact 0000000000 test/th1.test" test th1-artifact-9 {$RESULT eq {TH_ERROR: manifest not found}} ############################################################################### -run_in_checkout { +test_in_checkout th1-globalState-1 { if {$th1Hooks} { fossil test-th-eval "globalState checkout" } else { # NOTE: No TH1 hooks, force checkout to be populated. fossil test-th-eval --open-config "globalState checkout" } -} - -test th1-globalState-1 {[string length $RESULT] > 0} +} {[string length $RESULT] > 0} ############################################################################### -run_in_checkout { +test_block_in_checkout th1-globalState-2 { if {$th1Hooks} { fossil test-th-eval "globalState checkout" test th1-globalState-2 {$RESULT eq [fossil test-th-eval checkout]} } else { # NOTE: No TH1 hooks, force checkout to be populated. @@ -942,24 +941,22 @@ fossil test-th-eval --errorlog foserrors.log "globalState log" test th1-globalState-7 {$RESULT eq "foserrors.log"} ############################################################################### -run_in_checkout { +test_in_checkout th1-globalState-8 { if {$th1Hooks} { fossil test-th-eval "globalState repository" } else { # NOTE: No TH1 hooks, force repository to be populated. fossil test-th-eval --open-config "globalState repository" } -} - -test th1-globalState-8 {[string length $RESULT] > 0} +} {[string length $RESULT] > 0} ############################################################################### -run_in_checkout { +test_block_in_checkout th1-globalState-9 { if {$th1Hooks} { fossil test-th-eval "globalState repository" test th1-globalState-9 {$RESULT eq [fossil test-th-eval repository]} } else { # NOTE: No TH1 hooks, force repository to be populated. @@ -1603,21 +1600,20 @@ test th1-encode64-2 {$RESULT eq "dGVzdAA="} ############################################################################### # -# TODO: Modify the result of this test if the source file (i.e. -# "ajax/cgi-bin/fossil-json.cgi.example") changes. +# This test will fail if the Fossil source file named below changes. Update +# the expected result string below if that happens. # -run_in_checkout { +test_in_checkout th1-encode64-3 { fossil test-th-eval --open-config \ {encode64 [artifact trunk ajax/cgi-bin/fossil-json.cgi.example]} +} { + $RESULT eq "IyEvcGF0aC90by9mb3NzaWwvYmluYXJ5CnJlcG9zaXRvcnk6IC9wYXRoL3RvL3JlcG8uZnNsCg==" } -test th1-encode64-3 {$RESULT eq \ -"IyEvcGF0aC90by9mb3NzaWwvYmluYXJ5CnJlcG9zaXRvcnk6IC9wYXRoL3RvL3JlcG8uZnNsCg=="} - ############################################################################### fossil test-th-eval {array exists tcl_platform} test th1-platform-1 {$RESULT eq "1"} Index: win/Makefile.dmc ================================================================== --- win/Makefile.dmc +++ win/Makefile.dmc @@ -28,13 +28,13 @@ SQLITE_OPTIONS = -DNDEBUG=1 -DSQLITE_THREADSAFE=0 -DSQLITE_DEFAULT_MEMSTATUS=0 -DSQLITE_DEFAULT_WAL_SYNCHRONOUS=1 -DSQLITE_LIKE_DOESNT_MATCH_BLOBS -DSQLITE_OMIT_DECLTYPE -DSQLITE_OMIT_DEPRECATED -DSQLITE_OMIT_GET_TABLE -DSQLITE_OMIT_PROGRESS_CALLBACK -DSQLITE_OMIT_SHARED_CACHE -DSQLITE_OMIT_LOAD_EXTENSION -DSQLITE_MAX_EXPR_DEPTH=0 -DSQLITE_USE_ALLOCA -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_DEFAULT_FILE_FORMAT=4 -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_FTS4 -DSQLITE_ENABLE_FTS3_PARENTHESIS -DSQLITE_ENABLE_DBSTAT_VTAB -DSQLITE_ENABLE_JSON1 -DSQLITE_ENABLE_FTS5 -DSQLITE_ENABLE_STMTVTAB -DSQLITE_HAVE_ZLIB -DSQLITE_INTROSPECTION_PRAGMAS -DSQLITE_ENABLE_DBPAGE_VTAB SHELL_OPTIONS = -DNDEBUG=1 -DSQLITE_THREADSAFE=0 -DSQLITE_DEFAULT_MEMSTATUS=0 -DSQLITE_DEFAULT_WAL_SYNCHRONOUS=1 -DSQLITE_LIKE_DOESNT_MATCH_BLOBS -DSQLITE_OMIT_DECLTYPE -DSQLITE_OMIT_DEPRECATED -DSQLITE_OMIT_GET_TABLE -DSQLITE_OMIT_PROGRESS_CALLBACK -DSQLITE_OMIT_SHARED_CACHE -DSQLITE_OMIT_LOAD_EXTENSION -DSQLITE_MAX_EXPR_DEPTH=0 -DSQLITE_USE_ALLOCA -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_DEFAULT_FILE_FORMAT=4 -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_FTS4 -DSQLITE_ENABLE_FTS3_PARENTHESIS -DSQLITE_ENABLE_DBSTAT_VTAB -DSQLITE_ENABLE_JSON1 -DSQLITE_ENABLE_FTS5 -DSQLITE_ENABLE_STMTVTAB -DSQLITE_HAVE_ZLIB -DSQLITE_INTROSPECTION_PRAGMAS -DSQLITE_ENABLE_DBPAGE_VTAB -Dmain=sqlite3_shell -DSQLITE_SHELL_IS_UTF8=1 -DSQLITE_OMIT_LOAD_EXTENSION=1 -DUSE_SYSTEM_SQLITE=$(USE_SYSTEM_SQLITE) -DSQLITE_SHELL_DBNAME_PROC=sqlcmd_get_dbname -DSQLITE_SHELL_INIT_PROC=sqlcmd_init_proc -Daccess=file_access -Dsystem=fossil_system -Dgetenv=fossil_getenv -Dfopen=fossil_fopen -SRC = add_.c allrepo_.c attach_.c backoffice_.c bag_.c bisect_.c blob_.c branch_.c browse_.c builtin_.c bundle_.c cache_.c capabilities_.c captcha_.c cgi_.c checkin_.c checkout_.c clearsign_.c clone_.c comformat_.c configure_.c content_.c cookies_.c db_.c delta_.c deltacmd_.c descendants_.c diff_.c diffcmd_.c dispatch_.c doc_.c email_.c encode_.c etag_.c event_.c export_.c file_.c finfo_.c foci_.c forum_.c fshell_.c fusefs_.c glob_.c graph_.c gzip_.c hname_.c http_.c http_socket_.c http_ssl_.c http_transport_.c import_.c info_.c json_.c json_artifact_.c json_branch_.c json_config_.c json_diff_.c json_dir_.c json_finfo_.c json_login_.c json_query_.c json_report_.c json_status_.c json_tag_.c json_timeline_.c json_user_.c json_wiki_.c leaf_.c loadctrl_.c login_.c lookslike_.c main_.c manifest_.c markdown_.c markdown_html_.c md5_.c merge_.c merge3_.c moderate_.c name_.c path_.c piechart_.c pivot_.c popen_.c pqueue_.c printf_.c publish_.c purge_.c rebuild_.c regexp_.c report_.c rss_.c schema_.c search_.c security_audit_.c setup_.c setupuser_.c sha1_.c sha1hard_.c sha3_.c shun_.c sitemap_.c skins_.c smtp_.c sqlcmd_.c stash_.c stat_.c statrep_.c style_.c sync_.c tag_.c tar_.c th_main_.c timeline_.c tkt_.c tktsetup_.c undo_.c unicode_.c unversioned_.c update_.c url_.c user_.c utf8_.c util_.c verify_.c vfile_.c webmail_.c wiki_.c wikiformat_.c winfile_.c winhttp_.c wysiwyg_.c xfer_.c xfersetup_.c zip_.c +SRC = add_.c alerts_.c allrepo_.c attach_.c backoffice_.c bag_.c bisect_.c blob_.c branch_.c browse_.c builtin_.c bundle_.c cache_.c capabilities_.c captcha_.c cgi_.c checkin_.c checkout_.c clearsign_.c clone_.c comformat_.c configure_.c content_.c cookies_.c db_.c delta_.c deltacmd_.c descendants_.c diff_.c diffcmd_.c dispatch_.c doc_.c encode_.c etag_.c event_.c export_.c file_.c finfo_.c foci_.c forum_.c fshell_.c fusefs_.c glob_.c graph_.c gzip_.c hname_.c http_.c http_socket_.c http_ssl_.c http_transport_.c import_.c info_.c json_.c json_artifact_.c json_branch_.c json_config_.c json_diff_.c json_dir_.c json_finfo_.c json_login_.c json_query_.c json_report_.c json_status_.c json_tag_.c json_timeline_.c json_user_.c json_wiki_.c leaf_.c loadctrl_.c login_.c lookslike_.c main_.c manifest_.c markdown_.c markdown_html_.c md5_.c merge_.c merge3_.c moderate_.c name_.c path_.c piechart_.c pivot_.c popen_.c pqueue_.c printf_.c publish_.c purge_.c rebuild_.c regexp_.c report_.c rss_.c schema_.c search_.c security_audit_.c setup_.c setupuser_.c sha1_.c sha1hard_.c sha3_.c shun_.c sitemap_.c skins_.c smtp_.c sqlcmd_.c stash_.c stat_.c statrep_.c style_.c sync_.c tag_.c tar_.c th_main_.c timeline_.c tkt_.c tktsetup_.c undo_.c unicode_.c unversioned_.c update_.c url_.c user_.c utf8_.c util_.c verify_.c vfile_.c webmail_.c wiki_.c wikiformat_.c winfile_.c winhttp_.c wysiwyg_.c xfer_.c xfersetup_.c zip_.c -OBJ = $(OBJDIR)\add$O $(OBJDIR)\allrepo$O $(OBJDIR)\attach$O $(OBJDIR)\backoffice$O $(OBJDIR)\bag$O $(OBJDIR)\bisect$O $(OBJDIR)\blob$O $(OBJDIR)\branch$O $(OBJDIR)\browse$O $(OBJDIR)\builtin$O $(OBJDIR)\bundle$O $(OBJDIR)\cache$O $(OBJDIR)\capabilities$O $(OBJDIR)\captcha$O $(OBJDIR)\cgi$O $(OBJDIR)\checkin$O $(OBJDIR)\checkout$O $(OBJDIR)\clearsign$O $(OBJDIR)\clone$O $(OBJDIR)\comformat$O $(OBJDIR)\configure$O $(OBJDIR)\content$O $(OBJDIR)\cookies$O $(OBJDIR)\db$O $(OBJDIR)\delta$O $(OBJDIR)\deltacmd$O $(OBJDIR)\descendants$O $(OBJDIR)\diff$O $(OBJDIR)\diffcmd$O $(OBJDIR)\dispatch$O $(OBJDIR)\doc$O $(OBJDIR)\email$O $(OBJDIR)\encode$O $(OBJDIR)\etag$O $(OBJDIR)\event$O $(OBJDIR)\export$O $(OBJDIR)\file$O $(OBJDIR)\finfo$O $(OBJDIR)\foci$O $(OBJDIR)\forum$O $(OBJDIR)\fshell$O $(OBJDIR)\fusefs$O $(OBJDIR)\glob$O $(OBJDIR)\graph$O $(OBJDIR)\gzip$O $(OBJDIR)\hname$O $(OBJDIR)\http$O $(OBJDIR)\http_socket$O $(OBJDIR)\http_ssl$O $(OBJDIR)\http_transport$O $(OBJDIR)\import$O $(OBJDIR)\info$O $(OBJDIR)\json$O $(OBJDIR)\json_artifact$O $(OBJDIR)\json_branch$O $(OBJDIR)\json_config$O $(OBJDIR)\json_diff$O $(OBJDIR)\json_dir$O $(OBJDIR)\json_finfo$O $(OBJDIR)\json_login$O $(OBJDIR)\json_query$O $(OBJDIR)\json_report$O $(OBJDIR)\json_status$O $(OBJDIR)\json_tag$O $(OBJDIR)\json_timeline$O $(OBJDIR)\json_user$O $(OBJDIR)\json_wiki$O $(OBJDIR)\leaf$O $(OBJDIR)\loadctrl$O $(OBJDIR)\login$O $(OBJDIR)\lookslike$O $(OBJDIR)\main$O $(OBJDIR)\manifest$O $(OBJDIR)\markdown$O $(OBJDIR)\markdown_html$O $(OBJDIR)\md5$O $(OBJDIR)\merge$O $(OBJDIR)\merge3$O $(OBJDIR)\moderate$O $(OBJDIR)\name$O $(OBJDIR)\path$O $(OBJDIR)\piechart$O $(OBJDIR)\pivot$O $(OBJDIR)\popen$O $(OBJDIR)\pqueue$O $(OBJDIR)\printf$O $(OBJDIR)\publish$O $(OBJDIR)\purge$O $(OBJDIR)\rebuild$O $(OBJDIR)\regexp$O $(OBJDIR)\report$O $(OBJDIR)\rss$O $(OBJDIR)\schema$O $(OBJDIR)\search$O $(OBJDIR)\security_audit$O $(OBJDIR)\setup$O $(OBJDIR)\setupuser$O $(OBJDIR)\sha1$O $(OBJDIR)\sha1hard$O $(OBJDIR)\sha3$O $(OBJDIR)\shun$O $(OBJDIR)\sitemap$O $(OBJDIR)\skins$O $(OBJDIR)\smtp$O $(OBJDIR)\sqlcmd$O $(OBJDIR)\stash$O $(OBJDIR)\stat$O $(OBJDIR)\statrep$O $(OBJDIR)\style$O $(OBJDIR)\sync$O $(OBJDIR)\tag$O $(OBJDIR)\tar$O $(OBJDIR)\th_main$O $(OBJDIR)\timeline$O $(OBJDIR)\tkt$O $(OBJDIR)\tktsetup$O $(OBJDIR)\undo$O $(OBJDIR)\unicode$O $(OBJDIR)\unversioned$O $(OBJDIR)\update$O $(OBJDIR)\url$O $(OBJDIR)\user$O $(OBJDIR)\utf8$O $(OBJDIR)\util$O $(OBJDIR)\verify$O $(OBJDIR)\vfile$O $(OBJDIR)\webmail$O $(OBJDIR)\wiki$O $(OBJDIR)\wikiformat$O $(OBJDIR)\winfile$O $(OBJDIR)\winhttp$O $(OBJDIR)\wysiwyg$O $(OBJDIR)\xfer$O $(OBJDIR)\xfersetup$O $(OBJDIR)\zip$O $(OBJDIR)\shell$O $(OBJDIR)\sqlite3$O $(OBJDIR)\th$O $(OBJDIR)\th_lang$O +OBJ = $(OBJDIR)\add$O $(OBJDIR)\alerts$O $(OBJDIR)\allrepo$O $(OBJDIR)\attach$O $(OBJDIR)\backoffice$O $(OBJDIR)\bag$O $(OBJDIR)\bisect$O $(OBJDIR)\blob$O $(OBJDIR)\branch$O $(OBJDIR)\browse$O $(OBJDIR)\builtin$O $(OBJDIR)\bundle$O $(OBJDIR)\cache$O $(OBJDIR)\capabilities$O $(OBJDIR)\captcha$O $(OBJDIR)\cgi$O $(OBJDIR)\checkin$O $(OBJDIR)\checkout$O $(OBJDIR)\clearsign$O $(OBJDIR)\clone$O $(OBJDIR)\comformat$O $(OBJDIR)\configure$O $(OBJDIR)\content$O $(OBJDIR)\cookies$O $(OBJDIR)\db$O $(OBJDIR)\delta$O $(OBJDIR)\deltacmd$O $(OBJDIR)\descendants$O $(OBJDIR)\diff$O $(OBJDIR)\diffcmd$O $(OBJDIR)\dispatch$O $(OBJDIR)\doc$O $(OBJDIR)\encode$O $(OBJDIR)\etag$O $(OBJDIR)\event$O $(OBJDIR)\export$O $(OBJDIR)\file$O $(OBJDIR)\finfo$O $(OBJDIR)\foci$O $(OBJDIR)\forum$O $(OBJDIR)\fshell$O $(OBJDIR)\fusefs$O $(OBJDIR)\glob$O $(OBJDIR)\graph$O $(OBJDIR)\gzip$O $(OBJDIR)\hname$O $(OBJDIR)\http$O $(OBJDIR)\http_socket$O $(OBJDIR)\http_ssl$O $(OBJDIR)\http_transport$O $(OBJDIR)\import$O $(OBJDIR)\info$O $(OBJDIR)\json$O $(OBJDIR)\json_artifact$O $(OBJDIR)\json_branch$O $(OBJDIR)\json_config$O $(OBJDIR)\json_diff$O $(OBJDIR)\json_dir$O $(OBJDIR)\json_finfo$O $(OBJDIR)\json_login$O $(OBJDIR)\json_query$O $(OBJDIR)\json_report$O $(OBJDIR)\json_status$O $(OBJDIR)\json_tag$O $(OBJDIR)\json_timeline$O $(OBJDIR)\json_user$O $(OBJDIR)\json_wiki$O $(OBJDIR)\leaf$O $(OBJDIR)\loadctrl$O $(OBJDIR)\login$O $(OBJDIR)\lookslike$O $(OBJDIR)\main$O $(OBJDIR)\manifest$O $(OBJDIR)\markdown$O $(OBJDIR)\markdown_html$O $(OBJDIR)\md5$O $(OBJDIR)\merge$O $(OBJDIR)\merge3$O $(OBJDIR)\moderate$O $(OBJDIR)\name$O $(OBJDIR)\path$O $(OBJDIR)\piechart$O $(OBJDIR)\pivot$O $(OBJDIR)\popen$O $(OBJDIR)\pqueue$O $(OBJDIR)\printf$O $(OBJDIR)\publish$O $(OBJDIR)\purge$O $(OBJDIR)\rebuild$O $(OBJDIR)\regexp$O $(OBJDIR)\report$O $(OBJDIR)\rss$O $(OBJDIR)\schema$O $(OBJDIR)\search$O $(OBJDIR)\security_audit$O $(OBJDIR)\setup$O $(OBJDIR)\setupuser$O $(OBJDIR)\sha1$O $(OBJDIR)\sha1hard$O $(OBJDIR)\sha3$O $(OBJDIR)\shun$O $(OBJDIR)\sitemap$O $(OBJDIR)\skins$O $(OBJDIR)\smtp$O $(OBJDIR)\sqlcmd$O $(OBJDIR)\stash$O $(OBJDIR)\stat$O $(OBJDIR)\statrep$O $(OBJDIR)\style$O $(OBJDIR)\sync$O $(OBJDIR)\tag$O $(OBJDIR)\tar$O $(OBJDIR)\th_main$O $(OBJDIR)\timeline$O $(OBJDIR)\tkt$O $(OBJDIR)\tktsetup$O $(OBJDIR)\undo$O $(OBJDIR)\unicode$O $(OBJDIR)\unversioned$O $(OBJDIR)\update$O $(OBJDIR)\url$O $(OBJDIR)\user$O $(OBJDIR)\utf8$O $(OBJDIR)\util$O $(OBJDIR)\verify$O $(OBJDIR)\vfile$O $(OBJDIR)\webmail$O $(OBJDIR)\wiki$O $(OBJDIR)\wikiformat$O $(OBJDIR)\winfile$O $(OBJDIR)\winhttp$O $(OBJDIR)\wysiwyg$O $(OBJDIR)\xfer$O $(OBJDIR)\xfersetup$O $(OBJDIR)\zip$O $(OBJDIR)\shell$O $(OBJDIR)\sqlite3$O $(OBJDIR)\th$O $(OBJDIR)\th_lang$O RC=$(DMDIR)\bin\rcc RCFLAGS=-32 -w1 -I$(SRCDIR) /D__DMC__ @@ -49,11 +49,11 @@ $(OBJDIR)\fossil.res: $B\win\fossil.rc $(RC) $(RCFLAGS) -o$@ $** $(OBJDIR)\link: $B\win\Makefile.dmc $(OBJDIR)\fossil.res - +echo add allrepo attach backoffice bag bisect blob branch browse builtin bundle cache capabilities captcha cgi checkin checkout clearsign clone comformat configure content cookies db delta deltacmd descendants diff diffcmd dispatch doc email encode etag event export file finfo foci forum fshell fusefs glob graph gzip hname http http_socket http_ssl http_transport import info json json_artifact json_branch json_config json_diff json_dir json_finfo json_login json_query json_report json_status json_tag json_timeline json_user json_wiki leaf loadctrl login lookslike main manifest markdown markdown_html md5 merge merge3 moderate name path piechart pivot popen pqueue printf publish purge rebuild regexp report rss schema search security_audit setup setupuser sha1 sha1hard sha3 shun sitemap skins smtp sqlcmd stash stat statrep style sync tag tar th_main timeline tkt tktsetup undo unicode unversioned update url user utf8 util verify vfile webmail wiki wikiformat winfile winhttp wysiwyg xfer xfersetup zip shell sqlite3 th th_lang > $@ + +echo add alerts allrepo attach backoffice bag bisect blob branch browse builtin bundle cache capabilities captcha cgi checkin checkout clearsign clone comformat configure content cookies db delta deltacmd descendants diff diffcmd dispatch doc encode etag event export file finfo foci forum fshell fusefs glob graph gzip hname http http_socket http_ssl http_transport import info json json_artifact json_branch json_config json_diff json_dir json_finfo json_login json_query json_report json_status json_tag json_timeline json_user json_wiki leaf loadctrl login lookslike main manifest markdown markdown_html md5 merge merge3 moderate name path piechart pivot popen pqueue printf publish purge rebuild regexp report rss schema search security_audit setup setupuser sha1 sha1hard sha3 shun sitemap skins smtp sqlcmd stash stat statrep style sync tag tar th_main timeline tkt tktsetup undo unicode unversioned update url user utf8 util verify vfile webmail wiki wikiformat winfile winhttp wysiwyg xfer xfersetup zip shell sqlite3 th th_lang > $@ +echo fossil >> $@ +echo fossil >> $@ +echo $(LIBS) >> $@ +echo. >> $@ +echo fossil >> $@ @@ -134,10 +134,16 @@ $(OBJDIR)\add$O : add_.c add.h $(TCC) -o$@ -c add_.c add_.c : $(SRCDIR)\add.c +translate$E $** > $@ + +$(OBJDIR)\alerts$O : alerts_.c alerts.h + $(TCC) -o$@ -c alerts_.c + +alerts_.c : $(SRCDIR)\alerts.c + +translate$E $** > $@ $(OBJDIR)\allrepo$O : allrepo_.c allrepo.h $(TCC) -o$@ -c allrepo_.c allrepo_.c : $(SRCDIR)\allrepo.c @@ -315,16 +321,10 @@ $(TCC) -o$@ -c doc_.c doc_.c : $(SRCDIR)\doc.c +translate$E $** > $@ -$(OBJDIR)\email$O : email_.c email.h - $(TCC) -o$@ -c email_.c - -email_.c : $(SRCDIR)\email.c - +translate$E $** > $@ - $(OBJDIR)\encode$O : encode_.c encode.h $(TCC) -o$@ -c encode_.c encode_.c : $(SRCDIR)\encode.c +translate$E $** > $@ @@ -940,7 +940,7 @@ zip_.c : $(SRCDIR)\zip.c +translate$E $** > $@ headers: makeheaders$E page_index.h builtin_data.h default_css.h VERSION.h - +makeheaders$E add_.c:add.h allrepo_.c:allrepo.h attach_.c:attach.h backoffice_.c:backoffice.h bag_.c:bag.h bisect_.c:bisect.h blob_.c:blob.h branch_.c:branch.h browse_.c:browse.h builtin_.c:builtin.h bundle_.c:bundle.h cache_.c:cache.h capabilities_.c:capabilities.h captcha_.c:captcha.h cgi_.c:cgi.h checkin_.c:checkin.h checkout_.c:checkout.h clearsign_.c:clearsign.h clone_.c:clone.h comformat_.c:comformat.h configure_.c:configure.h content_.c:content.h cookies_.c:cookies.h db_.c:db.h delta_.c:delta.h deltacmd_.c:deltacmd.h descendants_.c:descendants.h diff_.c:diff.h diffcmd_.c:diffcmd.h dispatch_.c:dispatch.h doc_.c:doc.h email_.c:email.h encode_.c:encode.h etag_.c:etag.h event_.c:event.h export_.c:export.h file_.c:file.h finfo_.c:finfo.h foci_.c:foci.h forum_.c:forum.h fshell_.c:fshell.h fusefs_.c:fusefs.h glob_.c:glob.h graph_.c:graph.h gzip_.c:gzip.h hname_.c:hname.h http_.c:http.h http_socket_.c:http_socket.h http_ssl_.c:http_ssl.h http_transport_.c:http_transport.h import_.c:import.h info_.c:info.h json_.c:json.h json_artifact_.c:json_artifact.h json_branch_.c:json_branch.h json_config_.c:json_config.h json_diff_.c:json_diff.h json_dir_.c:json_dir.h json_finfo_.c:json_finfo.h json_login_.c:json_login.h json_query_.c:json_query.h json_report_.c:json_report.h json_status_.c:json_status.h json_tag_.c:json_tag.h json_timeline_.c:json_timeline.h json_user_.c:json_user.h json_wiki_.c:json_wiki.h leaf_.c:leaf.h loadctrl_.c:loadctrl.h login_.c:login.h lookslike_.c:lookslike.h main_.c:main.h manifest_.c:manifest.h markdown_.c:markdown.h markdown_html_.c:markdown_html.h md5_.c:md5.h merge_.c:merge.h merge3_.c:merge3.h moderate_.c:moderate.h name_.c:name.h path_.c:path.h piechart_.c:piechart.h pivot_.c:pivot.h popen_.c:popen.h pqueue_.c:pqueue.h printf_.c:printf.h publish_.c:publish.h purge_.c:purge.h rebuild_.c:rebuild.h regexp_.c:regexp.h report_.c:report.h rss_.c:rss.h schema_.c:schema.h search_.c:search.h security_audit_.c:security_audit.h setup_.c:setup.h setupuser_.c:setupuser.h sha1_.c:sha1.h sha1hard_.c:sha1hard.h sha3_.c:sha3.h shun_.c:shun.h sitemap_.c:sitemap.h skins_.c:skins.h smtp_.c:smtp.h sqlcmd_.c:sqlcmd.h stash_.c:stash.h stat_.c:stat.h statrep_.c:statrep.h style_.c:style.h sync_.c:sync.h tag_.c:tag.h tar_.c:tar.h th_main_.c:th_main.h timeline_.c:timeline.h tkt_.c:tkt.h tktsetup_.c:tktsetup.h undo_.c:undo.h unicode_.c:unicode.h unversioned_.c:unversioned.h update_.c:update.h url_.c:url.h user_.c:user.h utf8_.c:utf8.h util_.c:util.h verify_.c:verify.h vfile_.c:vfile.h webmail_.c:webmail.h wiki_.c:wiki.h wikiformat_.c:wikiformat.h winfile_.c:winfile.h winhttp_.c:winhttp.h wysiwyg_.c:wysiwyg.h xfer_.c:xfer.h xfersetup_.c:xfersetup.h zip_.c:zip.h $(SRCDIR)\sqlite3.h $(SRCDIR)\th.h VERSION.h $(SRCDIR)\cson_amalgamation.h + +makeheaders$E add_.c:add.h alerts_.c:alerts.h allrepo_.c:allrepo.h attach_.c:attach.h backoffice_.c:backoffice.h bag_.c:bag.h bisect_.c:bisect.h blob_.c:blob.h branch_.c:branch.h browse_.c:browse.h builtin_.c:builtin.h bundle_.c:bundle.h cache_.c:cache.h capabilities_.c:capabilities.h captcha_.c:captcha.h cgi_.c:cgi.h checkin_.c:checkin.h checkout_.c:checkout.h clearsign_.c:clearsign.h clone_.c:clone.h comformat_.c:comformat.h configure_.c:configure.h content_.c:content.h cookies_.c:cookies.h db_.c:db.h delta_.c:delta.h deltacmd_.c:deltacmd.h descendants_.c:descendants.h diff_.c:diff.h diffcmd_.c:diffcmd.h dispatch_.c:dispatch.h doc_.c:doc.h encode_.c:encode.h etag_.c:etag.h event_.c:event.h export_.c:export.h file_.c:file.h finfo_.c:finfo.h foci_.c:foci.h forum_.c:forum.h fshell_.c:fshell.h fusefs_.c:fusefs.h glob_.c:glob.h graph_.c:graph.h gzip_.c:gzip.h hname_.c:hname.h http_.c:http.h http_socket_.c:http_socket.h http_ssl_.c:http_ssl.h http_transport_.c:http_transport.h import_.c:import.h info_.c:info.h json_.c:json.h json_artifact_.c:json_artifact.h json_branch_.c:json_branch.h json_config_.c:json_config.h json_diff_.c:json_diff.h json_dir_.c:json_dir.h json_finfo_.c:json_finfo.h json_login_.c:json_login.h json_query_.c:json_query.h json_report_.c:json_report.h json_status_.c:json_status.h json_tag_.c:json_tag.h json_timeline_.c:json_timeline.h json_user_.c:json_user.h json_wiki_.c:json_wiki.h leaf_.c:leaf.h loadctrl_.c:loadctrl.h login_.c:login.h lookslike_.c:lookslike.h main_.c:main.h manifest_.c:manifest.h markdown_.c:markdown.h markdown_html_.c:markdown_html.h md5_.c:md5.h merge_.c:merge.h merge3_.c:merge3.h moderate_.c:moderate.h name_.c:name.h path_.c:path.h piechart_.c:piechart.h pivot_.c:pivot.h popen_.c:popen.h pqueue_.c:pqueue.h printf_.c:printf.h publish_.c:publish.h purge_.c:purge.h rebuild_.c:rebuild.h regexp_.c:regexp.h report_.c:report.h rss_.c:rss.h schema_.c:schema.h search_.c:search.h security_audit_.c:security_audit.h setup_.c:setup.h setupuser_.c:setupuser.h sha1_.c:sha1.h sha1hard_.c:sha1hard.h sha3_.c:sha3.h shun_.c:shun.h sitemap_.c:sitemap.h skins_.c:skins.h smtp_.c:smtp.h sqlcmd_.c:sqlcmd.h stash_.c:stash.h stat_.c:stat.h statrep_.c:statrep.h style_.c:style.h sync_.c:sync.h tag_.c:tag.h tar_.c:tar.h th_main_.c:th_main.h timeline_.c:timeline.h tkt_.c:tkt.h tktsetup_.c:tktsetup.h undo_.c:undo.h unicode_.c:unicode.h unversioned_.c:unversioned.h update_.c:update.h url_.c:url.h user_.c:user.h utf8_.c:utf8.h util_.c:util.h verify_.c:verify.h vfile_.c:vfile.h webmail_.c:webmail.h wiki_.c:wiki.h wikiformat_.c:wikiformat.h winfile_.c:winfile.h winhttp_.c:winhttp.h wysiwyg_.c:wysiwyg.h xfer_.c:xfer.h xfersetup_.c:xfersetup.h zip_.c:zip.h $(SRCDIR)\sqlite3.h $(SRCDIR)\th.h VERSION.h $(SRCDIR)\cson_amalgamation.h @copy /Y nul: headers Index: win/Makefile.mingw ================================================================== --- win/Makefile.mingw +++ win/Makefile.mingw @@ -160,11 +160,11 @@ endif #### Disable creation of the OpenSSL shared libraries. Also, disable support # for SSLv3 (i.e. thereby forcing the use of TLS). # -SSLCONFIG += no-ssl3 enable-capieng no-weak-ssl-ciphers no-shared +SSLCONFIG += no-ssl3 no-weak-ssl-ciphers no-shared #### When using zlib, make sure that OpenSSL is configured to use the zlib # that Fossil knows about (i.e. the one within the source tree). # ifndef FOSSIL_ENABLE_MINIZ @@ -437,10 +437,11 @@ XBCC = $(BCC) $(CFLAGS) XTCC = $(TCC) $(CFLAGS) -I. -I$(SRCDIR) SRC = \ $(SRCDIR)/add.c \ + $(SRCDIR)/alerts.c \ $(SRCDIR)/allrepo.c \ $(SRCDIR)/attach.c \ $(SRCDIR)/backoffice.c \ $(SRCDIR)/bag.c \ $(SRCDIR)/bisect.c \ @@ -467,11 +468,10 @@ $(SRCDIR)/descendants.c \ $(SRCDIR)/diff.c \ $(SRCDIR)/diffcmd.c \ $(SRCDIR)/dispatch.c \ $(SRCDIR)/doc.c \ - $(SRCDIR)/email.c \ $(SRCDIR)/encode.c \ $(SRCDIR)/etag.c \ $(SRCDIR)/event.c \ $(SRCDIR)/export.c \ $(SRCDIR)/file.c \ @@ -600,10 +600,11 @@ $(SRCDIR)/../skins/bootstrap/header.txt \ $(SRCDIR)/../skins/default/css.txt \ $(SRCDIR)/../skins/default/details.txt \ $(SRCDIR)/../skins/default/footer.txt \ $(SRCDIR)/../skins/default/header.txt \ + $(SRCDIR)/../skins/default/js.txt \ $(SRCDIR)/../skins/eagle/css.txt \ $(SRCDIR)/../skins/eagle/details.txt \ $(SRCDIR)/../skins/eagle/footer.txt \ $(SRCDIR)/../skins/eagle/header.txt \ $(SRCDIR)/../skins/enhanced1/css.txt \ @@ -646,10 +647,11 @@ $(SRCDIR)/useredit.js \ $(SRCDIR)/wiki.wiki TRANS_SRC = \ $(OBJDIR)/add_.c \ + $(OBJDIR)/alerts_.c \ $(OBJDIR)/allrepo_.c \ $(OBJDIR)/attach_.c \ $(OBJDIR)/backoffice_.c \ $(OBJDIR)/bag_.c \ $(OBJDIR)/bisect_.c \ @@ -676,11 +678,10 @@ $(OBJDIR)/descendants_.c \ $(OBJDIR)/diff_.c \ $(OBJDIR)/diffcmd_.c \ $(OBJDIR)/dispatch_.c \ $(OBJDIR)/doc_.c \ - $(OBJDIR)/email_.c \ $(OBJDIR)/encode_.c \ $(OBJDIR)/etag_.c \ $(OBJDIR)/event_.c \ $(OBJDIR)/export_.c \ $(OBJDIR)/file_.c \ @@ -783,10 +784,11 @@ $(OBJDIR)/xfersetup_.c \ $(OBJDIR)/zip_.c OBJ = \ $(OBJDIR)/add.o \ + $(OBJDIR)/alerts.o \ $(OBJDIR)/allrepo.o \ $(OBJDIR)/attach.o \ $(OBJDIR)/backoffice.o \ $(OBJDIR)/bag.o \ $(OBJDIR)/bisect.o \ @@ -813,11 +815,10 @@ $(OBJDIR)/descendants.o \ $(OBJDIR)/diff.o \ $(OBJDIR)/diffcmd.o \ $(OBJDIR)/dispatch.o \ $(OBJDIR)/doc.o \ - $(OBJDIR)/email.o \ $(OBJDIR)/encode.o \ $(OBJDIR)/etag.o \ $(OBJDIR)/event.o \ $(OBJDIR)/export.o \ $(OBJDIR)/file.o \ @@ -1139,10 +1140,11 @@ $(OBJDIR)/builtin_data.h: $(MKBUILTIN) $(EXTRA_FILES) $(MKBUILTIN) --prefix $(SRCDIR)/ $(EXTRA_FILES) >$@ $(OBJDIR)/headers: $(OBJDIR)/page_index.h $(OBJDIR)/builtin_data.h $(OBJDIR)/default_css.h $(MAKEHEADERS) $(OBJDIR)/VERSION.h $(MAKEHEADERS) $(OBJDIR)/add_.c:$(OBJDIR)/add.h \ + $(OBJDIR)/alerts_.c:$(OBJDIR)/alerts.h \ $(OBJDIR)/allrepo_.c:$(OBJDIR)/allrepo.h \ $(OBJDIR)/attach_.c:$(OBJDIR)/attach.h \ $(OBJDIR)/backoffice_.c:$(OBJDIR)/backoffice.h \ $(OBJDIR)/bag_.c:$(OBJDIR)/bag.h \ $(OBJDIR)/bisect_.c:$(OBJDIR)/bisect.h \ @@ -1169,11 +1171,10 @@ $(OBJDIR)/descendants_.c:$(OBJDIR)/descendants.h \ $(OBJDIR)/diff_.c:$(OBJDIR)/diff.h \ $(OBJDIR)/diffcmd_.c:$(OBJDIR)/diffcmd.h \ $(OBJDIR)/dispatch_.c:$(OBJDIR)/dispatch.h \ $(OBJDIR)/doc_.c:$(OBJDIR)/doc.h \ - $(OBJDIR)/email_.c:$(OBJDIR)/email.h \ $(OBJDIR)/encode_.c:$(OBJDIR)/encode.h \ $(OBJDIR)/etag_.c:$(OBJDIR)/etag.h \ $(OBJDIR)/event_.c:$(OBJDIR)/event.h \ $(OBJDIR)/export_.c:$(OBJDIR)/export.h \ $(OBJDIR)/file_.c:$(OBJDIR)/file.h \ @@ -1289,10 +1290,18 @@ $(OBJDIR)/add.o: $(OBJDIR)/add_.c $(OBJDIR)/add.h $(SRCDIR)/config.h $(XTCC) -o $(OBJDIR)/add.o -c $(OBJDIR)/add_.c $(OBJDIR)/add.h: $(OBJDIR)/headers + +$(OBJDIR)/alerts_.c: $(SRCDIR)/alerts.c $(TRANSLATE) + $(TRANSLATE) $(SRCDIR)/alerts.c >$@ + +$(OBJDIR)/alerts.o: $(OBJDIR)/alerts_.c $(OBJDIR)/alerts.h $(SRCDIR)/config.h + $(XTCC) -o $(OBJDIR)/alerts.o -c $(OBJDIR)/alerts_.c + +$(OBJDIR)/alerts.h: $(OBJDIR)/headers $(OBJDIR)/allrepo_.c: $(SRCDIR)/allrepo.c $(TRANSLATE) $(TRANSLATE) $(SRCDIR)/allrepo.c >$@ $(OBJDIR)/allrepo.o: $(OBJDIR)/allrepo_.c $(OBJDIR)/allrepo.h $(SRCDIR)/config.h @@ -1530,18 +1539,10 @@ $(OBJDIR)/doc.o: $(OBJDIR)/doc_.c $(OBJDIR)/doc.h $(SRCDIR)/config.h $(XTCC) -o $(OBJDIR)/doc.o -c $(OBJDIR)/doc_.c $(OBJDIR)/doc.h: $(OBJDIR)/headers -$(OBJDIR)/email_.c: $(SRCDIR)/email.c $(TRANSLATE) - $(TRANSLATE) $(SRCDIR)/email.c >$@ - -$(OBJDIR)/email.o: $(OBJDIR)/email_.c $(OBJDIR)/email.h $(SRCDIR)/config.h - $(XTCC) -o $(OBJDIR)/email.o -c $(OBJDIR)/email_.c - -$(OBJDIR)/email.h: $(OBJDIR)/headers - $(OBJDIR)/encode_.c: $(SRCDIR)/encode.c $(TRANSLATE) $(TRANSLATE) $(SRCDIR)/encode.c >$@ $(OBJDIR)/encode.o: $(OBJDIR)/encode_.c $(OBJDIR)/encode.h $(SRCDIR)/config.h $(XTCC) -o $(OBJDIR)/encode.o -c $(OBJDIR)/encode_.c Index: win/Makefile.mingw.mistachkin ================================================================== --- win/Makefile.mingw.mistachkin +++ win/Makefile.mingw.mistachkin @@ -160,11 +160,11 @@ endif #### Disable creation of the OpenSSL shared libraries. Also, disable support # for SSLv3 (i.e. thereby forcing the use of TLS). # -SSLCONFIG += no-ssl3 enable-capieng no-weak-ssl-ciphers no-shared +SSLCONFIG += no-ssl3 no-weak-ssl-ciphers no-shared #### When using zlib, make sure that OpenSSL is configured to use the zlib # that Fossil knows about (i.e. the one within the source tree). # ifndef FOSSIL_ENABLE_MINIZ @@ -437,10 +437,11 @@ XBCC = $(BCC) $(CFLAGS) XTCC = $(TCC) $(CFLAGS) -I. -I$(SRCDIR) SRC = \ $(SRCDIR)/add.c \ + $(SRCDIR)/alerts.c \ $(SRCDIR)/allrepo.c \ $(SRCDIR)/attach.c \ $(SRCDIR)/backoffice.c \ $(SRCDIR)/bag.c \ $(SRCDIR)/bisect.c \ @@ -467,11 +468,10 @@ $(SRCDIR)/descendants.c \ $(SRCDIR)/diff.c \ $(SRCDIR)/diffcmd.c \ $(SRCDIR)/dispatch.c \ $(SRCDIR)/doc.c \ - $(SRCDIR)/email.c \ $(SRCDIR)/encode.c \ $(SRCDIR)/etag.c \ $(SRCDIR)/event.c \ $(SRCDIR)/export.c \ $(SRCDIR)/file.c \ @@ -532,10 +532,11 @@ $(SRCDIR)/rss.c \ $(SRCDIR)/schema.c \ $(SRCDIR)/search.c \ $(SRCDIR)/security_audit.c \ $(SRCDIR)/setup.c \ + $(SRCDIR)/setupuser.c \ $(SRCDIR)/sha1.c \ $(SRCDIR)/sha1hard.c \ $(SRCDIR)/sha3.c \ $(SRCDIR)/shun.c \ $(SRCDIR)/sitemap.c \ @@ -599,10 +600,11 @@ $(SRCDIR)/../skins/bootstrap/header.txt \ $(SRCDIR)/../skins/default/css.txt \ $(SRCDIR)/../skins/default/details.txt \ $(SRCDIR)/../skins/default/footer.txt \ $(SRCDIR)/../skins/default/header.txt \ + $(SRCDIR)/../skins/default/js.txt \ $(SRCDIR)/../skins/eagle/css.txt \ $(SRCDIR)/../skins/eagle/details.txt \ $(SRCDIR)/../skins/eagle/footer.txt \ $(SRCDIR)/../skins/eagle/header.txt \ $(SRCDIR)/../skins/enhanced1/css.txt \ @@ -645,10 +647,11 @@ $(SRCDIR)/useredit.js \ $(SRCDIR)/wiki.wiki TRANS_SRC = \ $(OBJDIR)/add_.c \ + $(OBJDIR)/alerts_.c \ $(OBJDIR)/allrepo_.c \ $(OBJDIR)/attach_.c \ $(OBJDIR)/backoffice_.c \ $(OBJDIR)/bag_.c \ $(OBJDIR)/bisect_.c \ @@ -675,11 +678,10 @@ $(OBJDIR)/descendants_.c \ $(OBJDIR)/diff_.c \ $(OBJDIR)/diffcmd_.c \ $(OBJDIR)/dispatch_.c \ $(OBJDIR)/doc_.c \ - $(OBJDIR)/email_.c \ $(OBJDIR)/encode_.c \ $(OBJDIR)/etag_.c \ $(OBJDIR)/event_.c \ $(OBJDIR)/export_.c \ $(OBJDIR)/file_.c \ @@ -740,10 +742,11 @@ $(OBJDIR)/rss_.c \ $(OBJDIR)/schema_.c \ $(OBJDIR)/search_.c \ $(OBJDIR)/security_audit_.c \ $(OBJDIR)/setup_.c \ + $(OBJDIR)/setupuser_.c \ $(OBJDIR)/sha1_.c \ $(OBJDIR)/sha1hard_.c \ $(OBJDIR)/sha3_.c \ $(OBJDIR)/shun_.c \ $(OBJDIR)/sitemap_.c \ @@ -781,10 +784,11 @@ $(OBJDIR)/xfersetup_.c \ $(OBJDIR)/zip_.c OBJ = \ $(OBJDIR)/add.o \ + $(OBJDIR)/alerts.o \ $(OBJDIR)/allrepo.o \ $(OBJDIR)/attach.o \ $(OBJDIR)/backoffice.o \ $(OBJDIR)/bag.o \ $(OBJDIR)/bisect.o \ @@ -811,11 +815,10 @@ $(OBJDIR)/descendants.o \ $(OBJDIR)/diff.o \ $(OBJDIR)/diffcmd.o \ $(OBJDIR)/dispatch.o \ $(OBJDIR)/doc.o \ - $(OBJDIR)/email.o \ $(OBJDIR)/encode.o \ $(OBJDIR)/etag.o \ $(OBJDIR)/event.o \ $(OBJDIR)/export.o \ $(OBJDIR)/file.o \ @@ -876,10 +879,11 @@ $(OBJDIR)/rss.o \ $(OBJDIR)/schema.o \ $(OBJDIR)/search.o \ $(OBJDIR)/security_audit.o \ $(OBJDIR)/setup.o \ + $(OBJDIR)/setupuser.o \ $(OBJDIR)/sha1.o \ $(OBJDIR)/sha1hard.o \ $(OBJDIR)/sha3.o \ $(OBJDIR)/shun.o \ $(OBJDIR)/sitemap.o \ @@ -1136,10 +1140,11 @@ $(OBJDIR)/builtin_data.h: $(MKBUILTIN) $(EXTRA_FILES) $(MKBUILTIN) --prefix $(SRCDIR)/ $(EXTRA_FILES) >$@ $(OBJDIR)/headers: $(OBJDIR)/page_index.h $(OBJDIR)/builtin_data.h $(OBJDIR)/default_css.h $(MAKEHEADERS) $(OBJDIR)/VERSION.h $(MAKEHEADERS) $(OBJDIR)/add_.c:$(OBJDIR)/add.h \ + $(OBJDIR)/alerts_.c:$(OBJDIR)/alerts.h \ $(OBJDIR)/allrepo_.c:$(OBJDIR)/allrepo.h \ $(OBJDIR)/attach_.c:$(OBJDIR)/attach.h \ $(OBJDIR)/backoffice_.c:$(OBJDIR)/backoffice.h \ $(OBJDIR)/bag_.c:$(OBJDIR)/bag.h \ $(OBJDIR)/bisect_.c:$(OBJDIR)/bisect.h \ @@ -1166,11 +1171,10 @@ $(OBJDIR)/descendants_.c:$(OBJDIR)/descendants.h \ $(OBJDIR)/diff_.c:$(OBJDIR)/diff.h \ $(OBJDIR)/diffcmd_.c:$(OBJDIR)/diffcmd.h \ $(OBJDIR)/dispatch_.c:$(OBJDIR)/dispatch.h \ $(OBJDIR)/doc_.c:$(OBJDIR)/doc.h \ - $(OBJDIR)/email_.c:$(OBJDIR)/email.h \ $(OBJDIR)/encode_.c:$(OBJDIR)/encode.h \ $(OBJDIR)/etag_.c:$(OBJDIR)/etag.h \ $(OBJDIR)/event_.c:$(OBJDIR)/event.h \ $(OBJDIR)/export_.c:$(OBJDIR)/export.h \ $(OBJDIR)/file_.c:$(OBJDIR)/file.h \ @@ -1231,10 +1235,11 @@ $(OBJDIR)/rss_.c:$(OBJDIR)/rss.h \ $(OBJDIR)/schema_.c:$(OBJDIR)/schema.h \ $(OBJDIR)/search_.c:$(OBJDIR)/search.h \ $(OBJDIR)/security_audit_.c:$(OBJDIR)/security_audit.h \ $(OBJDIR)/setup_.c:$(OBJDIR)/setup.h \ + $(OBJDIR)/setupuser_.c:$(OBJDIR)/setupuser.h \ $(OBJDIR)/sha1_.c:$(OBJDIR)/sha1.h \ $(OBJDIR)/sha1hard_.c:$(OBJDIR)/sha1hard.h \ $(OBJDIR)/sha3_.c:$(OBJDIR)/sha3.h \ $(OBJDIR)/shun_.c:$(OBJDIR)/shun.h \ $(OBJDIR)/sitemap_.c:$(OBJDIR)/sitemap.h \ @@ -1285,10 +1290,18 @@ $(OBJDIR)/add.o: $(OBJDIR)/add_.c $(OBJDIR)/add.h $(SRCDIR)/config.h $(XTCC) -o $(OBJDIR)/add.o -c $(OBJDIR)/add_.c $(OBJDIR)/add.h: $(OBJDIR)/headers + +$(OBJDIR)/alerts_.c: $(SRCDIR)/alerts.c $(TRANSLATE) + $(TRANSLATE) $(SRCDIR)/alerts.c >$@ + +$(OBJDIR)/alerts.o: $(OBJDIR)/alerts_.c $(OBJDIR)/alerts.h $(SRCDIR)/config.h + $(XTCC) -o $(OBJDIR)/alerts.o -c $(OBJDIR)/alerts_.c + +$(OBJDIR)/alerts.h: $(OBJDIR)/headers $(OBJDIR)/allrepo_.c: $(SRCDIR)/allrepo.c $(TRANSLATE) $(TRANSLATE) $(SRCDIR)/allrepo.c >$@ $(OBJDIR)/allrepo.o: $(OBJDIR)/allrepo_.c $(OBJDIR)/allrepo.h $(SRCDIR)/config.h @@ -1526,18 +1539,10 @@ $(OBJDIR)/doc.o: $(OBJDIR)/doc_.c $(OBJDIR)/doc.h $(SRCDIR)/config.h $(XTCC) -o $(OBJDIR)/doc.o -c $(OBJDIR)/doc_.c $(OBJDIR)/doc.h: $(OBJDIR)/headers -$(OBJDIR)/email_.c: $(SRCDIR)/email.c $(TRANSLATE) - $(TRANSLATE) $(SRCDIR)/email.c >$@ - -$(OBJDIR)/email.o: $(OBJDIR)/email_.c $(OBJDIR)/email.h $(SRCDIR)/config.h - $(XTCC) -o $(OBJDIR)/email.o -c $(OBJDIR)/email_.c - -$(OBJDIR)/email.h: $(OBJDIR)/headers - $(OBJDIR)/encode_.c: $(SRCDIR)/encode.c $(TRANSLATE) $(TRANSLATE) $(SRCDIR)/encode.c >$@ $(OBJDIR)/encode.o: $(OBJDIR)/encode_.c $(OBJDIR)/encode.h $(SRCDIR)/config.h $(XTCC) -o $(OBJDIR)/encode.o -c $(OBJDIR)/encode_.c @@ -2045,10 +2050,18 @@ $(OBJDIR)/setup.o: $(OBJDIR)/setup_.c $(OBJDIR)/setup.h $(SRCDIR)/config.h $(XTCC) -o $(OBJDIR)/setup.o -c $(OBJDIR)/setup_.c $(OBJDIR)/setup.h: $(OBJDIR)/headers + +$(OBJDIR)/setupuser_.c: $(SRCDIR)/setupuser.c $(TRANSLATE) + $(TRANSLATE) $(SRCDIR)/setupuser.c >$@ + +$(OBJDIR)/setupuser.o: $(OBJDIR)/setupuser_.c $(OBJDIR)/setupuser.h $(SRCDIR)/config.h + $(XTCC) -o $(OBJDIR)/setupuser.o -c $(OBJDIR)/setupuser_.c + +$(OBJDIR)/setupuser.h: $(OBJDIR)/headers $(OBJDIR)/sha1_.c: $(SRCDIR)/sha1.c $(TRANSLATE) $(TRANSLATE) $(SRCDIR)/sha1.c >$@ $(OBJDIR)/sha1.o: $(OBJDIR)/sha1_.c $(OBJDIR)/sha1.h $(SRCDIR)/config.h Index: win/Makefile.msc ================================================================== --- win/Makefile.msc +++ win/Makefile.msc @@ -110,11 +110,11 @@ SSLLFLAGS = /nologo /opt:ref /debug SSLLIB = ssleay32.lib libeay32.lib user32.lib gdi32.lib crypt32.lib !if "$(PLATFORM)"=="amd64" || "$(PLATFORM)"=="x64" !message Using 'x64' platform for OpenSSL... # BUGBUG (OpenSSL): Using "no-ssl*" here breaks the build. -# SSLCONFIG = VC-WIN64A no-asm no-ssl3 enable-capieng no-weak-ssl-ciphers +# SSLCONFIG = VC-WIN64A no-asm no-ssl3 no-weak-ssl-ciphers SSLCONFIG = VC-WIN64A no-asm !if $(FOSSIL_DYNAMIC_BUILD)!=0 SSLCONFIG = $(SSLCONFIG) shared !else SSLCONFIG = $(SSLCONFIG) no-shared @@ -125,16 +125,16 @@ !else SSLNMAKE = ms\nt.mak all !endif # BUGBUG (OpenSSL): Using "OPENSSL_NO_SSL*" here breaks dynamic builds. !if $(FOSSIL_DYNAMIC_BUILD)==0 -SSLCFLAGS = -DOPENSSL_NO_SSL3 +SSLCFLAGS = -DOPENSSL_NO_SSL3 -DOPENSSL_NO_WEAK_SSL_CIPHERS !endif !elseif "$(PLATFORM)"=="ia64" !message Using 'ia64' platform for OpenSSL... # BUGBUG (OpenSSL): Using "no-ssl*" here breaks the build. -# SSLCONFIG = VC-WIN64I no-asm no-ssl3 enable-capieng no-weak-ssl-ciphers +# SSLCONFIG = VC-WIN64I no-asm no-ssl3 no-weak-ssl-ciphers SSLCONFIG = VC-WIN64I no-asm !if $(FOSSIL_DYNAMIC_BUILD)!=0 SSLCONFIG = $(SSLCONFIG) shared !else SSLCONFIG = $(SSLCONFIG) no-shared @@ -145,16 +145,16 @@ !else SSLNMAKE = ms\nt.mak all !endif # BUGBUG (OpenSSL): Using "OPENSSL_NO_SSL*" here breaks dynamic builds. !if $(FOSSIL_DYNAMIC_BUILD)==0 -SSLCFLAGS = -DOPENSSL_NO_SSL3 +SSLCFLAGS = -DOPENSSL_NO_SSL3 -DOPENSSL_NO_WEAK_SSL_CIPHERS !endif !else !message Assuming 'x86' platform for OpenSSL... # BUGBUG (OpenSSL): Using "no-ssl*" here breaks the build. -# SSLCONFIG = VC-WIN32 no-asm no-ssl3 enable-capieng no-weak-ssl-ciphers +# SSLCONFIG = VC-WIN32 no-asm no-ssl3 no-weak-ssl-ciphers SSLCONFIG = VC-WIN32 no-asm !if $(FOSSIL_DYNAMIC_BUILD)!=0 SSLCONFIG = $(SSLCONFIG) shared !else SSLCONFIG = $(SSLCONFIG) no-shared @@ -165,11 +165,11 @@ !else SSLNMAKE = ms\nt.mak all !endif # BUGBUG (OpenSSL): Using "OPENSSL_NO_SSL*" here breaks dynamic builds. !if $(FOSSIL_DYNAMIC_BUILD)==0 -SSLCFLAGS = -DOPENSSL_NO_SSL3 +SSLCFLAGS = -DOPENSSL_NO_SSL3 -DOPENSSL_NO_WEAK_SSL_CIPHERS !endif !endif !endif !if $(FOSSIL_ENABLE_TCL)!=0 @@ -379,10 +379,11 @@ MINIZ_OPTIONS = /DMINIZ_NO_STDIO \ /DMINIZ_NO_TIME \ /DMINIZ_NO_ARCHIVE_APIS SRC = add_.c \ + alerts_.c \ allrepo_.c \ attach_.c \ backoffice_.c \ bag_.c \ bisect_.c \ @@ -409,11 +410,10 @@ descendants_.c \ diff_.c \ diffcmd_.c \ dispatch_.c \ doc_.c \ - email_.c \ encode_.c \ etag_.c \ event_.c \ export_.c \ file_.c \ @@ -541,10 +541,11 @@ $(SRCDIR)\..\skins\bootstrap\header.txt \ $(SRCDIR)\..\skins\default\css.txt \ $(SRCDIR)\..\skins\default\details.txt \ $(SRCDIR)\..\skins\default\footer.txt \ $(SRCDIR)\..\skins\default\header.txt \ + $(SRCDIR)\..\skins\default\js.txt \ $(SRCDIR)\..\skins\eagle\css.txt \ $(SRCDIR)\..\skins\eagle\details.txt \ $(SRCDIR)\..\skins\eagle\footer.txt \ $(SRCDIR)\..\skins\eagle\header.txt \ $(SRCDIR)\..\skins\enhanced1\css.txt \ @@ -586,10 +587,11 @@ $(SRCDIR)\tree.js \ $(SRCDIR)\useredit.js \ $(SRCDIR)\wiki.wiki OBJ = $(OX)\add$O \ + $(OX)\alerts$O \ $(OX)\allrepo$O \ $(OX)\attach$O \ $(OX)\backoffice$O \ $(OX)\bag$O \ $(OX)\bisect$O \ @@ -617,11 +619,10 @@ $(OX)\descendants$O \ $(OX)\diff$O \ $(OX)\diffcmd$O \ $(OX)\dispatch$O \ $(OX)\doc$O \ - $(OX)\email$O \ $(OX)\encode$O \ $(OX)\etag$O \ $(OX)\event$O \ $(OX)\export$O \ $(OX)\file$O \ @@ -782,10 +783,11 @@ if exist $@.manifest \ $(MTC) -nologo -manifest $@.manifest -outputresource:$@;1 $(OX)\linkopts: $B\win\Makefile.msc echo $(OX)\add.obj > $@ + echo $(OX)\alerts.obj >> $@ echo $(OX)\allrepo.obj >> $@ echo $(OX)\attach.obj >> $@ echo $(OX)\backoffice.obj >> $@ echo $(OX)\bag.obj >> $@ echo $(OX)\bisect.obj >> $@ @@ -813,11 +815,10 @@ echo $(OX)\descendants.obj >> $@ echo $(OX)\diff.obj >> $@ echo $(OX)\diffcmd.obj >> $@ echo $(OX)\dispatch.obj >> $@ echo $(OX)\doc.obj >> $@ - echo $(OX)\email.obj >> $@ echo $(OX)\encode.obj >> $@ echo $(OX)\etag.obj >> $@ echo $(OX)\event.obj >> $@ echo $(OX)\export.obj >> $@ echo $(OX)\file.obj >> $@ @@ -1045,10 +1046,16 @@ $(OX)\add$O : add_.c add.h $(TCC) /Fo$@ -c add_.c add_.c : $(SRCDIR)\add.c translate$E $** > $@ + +$(OX)\alerts$O : alerts_.c alerts.h + $(TCC) /Fo$@ -c alerts_.c + +alerts_.c : $(SRCDIR)\alerts.c + translate$E $** > $@ $(OX)\allrepo$O : allrepo_.c allrepo.h $(TCC) /Fo$@ -c allrepo_.c allrepo_.c : $(SRCDIR)\allrepo.c @@ -1226,16 +1233,10 @@ $(TCC) /Fo$@ -c doc_.c doc_.c : $(SRCDIR)\doc.c translate$E $** > $@ -$(OX)\email$O : email_.c email.h - $(TCC) /Fo$@ -c email_.c - -email_.c : $(SRCDIR)\email.c - translate$E $** > $@ - $(OX)\encode$O : encode_.c encode.h $(TCC) /Fo$@ -c encode_.c encode_.c : $(SRCDIR)\encode.c translate$E $** > $@ @@ -1855,10 +1856,11 @@ fossil.res : $B\win\fossil.rc $(RCC) /fo $@ $** headers: makeheaders$E page_index.h builtin_data.h default_css.h VERSION.h makeheaders$E add_.c:add.h \ + alerts_.c:alerts.h \ allrepo_.c:allrepo.h \ attach_.c:attach.h \ backoffice_.c:backoffice.h \ bag_.c:bag.h \ bisect_.c:bisect.h \ @@ -1885,11 +1887,10 @@ descendants_.c:descendants.h \ diff_.c:diff.h \ diffcmd_.c:diffcmd.h \ dispatch_.c:dispatch.h \ doc_.c:doc.h \ - email_.c:email.h \ encode_.c:encode.h \ etag_.c:etag.h \ event_.c:event.h \ export_.c:export.h \ file_.c:file.h \ Index: www/aboutdownload.wiki ================================================================== --- www/aboutdownload.wiki +++ www/aboutdownload.wiki @@ -6,18 +6,19 @@ The [/uv/download.html|Download] page for the Fossil self-hosting repository is implemented using [./unvers.wiki|unversioned files]. The "download.html" screen itself, and the various build products are all stored as unversioned content. The download.html page uses AJAX to retrieve the [/help?cmd=/juvlist|/juvlist] webpage -for a list of all unversioned files. Javascript within the -download.html page then figures out which unversioned files are +for a list of all unversioned files. Javascript in the +[/uv/download.js?mimetype=text/plain|download.js] file (which is +sourced by "download.html") then figures out which unversioned files are build products and paints appropriate icons on the displayed download page. When a new version is generated, the developers use the [/help?cmd=uv|fossil uv edit] command to make minor changes -to the "[/uv/download.html?mimetype=text/plain|download.html]" +to the "[/uv/download.js?mimetype=text/plain|download.js]" file so that it knows about the new version number. Then the developers run the [/help?cmd=uv|fossil uv add] command for each build product. Finally, the [/help?cmd=uv|fossil uv sync] command is run to push all @@ -25,31 +26,36 @@ [./selfhost.wiki|three self-hosting repositories] for Fossil are updated automatically.

    2.0 Details

    -The current text of the "download.html" file can be seen -[/uv/download.html?mimetype=text/plain|here]. (Mouse-over that -hyperlink to see how the "mimetype=text/plain" query parameter -is added in order to display the file as plain text instead of -the usual HTML.) The default mimetype for "download.html" is -text/html. But because the entire page is enclosed within +The current text of the "download.html" and "download.js" files can +be seen at: + + * [/uv/download.html?mimetype=text/plain] + * [/uv/download.js?mimetype=text/plain] + +Notice how the hyperlinks above use the "mimetype=text/plain" +query parameter in order to display the file as plain text +instead of the usual HTML or Javascript. +The default mimetype for "download.html" is +text/html. But because the entire page is enclosed within <div class='fossil-doc' data-title='Download Page'>...</div> Fossil knows to add its standard header and footer information to the document, making it look just like any other page. See "[./embeddeddoc.wiki|embedded documentation]" for further details on -how this works. +how <div class='fossil-doc'> this works. With each new release, the "releases" variable in the javascript on -the [/uv/download.html?mimetype=text/plain|download.html] page is -edited (using "[/help?cmd=uv|fossil uv edit download.html]") to add +the [/uv/download.js?mimetype=text/plain|download.js] page is +edited (using "[/help?cmd=uv|fossil uv edit download.js]") to add details of the release. -When the javascript on the "download.html" page runs, it requests +When the javascript in the "download.js" file runs, it requests a listing of all unversioned content using the /juvlist URL. ([/juvlist|sample /juvlist output]). The content of the download page is constructed by matching unversioned files against regular expressions in the "releases" variable. @@ -62,11 +68,11 @@ [/help?cmd=uv|fossil uv sync] to push the new build product to the [./selfhost.wiki|various servers]. This process is repeated for each build product. When older builds are retired from the download page, the -[/uv/download.html?mimetype=text/plain|download.html] page is again +[/uv/download.js?mimetype=text/plain|download.js] page is again edited to remove the corresponding entry from the "release" variable and the edit is synced using [/help?cmd=uv|fossil uv sync]. This causes the build products to disappear from the download page immediately. But those build products are still taking up space in the unversioned content table of the Index: www/changes.wiki ================================================================== --- www/changes.wiki +++ www/changes.wiki @@ -1,17 +1,20 @@ Change Log

    Changes for Version 2.7 (2018-??-??)

    - * Add support for [./alerts.md|email alerts]. - * Add support for forums. - * Added new user capabilities letters needed to support alerts and forum. + * Add the [./alerts.md|email alerts] feature for commits, ticket + changes, wiki changes, forum posts, and announcements. + * Add the discussion forum feature. + * Add new user capabilities letters needed to support alerts and forum. Formerly, user capabilities were letters from [a-z], but with the enhancements, the supply of lower case letters was exhausted. User capabilities are now letters in [a-zA-Z0-9]. - * Added the [./backoffice.md|backoffice]. + * The default skin is now responsive, providing better layout on + small screens, including mobile devices. + * Add the [./backoffice.md|backoffice]. * Update internal Unicode character tables, used in regular expression handling, from version 10.0 to 11.0. * Improvements to the "Security Audit" administration page Index: www/forum.wiki ================================================================== --- www/forum.wiki +++ www/forum.wiki @@ -173,21 +173,22 @@ the WriteTrusted capability (4) to users in the developer category. If you did not give the Read Forum capability (2) to anonymous above, you should give developer that capability here if you choose to give it capability 3 or 4. -You must give at least one user or user category the Email Alerts -capability (7), else the only people able to sign themselves up for -email notifications are those with the Setup or Admin capability. Those -users could sign others up via Admin → Notification, but you -probably want to give this capability to one of the user categories. -Give it to nobody if you want anyone to sign up without any -restrictions. Give it to anonymous if you want the user to -solve a simple CAPTCHA before signing up. Give it to reader or -developer if you want only users with Fossil logins to have -this ability. (That's assuming you give one or both of these -capabilities to every user on your Fossil repository.) +If you want to use the email notification feature, by default only those +users in the Setup and Admin user categories can make use of it. Grant +the Email Alerts capability (7) to give others access to this feature. +Alternately, you can handle notification signups outside of Fossil, with +a Setup or Admin users manually signing users up via Admin → +Notification. You'll want to grant this capability to the +nobody user category if you want anyone to sign up without any +restrictions. Give it to anonymous instead if you want the +user to solve a simple CAPTCHA before signing up. Or, give it to +reader or developer if you want only users with Fossil +logins to have this ability. (That's assuming you give one or both of +these capabilities to every user on your Fossil repository.) By following this advice, you should not need to tediously add capabilities to individual accounts except in atypical cases, such as to grant the Moderate Forum capability (5) to an uncommonly highly-trusted user. @@ -197,22 +198,38 @@ If you create a new Fossil repository with version 2.7 or newer, its default skin is already set up correctly for typical forum configurations. -Those upgrading existing repositories will need to edit the Header part -of their existing Fossil skin in Admin → Skins, adding something -like this to create the navbar link: +If you have an existing repository, you have two choices if you want its +skin to be upgraded to support forums: + +
      +
    1. Go into Admin → Skins and switch from your current skin to + one of the stock skins. If you were on a stock skin, just switch away + from your current one to the actual stock skin, since they will be + different after the upgrade.
    2. + +
    3. If you have local customization that you do not want to throw + away, you can use the diff feature of Fossil's skin editor to show how + the skins differ.
    4. +
    + +The remainder of this section summarizes the differences you're expected +to see when taking option #2. + +The first thing is that you'll need to add something like the following +to the Header part of the skin to create the navbar link: - if {[anycap 23456] || [anoncap 2] || [anoncap 3]} { + if {[anycap 234567] || [anoncap 2] || [anoncap 3]} { menulink /forum Forum } These rules say that any logged-in user with any forum-related -capability (2-6 inclusive, as of this writing) or an anonymous user with +capability (2-7 inclusive, as of this writing) or an anonymous user with read or write capability on the forum (2, 3) will see the "Forum" navbar link, which just takes you to /forum. The exact code you need here varies depending on which skin you're using. Follow the style you see for the other navbar links. @@ -240,10 +257,35 @@ background-color: rgba(255, 255, 255, 0.05); } That overlays the background with 5% white to lighten it slightly. + +Another new forum-related CSS style you might want to reflect into your +existing skin is: + + + div.forumPosts a:visited { + color: #6A7F94; + } + + +This changes the clicked-hyperlink color for the forum post links on the +main /forum page only, which allows your browser's history +mechanism to show which threads a user has read and which not. The link +color will change back to the normal link color — indicating "unread" — +when a reply is added to an existing thread because that changes where +the link from the /forum page points, taking you to the newest +post in the thread. + +The color given above is suitable for the stock skin. + +Beware that when changing this example, there are some +[https://hacks.mozilla.org/2010/03/privacy-related-changes-coming-to-css-vistited/ +| stringent restrictions] in modern browsers to prevent snoopy web sites +from brute-forcing your browsing history. (See the link for the method, +which explains the restrictions.) One of the underlying assumptions of the forum feature is that you will Index: www/th1.md ================================================================== --- www/th1.md +++ www/th1.md @@ -33,14 +33,14 @@ seem inefficient, but it is faster than people imagine, and numeric computations do not come up very often for the kinds of work that TH1 does, so it has never been a factor.) A TH1 script consist of a sequence of commands. -Each command is terminated by the first (unescaped) newline or ";" character. +Each command is terminated by the first *unescaped* newline or ";" character. The text of the command (excluding the newline or semicolon terminator) is broken into space-separated tokens. The first token is the command -name and subsequent tokens are the arguments. In this since, TH1 syntax +name and subsequent tokens are the arguments. In this sense, TH1 syntax is similar to the familiar command-line shell syntax. A token is any sequence of characters other than whitespace and semicolons. Or, all text without double-quotes is a single token even if it includes whitespace and semicolons. Or, all text without nested {...} pairs is a @@ -48,36 +48,68 @@ The nested {...} form of tokens is important because it allows TH1 commands to have an appearance similar to C/C++. It is important to remember, though, that a TH1 script is really just a list of text commands, not a context-free language with a grammar like C/C++. This can be confusing to long-time -C/C++ programmers because TH1 does look a lot like C/C++. But the semantics +C/C++ programmers because TH1 does look a lot like C/C++, but the semantics of TH1 are closer to FORTH or Lisp than they are to C. -Consider the "if" command in TH1. +Consider the `if` command in TH1. if {$current eq "dev"} { puts "hello" } else { puts "world" } The example above is a single command. The first token, and the name -of the command, is "if". -The second token is '$current eq "dev"' - an expression. (The outer {...} +of the command, is `if`. +The second token is `$current eq "dev"` - an expression. (The outer {...} are removed from each token by the command parser.) The third token -is the 'puts "hello"', with its whitespace and newlines. The fourth token -is "else". And the fifth and last token is 'puts "world"'. +is the `puts "hello"`, with its whitespace and newlines. The fourth token +is `else"` And the fifth and last token is `puts "world"`. -The "if" command word by evaluating its first argument (the second token) -as an expression, and if that expression is true, evaluating its +The `if` command evaluates its first argument (the second token) +as an expression, and if that expression is true, evaluates its second argument (the third token) as a TH1 script. -If the expression is false and the third argument is "else" then +If the expression is false and the third argument is `else`, then the fourth argument is evaluated as a TH1 expression. So, you see, even though the example above spans five lines, it is really just a single command. + +All of this also explains the emphasis on *unescaped* characters above: +the curly braces `{ }` are string quoting characters in Tcl/TH1, not +block delimiters as in C. This is how we can have a command that extends +over multiple lines. It is also why the `else` keyword must be cuddled +up with the closing brace for the `if` clause's scriptlet. The following +is invalid Tcl/TH1: + + if {$current eq "dev"} { + puts "hello" + } + else { + puts "world" + } + +If you try to run this under either Tcl or TH1, the interpreter will +tell you that there is no `else` command, because with the newline on +the third line, you terminated the `if` command. + +Occasionally in Tcl/TH1 scripts, you may need to use a backslash at the +end of a line to allow a command to extend over multiple lines without +being considered two separate commands. Here's an example from one of +Fossil's test scripts: + + return [lindex [regexp -line -inline -nocase -- \ + {^uuid:\s+([0-9A-F]{40}) } [eval [getFossilCommand \ + $repository "" info trunk]]] end] + +Those backslashes allow the command to wrap nicely within a standard +terminal width while telling the interpreter to consider those three +lines as a single command. + Summary of Core TH1 Commands ---------------------------- The original Tcl language after when TH1 is modeled has a very rich