From b6a5b950d28e0b474fdad160b88bc15314cf9259 Mon Sep 17 00:00:00 2001 From: Kevin Krakauer Date: Fri, 2 Aug 2019 14:04:28 -0700 Subject: Job control: controlling TTYs and foreground process groups. (Don't worry, this is mostly tests.) Implemented the following ioctls: - TIOCSCTTY - set controlling TTY - TIOCNOTTY - remove controlling tty, maybe signal some other processes - TIOCGPGRP - get foreground process group. Also enables tcgetpgrp(). - TIOCSPGRP - set foreground process group. Also enabled tcsetpgrp(). Next steps are to actually turn terminal-generated control characters (e.g. C^c) into signals to the proper process groups, and to send SIGTTOU and SIGTTIN when appropriate. PiperOrigin-RevId: 261387276 --- test/util/BUILD | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'test/util/BUILD') diff --git a/test/util/BUILD b/test/util/BUILD index a1b9ff526..c124cef34 100644 --- a/test/util/BUILD +++ b/test/util/BUILD @@ -183,6 +183,17 @@ cc_test( ], ) +cc_library( + name = "pty_util", + testonly = 1, + srcs = ["pty_util.cc"], + hdrs = ["pty_util.h"], + deps = [ + ":file_descriptor", + ":posix_error", + ], +) + cc_library( name = "signal_util", testonly = 1, -- cgit v1.2.3