modified to install the pic16 headers
[fw/sdcc] / device / include / Makefile.in
index ec5408fac01cb2cd52789c8d2041a55319981eb5..7c3d11a2a4f5e11087a257f0485e7bfefe44282c 100644 (file)
@@ -41,7 +41,10 @@ all:
 # ----------------------------------------------------
 install: all installdirs
        $(CP) -r asm *.h $(sdcc_includedir)
-       find $(sdcc_includedir) -type d -name 'CVS' -exec rm {} \;
+        if [ "`grep pic16 ../../ports.build`" = pic16 ]; then \
+                $(CP) pic16/*.h $(sdcc_includedir)/pic16 ; \
+        fi
+       find $(sdcc_includedir) -type d -name 'CVS' -exec rm {} \;
 
 
 # Deleting all the installed files
@@ -64,6 +67,7 @@ installcheck:
 # ---------------------------------
 installdirs:
        [ -d $(sdcc_includedir) ] || mkdir -p $(sdcc_includedir)
+       [ -d $(sdcc_includedir)/pic16 ] || mkdir -p $(sdcc_includedir)/pic16
 
 
 # Creating dependencies