Mercurial > hg > early-roguelike
diff xrogue/acinclude.m4 @ 312:029c1f5c5588
Update the Autoconf files.
These are mostly automatic updates for obsolete macros.
author | John "Elwin" Edwards |
---|---|
date | Tue, 11 May 2021 22:30:03 -0400 |
parents | 3e1146666ae5 |
children |
line wrap: on
line diff
--- a/xrogue/acinclude.m4 Tue May 04 21:03:47 2021 -0400 +++ b/xrogue/acinclude.m4 Tue May 11 22:30:03 2021 -0400 @@ -6,14 +6,10 @@ then AC_CACHE_CHECK([for working curses], mp_cv_curses, [LIBS="$LIBS -lcurses" - AC_TRY_LINK( - [#include <curses.h>], - [chtype a; int b=A_STANDOUT, c=KEY_LEFT; initscr(); ], - mp_cv_curses=yes, mp_cv_curses=no)]) + AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <curses.h>]], [[chtype a; int b=A_STANDOUT, c=KEY_LEFT; initscr(); ]])],[mp_cv_curses=yes],[mp_cv_curses=no])]) if test "$mp_cv_curses" = yes then AC_DEFINE(HAVE_CURSES_H, 1, [Define to 1 if libcurses is requested]) - #AC_DEFINE(HAVE_CURSES_H) CURSES_LIB="-lcurses" fi fi @@ -21,10 +17,7 @@ then AC_CACHE_CHECK([for working ncurses], mp_cv_ncurses, [LIBS="$mp_save_LIBS -lncurses" - AC_TRY_LINK( - [#include <ncurses.h>], - [chtype a; int b=A_STANDOUT, c=KEY_LEFT; initscr(); ], - mp_cv_ncurses=yes, mp_cv_ncurses=no)]) + AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <ncurses.h>]], [[chtype a; int b=A_STANDOUT, c=KEY_LEFT; initscr(); ]])],[mp_cv_ncurses=yes],[mp_cv_ncurses=no])]) if test "$mp_cv_ncurses" = yes then AC_DEFINE(HAVE_NCURSES_H, 1, [Define to 1 if libncurses is requested]) @@ -35,10 +28,7 @@ then AC_CACHE_CHECK([for working pdcurses], mp_cv_pdcurses, [LIBS="$mp_save_LIBS -lpdcurses" - AC_TRY_LINK( - [#include <curses.h>], - [chtype a; int b=A_STANDOUT, c=KEY_LEFT; initscr(); ], - mp_cv_pdcurses=yes, mp_cv_pdcurses=no)]) + AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <curses.h>]], [[chtype a; int b=A_STANDOUT, c=KEY_LEFT; initscr(); ]])],[mp_cv_pdcurses=yes],[mp_cv_pdcurses=no])]) if test "$mp_cv_pdcurses" = yes then AC_DEFINE(HAVE_CURSES_H, 1, [Define to 1 if libcurses is requested]) @@ -49,10 +39,7 @@ then AC_CACHE_CHECK([for working pdcur], mp_cv_pdcur, [LIBS="$mp_save_LIBS -lpdcur" - AC_TRY_LINK( - [#include <curses.h>], - [chtype a; int b=A_STANDOUT, c=KEY_LEFT; initscr(); ], - mp_cv_pdcur=yes, mp_cv_pdcur=no)]) + AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <curses.h>]], [[chtype a; int b=A_STANDOUT, c=KEY_LEFT; initscr(); ]])],[mp_cv_pdcur=yes],[mp_cv_pdcur=no])]) if test "$mp_cv_pdcur" = yes then AC_DEFINE(HAVE_CURSES_H, 1, [Define to 1 if libcurses is requested]) @@ -63,10 +50,7 @@ then AC_CACHE_CHECK([for working peer pdcurses], mp_cv_lpdcurses, [LIBS="$mp_save_LIBS ../pdcurses/pdcurses.a" - AC_TRY_LINK( - [#include "../pdcurses/curses.h"], - [chtype a; int b=A_STANDOUT, c=KEY_LEFT; initscr(); ], - mp_cv_lpdcurses=yes, mp_cv_lpdcurses=no)]) + AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include "../pdcurses/curses.h"]], [[chtype a; int b=A_STANDOUT, c=KEY_LEFT; initscr(); ]])],[mp_cv_lpdcurses=yes],[mp_cv_lpdcurses=no])]) if test "$mp_cv_lpdcurses" = yes then AC_DEFINE(HAVE_CURSES_H, 1, [Define to 1 if libcurses is requested]) @@ -76,12 +60,10 @@ fi AC_CACHE_CHECK([for ESCDELAY variable], [mc_cv_ncurses_escdelay], - [AC_TRY_LINK([], [ + [AC_LINK_IFELSE([AC_LANG_PROGRAM([[]], [[ extern int ESCDELAY; ESCDELAY = 0; - ], - [mc_cv_ncurses_escdelay=yes], - [mc_cv_ncurses_escdelay=no]) + ]])],[mc_cv_ncurses_escdelay=yes],[mc_cv_ncurses_escdelay=no]) ]) if test "$mc_cv_ncurses_escdelay" = yes; then AC_DEFINE(HAVE_ESCDELAY, 1,