Skip to content

Commit fa4069d

Browse files
committed
Remove backconfig in favor of using DMD's copy
1 parent d0631db commit fa4069d

File tree

3 files changed

+33
-570
lines changed

3 files changed

+33
-570
lines changed

README.md

Lines changed: 31 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,41 @@ https://digitalmars.com/ctg/sc.html
1414
`shared stdout = &_iob[1];`
1515
with
1616
`enum stdout = &_iob[1];`.
17-
4. Change directory to `dm\src\dmc`
18-
5. Make sure the `dm\bin\make.exe` program is on your `PATH`.
19-
6. Execute the commands:
17+
4. Run `git submodule update --init` to make sure you have up-to-date submodules.
18+
5. Change directory to `dm\src\dmc`
19+
6. Make sure the `dm\bin\make.exe` program is on your `PATH`.
20+
7. Execute the commands:
2021
`make CC=dmc clean`
2122
`make CC=dmc scppn`
2223
You might need to edit the `makefile` to set the path to your DMD installation.
2324

2425
Note that DMC runs on Win32, and hasn't been ported to other platforms.
2526
It can generate code for Win32, 16 bit DOS, 16 and 32 bit Windows, 286 DOS extenders,
2627
and 386 DOS extenders.
28+
29+
# Updating the backend
30+
31+
In order to update the backend to a more recent version, do the following:
32+
1. Go to the DMD submodule: `cd dm/src/dmd`;
33+
2. Fetch the latest commits: `git fetch`
34+
3. Checkout the desired commit, e.g.:
35+
- `git checkout origin/master`: Checkout the latest version of the DMD backend;
36+
- `git checkout v2.095.0`: Checkout the state of the backend as of DMD v2.095.0;
37+
- `git checkout 385312b93`: Checkout the state of the backend as of commit `385312b93`;
38+
4. Leave the `dmd` repository, e.g. `cd ../../` to come back to the root of this repository;
39+
5. Commit the change to the submodule: `git add dm/src/dmd && git commit -m "Update DMD backend to master"`
40+
41+
Alternatively, when pulling from this repository, remember to always run `git submodule update --init`
42+
if the submodule have been updated. This is visible from `git status`:
43+
```shell
44+
$ git diff
45+
diff --git a/dm/src/dmd b/dm/src/dmd
46+
index 123456789..abcdef123 160000
47+
--- a/dm/src/dmd
48+
+++ b/dm/src/dmd
49+
@@ -1 +1 @@
50+
-Subproject commit 67ca0a14c4d4d3161541eda27a4126f889d53546
51+
+Subproject commit 385312b93239311c038ffd8c221ac62738006382
52+
```
53+
54+
To learn more about `git submodule`, see [this section of the Pro Git book](https://git-scm.com/book/en/v2/Git-Tools-Submodules).

0 commit comments

Comments
 (0)