Build the modem into the Windows app on Linux and macOS

The Windows app on macOS (and on Linux) had no built-in modem: CMake
turned DMODEM_GUI_EMBED off for winport/, and CI did not check out the
D-Modem submodule. The app looked for dmodemd.

- CMake: DMODEM_GUI_EMBED is on by default for winport/. winport/
  links libdmodem_embed. The data file of the line uses DIR_SEP.
- CI: the winport jobs check out the submodule and check that the
  built-in modem is in the app. The smoke test starts the built-in
  modem (SIP, no account), and runs dmodemd with builtin=0.
- CI: the SwiftUI app builds for arm64 and x86_64 (it was arm64 alone),
  and the check looks at each architecture.
- Docs and the release notes say which builds have the modem.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01B82eRTrw1ffsyY5bhTghu1
This commit is contained in:
Claude committed 2026-11-25 03:45:59 +00:00
1 parent 2a2f1fed62
commit 1ca2115f4d
11 files changed
+111 -36

No files matched your search

+3 -1
View File
@@ -44,7 +44,9 @@ is necessary for the built-in modem. Then use
`brew install xcodegen && cd macos && xcodegen && open DModem.xcodeproj`.
The Windows app on Linux or macOS: get [clang-retro MFC](https://github.com/clang-retro/mfc),
clang and `llvm-rc` (on macOS, `brew install llvm`). Then:
clang and `llvm-rc` (on macOS, `brew install llvm`). For the built-in
modem, get the D-Modem submodule (`git submodule update --init`). On
Linux, also install `libusb-1.0-0-dev` and `libasound2-dev`. Then:
cmake -S . -B build -DDMODEM_GUI_WINPORT=ON -DCLANG_RETRO_MFC=/path/to/mfc \
-DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++
+13 -4
View File
@@ -556,12 +556,21 @@ code is the same as on Windows.
no `SHGetFolderPath`.
- The line is dmodemd by default. The layer tells the app that Windows
is version 5, and on Windows the app then uses a COM port by default.
- dmodemd is `dmodemd` next to the app, or else on the `PATH`.
- dmodemd is `dmodemd` next to the app, or else on the `PATH`. The app
starts dmodemd only when the built-in modem is off (`builtin=0`).
- With the D-Modem submodule, the app has the built-in modem
(`DMODEM_GUI_EMBED`), as the Windows app on Windows has it. The layer's
`SOCKET` is a POSIX file descriptor, so `WSAAsyncSelect` works with the
socket that `libdmodem_embed` gives. The data file of the line is
`dmodem0.data` in the settings folder.
- SSH uses `~/.ssh` and `/` in paths, because libssh uses POSIX paths
on these systems.
- The layer changes a COM port name to a device: `COM1` is `/dev/ttyS0`.
- CI builds the app on Linux and macOS. On Linux, `winport/test/smoke.sh`
starts the app in Xvfb two times: with a TCP line, and with a dmodemd
that the app starts (`winport/test/dmodemd`, a test dmodemd). Each time,
starts the app in Xvfb three times: with a TCP line, with a dmodemd
that the app starts (`winport/test/dmodemd`, a test dmodemd), and with
the built-in modem on a SIP line with no account. For the first two,
the test makes sure that the app stays up and sends AT commands to a
test modem.
test modem. For the third, the test makes sure that the app stays up
and that the built-in modem writes its data file. On Linux and macOS,
CI also makes sure that the built-in modem is in the app.
+3 -3
View File
@@ -16,10 +16,10 @@ When `main` has no new commits, the release does not change.
| Windows 95, 98, ME, NT 4.0 and later | [`dmodem-win9x.exe`](https://github.com/D-Modem/gui/releases/download/nightly/dmodem-win9x.exe) | The Windows app with the built-in modem. It needs no C runtime DLL. Windows 95 needs Winsock 2. |
| Windows 98 SE, ME, 2000 and later | [`dmodem-win98.exe`](https://github.com/D-Modem/gui/releases/download/nightly/dmodem-win98.exe) | The Windows app with the built-in modem, on `msvcrt.dll`. |
| Windows 7 and later | [`dmodem-win7.exe`](https://github.com/D-Modem/gui/releases/download/nightly/dmodem-win7.exe) | The Windows app with the built-in modem. |
| macOS 13 and later | [`D-Modem-macos.zip`](https://github.com/D-Modem/gui/releases/download/nightly/D-Modem-macos.zip) | The macOS app (SwiftUI), for arm64 and x86_64. |
| macOS 13 and later | [`D-Modem-macos.zip`](https://github.com/D-Modem/gui/releases/download/nightly/D-Modem-macos.zip) | The macOS app (SwiftUI) with the built-in modem, for arm64 and x86_64. |
| Linux, x86_64 | [`dmodem-gui-linux-x86_64.tar.gz`](https://github.com/D-Modem/gui/releases/download/nightly/dmodem-gui-linux-x86_64.tar.gz) | The Linux app (GTK 4). |
| Linux, x86_64 (X11) | [`dmodem-win32-linux-x86_64.tar.gz`](https://github.com/D-Modem/gui/releases/download/nightly/dmodem-win32-linux-x86_64.tar.gz) | The Windows app on Linux. |
| macOS, arm64 | [`dmodem-win32-macos-arm64.tar.gz`](https://github.com/D-Modem/gui/releases/download/nightly/dmodem-win32-macos-arm64.tar.gz) | The Windows app on macOS. |
| Linux, x86_64 (X11) | [`dmodem-win32-linux-x86_64.tar.gz`](https://github.com/D-Modem/gui/releases/download/nightly/dmodem-win32-linux-x86_64.tar.gz) | The Windows app on Linux, with the built-in modem. |
| macOS, arm64 | [`dmodem-win32-macos-arm64.tar.gz`](https://github.com/D-Modem/gui/releases/download/nightly/dmodem-win32-macos-arm64.tar.gz) | The Windows app on macOS, with the built-in modem. |
| All | [`SHA256SUMS`](https://github.com/D-Modem/gui/releases/download/nightly/SHA256SUMS) | The SHA-256 of each file. |
If a file is not in the release, the newest build did not make it. The
+13 -7
View File
@@ -1,8 +1,9 @@
# The built-in modem
The Linux app, the macOS app and the Windows app (Windows 98 SE and
later) have the D-Modem modem in them. Thus, these apps do not need a
separate `dmodemd`. This includes the Windows 95 build.
The Linux app, the macOS app, the Windows app (Windows 98 SE and later)
and the Windows app on Linux and macOS have the D-Modem modem in them.
Thus, these apps do not need a separate `dmodemd`. This includes the
Windows 95 build.
## What it does
@@ -49,7 +50,10 @@ On macOS:
On Windows, the Line Settings dialog does not have this setting yet. Close
the app, and add this line to the `[line]` section of
`%APPDATA%\D-Modem\dmodem.ini`:
`%APPDATA%\D-Modem\dmodem.ini` (Windows), `~/.config/D-Modem/dmodem.ini`
(the Windows app on Linux) or
`~/Library/Application Support/D-Modem/dmodem.ini` (the Windows app on
macOS):
builtin=0
@@ -64,8 +68,8 @@ The D-Modem source is a git submodule in `external/D-Modem`. To get it:
If the submodule is there, CMake builds the built-in modem
(`DMODEM_GUI_EMBED`, on by default) for the Linux app, the macOS app, and
the Windows app with the clang-retro configurations `win32-picolibc` (the
Windows 95 build), `win98`, `winme`, `win7` and later. It is off for the
Windows app on Linux and macOS (`DMODEM_GUI_WINPORT`). To build the app with no built-in
Windows 95 build), `win98`, `winme`, `win7` and later, and for the Windows
app on Linux and macOS (`DMODEM_GUI_WINPORT`). To build the app with no built-in
modem, use `-DDMODEM_GUI_EMBED=OFF`. For a USB line and an ALSA line, also
install `libusb-1.0-0-dev` and `libasound2-dev`.
@@ -95,7 +99,9 @@ Windows and macOS, the build links libusb (LGPL-2.1) statically, as
| Windows 98 SE and later | Done (`win98` build). It builds, and its imports agree with Windows 98 SE. It is not tested on Windows or Wine yet. |
| Windows 7 and later | Done (`win7` build). It builds. It is not tested on Windows or Wine yet. |
| Windows 95, NT 4.0 and later | Done (`win32-picolibc` build). It builds, and its imports agree with Windows 95 and NT 4.0. It is not tested on Windows or Wine yet. Refer to "Windows 95" below. |
| macOS | Done. CI builds it and checks that the library is in the app. It is not tested on a Mac yet. |
| macOS | Done. CI builds it for arm64 and x86_64, and checks that the library is in the app for each architecture. It is not tested on a Mac yet. |
| The Windows app on Linux | Done. CI builds it, checks that the library is in the app, and starts the built-in modem in Xvfb (`winport/test/smoke.sh`). |
| The Windows app on macOS | Done (arm64). CI builds it and checks that the library is in the app. It is not tested on a Mac yet. |
### Windows 95