File checkinstall-test_with_DESTDIR.patch of Package checkinstall
--- installwatch-0.7.0beta5/Makefile
+++ installwatch-0.7.0beta5/Makefile
@@ -52,7 +52,7 @@
tar -czvC .. -f ../installwatch-$(VERSION).tar.gz installwatch-$(VERSION)
test: install
- gcc $(ALL_CFLAGS) -DLIBDIR=\"$(LIBDIR)\" -o test-installwatch test-installwatch.c $(LIBS)
- $(DESTDIR)$(PREFIX)/bin/installwatch ./test-installwatch
+ gcc $(ALL_CFLAGS) -DLIBDIR=\"$(DESTDIR)$(LIBDIR)\" -o test-installwatch test-installwatch.c $(LIBS)
+ PREFIX=$(DESTDIR)$(PREFIX) $(DESTDIR)$(PREFIX)/bin/installwatch ./test-installwatch
--- installwatch-0.7.0beta5/installwatch
+++ installwatch-0.7.0beta5/installwatch
@@ -3,7 +3,7 @@
#set -x
-PREFIX=#PREFIX#
+PREFIX=${PREFIX:-#PREFIX#}
HACK="PREFIX"
HACK="#$HACK#";