]> ncurses.scripts.mit.edu Git - ncurses.git/blobdiff - ncurses/base/MKunctrl.awk
ncurses 5.7 - patch 20090606
[ncurses.git] / ncurses / base / MKunctrl.awk
index 4bebf3cf4cc75481ffac3095b9a2b871df13a81a..2c37d442c9d38e8818bc7066591878ade3d41ac6 100644 (file)
@@ -1,6 +1,6 @@
-# $Id: MKunctrl.awk,v 1.22 2008/05/31 19:36:11 tom Exp $
+# $Id: MKunctrl.awk,v 1.25 2009/04/18 23:43:49 tom Exp $
 ##############################################################################
-# Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.                #
+# Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.                #
 #                                                                            #
 # Permission is hereby granted, free of charge, to any person obtaining a    #
 # copy of this software and associated documentation files (the "Software"), #
@@ -46,9 +46,8 @@ BEGIN {
                print ""
        }
 END    {
-               print "NCURSES_EXPORT(NCURSES_CONST char *) _nc_unctrl (SCREEN *sp, chtype ch)"
+               print "NCURSES_EXPORT(NCURSES_CONST char *) safe_unctrl(SCREEN *sp, chtype ch)"
                print "{"
-
                blob=""
                offset=0
                if (bigstrings) {
@@ -101,6 +100,7 @@ END {
                blob = blob "\"";
 
                print ""
+               printf "#if NCURSES_EXT_FUNCS\n";
                if (bigstrings) {
                        blob = blob "\n/* printable values in 128-255 range */"
                        printf "static const short unctrl_c1[] = {"
@@ -135,6 +135,7 @@ END {
                        }
                }
                print "};"
+               print "#endif /* NCURSES_EXT_FUNCS */"
                blob = blob "\"\n"
 
                print ""
@@ -185,6 +186,6 @@ END {
                print  ""
                print  "NCURSES_EXPORT(NCURSES_CONST char *) unctrl (chtype ch)"
                print  "{"
-               print  "\treturn _nc_unctrl(SP, ch);"
+               print  "\treturn safe_unctrl(CURRENT_SCREEN, ch);"
                print  "}"
        }