and support the _HEADERS variables as well
authorPierre Habouzit <madcoder@debian.org>
Sat, 11 Nov 2006 00:06:24 +0000 (01:06 +0100)
committerPierre Habouzit <madcoder@debian.org>
Sat, 11 Nov 2006 00:06:24 +0000 (01:06 +0100)
Signed-off-by: Pierre Habouzit <madcoder@debian.org>
am/footer.mk
madtty/Makefile.in

index 25fae74..0acffb8 100644 (file)
@@ -102,6 +102,16 @@ install-SCRIPTS/%::
 
 install:: $(foreach v,$(filter %_SCRIPTS,$(.VARIABLES)),$(patsubst %_SCRIPTS,install-SCRIPTS/%,$v))
 
+##
+##  rules for *_HEADERS
+##
+
+install-HEADERS/%::
+       $(if $($*dir), $(INSTALL_DIR) $(DESTDIR)$($*dir))
+       $(if $($*dir), $(INSTALL_DATA) $($*_HEADERS) $(DESTDIR)$($*dir))
+
+install:: $(foreach v,$(filter %_HEADERS,$(.VARIABLES)),$(patsubst %_HEADERS,install-HEADERS/%,$v))
+
 
 ########################################################################}}}#
 #[ Candy ]##############################################################{{{#
index bb58d1d..f126861 100644 (file)
@@ -3,14 +3,17 @@ include $(DEPTH)/am/header.mk
 
 DISTCLEANFILES = madtty.pc
 
-pkgconfigdir=$(libdir)/pkgconfig
-pkgconfig_DATA = madtty.pc
+
+include_HEADERS = madtty.h
 
 lib_LIBRARIES = libmadtty
 libmadtty_SOURCES  = inject.c inject_csi.c inject_csi.h madtty.h rote.c rote_keymap.c roteprivate.h
 libmadtty_CPPFLAGS = -Wno-error
 libmadtty_VERSION  = @PACKAGE_VERSION@
 
-include $(DEPTH)/am/footer.mk
+pkgconfigdir=$(libdir)/pkgconfig
+pkgconfig_DATA = madtty.pc
 
+
+include $(DEPTH)/am/footer.mk
 # vim:set ft=automake: