Files
mcde/programs/dtchat/Makefile.am
T
lotherk ea31073ce0 dtchat: exchange media keys and wire live calls into the UI (T6.5)
The local protocol gets media-key: each side sends its ephemeral X25519 public key (base64) and UDP port over the ready text connection; both derive the direction keys with HKDF-SHA256, the caller is the initiator. localui sends the key on Conversation > Call, answers an offer with its own key, creates the call with dc_call_new_bound on the listener port (TLS and media share the number), rings, and opens the call window; an incoming ring enables Answer. The Xt loop pumps the call: drain, Opus decode to the playback stream, capture and encode only while our own PTT is held, video frames to the window, ring timeout. dc_local_conn_remote_addr gives the numeric peer address; dc_call_new_bound binds the announced port. dc_call_talking() is now only our own key, dc_call_peer_talking() the peer's (a received PTT used to start our microphone too). The call window has an Answer button and lays the buttons above the video so they stay visible. --call-first and DTCHAT_TEST_TRUST/DTCHAT_TEST_AUTOANSWER/DTCHAT_TEST_PTT drive the test: two UI instances auto-paired, exchanged media-key, rang, answered, reached IN_CALL and carried 200 Opus frames caller->callee with the callee silent (audio out 200 on the receiver, audio in 200 on the sender); screenshot build/mcde-shots/dtchat-t65-live.png. The smoke still passes; test_media_call uses peer_talking; test_media_packet covers the base64 key exchange. The test switch is documented in the security review.
2026-11-17 08:49:25 +00:00

56 lines
2.0 KiB
Makefile

MAINTAINERCLEANFILES = Makefile.in
bin_PROGRAMS = dtchat dtchat-headless
noinst_PROGRAMS = dtchat-demo dtchat-irc
man_MANS = dtchat.1
dtchat_CPPFLAGS = -I$(top_srcdir)/include \
-I$(top_srcdir)/lib/libDtChat -I$(top_builddir)/lib/libDtChat \
-DCDE_INSTALLATION_TOP=\"$(CDE_INSTALLATION_TOP)\"
# The model and the JSON schema helpers live in libDtChat/libDtChatIpc;
# DtInitialize/DTCLIENTLIBS come with T2.7.
dtchat_LDADD = $(top_builddir)/lib/libDtChat/libDtChat.la \
$(top_builddir)/lib/libDtChat/libDtChatIpc.la \
$(top_builddir)/lib/McdeSys/libMcdeSys.la $(XTOOLLIB)
dtchat_SOURCES = main.c ui_main.c ui_accounts.c ui_request.c ui_peer.c \
ui_file.c localui.c ui_call.c demo.c ui_main.h ui_accounts.h \
ui_request.h ui_peer.h ui_file.h localui.h ui_call.h demo.h
dtchat_demo_SOURCES = demo_adapter.c
dtchat_demo_CPPFLAGS = -I$(top_srcdir)/include \
-I$(top_srcdir)/lib/libDtChat -I$(top_builddir)/lib/libDtChat
dtchat_demo_LDADD = $(top_builddir)/lib/libDtChat/libDtChatIpc.la
dtchat_irc_SOURCES = irc_adapter.c
dtchat_irc_CPPFLAGS = -I$(top_srcdir)/include \
-I$(top_srcdir)/lib/libDtChat -I$(top_builddir)/lib/libDtChat \
$(TLS_CPPFLAGS)
dtchat_irc_LDADD = $(top_builddir)/lib/libDtChat/libDtChat.la \
$(top_builddir)/lib/libDtChat/libDtChatIpc.la $(LIBTLS)
dtchat_headless_SOURCES = headless.c
dtchat_headless_CPPFLAGS = -I$(top_srcdir)/include \
-I$(top_srcdir)/lib/libDtChat -I$(top_builddir)/lib/libDtChat
dtchat_headless_LDADD = $(top_builddir)/lib/libDtChat/libDtChat.la \
$(top_builddir)/lib/libDtChat/libDtChatIpc.la $(LIBTLS) $(CRYPTOLIB)
if MCDE_STROPHE
noinst_PROGRAMS += dtchat-xmpp
dtchat_xmpp_SOURCES = xmpp_adapter.c
dtchat_xmpp_CPPFLAGS = -I$(top_srcdir)/include \
-I$(top_srcdir)/lib/libDtChat -I$(top_builddir)/lib/libDtChat
dtchat_xmpp_LDADD = $(top_builddir)/lib/libDtChat/libDtChat.la \
$(top_builddir)/lib/libDtChat/libDtChatIpc.la $(STROPHELIB)
endif
appdefaultsdir = $(CDE_INSTALLATION_TOP)/app-defaults/C
dist_appdefaults_DATA = Dtchat
if SOLARIS
dtchat_LDADD += -lintl
endif