]> skyeroc.xyz Git - dgamelaunch/commitdiff
stuff
authorJoshua Kwan <joshk@triplehelix.org>
Fri, 18 Jun 2004 18:04:36 +0000 (18:04 +0000)
committerJoshua Kwan <joshk@triplehelix.org>
Fri, 18 Jun 2004 18:04:36 +0000 (18:04 +0000)
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@303 db0b04b0-f4d1-0310-9a6d-de3e77497b0e

configure.ac
dgamelaunch.c
dgamelaunch.h

index dfeb6e1933106cdffb41b42dab4f167fb3604927..2fedfc1d1366f72b77494a0eb456c05afc4cd493 100644 (file)
@@ -14,6 +14,7 @@ AC_PROG_YACC
 case "$(uname -s)" in
   Linux | *BSD)
     LIBS="$LIBS -lutil -lcrypt"
+    AC_DEFINE(NOSTREAMS, 1, [Use SVR4 streams support in ttyrec.])
   ;;
 esac
 
@@ -29,10 +30,11 @@ AC_ARG_ENABLE(enable-virus,
 [AC_SUBST(EDITOR, virus.c)], [AC_SUBST(EDITOR, ee.c)])
 
 AC_ARG_WITH(config-file,
-[AS_HELP_STRING([--with-config-file=PATH], [Define the path to the default configuration file.])]
-[configfile=$withval], [configfile=/etc/dgamelaunch.conf])
+[AS_HELP_STRING([--with-config-file=PATH], [Define the path to the default configuration file.])],
+[configfile=$withval], [configfile="/etc/dgamelaunch.conf"])
 
 AC_DEFINE_UNQUOTED(DEFCONFIG, "$configfile", [Path to the default config file.])
 
+AC_CHECK_FUNCS(openpty)
 AC_CONFIG_FILES(Makefile)
 AC_OUTPUT
index 435c1d031724fa1edcba526cb105369ae28c5a5d..68b3cfabacb2453ce3062894416b7560f42d06e6 100644 (file)
@@ -129,7 +129,7 @@ mysetenv (const char* name, const char* value, int overwrite)
 void
 ttyrec_getpty ()
 {
-#ifdef USE_OPENPTY
+#ifdef HAVE_OPENPTY
   if (openpty (&master, &slave, NULL, NULL, NULL) == -1)
     graceful_exit (62);
 #else
index 17e53786badaaa27aaa9b1691497fd5461e5d4f0..72dbeca477a7541bd9ae6e1cea19c9191367d9b0 100644 (file)
@@ -7,12 +7,6 @@
 #include <sys/types.h>
 #include <time.h>
 
-/* Default - should work everywhere */
-#if defined(__linux__) || defined(BSD)
-# define USE_OPENPTY
-# define NOSTREAMS
-#endif
-
 #ifndef ARRAY_SIZE
 # define ARRAY_SIZE(x) (sizeof(x) / sizeof(x[0]))
 #endif