File scotty-2.1.11.dif of Package scotty

--- tkined/generic/tkiBarchart.c
+++ tkined/generic/tkiBarchart.c
@@ -15,6 +15,7 @@
 #include <stdlib.h>
 #include <math.h>
 #include <ctype.h>
+#include <string.h>
 
 #ifdef HAVE_CONFIG_H
 #include <config.h>
--- tkined/generic/tkiInit.c
+++ tkined/generic/tkiInit.c
@@ -62,11 +62,11 @@
 
     buffersize(1024);
 
-    if (Tcl_PkgRequire(interp, "Tcl", TCL_VERSION, 1) == NULL) {
+    if (Tcl_PkgRequire(interp, "Tcl", TCL_VERSION, 0) == NULL) {
         return TCL_ERROR;
     }
 
-    if (Tcl_PkgRequire(interp, "Tk", TK_VERSION, 1) == NULL) {
+    if (Tcl_PkgRequire(interp, "Tk", TK_VERSION, 0) == NULL) {
         return TCL_ERROR;
     }
 
--- tkined/generic/tkiStripchart.c
+++ tkined/generic/tkiStripchart.c
@@ -15,6 +15,7 @@
 #include <stdlib.h>
 #include <math.h>
 #include <ctype.h>
+#include <string.h>
 
 #ifdef HAVE_CONFIG_H
 #include <config.h>
--- tnm/generic/tnmInt.h
+++ tnm/generic/tnmInt.h
@@ -36,7 +36,10 @@
 #define TnmGetTime TclpGetTime
 #endif
 
+#if TCL_MAJOR_VERSION < 8 || TCL_MAJOR_VERSION == 8 && TCL_MINOR_VERSION < 4
 #define TnmCreateDirectory	TclpCreateDirectory
+#endif
+
 #if TCL_MAJOR_VERSION == 8 && TCL_MINOR_VERSION == 8 && TCL_RELEASE_SERIAL > 2 
 #define TnmStat			TclStat
 #else
--- tnm/generic/tnmUtil.c
+++ tnm/generic/tnmUtil.c
@@ -12,6 +12,18 @@
 #include "tnmInt.h"
 #include "tnmPort.h"
 
+#if TCL_MAJOR_VERSION == 8 && TCL_MINOR_VERSION >= 4 || TCL_MAJOR_VERSION > 8
+int TnmCreateDirectory(char *path)
+{
+	Tcl_Obj *o;
+	int res;
+	o = Tcl_NewStringObj(path, -1);
+	Tcl_IncrRefCount(o);
+        res = Tcl_FSCreateDirectory(o);
+	Tcl_DecrRefCount(o);
+	return res;
+}
+#endif
 
 /*
  *----------------------------------------------------------------------
--- unix/Makefile.in
+++ unix/Makefile.in
@@ -24,24 +24,26 @@
 
 prefix =	@prefix@
 exec_prefix =	@exec_prefix@
+libdir =        @libdir@
+tclscriptdir =  $(libdir)
 
 # Directory in which to install the program scotty:
 BIN_INSTALL_DIR =	$(exec_prefix)/bin
 
 # Directory in which to install dynamic loadable modules:
-LIB_INSTALL_DIR =       $(exec_prefix)/lib
+LIB_INSTALL_DIR =       $(libdir)
 
 # Directory in which dynamic loadable modules are installed:
-LIB_RUNTIME_DIR =       $(exec_prefix)/lib
+LIB_RUNTIME_DIR =       $(libdir)
 
 # Directory in which to install library files belonging to the extension.
-TNM_INSTALL_DIR =	$(prefix)/lib/tnm$(TNM_VERSION)
+TNM_INSTALL_DIR =	$(tclscriptdir)/tnm$(TNM_VERSION)
 
 # Directory in which to install library files belonging to the extension.
-TCL_INSTALL_DIR =	$(prefix)/lib/tcl$(TCL_VERSION)
+TCL_INSTALL_DIR =	$(tclscriptdir)/tcl$(TCL_VERSION)
 
 # Directory in which to install the library of tkined scripts.
-TKI_INSTALL_DIR =	$(prefix)/lib/tkined$(TKI_VERSION)
+TKI_INSTALL_DIR =	$(tclscriptdir)/tkined$(TKI_VERSION)
 
 # Top-level directory for manual entries:
 MAN_INSTALL_DIR =	$(prefix)/man
@@ -690,7 +692,7 @@
 	@for i in ntping straps ; \
 	    do \
 	    echo "Installing $$i"; \
-	    $(INSTALL_PROGRAM) -o root -m 4755 $$i $(BIN_INSTALL_DIR)/$$i; \
+	    $(INSTALL_PROGRAM) -m 4755 $$i $(BIN_INSTALL_DIR)/$$i; \
 	    done
 
 uninstall: tnm-uninstall uninstall-man tki-uninstall
--- unix/configure.in
+++ unix/configure.in
@@ -251,8 +251,8 @@
 AC_CHECK_LIB(ieee, main, [LIBS="$LIBS -lieee"])
 AC_CHECK_LIB(rpc, main, [LIBS="$LIBS -lrpc"])
 AC_CHECK_LIB(rpcsvc, main, [LIBS="$LIBS -lrpcsvc"])
-AC_CHECK_FUNC(res_mkquery, ,
-	AC_CHECK_LIB(resolv, res_mkquery, [LIBS="$LIBS -lresolv"]))
+AC_CHECK_FUNC(res_gethostbyname, ,
+	AC_CHECK_LIB(resolv, res_gethostbyname, [LIBS="$LIBS -lresolv"]))
 
 #----------------------------------------------------------------------------
 #	Checks for various include files missing on some machines.
openSUSE Build Service is sponsored by