Fossil SCM

Improve consistency of the version information.

mistachkin 2013-03-18 07:05 trunk
Commit e452aa97f1789601afb60b421394e9cf8013e467
2 files changed +16 -10 +5 -1
+16 -10
--- src/main.c
+++ src/main.c
@@ -29,18 +29,22 @@
2929
#if defined(_WIN32)
3030
# include <windows.h>
3131
#else
3232
# include <errno.h> /* errno global */
3333
#endif
34
+#include "zlib.h"
35
+#ifdef FOSSIL_ENABLE_SSL
36
+# include "openssl/opensslv.h"
37
+#endif
3438
#if INTERFACE
39
+#ifdef FOSSIL_ENABLE_TCL
40
+# include "tcl.h"
41
+#endif
3542
#ifdef FOSSIL_ENABLE_JSON
3643
# include "cson_amalgamation.h" /* JSON API. */
3744
# include "json_detail.h"
3845
#endif
39
-#ifdef FOSSIL_ENABLE_TCL
40
-#include "tcl.h"
41
-#endif
4246
4347
/*
4448
** Number of elements in an array
4549
*/
4650
#define count(X) (sizeof(X)/sizeof(X[0]))
@@ -751,39 +755,41 @@
751755
** be output about what optional features this binary was compiled
752756
** with
753757
*/
754758
void version_cmd(void){
755759
fossil_print("This is fossil version " RELEASE_VERSION " "
756
- MANIFEST_VERSION " " MANIFEST_DATE " UTC\n");
760
+ MANIFEST_VERSION " " MANIFEST_DATE " UTC\n");
757761
if(!find_option("verbose","v",0)){
758762
return;
759763
}else{
760764
int count = 0;
761
- fossil_print("Compiled using %s with the following features enabled:\n",
762
- COMPILER_NAME);
765
+ fossil_print("\nCompiled using \"%s\" with\nSQLite %s [%s],\nzlib %s, "
766
+ "and the following optional features enabled:\n\n",
767
+ COMPILER_NAME, SQLITE_VERSION, SQLITE_SOURCE_ID,
768
+ ZLIB_VERSION);
763769
#if defined(FOSSIL_ENABLE_SSL)
764770
++count;
765
- fossil_print("\tSSL\n");
771
+ fossil_print("\tSSL (%s)\n", OPENSSL_VERSION_TEXT);
766772
#endif
767773
#if defined(FOSSIL_ENABLE_TCL)
768774
++count;
769
- fossil_print("\tTCL\n");
775
+ fossil_print("\tTCL (Tcl %s)\n", TCL_PATCH_LEVEL);
770776
#endif
771777
#if defined(FOSSIL_ENABLE_TCL_STUBS)
772778
++count;
773779
fossil_print("\tTCL_STUBS\n");
774780
#endif
775781
#if defined(FOSSIL_ENABLE_JSON)
776782
++count;
777
- fossil_print("\tJSON\n");
783
+ fossil_print("\tJSON (API %s)\n", FOSSIL_JSON_API_VERSION);
778784
#endif
779785
#if defined(FOSSIL_ENABLE_MARKDOWN)
780786
++count;
781787
fossil_print("\tMARKDOWN\n");
782788
#endif
783789
if( !count ){
784
- fossil_print("\tno optional features enabled.\n");
790
+ fossil_print("\tNo optional features were enabled.\n");
785791
}
786792
}
787793
}
788794
789795
790796
--- src/main.c
+++ src/main.c
@@ -29,18 +29,22 @@
29 #if defined(_WIN32)
30 # include <windows.h>
31 #else
32 # include <errno.h> /* errno global */
33 #endif
 
 
 
 
34 #if INTERFACE
 
 
 
35 #ifdef FOSSIL_ENABLE_JSON
36 # include "cson_amalgamation.h" /* JSON API. */
37 # include "json_detail.h"
38 #endif
39 #ifdef FOSSIL_ENABLE_TCL
40 #include "tcl.h"
41 #endif
42
43 /*
44 ** Number of elements in an array
45 */
46 #define count(X) (sizeof(X)/sizeof(X[0]))
@@ -751,39 +755,41 @@
751 ** be output about what optional features this binary was compiled
752 ** with
753 */
754 void version_cmd(void){
755 fossil_print("This is fossil version " RELEASE_VERSION " "
756 MANIFEST_VERSION " " MANIFEST_DATE " UTC\n");
757 if(!find_option("verbose","v",0)){
758 return;
759 }else{
760 int count = 0;
761 fossil_print("Compiled using %s with the following features enabled:\n",
762 COMPILER_NAME);
 
 
763 #if defined(FOSSIL_ENABLE_SSL)
764 ++count;
765 fossil_print("\tSSL\n");
766 #endif
767 #if defined(FOSSIL_ENABLE_TCL)
768 ++count;
769 fossil_print("\tTCL\n");
770 #endif
771 #if defined(FOSSIL_ENABLE_TCL_STUBS)
772 ++count;
773 fossil_print("\tTCL_STUBS\n");
774 #endif
775 #if defined(FOSSIL_ENABLE_JSON)
776 ++count;
777 fossil_print("\tJSON\n");
778 #endif
779 #if defined(FOSSIL_ENABLE_MARKDOWN)
780 ++count;
781 fossil_print("\tMARKDOWN\n");
782 #endif
783 if( !count ){
784 fossil_print("\tno optional features enabled.\n");
785 }
786 }
787 }
788
789
790
--- src/main.c
+++ src/main.c
@@ -29,18 +29,22 @@
29 #if defined(_WIN32)
30 # include <windows.h>
31 #else
32 # include <errno.h> /* errno global */
33 #endif
34 #include "zlib.h"
35 #ifdef FOSSIL_ENABLE_SSL
36 # include "openssl/opensslv.h"
37 #endif
38 #if INTERFACE
39 #ifdef FOSSIL_ENABLE_TCL
40 # include "tcl.h"
41 #endif
42 #ifdef FOSSIL_ENABLE_JSON
43 # include "cson_amalgamation.h" /* JSON API. */
44 # include "json_detail.h"
45 #endif
 
 
 
