diff -wbBur checkinstall-1.6.2/checkinstall checkinstall-1.6.2.my/checkinstall
--- checkinstall-1.6.2/checkinstall	2009-12-26 19:17:24.000000000 +0000
+++ checkinstall-1.6.2.my/checkinstall	2010-01-15 14:37:21.000000000 +0000
@@ -869,7 +869,7 @@
 
 ################################################################
 # User-configurable variables were moved to the checkinstallrc #
-# file which is probably found at /usr/local/lib/checkinstall  #          
+# file which is probably found at /usr/lib/checkinstall        #
 #                                                              #
 #                  DO NOT modify them here!!                   #
 ################################################################
@@ -1851,11 +1851,11 @@
  COMPRESS="gzip -9"
  COMPRESS_EXT=.gz
  
- for d in ./usr/local/man/man* ./usr/local/man/*/man* ./usr/local/info \
- 	./usr/local/share/man/man* ./usr/local/share/man/*/man* \
- 	./usr/local/share/info \
- 	./usr/local/kerberos/man \
- 	./usr/local/share/doc/*/man/man* ./usr/local/lib/*/man/man* \
+ for d in ./usr/man/man* ./usr/man/*/man* ./usr/info \
+ 	./usr/share/man/man* ./usr/share/man/*/man* \
+ 	./usr/share/info \
+ 	./usr/kerberos/man \
+ 	./usr/share/doc/*/man/man* ./usr/lib/*/man/man* \
  	././usr/man/man* ./usr/man/*/man* ./usr/info \
  	./usr/share/man/man* ./usr/share/man/*/man* ./usr/share/info \
  	./usr/kerberos/man ./usr/X11R6/man/man* ./usr/lib/perl5/man/man* \
diff -wbBur checkinstall-1.6.2/checkinstallrc-dist checkinstall-1.6.2.my/checkinstallrc-dist
--- checkinstall-1.6.2/checkinstallrc-dist	2008-11-11 19:10:34.000000000 +0000
+++ checkinstall-1.6.2.my/checkinstallrc-dist	2010-01-15 14:37:21.000000000 +0000
@@ -16,7 +16,7 @@
 DEBUG=0
 
 # Location of the "installwatch" program
-INSTALLWATCH_PREFIX="/usr/local"
+INSTALLWATCH_PREFIX="/usr"
 INSTALLWATCH=${INSTALLWATCH_PREFIX}/bin/installwatch
 
 # Location of the makepkg program. "makepak" is the default, and is 
diff -wbBur checkinstall-1.6.2/installwatch/installwatch.c checkinstall-1.6.2.my/installwatch/installwatch.c
--- checkinstall-1.6.2/installwatch/installwatch.c	2008-11-16 16:20:53.000000000 +0000
+++ checkinstall-1.6.2.my/installwatch/installwatch.c	2010-01-15 14:37:21.000000000 +0000
@@ -3077,9 +3077,12 @@
 	return result;
 }
 
-int scandir(	const char *dir,struct dirent ***namelist,
-		int (*select)(const struct dirent *),
-		int (*compar)(const void *,const void *)	) {
+extern int scandir (__const char *__restrict dir,
+		    struct dirent ***__restrict namelist,
+		    int (*select) (__const struct dirent *),
+		    int (*compar) (__const struct dirent **,
+				  __const struct dirent **))
+{
 	int result;
 
 	if (!libc_handle)
@@ -3689,9 +3692,13 @@
 	return result;
 }
 
-int scandir64(	const char *dir,struct dirent64 ***namelist,
-		int (*select)(const struct dirent64 *),
-		int (*compar)(const void *,const void *)	) {
+extern int scandir64 (__const char *__restrict dir,
+		      struct dirent64 ***__restrict namelist,
+		      int (*select) (__const struct dirent64 *),
+		      int (*compar) (__const struct dirent64 **,
+				    __const struct dirent64 **))
+//     __nonnull ((1, 2))
+{
 	int result;
 
 	if (!libc_handle)
Only in checkinstall-1.6.2.my/installwatch: installwatch.o
Only in checkinstall-1.6.2.my/installwatch: installwatch.so
Only in checkinstall-1.6.2.my/installwatch: localdecls.h
diff -wbBur checkinstall-1.6.2/installwatch/Makefile checkinstall-1.6.2.my/installwatch/Makefile
--- checkinstall-1.6.2/installwatch/Makefile	2008-11-16 16:20:53.000000000 +0000
+++ checkinstall-1.6.2.my/installwatch/Makefile	2010-01-15 14:39:21.000000000 +0000
@@ -4,14 +4,14 @@
 # Well, the only configurable part is the following variable.
 # Make sure the directory you specify exists.
 
-PREFIX=/usr/local
+PREFIX=/usr
 
 # End of configurable part
 
 VERSION=0.7.0beta7
 
-BINDIR=$(PREFIX)/bin
-LIBDIR=$(PREFIX)/lib
+BINDIR=$(DESTDIR)$(PREFIX)/bin
+LIBDIR=$(DESTDIR)$(PREFIX)/lib
 
 all: installwatch.so
 
Only in checkinstall-1.6.2.my/locale: checkinstall-de.mo
Only in checkinstall-1.6.2.my/locale: checkinstall-es.mo
Only in checkinstall-1.6.2.my/locale: checkinstall-id.mo
Only in checkinstall-1.6.2.my/locale: checkinstall-it.mo
Only in checkinstall-1.6.2.my/locale: checkinstall-ja.mo
Only in checkinstall-1.6.2.my/locale: checkinstall-no.mo
Only in checkinstall-1.6.2.my/locale: checkinstall-pt_BR.mo
Only in checkinstall-1.6.2.my/locale: checkinstall-ru.mo
Only in checkinstall-1.6.2.my/locale: checkinstall-zh_CN.mo
diff -wbBur checkinstall-1.6.2/Makefile checkinstall-1.6.2.my/Makefile
--- checkinstall-1.6.2/Makefile	2008-11-12 02:43:53.000000000 +0000
+++ checkinstall-1.6.2.my/Makefile	2010-01-15 14:37:21.000000000 +0000
@@ -1,10 +1,10 @@
 # $Id: Makefile,v 1.6.2.1 2008/11/09 07:48:18 izto Exp $
 
 # Where to install.
-PREFIX=/usr/local
-BINDIR=$(PREFIX)/sbin
-LCDIR=$(PREFIX)/lib/checkinstall/locale
-CONFDIR=$(PREFIX)/lib/checkinstall
+PREFIX=/usr
+BINDIR=$(DESTDIR)/$(PREFIX)/sbin
+LCDIR=$(DESTDIR)/$(PREFIX)/share/locale
+CONFDIR=$(DESTDIR)/etc/checkinstall
 
 all:
 	for file in locale/checkinstall-*.po ; do \
@@ -25,7 +25,11 @@
 	export
 	$(MAKE) -C installwatch install
 	
+	mkdir -p $(DESTDIR)/usr/bin
 	mkdir -p $(BINDIR)
+	mkdir -p $(CONFDIR)
+	mkdir -p $(DESTDIR)/etc/checkinstall
+	
 	install checkinstall makepak $(BINDIR)
 	for file in locale/*.mo ; do \
 		LANG=`echo $$file | sed -e 's|locale/checkinstall-||' \
