@@ -11,36 +11,34 @@ Make sure you have these prerequisites working:
11
11
* The C++ compiler for your platform (invokable as ` gcc ` )
12
12
* Optional: ` latex ` for building the pdf documentation
13
13
* Optional: ` kindlegen ` for building the Kindle documentation
14
- * If you're running OSX, make sure you have some version of ` libevent ` installed
14
+ * If you're running OSX, make sure you have some version of ` libevent ` installed (needed for Ddox)
15
15
16
16
## Getting the code
17
17
18
- Create a working directory for the D language, e.g. ` ~/code/d ` . The remainder
19
- of this document calls that directory henceforth ` $R ` from "Root". To get the
20
- code:
18
+ If you already have a [ working directory for the D language] ( https://wiki.dlang.org/Building_under_Posix#Fetch_repositories_from_GitHub ) ,
19
+ e.g. ` ~/dlang ` , change to it.
20
+
21
+ To get the code, run:
21
22
22
23
```
23
- cd $R
24
24
git clone https://github.com/dlang/dlang.org
25
- git clone https://github.com/ dlang/dmd
25
+ cd dlang.org
26
26
```
27
27
28
- The ` dmd ` compiler is needed for processing the documentation .
28
+ The remainder of this document assumes that is your current working directory .
29
29
30
30
## Building the main site
31
31
32
- Now in ` $R ` there are two directories called ` dmd ` and ` dlang.org ` . To
33
- build the main site, run this:
32
+ To build the main site, run:
34
33
35
34
```
36
- cd $R/dlang.org
37
35
make -f posix.mak html
38
36
```
39
37
40
38
This builds the ` dmd ` compiler itself first and then uses it to build the
41
39
website pages. You may see warnings while the compiler is built. After ` make `
42
- ended with error code 0, directory ` $R/dlang.org/ web` contains the produced HTML
43
- files. Take a moment to open ` $R/dlang.org/ web/index.html` in a browser.
40
+ ended with error code 0, directory ` web ` contains the produced HTML
41
+ files. Take a moment to open ` web/index.html ` in a browser.
44
42
45
43
## Building the standard library documentation
46
44
@@ -54,48 +52,47 @@ currently being worked on. The "release" version is built with the "release"
54
52
compiler, and the current version is built with the current compiler (which we
55
53
already have from the previous step).
56
54
57
- ### Building the release libraries
55
+ ### Building the ` prerelease ` libraries
58
56
59
- Fortunately there's no need to fumble with version numbers and git tags etc.;
60
- all is automated. Run this command:
57
+ The more interesting stuff to build is the prerelease libraries because in all
58
+ likelihood that's what needs looking at and testing.
61
59
62
60
```
63
- cd $R/dlang.org
64
- make -f posix.mak druntime-release
65
- make -f posix.mak phobos-release
66
- make -f posix.mak apidocs-release
61
+ make -f posix.mak docs-prerelease
67
62
```
68
63
69
- These commands tell you the release being built in their first line of output.
70
- Then they proceed and clone the appropriate release for ` dmd ` , ` druntime ` , and
71
- ` phobos ` . After all commands have been executed, the following directories will
72
- be present in ` $R ` : ` dlang.org ` , ` dmd ` , ` dmd-2.083.2 ` , ` druntime-2.083.2 ` , and
73
- ` phobos-2.083.2 ` . Note that the actual release number may not be ` 2.083.2 ` , but
74
- should be the same for all three directories.
64
+ If you only want to build a specific part (e.g. Phobos), run:
75
65
76
- The output is in ` $R/dlang.org/web/phobos ` and ` $R/dlang.org/web/library ` .
66
+ ```
67
+ make -f posix.mak phobos-prerelease
68
+ ```
77
69
78
- ### Building the prerelease libraries
70
+ ( ` docs-prerelease ` is a shorthand for ` dmd- prerelease` , ` druntime-prerelease ` , ` phobos-releas ` and ` apidocs-prerelease ` )
79
71
80
- The more interesting stuff to build is the prerelease libraries because in all
81
- likelihood that's what needs looking at and testing. To do that two more
82
- repositories containing the core and standard libraries are needed: ` druntime `
83
- and ` phobos ` :
72
+ The output is in ` web/phobos-prerelease ` and ` library-prerelease ` .
73
+
74
+ ### Building the ` release ` libraries
75
+
76
+ Fortunately there's no need to fumble with version numbers and git tags etc.;
77
+ all is automated. Run this command:
84
78
85
79
```
86
- cd $R
87
- git clone https://github.com/dlang/druntime
88
- git clone https://github.com/dlang/phobos
80
+ make -f posix.mak docs-release
89
81
```
90
82
91
- With the new repos in tow this builds the prerelease libraries :
83
+ If you only want to build a specific part (e.g. Phobos), run :
92
84
93
85
```
94
- cd $R/dlang.org
95
- make -f posix.mak druntime-prerelease
96
- make -f posix.mak phobos-prerelease
97
- make -f posix.mak apidocs-prerelease
86
+ make -f posix.mak phobos-release
98
87
```
99
88
100
- The output is in ` $R/dlang.org/web/phobos-prerelease ` and
101
- ` $R/dlang.org/web/library-prerelease ` .
89
+ (` docs-release ` is a shorthand for ` dmd-release ` , ` druntime-release ` , ` phobos-releas ` and ` apidocs-release ` )
90
+
91
+ These commands tell you the release being built in their first line of output.
92
+ Then they proceed and clone the appropriate release for ` dmd ` , ` druntime ` , and
93
+ ` phobos ` . After all commands have been executed, the following directories will
94
+ be present in ` $R ` : ` dlang.org ` , ` dmd ` , ` dmd-2.083.2 ` , ` druntime-2.083.2 ` , and
95
+ ` phobos-2.083.2 ` . Note that the actual release number may not be ` 2.083.2 ` , but
96
+ should be the same for all three directories.
97
+
98
+ The output is in ` web/phobos ` and ` web/library ` .
0 commit comments