mirror of
https://github.com/ghostty-org/ghostty.git
synced 2026-04-18 05:20:29 +00:00
* consolidate *.c files into a single file * consolidate ProcessInfo enums into a single enum
35 lines
830 B
C
35 lines
830 B
C
#if ZIG_TARGET == freebsd
|
|
#include <termios.h> // ioctl and constants
|
|
#include <libutil.h> // openpty
|
|
#include <stdlib.h> // ptsname_r
|
|
#include <unistd.h> // tcgetpgrp
|
|
#endif
|
|
|
|
#if ZIG_TARGET == linux
|
|
#define _GNU_SOURCE // ptsname_r
|
|
#include <pty.h> // openpty
|
|
#include <stdlib.h> // ptsname_r
|
|
#include <sys/ioctl.h> // ioctl and constants
|
|
#include <unistd.h> // tcgetpgrp, setsid
|
|
#endif
|
|
|
|
#if ZIG_TARGET == macos
|
|
#include <sys/ioctl.h> // ioctl and constants
|
|
#include <sys/ttycom.h> // ioctl and constants for TIOCPTYGNAME
|
|
#include <sys/types.h>
|
|
#include <unistd.h> // tcgetpgrp
|
|
#include <util.h> // openpty
|
|
|
|
#ifndef tiocsctty
|
|
#define tiocsctty 536900705
|
|
#endif
|
|
|
|
#ifndef tiocswinsz
|
|
#define tiocswinsz 2148037735
|
|
#endif
|
|
|
|
#ifndef tiocgwinsz
|
|
#define tiocgwinsz 1074295912
|
|
#endif
|
|
#endif
|