cp on sparc-solaris (SunOS) does not support -u option
authorsdcc-builder <sdcc-builder@4a8a32a2-be11-0410-ad9d-d568d2c75423>
Sat, 20 Aug 2005 17:28:56 +0000 (17:28 +0000)
committersdcc-builder <sdcc-builder@4a8a32a2-be11-0410-ad9d-d568d2c75423>
Sat, 20 Aug 2005 17:28:56 +0000 (17:28 +0000)
git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@3862 4a8a32a2-be11-0410-ad9d-d568d2c75423

device/lib/Makefile.in

index 7465987af74954e91da964358f95063818195a9f..81449e3ba65161287d9a3f083197ab725b30b7c6 100644 (file)
@@ -12,6 +12,12 @@ CPP          = @CPP@
 INSTALL                = @INSTALL@
 CP              = @CP@
 
+ifeq ($(shell uname -s),SunOS)
+CP_U   = $(CP)
+else
+CP_U   = $(CP) -p
+endif
+
 PRJDIR         = ../..
 INCDIR         = $(PRJDIR)/device/include
 ifndef PORTINCDIR
@@ -273,8 +279,8 @@ clean_intermediate-pic16:
 # Compiling and installing everything and runing test
 # ---------------------------------------------------
 install: all installdirs
-       cp -r -u $(BUILDDIR)/* $(sdcc_libdir)
-       cp -r -u ds390 ds400 gbz80 z80 hc08 *.c $(sdcc_libdir)/src
+       $(CP_U) -r $(BUILDDIR)/* $(sdcc_libdir)
+       $(CP_U) -r ds390 ds400 gbz80 z80 hc08 *.c $(sdcc_libdir)/src
        rm -r `find $(sdcc_libdir)/src -name '*.rel' -or -name '*.dump*' -or -name '*.sym' -or -name '*.o' -or -name '*.lst' -or -name '*.asm' -or -name 'CVS'`
 
 # Deleting all the installed files