mirror of
https://github.com/D-Modem/gui.git
synced 2026-11-28 14:19:58 -08:00
- CMake builds libdmodem_embed on macOS too. cmake/MacosEmbed.cmake links a small program with it and keeps the link command (a linker launcher). From it, CMake writes build/macos-embed.xcconfig: the header path, all the static libraries and the Swift condition DMODEM_GUI_EMBED. - macos/project.yml includes that file. - Modem.swift starts the built-in modem for the SIP and USB lines, in a thread of the app. Its DTE socket goes to the same session code as the pty. LineSettingsView has a Built-in modem switch (on by default). - CI: the macOS job checks out the submodule, and checks that the app has the library. - Docs: macOS in docs/embedded-modem.md, building.md, design.md and the README. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01B82eRTRNP9YEnRxydbrw9G
62 lines
2.8 KiB
YAML
62 lines
2.8 KiB
YAML
# The macOS app's Xcode project, made by XcodeGen. libssh and mbedTLS
|
|
# (for libdmodemssh), and the built-in modem (libdmodem_embed, from the
|
|
# submodule external/D-Modem), are built first by the repository's
|
|
# CMake, for both architectures, into ../build. CMake also writes
|
|
# ../build/macos-embed.xcconfig: the built-in modem's libraries, or
|
|
# nothing when the build has no built-in modem.
|
|
# cmake -S .. -B ../build -DCMAKE_OSX_ARCHITECTURES="arm64;x86_64" \
|
|
# -DCMAKE_OSX_DEPLOYMENT_TARGET=13.0 && cmake --build ../build
|
|
# brew install xcodegen && cd macos && xcodegen
|
|
# xcodebuild -project DModem.xcodeproj -scheme DModem build
|
|
name: DModem
|
|
options:
|
|
bundleIdPrefix: io.github.d-modem
|
|
deploymentTarget:
|
|
macOS: "13.0"
|
|
targets:
|
|
DModem:
|
|
type: application
|
|
platform: macOS
|
|
configFiles:
|
|
Debug: ../build/macos-embed.xcconfig
|
|
Release: ../build/macos-embed.xcconfig
|
|
sources:
|
|
- path: DModem
|
|
- path: ../core/src
|
|
buildPhase: sources
|
|
- path: ../ssh/src
|
|
buildPhase: sources
|
|
settings:
|
|
base:
|
|
PRODUCT_NAME: D-Modem
|
|
PRODUCT_BUNDLE_IDENTIFIER: io.github.d-modem.DModem
|
|
MARKETING_VERSION: "1.0.0"
|
|
CURRENT_PROJECT_VERSION: "1"
|
|
HEADER_SEARCH_PATHS: $(SRCROOT)/../core/include $(SRCROOT)/../ssh/include $(SRCROOT)/../build/dmodem-libssh/include $(DMODEM_EMBED_HEADERS)
|
|
GCC_PREPROCESSOR_DEFINITIONS: LIBSSH_STATIC=1
|
|
# libssh and mbedTLS, and the built-in modem, as CMake built them
|
|
# (see above)
|
|
LIBRARY_SEARCH_PATHS: $(SRCROOT)/../build/dmodem-libssh/lib
|
|
OTHER_LDFLAGS: -lssh -lmbedtls -lmbedx509 -lmbedcrypto -leverest -lp256m $(DMODEM_EMBED_LDFLAGS)
|
|
SWIFT_ACTIVE_COMPILATION_CONDITIONS: $(inherited) $(DMODEM_EMBED_SWIFT)
|
|
SWIFT_OBJC_BRIDGING_HEADER: DModem/Bridging.h
|
|
SWIFT_VERSION: "5.0"
|
|
GCC_C_LANGUAGE_STANDARD: c11
|
|
GENERATE_INFOPLIST_FILE: YES
|
|
INFOPLIST_KEY_CFBundleDisplayName: D-Modem
|
|
INFOPLIST_KEY_LSApplicationCategoryType: public.app-category.utilities
|
|
INFOPLIST_KEY_NSHumanReadableCopyright: Copyright (C) 2026 D-Modem Authors. AGPL-3.0-only.
|
|
INFOPLIST_KEY_NSMicrophoneUsageDescription: D-Modem uses the microphone for voice calls and to record the answering machine's greeting.
|
|
ASSETCATALOG_COMPILER_APPICON_NAME: AppIcon
|
|
CODE_SIGN_IDENTITY: "-"
|
|
ENABLE_HARDENED_RUNTIME: YES
|
|
# dmodemd runs as a child process and the modem's pty is opened,
|
|
# or the built-in modem uses the network and USB: no sandbox
|
|
ENABLE_APP_SANDBOX: NO
|
|
# the microphone, for voice calls (the hardened runtime asks for it)
|
|
ENABLE_RESOURCE_ACCESS_AUDIO_INPUT: YES
|
|
entitlements:
|
|
path: DModem/DModem.entitlements
|
|
properties:
|
|
com.apple.security.device.audio-input: true
|