X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=device%2Finclude%2FMakefile.in;h=70fb7a6693d1e74caf98f6e287e9089ffdbdd9a3;hb=bfd7431078b6d902b991d098798911bd612bf670;hp=c98bd1251cc1abd5a1a52fef408c7a57299089eb;hpb=b09af35f2f1cde7649d3ac4a6f5d2af6d97895a0;p=fw%2Fsdcc diff --git a/device/include/Makefile.in b/device/include/Makefile.in index c98bd125..70fb7a66 100644 --- a/device/include/Makefile.in +++ b/device/include/Makefile.in @@ -7,12 +7,12 @@ VERSIONHI = @VERSIONHI@ VERSIONLO = @VERSIONLO@ VERSIONP = @VERSIONP@ -SHELL = /bin/sh -CPP = @CPP@ -INSTALL = @INSTALL@ +SHELL = /bin/sh +CPP = @CPP@ +INSTALL = @INSTALL@ CP = @CP@ -PRJDIR = .. +PRJDIR = .. prefix = @prefix@ exec_prefix = @exec_prefix@ @@ -26,6 +26,10 @@ man2dir = $(mandir)/man2 infodir = @infodir@ srcdir = @srcdir@ +include_dir_suffix = @include_dir_suffix@ + +sdcc_includedir = $(DESTDIR)$(datadir)/$(include_dir_suffix) + CPPFLAGS = @CPPFLAGS@ -I$(PRJDIR) @@ -33,17 +37,32 @@ CPPFLAGS = @CPPFLAGS@ -I$(PRJDIR) # ------------------------------------------ all: - -# Compiling and installing everything and runing test -# --------------------------------------------------- +# Compiling and installing everything and running test +# ---------------------------------------------------- install: all installdirs - $(CP) *.h $(datadir)/sdcc51inc/ + $(CP) -r asm *.h $(sdcc_includedir) + if [ "`grep mcs51 ../../ports.build`" = mcs51 ]; then \ + $(CP) mcs51/*.h $(sdcc_includedir)/mcs51 ; \ + fi + if [ "`grep '^pic$$' ../../ports.build`" = pic ]; then \ + $(CP) pic/*.h pic/*.inc pic/*.txt $(sdcc_includedir)/pic ; \ + fi + if [ "`grep pic16 ../../ports.build`" = pic16 ]; then \ + $(CP) pic16/*.h $(sdcc_includedir)/pic16 ; \ + fi + if [ "`grep z80 ../../ports.build`" = z80 ]; then \ + $(CP) z80/*.h $(sdcc_includedir)/z80 ; \ + fi + if [ "`grep hc08 ../../ports.build`" = hc08 ]; then \ + $(CP) hc08/*.h $(sdcc_includedir)/hc08 ; \ + fi + rm -rf `find $(sdcc_includedir) -type d -name '.svn'` # Deleting all the installed files # -------------------------------- uninstall: - for hdr in *.h; do rm -f $(datadir)/$$hdr; done + rm -rf $(sdcc_includedir) # Performing self-test @@ -59,7 +78,12 @@ installcheck: # Creating installation directories # --------------------------------- installdirs: - [ -d $(datadir)/sdcc51inc ] || mkdir -p $(datadir)/sdcc51inc + [ -d $(sdcc_includedir) ] || mkdir -p $(sdcc_includedir) + [ -d $(sdcc_includedir)/mcs51 ] || mkdir -p $(sdcc_includedir)/mcs51 + [ -d $(sdcc_includedir)/pic ] || mkdir -p $(sdcc_includedir)/pic + [ -d $(sdcc_includedir)/pic16 ] || mkdir -p $(sdcc_includedir)/pic16 + [ -d $(sdcc_includedir)/z80 ] || mkdir -p $(sdcc_includedir)/z80 + [ -d $(sdcc_includedir)/hc08 ] || mkdir -p $(sdcc_includedir)/hc08 # Creating dependencies