Fossil SCM

Make it easier to do out of source builds by optionally including config.mak or config.w32.

Jeremy 2009-12-09 22:05 trunk
Commit fb1fa7f1a6af4a4fe5fbe62edf83da74f10a16a6
3 files changed +62 -34 +4 +4
+62 -34
--- BUILD.txt
+++ BUILD.txt
@@ -1,35 +1,62 @@
1
-All of the source code for fossil is contained in the src/ subdirectory.
2
-But there is a lot of generated code, so you will probably want to
3
-use the Makefile. To do a complete build, just type:
4
-
5
- make
6
-
7
-That should work out-of-the-box on Macs and Linux systems. If
8
-you have trouble, or you want to do something fancy, just edit
9
-the Makefile in the top-level folder. There are 5 things you
10
-might want to change in the Makefile. All 5 things are well
11
-commented. The complete Makefile is only a few dozen lines long.
12
-Do not be intimidated.
13
-
---------------------------------------------------------------------------
14
-
15
-Here are some notes on what is happening behind the scenes:
16
-
17
-* The Makefile just sets up a few macros and then invokes the
18
- real makefile in src/main.mk. The src/main.mk makefile is
19
- automatically generated by a TCL script found at src/makemake.tcl.
20
- Do not edit src/main.mk directly. Update src/makemake.tcl and
21
- then rerun it.
22
-
23
-* The *.h header files are automatically generated using a program
24
- called "makeheaders". Source code to the makeheaders program is
25
- found in src/makeheaders.c. Documentation is found in
26
- src/makeheaders.html.
27
-
28
-* Most *.c source files are preprocessed using a program called
29
- "translate". The sources to translate are found in src/translate.c.
30
- A header comment in src/translate.c explains in detail what it does.
31
-
32
-* The src/mkindex.c program generates some C code that implements
33
- static lookup tables. See the header comment in the source code
34
- for details on what it does.
1
+All of the source code for fossil is contained in the src/ subdirectory.
2
+But there is a lot of generated code, so you will probably want to
3
+use the Makefile. To do a complete build, just type:
4
+
5
+ make
6
+
7
+That should work out-of-the-box on Macs and Linux systems. If you are
8
+building on a Windows box, install MinGW as well as MinGW's make (or
9
+MSYS). You can then type:
10
+
11
+ make -f Makefile.w32
12
+
13
+If you have trouble, or you want to do something fancy, just look at
14
+top level makefile. There are 5 configuration options that are all well
15
+commented. Instead of editing the Makefile, create a new file named
16
+config.mak (for Macs and Linux systems) or config.w32 (for Windows) and
17
+override any settings you wish there.
18
+
19
+Out of source builds?
20
+--------------------------------------------------------------------------
21
+
22
+An out of source build is pretty easy:
23
+
24
+ 1. Make a new directory to do the builds in.
25
+ 2. Create a config.mak (or .w32 ... explained above) and add something
26
+ along the lines of:
27
+
28
+ SRCDIR=../src
29
+
30
+ 3. From that directory, type:
31
+
32
+ Macs and Linux:
33
+ $ make -f ../Makefile
34
+
35
+ Windows:
36
+ C:\fossil\build> make -f ../Makefile.w32
37
+
38
+This will now keep all generates files seperate from the maintained
39
+source code.
40
+
41
+--------------------------------------------------------------------------
42
+
43
+Here are some notes on what is happening behind the scenes:
44
+
45
+* The Makefile just sets up a few macros and then invokes the
46
+ real makefile in src/main.mk. The src/main.mk makefile is
47
+ automatically generated by a TCL script found at src/makemake.tcl.
48
+ Do not edit src/main.mk directly. Update src/makemake.tcl and
49
+ then rerun it.
50
+
51
+* The *.h header files are automatically generated using a program
52
+ called "makeheaders". Source code to the makeheaders program is
53
+ found in src/makeheaders.c. Documentation is found in
54
+ src/makeheaders.html.
55
+
56
+* Most *.c source files are preprocessed using a program called
57
+ "translate". The sources to translate are found in src/translate.c.
58
+ A header comment in src/translate.c explains in detail what it does.
59
+
60
+* The src/mkindex.c program generates some C code that implements
61
+ static lookup tables. See the header comment in the source code
62
+ for details on what it does.
3563
--- BUILD.txt
+++ BUILD.txt
@@ -1,35 +1,62 @@
1 All of the source code for fossil is contained in the src/ subdirectory.
2 But there is a lot of generated code, so you will probably want to
3 use the Makefile. To do a complete build, just type:
4
5 make
6
7 That should work out-of-the-box on Macs and Linux systems. If
8 you have trouble, or you want to do something fancy, just edit
9 the Makefile in the top-level folder. There are 5 things you
10 might want to change in the Makefile. All 5 things are well
11 commented. The complete Makefile is only a few dozen lines long.
12 Do not be intimidated.
13
---------------------------------------------------------------------------
14
15 Here are some notes on what is happening behind the scenes:
16
17 * The Makefile just sets up a few macros and then invokes the
18 real makefile in src/main.mk. The src/main.mk makefile is
19 automatically generated by a TCL script found at src/makemake.tcl.
20 Do not edit src/main.mk directly. Update src/makemake.tcl and
21 then rerun it.
22
23 * The *.h header files are automatically generated using a program
24 called "makeheaders". Source code to the makeheaders program is
25 found in src/makeheaders.c. Documentation is found in
26 src/makeheaders.html.
27
28 * Most *.c source files are preprocessed using a program called
29 "translate". The sources to translate are found in src/translate.c.
30 A header comment in src/translate.c explains in detail what it does.
31
32 * The src/mkindex.c program generates some C code that implements
33 static lookup tables. See the header comment in the source code
34 for details on what it does.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
35
--- BUILD.txt
+++ BUILD.txt
@@ -1,35 +1,62 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
---------------------------------------------------------------------------
1 All of the source code for fossil is contained in the src/ subdirectory.
2 But there is a lot of generated code, so you will probably want to
3 use the Makefile. To do a complete build, just type:
4
5 make
6
7 That should work out-of-the-box on Macs and Linux systems. If you are
8 building on a Windows box, install MinGW as well as MinGW's make (or
9 MSYS). You can then type:
10
11 make -f Makefile.w32
12
13 If you have trouble, or you want to do something fancy, just look at
14 top level makefile. There are 5 configuration options that are all well
15 commented. Instead of editing the Makefile, create a new file named
16 config.mak (for Macs and Linux systems) or config.w32 (for Windows) and
17 override any settings you wish there.
18
19 Out of source builds?
20 --------------------------------------------------------------------------
21
22 An out of source build is pretty easy:
23
24 1. Make a new directory to do the builds in.
25 2. Create a config.mak (or .w32 ... explained above) and add something
26 along the lines of:
27
28 SRCDIR=../src
29
30 3. From that directory, type:
31
32 Macs and Linux:
33 $ make -f ../Makefile
34
35 Windows:
36 C:\fossil\build> make -f ../Makefile.w32
37
38 This will now keep all generates files seperate from the maintained
39 source code.
40
41 --------------------------------------------------------------------------
42
43 Here are some notes on what is happening behind the scenes:
44
45 * The Makefile just sets up a few macros and then invokes the
46 real makefile in src/main.mk. The src/main.mk makefile is
47 automatically generated by a TCL script found at src/makemake.tcl.
48 Do not edit src/main.mk directly. Update src/makemake.tcl and
49 then rerun it.
50
51 * The *.h header files are automatically generated using a program
52 called "makeheaders". Source code to the makeheaders program is
53 found in src/makeheaders.c. Documentation is found in
54 src/makeheaders.html.
55
56 * Most *.c source files are preprocessed using a program called
57 "translate". The sources to translate are found in src/translate.c.
58 A header comment in src/translate.c explains in detail what it does.
59
60 * The src/mkindex.c program generates some C code that implements
61 static lookup tables. See the header comment in the source code
62 for details on what it does.
63
+4
--- Makefile
+++ Makefile
@@ -43,9 +43,13 @@
4343
4444
4545
#### Tcl shell for use in running the fossil testsuite.
4646
#
4747
TCLSH = tclsh
48
+
49
+#### Include a configuration file that can override any one of these settings.
50
+#
51
+-include config.mak
4852
4953
# You should not need to change anything below this line
5054
###############################################################################
5155
include $(SRCDIR)/main.mk
5256
--- Makefile
+++ Makefile
@@ -43,9 +43,13 @@
43
44
45 #### Tcl shell for use in running the fossil testsuite.
46 #
47 TCLSH = tclsh
 
 
 
 
48
49 # You should not need to change anything below this line
50 ###############################################################################
51 include $(SRCDIR)/main.mk
52
--- Makefile
+++ Makefile
@@ -43,9 +43,13 @@
43
44
45 #### Tcl shell for use in running the fossil testsuite.
46 #
47 TCLSH = tclsh
48
49 #### Include a configuration file that can override any one of these settings.
50 #
51 -include config.mak
52
53 # You should not need to change anything below this line
54 ###############################################################################
55 include $(SRCDIR)/main.mk
56
--- Makefile.w32
+++ Makefile.w32
@@ -41,9 +41,13 @@
4141
LIB = -lmingwex -lz -lws2_32
4242
4343
#### Tcl shell for use in running the fossil testsuite.
4444
#
4545
TCLSH = tclsh
46
+
47
+#### Include a configuration file that can override any one of these settings.
48
+#
49
+-include config.w32
4650
4751
# You should not need to change anything below this line
4852
###############################################################################
4953
include $(SRCDIR)/main.mk
5054
--- Makefile.w32
+++ Makefile.w32
@@ -41,9 +41,13 @@
41 LIB = -lmingwex -lz -lws2_32
42
43 #### Tcl shell for use in running the fossil testsuite.
44 #
45 TCLSH = tclsh
 
 
 
 
46
47 # You should not need to change anything below this line
48 ###############################################################################
49 include $(SRCDIR)/main.mk
50
--- Makefile.w32
+++ Makefile.w32
@@ -41,9 +41,13 @@
41 LIB = -lmingwex -lz -lws2_32
42
43 #### Tcl shell for use in running the fossil testsuite.
44 #
45 TCLSH = tclsh
46
47 #### Include a configuration file that can override any one of these settings.
48 #
49 -include config.w32
50
51 # You should not need to change anything below this line
52 ###############################################################################
53 include $(SRCDIR)/main.mk
54

Keyboard Shortcuts

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