46
47 /*
48 ** Number of elements in an array
49 */
50 #define count(X) (sizeof(X)/sizeof(X[0]))
@@ -751,39 +755,41 @@
755 ** be output about what optional features this binary was compiled
756 ** with
757 */
758 void version_cmd(void){
759 fossil_print("This is fossil version " RELEASE_VERSION " "
760 MANIFEST_VERSION " " MANIFEST_DATE " UTC\n");
761 if(!find_option("verbose","v",0)){
762 return;
763 }else{
764 int count = 0;
765 fossil_print("\nCompiled using \"%s\" with\nSQLite %s [%s],\nzlib %s, "
766 "and the following optional features enabled:\n\n",
767 COMPILER_NAME, SQLITE_VERSION, SQLITE_SOURCE_ID,
768 ZLIB_VERSION);
769 #if defined(FOSSIL_ENABLE_SSL)
770 ++count;
771 fossil_print("\tSSL (%s)\n", OPENSSL_VERSION_TEXT);
772 #endif
773 #if defined(FOSSIL_ENABLE_TCL)
774 ++count;
775 fossil_print("\tTCL (Tcl %s)\n", TCL_PATCH_LEVEL);
776 #endif
777 #if defined(FOSSIL_ENABLE_TCL_STUBS)
778 ++count;
779 fossil_print("\tTCL_STUBS\n");
780 #endif
781 #if defined(FOSSIL_ENABLE_JSON)
782 ++count;
783 fossil_print("\tJSON (API %s)\n", FOSSIL_JSON_API_VERSION);
784 #endif
785 #if defined(FOSSIL_ENABLE_MARKDOWN)
786 ++count;
787 fossil_print("\tMARKDOWN\n");
788 #endif
789 if( !count ){
790 fossil_print("\tNo optional features were enabled.\n");
791 }
792 }
793 }
794
795
796
+5 -1
--- win/fossil.rc
+++ win/fossil.rc
@@ -36,10 +36,14 @@
3636
3737
#ifdef FOSSIL_ENABLE_TCL
3838
#include "tcl.h"
3939
#endif
4040
41
+#ifdef FOSSIL_ENABLE_JSON
42
+#include "json_detail.h"
43
+#endif
44
+
4145
/*
4246
* English (U.S.) resources
4347
*/
4448
4549
#ifdef _WIN32
@@ -102,11 +106,11 @@
102106
#else
103107
VALUE "TclStubsEnabled", "No\0"
104108
#endif
105109
#endif
106110
#ifdef FOSSIL_ENABLE_JSON
107
- VALUE "JsonEnabled", "Yes, cson\0"
111
+ VALUE "JsonEnabled", "Yes, cson " FOSSIL_JSON_API_VERSION "\0"
108112
#endif
109113
#ifdef FOSSIL_ENABLE_MARKDOWN
110114
VALUE "MarkdownEnabled", "Yes\0"
111115
#endif
112116
END
113117
--- win/fossil.rc
+++ win/fossil.rc
@@ -36,10 +36,14 @@
36
37 #ifdef FOSSIL_ENABLE_TCL
38 #include "tcl.h"
39 #endif
40
 
 
 
 
41 /*
42 * English (U.S.) resources
43 */
44
45 #ifdef _WIN32
@@ -102,11 +106,11 @@
102 #else
103 VALUE "TclStubsEnabled", "No\0"
104 #endif
105 #endif
106 #ifdef FOSSIL_ENABLE_JSON
107 VALUE "JsonEnabled", "Yes, cson\0"
108 #endif
109 #ifdef FOSSIL_ENABLE_MARKDOWN
110 VALUE "MarkdownEnabled", "Yes\0"
111 #endif
112 END
113
--- win/fossil.rc
+++ win/fossil.rc
@@ -36,10 +36,14 @@
36
37 #ifdef FOSSIL_ENABLE_TCL
38 #include "tcl.h"
39 #endif
40
41 #ifdef FOSSIL_ENABLE_JSON
42 #include "json_detail.h"
43 #endif
44
45 /*
46 * English (U.S.) resources
47 */
48
49 #ifdef _WIN32
@@ -102,11 +106,11 @@
106 #else
107 VALUE "TclStubsEnabled", "No\0"
108 #endif
109 #endif
110 #ifdef FOSSIL_ENABLE_JSON
111 VALUE "JsonEnabled", "Yes, cson " FOSSIL_JSON_API_VERSION "\0"
112 #endif
113 #ifdef FOSSIL_ENABLE_MARKDOWN
114 VALUE "MarkdownEnabled", "Yes\0"
115 #endif
116 END
117

Keyboard Shortcuts

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